What I need to have is a layout which
- is vertically (only, not horizontally) scrollable
- lays out its children like in GridView, but
- automatically use as many colums as possible, so they fit layout’s width
- if total count of its children isn’t divisible by number of columns, last row centers its elements inside
- it enables animations while swapping children – I need to sort them all with some algorithm and then update their positions according to received order.
I’ve been trying to subclass TableLayout and GridView in order to implement missing features, but with no luck for now. Could you give me some hint in which way should I go? What classes subclass / combine?
The hardest part is the animation requirement, I have no idea how to achieve that kind of animation (I’m targeting Android 3.0, so I can use ObjectAnimators).
OK, There absolutely no such thing, did it my way.