如何更改“全局区域” Google TV 应用的内容/大小?
我已阅读 Google TV 设计模式文章,但仍然无法理解弄清楚如何更改默认的“全局”区域大小/位置或如何让多个项目显示在其中。
有一些(对我来说)模糊的陈述。例如:“因为全局区域在应用程序的整个生命周期中持续存在,所以您不应该允许它占用太多的屏幕空间。”。 (好的,我如何在布局中更改它?)
然后它指出全局区域“[...] 包含应用程序层次结构中的所有顶级 'global' 项。 ..]”。然后继续说明“它还包含您的应用程序的所有类别[...]”
什么被视为全局项目?具有“LAUNCHER”和“MAIN”<意图过滤器>的活动类别和动作? (尝试过,但没有喜悦)
“类别”是什么意思?每个活动的
我已经运行了与片段相关的 SDK 的 ApiDemos 代码,但它并没有让我感到惊讶。我已经成功移植了现有应用程序的一部分来扩展 Fragment 和 ListFragment,但我一生都无法弄清楚这一点。
I've read the Google TV Design Patterns article and still can't figure out how to change the default "global" zone size/position or how to get more than one item to show up in it.
There are some vague (to me) statements. E.g.: "Because the global zone persists throughout the life of the application, you should not allow it to take up too much screen space.". (OK, how do I change it in the layout?)
It then states that the global zone "[...] holds all of the top-level 'global' items in your application hierarchy [...]". Then goes on to state "It also contains all the categories for your application [...]"
What is considered a global item? An activity with a "LAUNCHER" and "MAIN" <intent-filter> category and action? (Tried that and no joy)
What do "categories" mean? Categories as defined in each activity's <intent-filter> "category" manifest entry? (Tried that too and no joy)
I've run through the SDK's ApiDemos code relating to Fragments and it's not jumping out at me. I have successfully ported part of an existing app to extend Fragment and ListFragment but for the life of me can't figure this one out.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
全局区域可以通过您希望大小的片段来实现。不要求您使用其他东西,例如 ActionBar。
The global zone could be implemented by a fragment that is the size you wish it to be. There are no requirements that you use something else, like an ActionBar.