我们在引用android.support.v4包中的drawerlayout时经常出现这种错误
DrawerLayout must be measured with MeasureSpec.EXACTLY.

    <android.support.v4.widget.DrawerLayout        android:layout_height="wrap_content"        android:layout_width="wrap_content"        android:layout_below="@+id/toolbar"        android:fitsSystemWindows="true">        <include layout="@layout/drawercontent"></include>        <LinearLayout            android:layout_width="wrap_content"            android:layout_height="wrap_content"></LinearLayout>    </android.support.v4.widget.DrawerLayout>    其实原因很简单,drawerlayout必须给一个确定的大小不能用wrap_content换成其他的问题就解决了。

更多相关文章

  1. android 通过经纬度获取地址信息
  2. Android(安卓)studio 混淆打包安装后报错NullPointerException i
  3. Ubuntu14.04 ERROR WHILE LOADING SHARED LIBRARIES: LIBSTDC++.
  4. android helloworld
  5. Gradle DSL method not found: 'android()错误的解决方法
  6. android 可自定义大小和位置的Dialog
  7. Android(安卓)学习记录-布局预览错误
  8. android日常问题及解决方案
  9. Android(安卓)WebView 播放视频问题

随机推荐

  1. 【1510-12.1】textview加图片&nbsp…
  2. 50个Android开发人员必备UI效果源码
  3. Android中的android:layout_width和andro
  4. 50个Android开发人员必备UI效果源码
  5. 【1510-12.2】textview加图片&nbsp…
  6. 50个Android开发人员必备UI效果源码
  7. android高级应用第二阶段
  8. 页面跳转
  9. 50个Android开发人员必备UI效果源码
  10. Android(安卓)屏幕自适应方向尺寸与分辨