adding items to expandable list view by drag and drop android

你说的曾经没有我的故事 提交于 2019-12-11 05:18:35

问题


how to add items to the expandable list by drag and drop ?e.g If you drag and drop some text it should be added in expandable list.


回答1:


You would need to draw a custom component see this page for more information:

http://developer.android.com/guide/topics/ui/custom-components.html.

You would need to override the draw method and draw your own list view as well as where ever your dragging your items from. This is a complicated task and may seem daunting but I haven't really seen anyone do a drag and drop on android before. You may be the first!

If you need to simply reorder your listview then you should check out this thread:

reordering of listview items by drag and drop using android



来源:https://stackoverflow.com/questions/7136386/adding-items-to-expandable-list-view-by-drag-and-drop-android

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!