push activity on the right when open drawer

后端 未结 8 2041
隐瞒了意图╮
隐瞒了意图╮ 2020-12-07 11:29

I have implemented drawerlayout which slides from the right but it does not shift the activity the right like facebook does (See below image). How do I push the current acti

8条回答
  •  一个人的身影
    2020-12-07 11:45

    To answer your question. The DrawerLayout is behaving as expected.

    You can use Slidingmenu (or Umano) in conjunction with a DrawerLayout (I do).

    Finally, regarding what you want (and what Facebook does), Google itself doesn't want you to do that. They want you to use the drawer the way they use it in Google Music (for example)

    A Google contact said exactly this to me:

    • The navigation drawer should follow the new guidelines and should be implemented using DrawerLayout and ActionBarDrawerToggle.
    • The navigation drawer should not shift the action bar and should appear as an overlay above the screen contents.
    • The navigation drawer should contain only primary navigational elements. Avoid showing items in the navigation drawer that would typically be placed in the action bar, such as Settings or Search. Blockquote

    So don't do what Facebook does. (That is a good advice in any other context) :)

提交回复
热议问题