android工具栏在哪块,android – 如何使DrawerLayout显示在工具栏下面?

如何使抽屉布局在操作栏/工具栏下面?我使用v7:21应用程序兼容库与新的ToolBar视图。

我看到的例子

xmlns:android="http://schemas.android.com/apk/res/android"

android:id="@+id/my_drawer_layout"

android:layout_width="match_parent"

android:layout_height="match_parent">

android:layout_width="304dp"

android:layout_height="match_parent"

android:layout_gravity="left|start">

android:layout_width="match_parent"

android:layout_height="match_parent"

android:orientation="vertical">

android:id="@+id/my_awesome_toolbar"

android:layout_height="wrap_content"

android:layout_width="match_parent"

android:minHeight="?attr/actionBarSize"

android:background="?attr/colorPrimary" />

但是,然后工具栏将被隐藏的抽屉,这使得一个动画汉堡包图标(如v7.ActionBarDrawerToggle)无用,因为它不会在下面的抽屉,但我想要使用新的工具栏视图更好地支持材质主题。

那么如何实现呢?是否可能将DrawerLayout作为非顶级视图?

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值