我必须在右侧设置一个 SlidingDrawer,点击它不应该扩大到半屏。我看到了很多 tutos,我设法或多或少地正确设置了它,但它目前正在将布局中的所有内容推向左侧。这是我的xml:
<LinearLayout android:layout_height="wrap_content"
android:id="@+id/edition_content_linear" android:layout_width="fill_parent"
android:layout_weight="1" android:background="@android:color/white">
<LinearLayout android:layout_width="fill_parent"
android:id="@+id/static_menu_layout" android:layout_height="fill_parent"
android:layout_weight="2" android:visibility="gone" android:background="@drawable/ipad_category_back">
<ExpandableListView android:id="@+id/static_expandable_list"
android:layout_height="fill_parent" android:layout_width="fill_parent"
android:drawSelectorOnTop="false" android:groupIndicator="@drawable/expandablelist_selector" android:indicatorLeft="210dp" android:indicatorRight="230dp"></ExpandableListView>
</LinearLayout>
<LinearLayout android:id="@+id/center_linear"
android:layout_width="fill_parent" android:layout_height="fill_parent"
android:layout_weight="1">
<ImageView android:scaleType="centerInside"
android:layout_height="fill_parent" android:layout_width="fill_parent"
android:id="@+id/cover_image_big"></ImageView>
<WebView android:id="@+id/story_webview"
android:layout_height="fill_parent" android:layout_width="fill_parent"
android:visibility="gone"></WebView>
</LinearLayout>
<SlidingDrawer android:id="@+id/slider_drawer"
android:layout_width="250dp" android:layout_height="500dp"
android:orientation="horizontal" android:layout_gravity="center_vertical"
android:handle="@+id/slider_handle" android:content="@+id/slider_expandable_list_container">
<ImageView android:id="@+id/slider_handle"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:src="@drawable/menu_handler" />
<RelativeLayout android:id="@+id/slider_expandable_list_container"
android:layout_height="500dp" android:layout_width="250dp">
<ExpandableListView android:id="@+id/slider_expandable_list"
android:layout_height="fill_parent" android:layout_width="fill_parent"
android:drawSelectorOnTop="false" android:indicatorLeft="210dp" android:layout_gravity="center_vertical"
android:indicatorRight="230dp" android:groupIndicator="@drawable/expandablelist_selector"></ExpandableListView>
</RelativeLayout>
</SlidingDrawer>
</LinearLayout>