机器人:从库中删除一个视图 [英] android: remove a view from a gallery

查看:71
本文介绍了机器人:从库中删除一个视图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我用我的应用程序图库视图。该应用程序的设计,这样我可以拖放从画廊景色。

I'm using a Gallery view in my app. The app is designed so that I can drag and drop a view from that Gallery.

如何删除从图库中拖看法?

How can I remove the dragged view from the Gallery?

推荐答案

您从底层的适配器将其删除。如果你正确地做到这一点,图库将刷新自己。否则,调用 notifyDataSetChanged()来触发适配器上画廊更新。

You remove it from the underlying adapter. If you do this correctly, the Gallery will refresh itself. Otherwise, call notifyDataSetChanged() on the adapter to trigger a Gallery update.

这篇关于机器人:从库中删除一个视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆