GridView控件,如Android窗口小部件具有可变长度 [英] GridView-like Android widget with variable lengths

查看:205
本文介绍了GridView控件,如Android窗口小部件具有可变长度的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有一个现有的Andr​​oid小工具第三方实现,看起来像一个 GridView控件但是支持可变高度的项目?我需要一个图像,但当然一个任意的意见将工作作品。内存管理是非常重要的,这样的观点和位图可被回收。

Is there an existing Android widget third-party implementation that looks like a GridView but supports variable height items? I need one for images, but of course one that works with arbitrary views will work. Memory management is important, such that the Views and the bitmaps may be recycled.

或者,一个方法来转换 GridView控件源$ C ​​$ C做到这一点?

Or, a way to convert GridView source code to do this?

网格的一个例子:

1A 2A 3A

1A 2A 3B

1A 2B 3C

第一栏标为1A(相对高度1)1项,第二个包含标记为2A(相对高度2/3)和2B(相对高度1/3)两个项目。第三列包含三个项目(均为相对高度1/3)。

The first column contains 1 item labeled as 1A (relative height 1), the second one contains two items labeled as 2A (relative height 2/3) and 2B (relative height 1/3). The third column contains three items (all of them with relative height 1/3).

推荐答案

我想你正在寻找在MS Windows 8中类似VariableSizedWrapGrid我认为是没有为Android类似的事情。在<一个也许建议href=\"http://stackoverflow.com/questions/11227597/gridview-with-dynamic-number-of-colums-in-each-row\">this SO线程会帮助你。

I suppose you are looking for something like VariableSizedWrapGrid in MS Windows 8. I think there is no a similar thing for Android. Maybe suggestions in this SO thread will help you.

这篇关于GridView控件,如Android窗口小部件具有可变长度的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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