Android ViewPager内的PreferenceScreen未正确滚动
嘿,伙计们,我有一个协调器布局,里面有一些选项卡和一个显示我偏好片段的viewpager。您可以在这里查看:Android ViewPager内的PreferenceScreen未正确滚动,android,android-layout,android-viewpager,android-preferences,Android,Android Layout,Android Viewpager,Android Preferences,嘿,伙计们,我有一个协调器布局,里面有一些选项卡和一个显示我偏好片段的viewpager。您可以在这里查看: <android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:theme="@style/TabStyle">
<android.support.design.widget.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
android:minWidth="@dimen/abc_action_bar_stacked_max_height"
android:nestedScrollingEnabled="true">
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"
android:layout_width="wrap_content"
android:layout_height="?attr/actionBarSize"
android:background="?attr/colorPrimary"
app:layout_scrollFlags="scroll|enterAlways"
app:popupTheme="@style/ThemeOverlay.AppCompat.Light" />
<android.support.design.widget.TabLayout
android:id="@+id/tabs"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:tabMode="fixed"
app:tabGravity="fill"
android:theme="@style/TabStyle"
app:tabIndicatorColor="@color/colorAccent"/>
</android.support.design.widget.AppBarLayout>
<android.support.v4.view.ViewPager
android:id="@+id/viewpager"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
</android.support.design.widget.CoordinatorLayout>
我的首选项布局如下所示:
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
...
<PreferenceCategory android:title="Settings">
<EditTextPreference
android:defaultValue="picture1"
android:key="editTextPref"
android:summary="picture"
android:title="picture" />
</PreferenceCategory>
</PreferenceScreen>
...