如何将一个实现Android的API 7 NumberPicker? [英] How would one implement a NumberPicker in Android API 7?

查看:112
本文介绍了如何将一个实现Android的API 7 NumberPicker?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有一个在API 11 NumberPicker小部件,但我为建设7.我怎么会去实现一个最低的API?是否有一个自定义窗口小部件,我可以使用,还是有办法让那个弥补的DatePicker / TimePicker?

There's a NumberPicker widget in API 11, but I'm building for a minimum API of 7. How would I go about implementing one? Is there a custom widget that I can use, or is there a way to get at the components that make up DatePicker / TimePicker?

推荐答案

我觉得这是一个非常良好的和灵活的因为有当被问到这个问题的一些现成的方案可以在2012年初的API级别。

I find this one very good and flexible given that there were few ready made options available at that api level at the beginning of 2012 when this question was asked.

HTTP://$c$c.google.com/p/android-wheel/

编辑: 因此,如果IOS有什么类似的外观控件。这不会使这个答案不错。 Android是关于选择的自由。此外,该控件的外观取决于风格。带走的阴影,加蓝的亮点,它看起来与Android的4时间选择器这是什么OP问了。

So what if IOS has a similar looking control. That does not make this answer bad. Android is about freedom of choice. Besides, the look of this control is dependent on styles. Take away the shadow, add blue highlights and it looks identical to the Android 4 time picker which is what the OP was asking for.

我指着一个可能的解决方案,以一个人的问题。我不主张Android应用程序应该像iOS应用程序,我个人恨都是很移植,使他们有他们的IOS版本的克隆Android应用程序。有些人确实是的fanboys。

I am pointing to a possible solution to a persons problem. I am NOT advocating that Android apps should look like IOS apps and I personally hate Android apps that are badly ported so they are a clone of their IOS versions. Some people really are fanboys.

这篇关于如何将一个实现Android的API 7 NumberPicker?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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