Ich verwende Viewpager oben in meinem Layout und darunter ein Rahmenlayout, das eine Recycler-Ansicht enthält. Ich möchte den Viewpager reduzieren, wenn ich in meiner Recycler-Ansicht blättere, sodass er im Vollbildmodus angezeigt werden kann. DieseWie benutze ich viewpager in der zusammenklappbaren Symbolleiste?
ist, wie mein Layout-Datei wie folgt aussieht:
<RelativeLayout 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/main_container"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/white"
android:orientation="vertical"
tools:context=".MainActivity">
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="?attr/colorPrimary"
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
app:popupTheme="@style/ThemeOverlay.AppCompat.Light" />
<android.support.v4.view.ViewPager
android:id="@+id/pager_container"
android:layout_width="match_parent"
android:layout_height="180dp"
android:layout_gravity="center_horizontal"
android:layout_marginTop="?attr/actionBarSize" />
<FrameLayout
android:id="@+id/content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@id/seperator"
android:layout_marginTop="20dp" />
</RelativeLayout>
ich die screenshort auch für denselben angeschlossen haben.
ich das gleiche tue aber mein Layout ist immer chaotisch. Kannst du meine Layoutdatei bearbeiten? – Abhishek
Was happed? Ich warte auf Ihre Antwort. Bitte helfen Sie – Abhishek
Jaydroider ist drauf. Werfen Sie einen Blick auf seine Antwort –