菜单按钮未显示在操作栏上
我有一个在 Honeycomb 上运行的应用程序,它使用操作栏。在 XLarge 模拟器上,操作栏显示为带有图标、左侧的应用程序名称和右侧的下拉菜单。但是,如果我在小于 XLarge(例如“大”或“正常”)的模拟器上运行此程序,则我不会在操作栏上看到下拉菜单。因此,菜单只能通过使用 PgUp 键来使用。有人有解决这个问题的办法吗?
I have an application running on Honeycomb that uses an Action Bar. On an XLarge emulator the Action Bar appears as documented with an icon, application name on the left and a menu dropdown on the right. If however I run this on an emulator that is smaller that XLarge e.g. Large or Normal, I do not get the menu dropdown on the Action Bar. Menu is therefore only available by use of the PgUp key. Anyone have a solution to this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您需要首先彻底阅读操作栏开发指南。我怀疑您的问题是您所得到的行为可能与您正在使用的不同虚拟设备的 sdk 级别设置有关。使用两个虚拟设备进行尝试,这两个虚拟设备设置了不同的显示分辨率/尺寸但使用相同的 SDK 级别。您应该得到类似的相同行为。
Android 开发者博客中的这篇文章对从旧的菜单按钮到使用新的操作栏和操作溢出列表的设计过渡进行了很好的讨论。
You will want to first thoroughly review the Dev Guide on Action Bar. I suspect that your problem is that the behavior you are getting may relate to the the sdk level set for the different virtual devices you are using. Try it with two virtual devices that are set up with differing display resolutions/sizes but that are using the same sdk level. You should get similar same behavior.
This post in the Android Developers blog has a good discussion of the design transition from the old Menu Button to use of the new Action Bar and Action Overflow list.