サンプルのnavigationアプリをいじっています
SearchViewだけなら問題ないんですが、
ListViewを組み合わせると検索ボックスが入力状態になった時、一緒にナビゲーションバーも動いてしまいます。
何が問題なのでしょうか。ボタンなど追加して試してみましたが同じことは起こりませんでした。
リストビューには何も機能を追加していません!Javaでリストビューについて書いていた部分をコメントアウトしましたが何も変わりませんでした。
よろしくお願いします。
xml
fragment_search.xml <?xml version="1.0" encoding="utf-8"?> <LinearLayout 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" tools:context=".main.search.SearchFragment" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" android:padding="16dp"> <SearchView android:id="@+id/searchingbox" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center_horizontal" android:layout_marginTop="3dp" android:iconifiedByDefault="false" android:queryHint="検索" /> <ListView android:id="@+id/list" android:layout_width="match_parent" android:layout_height="wrap_content"/> </LinearLayout>
まだ回答がついていません
会員登録して回答してみよう