如何手动重新排序Android的一个ListView? [英] How can you manually reorder a ListView in Android?

查看:438
本文介绍了如何手动重新排序Android的一个ListView?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Android的一个ListView需要必须手动重新排序的能力。一个例子是Android的音乐播放器应用程序中,当你可以在播放列表中更改曲目的顺序。我知道如何编程方式更改ListView的顺序,但不知道如何做到这一点的问候触摸和幻灯片的方式,可以在音乐播放器应用程序被发现。

I have a ListView in Android that needs to have the ability to be manually reordered. An example would be within Android's Music Player application, when you can change the order of tracks in a playlist. I know how to programmatically change the order of a ListView, but not how to do it in regards to a touch and slide approach that can be found in the Music Player application.

由于提前,

groomsy。

推荐答案

有什么在当下这个框架下,你需要看的音乐源$ C ​​$ C 获得如何实现这一点的想法。您还可以,当然,拷贝过来的相关执行的部分,你认为合适。

There's nothing in the framework for this at the moment, you'll need to look at the Music source code to get an idea of how to implement this. You can also, of course, copy over parts of the relevant implementation as you see fit.

这篇关于如何手动重新排序Android的一个ListView?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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