Be clement iam new to android and groups.
Ive fetched Lorentzos SwipeCards Lib from 
https://github.com/Diolor/Swipecards.
Previously i must learn to implement a BaseAdapter to provide the method 
getView that was called from Lorentzos SwipeFlingAdapterView.
I implemented getView like the common Tutorials for ListViews and add some 
items to the list. I couldt update the cardStack with notifyDataSetChanged(), 
he described it as issue.
After a lot of tries i noticed that SwipeFlingAdapterView issnt a common 
ListView. In Line 140 in swipeFlingAdapterView he calls 
mAdapter.getView(startingIndex, 
null, this); manually.
So now i try to change this part of the code and first of all i want fill 
the convertView param of getView().
With Lorentzos implementation, a call of list.add() and 
notifyDataSetChanged() must rebuild the whole Cardstack again.
Even iam a newbie but in all tutorials about ListViews (Yes ive seen it is 
an AdapterView but do not understand this way) something like this will 
managed inside the sdk.
Is Lorentzos way okay and if it is, is it right if i hold the empty 
inflated view of the cards in items.xml to give it back as recycled view 
manually?
Can i implement a method that renews the important part of CardStack 
immediately when i call notifyDataSetChanged() or...
If you have a bit time for me, how can i get a reference to the onLayout 
Hook to say: "Render the whole stack again" from my activity respectively 
my fragment (Like the Buttons left and right, implemented in 
MyActivity.java Line 105)?
My intention is to made a onclick undo button that adds an Element at list 
position 0 but with the manually implemented getView call, the stack will 
upgraded only after the next swype.
The Element 0 is gone and the new Element on 0 will removed from List, dead 
end.

Thank you

Sry @ lorentzo but ive searched for a idependetly opinion and give back 
what i have, after my project works.
Your issue: "how to implement a undo button", only works immidiatly if it 
is the last element, If the view is visible, there is no way to add an item 
at position 0. 0 referenceing the visble/touchable card.

-- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/android-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-developers/753f9c00-819b-4f13-9fed-38374cd3e48c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to