diff options
author | daniel oeh <daniel.oeh@gmail.com> | 2014-04-01 22:53:18 +0200 |
---|---|---|
committer | daniel oeh <daniel.oeh@gmail.com> | 2014-04-01 22:53:18 +0200 |
commit | c37b67172e929289ffb8fe5e901661f4456abaae (patch) | |
tree | 0825759715295085832c52c798fd345e55229e35 /res/layout | |
parent | 9abf27ca2f32240206d1dae3c55d2046372abf3f (diff) | |
download | AntennaPod-c37b67172e929289ffb8fe5e901661f4456abaae.zip |
Added navigation drawer + new episodes fragment
Diffstat (limited to 'res/layout')
-rw-r--r-- | res/layout/main.xml | 51 | ||||
-rw-r--r-- | res/layout/nav_feedlistitem.xml | 38 | ||||
-rw-r--r-- | res/layout/nav_listitem.xml | 20 | ||||
-rw-r--r-- | res/layout/nav_section_item.xml | 26 | ||||
-rw-r--r-- | res/layout/new_episodes_fragment.xml | 44 | ||||
-rw-r--r-- | res/layout/new_episodes_listdivider.xml | 18 | ||||
-rw-r--r-- | res/layout/new_episodes_listitem.xml | 114 |
7 files changed, 295 insertions, 16 deletions
diff --git a/res/layout/main.xml b/res/layout/main.xml index 2917db164..229b03255 100644 --- a/res/layout/main.xml +++ b/res/layout/main.xml @@ -1,21 +1,40 @@ <?xml version="1.0" encoding="utf-8"?> -<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" - android:id="@+id/main_view" +<android.support.v4.widget.DrawerLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@+id/drawer_layout" android:layout_width="match_parent" - android:layout_height="match_parent" > + android:layout_height="match_parent"> - <FrameLayout - android:id="@+id/playerFragment" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_alignParentBottom="true" /> + <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@+id/content" + android:layout_width="match_parent" + android:layout_height="match_parent"> - <android.support.v4.view.ViewPager - android:id="@+id/viewpager" - android:layout_width="match_parent" - android:layout_height="0px" - android:layout_above="@id/playerFragment" - android:layout_alignParentTop="true" > - </android.support.v4.view.ViewPager> -</RelativeLayout>
\ No newline at end of file + <FrameLayout + android:id="@+id/playerFragment" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_alignParentBottom="true"/> + + <FrameLayout + android:id="@+id/main_view" + android:layout_width="match_parent" + android:layout_height="0px" + android:layout_alignParentTop="true" + android:layout_above="@id/playerFragment"/> + + </RelativeLayout> + + <ListView + android:id="@+id/nav_list" + android:layout_width="280dp" + android:layout_height="match_parent" + android:layout_gravity="start" + android:choiceMode="singleChoice" + android:background="?attr/nav_drawer_background" + android:scrollbarStyle="outsideOverlay" + android:paddingLeft="8dp" + android:paddingRight="8dp"/> + +</android.support.v4.widget.DrawerLayout>
\ No newline at end of file diff --git a/res/layout/nav_feedlistitem.xml b/res/layout/nav_feedlistitem.xml new file mode 100644 index 000000000..e01087077 --- /dev/null +++ b/res/layout/nav_feedlistitem.xml @@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="utf-8"?> + +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:orientation="vertical" + android:layout_width="match_parent" + android:layout_height="match_parent"> + + + <ImageView + android:id="@+id/imgvCover" + android:contentDescription="@string/cover_label" + android:layout_width="@dimen/thumbnail_length_navlist" + android:layout_height="@dimen/thumbnail_length_navlist" + android:layout_alignParentLeft="true" + android:layout_centerVertical="true" + android:adjustViewBounds="true" + android:cropToPadding="true" + android:scaleType="fitXY" + android:layout_marginTop="6dp" + android:layout_marginBottom="6dp"/> + + + <TextView + android:id="@+id/txtvTitle" + android:lines="1" + android:ellipsize="end" + android:layout_centerVertical="true" + android:textColor="?android:attr/textColorPrimary" + android:textSize="@dimen/text_size_navdrawer" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginLeft="12dp" + android:layout_marginTop="14dp" + android:layout_marginBottom="14dp" + android:layout_marginRight="48dp" + android:layout_toRightOf="@id/imgvCover" + /> +</RelativeLayout>
\ No newline at end of file diff --git a/res/layout/nav_listitem.xml b/res/layout/nav_listitem.xml new file mode 100644 index 000000000..f1b585189 --- /dev/null +++ b/res/layout/nav_listitem.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> + +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:orientation="vertical" + android:layout_width="match_parent" + android:layout_height="match_parent"> + + <TextView + android:id="@+id/txtvTitle" + android:lines="1" + android:ellipsize="end" + android:layout_centerVertical="true" + android:textColor="?android:attr/textColorPrimary" + android:textSize="@dimen/text_size_navdrawer" + android:layout_width="wrap_content" + android:layout_height="match_parent" + android:layout_alignParentLeft="true" + android:layout_marginTop="28dp" + android:layout_marginBottom="28dp"/> +</RelativeLayout>
\ No newline at end of file diff --git a/res/layout/nav_section_item.xml b/res/layout/nav_section_item.xml new file mode 100644 index 000000000..1f2fc7e3e --- /dev/null +++ b/res/layout/nav_section_item.xml @@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> + +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:orientation="vertical" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:background="@android:color/transparent"> + + <TextView + android:id="@+id/txtvTitle" + android:textColor="?android:attr/textColorTertiary" + android:textSize="@dimen/text_size_small" + android:typeface="sans" + android:layout_width="wrap_content" + android:layout_height="match_parent" + android:layout_alignParentLeft="true" + android:layout_alignParentBottom="true" + android:layout_marginTop="16dp" + android:paddingBottom="4dp"/> + + <View + android:layout_width="match_parent" + android:layout_height="2dp" + android:layout_alignParentBottom="true" + android:background="@color/gray"/> +</RelativeLayout>
\ No newline at end of file diff --git a/res/layout/new_episodes_fragment.xml b/res/layout/new_episodes_fragment.xml new file mode 100644 index 000000000..d8276cf38 --- /dev/null +++ b/res/layout/new_episodes_fragment.xml @@ -0,0 +1,44 @@ +<?xml version="1.0" encoding="utf-8"?> + +<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:dslv="http://schemas.android.com/apk/res-auto" + android:orientation="vertical" + android:layout_width="match_parent" + android:layout_height="match_parent"> + + <com.mobeta.android.dslv.DragSortListView + android:id="@android:id/list" + android:paddingLeft="8dp" + android:paddingRight="8dp" + android:scrollbarStyle="outsideOverlay" + android:layout_width="match_parent" + android:layout_height="match_parent" + dslv:collapsed_height="2dp" + dslv:drag_enabled="false" + dslv:drag_scroll_start="0.33" + dslv:float_alpha="0.6" + dslv:max_drag_scroll_speed="0.5" + dslv:remove_enabled="true" + dslv:remove_mode="flingRemove" + dslv:slide_shuffle_speed="0.3" + dslv:sort_enabled="false" + dslv:track_drag_sort="false" + dslv:float_background_color="?attr/dragview_float_background" + dslv:use_default_controller="true" /> + + <TextView + android:id="@id/android:empty" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:layout_gravity="center" + android:gravity="center" + android:text="@string/no_items_label" /> + + <ProgressBar + android:id="@+id/progLoading" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_gravity="center" + android:indeterminateOnly="true" /> + +</LinearLayout>
\ No newline at end of file diff --git a/res/layout/new_episodes_listdivider.xml b/res/layout/new_episodes_listdivider.xml new file mode 100644 index 000000000..f57234a1a --- /dev/null +++ b/res/layout/new_episodes_listdivider.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> + +<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:orientation="vertical" + android:layout_width="match_parent" + android:layout_height="match_parent"> + + <TextView + android:padding="12dp" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:textSize="@dimen/text_size_large" + android:textColor="@color/bright_blue" + android:textAllCaps="true" + android:textStyle="italic" + android:text="@string/recently_published_episodes_label"/> + +</LinearLayout>
\ No newline at end of file diff --git a/res/layout/new_episodes_listitem.xml b/res/layout/new_episodes_listitem.xml new file mode 100644 index 000000000..108501133 --- /dev/null +++ b/res/layout/new_episodes_listitem.xml @@ -0,0 +1,114 @@ +<?xml version="1.0" encoding="utf-8"?> + +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:tools="http://schemas.android.com/tools" + android:layout_width="match_parent" + android:layout_height="match_parent"> + + <ImageView + android:id="@+id/imgvImage" + android:contentDescription="@string/cover_label" + android:layout_width="@dimen/thumbnail_length_itemlist" + android:layout_height="@dimen/thumbnail_length_itemlist" + android:layout_alignParentLeft="true" + android:scaleType="centerCrop"/> + + <ImageView + android:id="@+id/statusPlaying" + android:contentDescription="@string/status_playing_label" + android:layout_width="@dimen/status_indicator_width" + android:layout_height="18dp" + android:layout_alignParentRight="true" + android:layout_alignParentTop="true" + android:layout_margin="8dp" + android:background="@color/status_playing" + android:gravity="center" + android:padding="2dp" + android:src="@drawable/av_play_dark"/> + + <TextView + android:id="@+id/txtvPublished" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_marginLeft="8dp" + android:layout_marginRight="8dp" + android:layout_alignParentTop="true" + android:layout_toRightOf="@id/imgvImage" + android:layout_toLeftOf="@id/statusPlaying" + android:ellipsize="end" + android:maxLines="1" + android:textColor="?android:attr/textColorTertiary" + android:textSize="@dimen/text_size_micro"/> + + <TextView + android:id="@+id/txtvTitle" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_below="@id/txtvPublished" + android:layout_marginLeft="8dp" + android:layout_marginRight="4dp" + android:layout_marginTop="2dp" + android:layout_toRightOf="@id/imgvImage" + android:layout_toLeftOf="@id/statusPlaying" + android:ellipsize="end" + android:lines="2" + android:textColor="?android:attr/textColorPrimary" + android:textSize="@dimen/text_size_small"/> + + <LinearLayout + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_alignParentBottom="true" + android:layout_alignParentRight="true" + android:layout_toRightOf="@id/imgvImage" + android:orientation="vertical"> + + <RelativeLayout + android:id="@+id/bottom_bar" + android:layout_width="match_parent" + android:layout_height="wrap_content"> + + <ImageView + android:id="@+id/imgvDownloadStatus" + android:layout_width="@dimen/enc_icons_size" + android:layout_height="@dimen/enc_icons_size" + android:layout_alignParentRight="true" + android:layout_marginLeft="8dp" + android:layout_marginRight="8dp" + android:layout_marginBottom="8dp" + tools:ignore="ContentDescription"/> + + <ImageView + android:id="@id/imgvInPlaylist" + android:contentDescription="@string/in_queue_label" + android:layout_width="@dimen/enc_icons_size" + android:layout_height="@dimen/enc_icons_size" + android:layout_toLeftOf="@+id/imgvDownloadStatus" + android:src="?attr/stat_playlist"/> + + <ProgressBar + android:id="@+id/pbar_download_progress" + style="?android:attr/progressBarStyleHorizontal" + android:max="100" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_toLeftOf="@id/imgvInPlaylist" + android:layout_marginLeft="8dp" + android:layout_marginRight="8dp" + android:layout_alignParentLeft="true"/> + + <TextView + android:id="@+id/txtvDuration" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_toLeftOf="@id/imgvDownloadStatus" + android:layout_marginLeft="8dp" + android:layout_marginRight="8dp" + android:layout_alignParentLeft="true" + android:textColor="?android:attr/textColorTertiary" + android:textSize="@dimen/text_size_micro"/> + </RelativeLayout> + </LinearLayout> + + +</RelativeLayout>
\ No newline at end of file |