1
xmlコードにFabを追加しようとするとこの問題が発生しますが、なぜ理解できません。プロジェクトと無効なキャッシュを消去しようとしました再起動しても何も変わりません。Androidスタジオ - @ id/default_stateを解決できませんでした - レンダリングの問題
これは私のXMLコードです:
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/left_drawer_activity_tickets"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
tools:openDrawer="start">
<android.support.v4.widget.DrawerLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/right_drawer_activity"
android:layout_width="match_parent"
android:layout_height="match_parent">
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
android:background="#DDDDDD"
>
<android.support.design.widget.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay"
android:id="@+id/appbar_activity"
>
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar_activity"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="?attr/colorPrimary"
app:popupTheme="@style/AppTheme.PopupOverlay" />
<SearchView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:imeOptions="actionSearch"
android:id="@+id/search_activity"
android:iconifiedByDefault="false"
android:focusable="false"
android:focusableInTouchMode="true"
android:queryHint="Search..."
android:visibility="gone"
/>
</android.support.design.widget.AppBarLayout>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_height="match_parent"
android:background="#DDDDDD"
android:layout_margin="5dp"
>
<it.prova.widgets.AnimatedExpandableListView
android:id="@+id/listViewTickets"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:layout_marginTop="55dp"
/>
</RelativeLayout>
<io.github.yavski.fabspeeddial.FabSpeedDial
android:id="@+id/fab_option_activity"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
app:fabGravity="bottom_end"
app:fabMenu="@menu/fab_speed_dial_tickets_minimal"
app:miniFabBackgroundTint="@android:color/white"
app:miniFabDrawableTint="?attr/colorPrimaryDark"
app:miniFabTitleTextColor="?attr/colorPrimaryDark" />
</android.support.design.widget.CoordinatorLayout>
<android.support.design.widget.NavigationView
android:id="@+id/nav_view_right_activity"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="end"
android:fitsSystemWindows="true"
app:headerLayout="@layout/nav_header_right_customer"
app:menu="@menu/menu_right_customer" />
</android.support.v4.widget.DrawerLayout>
<android.support.design.widget.NavigationView
android:id="@+id/nav_view_left_activity"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="start"
android:fitsSystemWindows="true"
app:headerLayout="@layout/nav_header_main"
app:menu="@menu/menu_left_drawer" />
私はどのように行うことができますか? ありがとうございます。私が使用し
編集
のFabは、あなたがFAB-Speed-Dial library by yavskiを使用しているようthis
なぜですか? drawerLayoutを2つ使用しますか? –
@NguyễnTrungHiếuはい、左と右の引き出しを使用します – Jigen
xmlns:android = "http://schemas.android.com/apk/res/android"を削除してみてください。ただレイアウトルートでそれを呼び出す –