导航抽屉(Google+上与YouTube的) [英] Navigation Drawer (Google+ vs. YouTube)

查看:173
本文介绍了导航抽屉(Google+上与YouTube的)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有谁知道如何实现像一些当今的顶级应用程序的滑动菜单?

其他堆栈溢出<一href="http://stackoverflow.com/questions/11328895/facebook-lide-slideout-menu-not-using-that-library">questions还没有对如何做到这一点的任何答案,所以我试图收集尽可能多的信息,以帮助他人。所有我提到下面的应用程序确实实现滑动菜单中的一个伟大的工作。

1。谷歌加(截至12年7月7日)

您只能通过单击左上角的G +标志的第一个屏幕转到第二个屏幕。请注意,从它的整个屏幕上移动的位置和获得的轻推到屏幕右侧的(包括操作栏)。要回到你可以在右侧滑入焦点,也可以再次点击G +图标,第一个画面。

2。 YouTube的(截至12年7月7日)

您可以使用两种方法去从第一屏第二个屏幕。您可以点击YouTube标志的左上方,也可以使用滑动手势将其移动到右侧。这是从G +的应用程序已经不同。其次,你可以看到,操作栏原地踏步(与G +)。最后,让原来的画面回它的工作原理就像G +。

应用程序

如果您想体验什么是美丽的滑动菜单的外观和感觉下载:

  1. <一个href="https://play.google.com/store/apps/details?id=fr.epicdream.beamy&feature=nav_result#?t=W251bGwsMSwxLDMsImZyLmVwaWNkcmVhbS5iZWFteSJd">Prixing
  2. <一个href="https://play.google.com/store/apps/details?id=com.evernote&feature=nav_result#?t=W251bGwsMSwxLDMsImNvbS5ldmVybm90ZSJd">Evernote
  3. <一个href="https://play.google.com/store/apps/details?id=com.spotify.mobile.android.ui&feature=search_result#?t=W251bGwsMSwxLDEsImNvbS5zcG90aWZ5Lm1vYmlsZS5hbmRyb2lkLnVpIl0.">Spotify
解决方案

编辑#3:

的抽屉式导航模式正式在Android文档中描述!

请查看以下链接:

  • 设计文档的可发现的 这里
  • 开发者文档的可发现的 <一个href="http://developer.android.com/training/implementing-navigation/nav-drawer.html">here.

编辑#2:

罗马Nurik(一个Android设计工程师在谷歌)已经确认推荐的行为是打开抽屉(如YouTube应用程序)时,不动的操作栏。看到这个 Google+的帖子


编辑#1:

我刚才回答了这个问题,但我回来再次强调, Prixing具有最好的弹出菜单有...迄今为止。这绝对是美丽的,完美流畅,并把Facebook的,谷歌和YouTube汗颜。 EverNote的是pretty的太好了...但还是不完美的,因为Prixing。请查看 这一系列帖子在弹出的菜单中是如何实现的(从莫属首席开发人员在Prixing自己!)。


原来的答案:

亚当·鲍威尔和理查德·富尔彻谈论这个在 49:47 - 52:50 在谷歌I / O谈话名为导航Android中。

要总结自己的答案,因为这张贴滑出导航菜单的日期是的没有的的Andr​​oid应用程序的设计标准正式组成部分。正如你可能已经发现,目前旗下有这个功能没有原生支持,但有谈论使之成为一个除了支持包的即将到来的版本。

至于在YouTube和G +的应用程序,它似乎奇怪的是,他们的行为有所不同。我最好的猜测是,之所以YouTube应用程序修复了操作栏的位置,

  1. 其中一个最重要的导航选项使用YouTube应用程序的用户是搜索,这是在搜索查看操作栏中的执行。它将使意义,使操作栏静在这方面,因为这将允许用户的总是的必须寻找新的视频选项。

  2. 在G +应用程序使用了 ViewPager 来显示其内容,因此提出具体的布局内容拉出菜单(即在操作栏的一切)止跌T太大的意义。刷卡应该提供的页面之间导航,而不是一个全球导航的装置的装置。这可能是为什么他们决定不同的方法来做这在G +应用程序比他们的YouTube应用程序一样。

    在另一方面,检查了谷歌Play应用的另一个版本的拉出来的菜单中(当你在最左边的页面,向左滑动和拉出来,半页​​菜单出现)。

您说得对,这不是很一致的行为,但它似乎并不像有Android团队中的100%达成共识,如何这种行为应该没有实现。我也不会感到惊讶,如果在未来的应用程序进行更新,以便在这两个应用程序导航是相同的(他们似乎非常热衷于使航行在所有谷歌制作的应用程序相一致的谈话)。

Does anyone know how to implement a sliding menu like some of the top apps of today?

Other Stack Overflow questions haven't had any answers on how to do this, so I'm trying to gather as much info to help out others. All the applications I mention below do a great job of implementing the slide menu.

1. Google Plus (as of 7/7/12)

You can only go from the first screen to the second screen by clicking the G+ logo in the upper left hand corner. Notice that the entire screen moves from it's position and get's nudged to the right side of the screen (including the action bar). To get back to the first screen you can either slide the right side back into focus or you can click the G+ icon again.

2. YouTube (as of 7/7/12)

You can go from the first screen to second screen using two methods. Either click the YouTube logo in the upper left, or you can use a swipe gesture to move it to the right. This is already different from the G+ app. Secondly, you can see that the action bar stays put (Unlike G+). Lastly, to get the original screen back it works just like G+.

Apps

If you would like to experience what a beautiful slide menu looks and feels like download:

  1. Prixing
  2. Evernote
  3. Spotify

解决方案

Edit #3:

The Navigation Drawer pattern is officially described in the Android documentation!

Check out the following links:

  • Design docs can be found here.
  • Developer docs can be found here.

Edit #2:

Roman Nurik (an Android design engineer at Google) has confirmed that the recommended behavior is to not move the Action Bar when opening the drawer (like the YouTube app). See this Google+ post.


Edit #1:

I answered this question a while ago, but I'm back to re-emphasize that Prixing has the best fly-out menu out there... by far. It's absolutely beautiful, perfectly smooth, and it puts Facebook, Google+, and YouTube to shame. EverNote is pretty good too... but still not as perfect as Prixing. Check out this series of posts on how the flyout menu was implemented (from none other than the head developer at Prixing himself!).


Original Answer:

Adam Powell and Richard Fulcher talk about this at 49:47 - 52:50 in the Google I/O talk titled "Navigation in Android".

To summarize their answer, as of the date of this posting the slide out navigation menu is not officially part of the Android application design standard. As you have probably discovered, there's currently no native support for this feature, but there was talk about making this an addition to an upcoming revision of the support package.

With regards to the YouTube and G+ apps, it does seem odd that they behave differently. My best guess is that the reason the YouTube app fixes the position of the action bar is,

  1. One of the most important navigational options for users using the YouTube app is search, which is performed in the SearchView in the action bar. It would make sense to make the action bar static in this regard, since it would allow the user to always have the option to search for new videos.

  2. The G+ app uses a ViewPager to display its content, so making the pull out menu specific to the layout content (i.e. everything under the action bar) wouldn't make much sense. Swiping is supposed to provide a means of navigating between pages, not a means of global navigation. This might be why they decided to do it differently in the G+ app than they did in the YouTube app.

    On another note, check out the Google Play app for another version of the "pull out menu" (when you are at the left most page, swipe left and a pull out, "half-page" menu will appear).

You're right in that this isn't very consistent behavior, but it doesn't seem like there is a 100% consensus within the Android team on how this behavior should be implemented yet. I wouldn't be surprised if in the future the apps are updated so that the navigation in both apps are identical (they seemed very keen on making navigation consistent across all Google-made apps in the talk).

这篇关于导航抽屉(Google+上与YouTube的)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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