mrKlar / PagedDragDropGrid

An Android ViewGroup that implements a paged grid with drag'n'drop moveable items
406 stars 184 forks source link

Preventing modifications while in drag #31

Open paour opened 11 years ago

paour commented 11 years ago

My application is displaying real-time data in a PDDG and if I allow it to change anything in the view hierarchy (which causes a layout) while a drag is in progress, the drag is completely messed up.

I've added a set of methods to the adapter to let the client know that a drag has started / ended. It might be better to add a listener interface and a isInDrag() method to handle the same thing, so I won't add a pull request for my changes.

mrKlar commented 11 years ago

Ok, good catch, it is a new feature.

paour commented 11 years ago

Call the notifyDataChanged method, which will cause the grid to query the adapter.

Pierre Le 10 août 2013 18:49, "loganek" notifications@github.com a écrit :

HI, I would like to know, how can I dynamically insert new item to a grid? I many solutions, but they didn't work for me.

— Reply to this email directly or view it on GitHubhttps://github.com/mrKlar/PagedDragDropGrid/issues/31#issuecomment-22443037 .