Android Slide to expand view

I have a layout as shown in this image:

Layout

I want the user to be able to drag the "Show Details ..." part to see more information. I tried SlidingDrawer but no luck. Is there a suggestion, for example, a piece of code or a third-party component that would do the trick? Or even another layout of the user interface that would be suitable for the intuitive display of information without violating too many users.

This is the XML layout I am currently using, but this is just a working draft:

<?xml version="1.0" encoding="UTF-8"?>


<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
             android:layout_width="match_parent" 
             android:layout_height="match_parent">

  <fragment android:id="@+id/map"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:name="com.google.android.gms.maps.SupportMapFragment"/>


  <LinearLayout android:orientation="vertical" 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" 
                android:layout_gravity="top"
                android:background="#A0000000">


    <TextView android:id="@+id/message_text_text"
              android:layout_height="wrap_content"
              android:layout_width="fill_parent"
              android:textColor="#FFFFFF"
              android:padding="10dip"
              android:textSize="13sp"/>



    <LinearLayout android:orientation="vertical" 
                  android:visibility="gone"
                  android:id="@+id/details"
                  android:layout_width="fill_parent" 
                  android:layout_height="wrap_content" 
                  android:layout_gravity="top"
                  android:padding="10dip">

      <ListView android:id="@+id/message_list_responses"
                android:layout_width="fill_parent"
                android:layout_marginTop="10dp"
                android:layout_marginLeft="30dp"
                android:layout_height="wrap_content" />  


    </LinearLayout>

    <TextView android:id="@+id/details_button"
              android:layout_height="wrap_content"
              android:layout_width="fill_parent"
              android:textColor="#FFFFFF"
              android:padding="5dip"
              android:onClick="onDetails"
              android:gravity="center"                
              android:clickable="true"
              android:background="#80000000"
              android:text="Show details..."
              android:textSize="11sp"/>
  </LinearLayout>


</FrameLayout>
+5
source share
1 answer

SlidingMenu GitHub. , . , :

setSlidingActionBarEnabled(true);

https://github.com/jfeinstein10/SlidingMenu

0

All Articles