diff options
Diffstat (limited to 'app/src/main/res/layout')
-rw-r--r-- | app/src/main/res/layout/audio_controls.xml | 146 | ||||
-rw-r--r-- | app/src/main/res/layout/audioplayer_activity.xml | 266 | ||||
-rw-r--r-- | app/src/main/res/layout/choose_speed_dialog.xml | 45 | ||||
-rw-r--r-- | app/src/main/res/layout/cover_fragment.xml | 63 | ||||
-rw-r--r-- | app/src/main/res/layout/feeditem_fragment.xml | 36 |
5 files changed, 352 insertions, 204 deletions
diff --git a/app/src/main/res/layout/audio_controls.xml b/app/src/main/res/layout/audio_controls.xml new file mode 100644 index 000000000..7532722dd --- /dev/null +++ b/app/src/main/res/layout/audio_controls.xml @@ -0,0 +1,146 @@ +<?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="wrap_content"> + + <LinearLayout + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginTop="12dp" + android:layout_marginLeft="24dp"> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + style="@style/AntennaPod.TextView.ListItemPrimaryTitle" + android:text="@string/playback_speed" + android:textStyle="bold"/> + + <TextView + android:id="@+id/txtvPlaybackSpeed" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginLeft="16dp" + android:text="1.00x"/> + + </LinearLayout> + + <RelativeLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="-12dp" + android:layout_marginLeft="24dp" + android:layout_marginRight="24dp"> + + <Button + android:id="@+id/butDecSpeed" + android:layout_width="32dp" + android:layout_height="32dp" + android:layout_alignParentLeft="true" + android:gravity="center" + android:text="-" + android:textStyle="bold" + android:textColor="@color/status_progress" + android:textSize="24sp" + android:background="@drawable/borderless_button_dark"/> + + <Button + android:id="@+id/butIncSpeed" + android:layout_width="32dp" + android:layout_height="32dp" + android:minWidth="0dp" + android:layout_alignParentRight="true" + android:gravity="center" + android:text="+" + android:textStyle="bold" + android:textColor="@color/status_progress" + android:textSize="24sp" + android:background="@drawable/borderless_button_dark"/> + + <SeekBar + android:id="@+id/playback_speed" + android:layout_width="match_parent" + android:layout_height="32dp" + android:layout_toRightOf="@id/butDecSpeed" + android:layout_toLeftOf="@id/butIncSpeed" + android:layout_centerVertical="true" + android:max="40"/> + + </RelativeLayout> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginTop="4dp" + android:layout_marginLeft="24dp" + style="@style/AntennaPod.TextView.ListItemPrimaryTitle" + android:text="@string/volume" + android:textStyle="bold"/> + + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="-12dp" + android:layout_marginLeft="24dp" + android:layout_marginRight="24dp" + android:orientation="horizontal" + android:gravity="center"> + + <TextView + android:id="@+id/txtvLeft" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="@string/left_short" /> + + <SeekBar + android:id="@+id/volume_left" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:max="100" /> + + </LinearLayout> + + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="8dp" + android:layout_marginLeft="24dp" + android:layout_marginRight="24dp" + android:orientation="horizontal" + android:gravity="center"> + + <TextView + android:id="@+id/txtvRight" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="@string/right_short" /> + + <SeekBar + android:id="@+id/volume_right" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:max="100"/> + + </LinearLayout> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginTop="12dp" + android:layout_marginLeft="24dp" + style="@style/AntennaPod.TextView.ListItemPrimaryTitle" + android:text="@string/audio_effects" + android:textStyle="bold"/> + + <CheckBox + android:id="@+id/stereo_to_mono" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginTop="-12dp" + android:layout_marginLeft="24dp" + android:layout_marginRight="24dp" + android:text="@string/stereo_to_mono" /> + +</LinearLayout> diff --git a/app/src/main/res/layout/audioplayer_activity.xml b/app/src/main/res/layout/audioplayer_activity.xml index 379028c8e..fb4f995a2 100644 --- a/app/src/main/res/layout/audioplayer_activity.xml +++ b/app/src/main/res/layout/audioplayer_activity.xml @@ -1,219 +1,219 @@ <?xml version="1.0" encoding="utf-8"?> -<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android" +<android.support.v4.widget.DrawerLayout + xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" + xmlns:app="http://schemas.android.com/apk/res-auto" android:id="@+id/drawer_layout" android:layout_width="match_parent" android:layout_height="match_parent" tools:background="@android:color/holo_red_dark"> - <LinearLayout + <RelativeLayout android:layout_width="match_parent" - android:layout_height="match_parent" - android:orientation="vertical"> + android:layout_height="match_parent"> + + <android.support.design.widget.AppBarLayout + android:id="@+id/appBar" + android:layout_width="match_parent" + android:layout_height="wrap_content"> <android.support.v7.widget.Toolbar android:id="@+id/toolbar" android:layout_width="match_parent" android:layout_height="wrap_content" + android:layout_alignParentTop="true" android:background="?attr/colorPrimary" android:minHeight="?attr/actionBarSize" - tools:background="@android:color/darker_gray"> + tools:background="@android:color/darker_gray"/> - <LinearLayout + <com.viewpagerindicator.CirclePageIndicator + android:id="@+id/page_indicator" + android:layout_height="wrap_content" android:layout_width="match_parent" - android:layout_height="match_parent" - android:orientation="horizontal" - android:paddingLeft="8dp" - android:paddingRight="8dp"> - - <TextView - android:id="@+id/txtvTitle" - android:layout_width="0dp" - android:layout_height="wrap_content" - android:layout_gravity="center_vertical" - android:layout_weight="1" - android:ellipsize="end" - android:gravity="left" - android:maxLines="2" - android:textColor="?android:attr/textColorPrimary" - android:textSize="16sp" - tools:text="Audio title" - tools:background="@android:color/holo_green_dark" /> - - <ImageButton - android:id="@+id/butCover" - android:layout_width="32dp" - android:layout_height="32dp" - android:layout_gravity="center_vertical" - android:layout_marginLeft="8dp" - android:background="?attr/selectableItemBackground" - android:contentDescription="@string/show_cover_label" - android:gravity="right" - tools:src="@drawable/ic_stat_antenna_default" - tools:background="@android:color/holo_green_dark" /> - - - </LinearLayout> - </android.support.v7.widget.Toolbar> - - <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" - android:id="@+id/content" + android:layout_marginTop="-12dp" + android:layout_marginBottom="4dp" + android:background="@android:color/transparent" + app:fillColor="?android:attr/textColorSecondary" + app:strokeColor="?android:attr/textColorSecondary" + app:radius="4dp" /> + + </android.support.design.widget.AppBarLayout> + + <LinearLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@+id/playtime_layout" android:layout_width="match_parent" - android:layout_height="match_parent" - android:background="?attr/non_transparent_background" - android:foreground="?android:windowContentOverlay" + android:layout_height="wrap_content" + android:paddingTop="8dp" + android:layout_alignParentBottom="true" + android:background="?attr/overlay_drawable" android:orientation="vertical"> + + <RelativeLayout + android:layout_width="match_parent" + android:layout_height="wrap_content"> + + <TextView + android:id="@+id/txtvPosition" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignParentLeft="true" + android:layout_centerVertical="true" + android:layout_marginLeft="8dp" + android:text="@string/position_default_label" + android:textColor="?android:attr/textColorSecondary" + android:textSize="@dimen/text_size_micro" + tools:background="@android:color/holo_green_dark" /> + + <TextView + android:id="@+id/txtvLength" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignParentRight="true" + android:layout_centerVertical="true" + android:layout_marginRight="8dp" + android:text="@string/position_default_label" + android:textColor="?android:attr/textColorSecondary" + android:textSize="@dimen/text_size_micro" + tools:background="@android:color/holo_green_dark" /> + + <SeekBar + android:id="@+id/sbPosition" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_centerVertical="true" + android:layout_marginLeft="8dp" + android:layout_marginRight="8dp" + android:layout_toLeftOf="@id/txtvLength" + android:layout_toRightOf="@id/txtvPosition" + android:max="500" + tools:background="@android:color/holo_green_dark" /> + + </RelativeLayout> + <RelativeLayout android:id="@+id/player_control" android:layout_width="match_parent" - android:layout_height="@dimen/audioplayer_playercontrols_length" - android:layout_alignParentBottom="true" + android:layout_height="wrap_content" + android:paddingTop="4dp" + android:paddingBottom="8dp" android:background="?attr/overlay_background" tools:background="@android:color/holo_purple"> <ImageButton android:id="@+id/butPlay" android:layout_width="@dimen/audioplayer_playercontrols_length" - android:layout_height="match_parent" + android:layout_height="@dimen/audioplayer_playercontrols_length" + android:layout_marginLeft="16dp" + android:layout_marginRight="16dp" android:layout_centerHorizontal="true" android:background="?attr/selectableItemBackground" android:contentDescription="@string/pause_label" android:src="?attr/av_pause" + android:scaleType="fitCenter" tools:src="@drawable/ic_pause_white_36dp" tools:background="@android:color/holo_green_dark" /> <ImageButton android:id="@+id/butRev" android:layout_width="@dimen/audioplayer_playercontrols_length" - android:layout_height="match_parent" + android:layout_height="@dimen/audioplayer_playercontrols_length" android:layout_toLeftOf="@id/butPlay" + android:layout_marginLeft="16dp" android:background="?attr/selectableItemBackground" android:contentDescription="@string/rewind_label" android:src="?attr/av_rew_big" + android:scaleType="fitCenter" tools:src="@drawable/ic_fast_rewind_white_36dp" tools:background="@android:color/holo_blue_dark" /> <TextView android:id="@+id/txtvRev" android:layout_width="wrap_content" - android:layout_height="32dp" - android:layout_alignTop="@id/butRev" + android:layout_height="wrap_content" + android:layout_below="@id/butRev" android:layout_alignLeft="@id/butRev" android:layout_alignRight="@id/butRev" + android:layout_marginTop="-8dp" android:gravity="center" android:text="30" - android:textSize="8dp" + android:textSize="10sp" + android:textColor="?android:attr/textColorSecondary" android:clickable="false"/> + <Button + android:id="@+id/butPlaybackSpeed" + android:layout_width="@dimen/audioplayer_playercontrols_length" + android:layout_height="@dimen/audioplayer_playercontrols_length" + android:layout_toLeftOf="@id/butRev" + android:background="?attr/selectableItemBackground" + android:contentDescription="@string/set_playback_speed_label" + android:src="?attr/av_fast_forward" + android:textSize="@dimen/text_size_medium" + android:textAllCaps="false" + tools:background="@android:color/holo_green_dark" /> + <ImageButton android:id="@+id/butFF" android:layout_width="@dimen/audioplayer_playercontrols_length" - android:layout_height="match_parent" + android:layout_height="@dimen/audioplayer_playercontrols_length" android:layout_toRightOf="@id/butPlay" + android:layout_marginRight="16dp" android:background="?attr/selectableItemBackground" android:contentDescription="@string/fast_forward_label" android:src="?attr/av_ff_big" + android:scaleType="fitCenter" tools:src="@drawable/ic_fast_forward_white_36dp" tools:background="@android:color/holo_blue_dark" /> <TextView android:id="@+id/txtvFF" android:layout_width="wrap_content" - android:layout_height="32dp" - android:layout_alignTop="@id/butFF" + android:layout_height="wrap_content" + android:layout_below="@id/butFF" android:layout_alignLeft="@id/butFF" android:layout_alignRight="@id/butFF" + android:layout_marginTop="-8dp" android:gravity="center" android:text="30" - android:textSize="8dp" + android:textSize="10sp" + android:textColor="?android:attr/textColorSecondary" android:clickable="false"/> - <Button - android:id="@+id/butPlaybackSpeed" - android:layout_width="@dimen/audioplayer_playercontrols_length" - android:layout_height="match_parent" - android:layout_toRightOf="@id/butFF" - android:background="?attr/selectableItemBackground" - android:contentDescription="@string/set_playback_speed_label" - android:src="?attr/av_fast_forward" - android:textSize="@dimen/text_size_medium" - android:visibility="gone" - tools:background="@android:color/holo_green_dark" /> - <ImageButton - android:id="@+id/butNavChaptersShownotes" + android:id="@+id/butSkip" android:layout_width="@dimen/audioplayer_playercontrols_length" - android:layout_height="match_parent" - android:layout_toLeftOf="@id/butRev" + android:layout_height="@dimen/audioplayer_playercontrols_length" + android:layout_toRightOf="@id/butFF" android:background="?attr/selectableItemBackground" - android:scaleType="centerInside" - android:src="@drawable/ic_toc_white_36dp" - tools:background="@android:color/holo_green_dark" /> - </RelativeLayout> - - <RelativeLayout - android:id="@+id/playtime_layout" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_above="@id/player_control" - android:layout_alignParentLeft="true" - android:background="?attr/overlay_drawable"> - - <TextView - android:id="@+id/txtvPosition" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_alignParentLeft="true" - android:layout_centerVertical="true" - android:layout_marginLeft="8dp" - android:layout_marginTop="16dp" - android:text="@string/position_default_label" - android:textColor="?android:attr/textColorSecondary" - android:textSize="@dimen/text_size_micro" - tools:background="@android:color/holo_green_dark" /> - - <TextView - android:id="@+id/txtvLength" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_alignParentRight="true" - android:layout_alignParentTop="true" - android:layout_centerVertical="true" - android:layout_marginRight="8dp" - android:layout_marginTop="16dp" - android:text="@string/position_default_label" - android:textColor="?android:attr/textColorSecondary" - android:textSize="@dimen/text_size_micro" - tools:background="@android:color/holo_green_dark" /> - - <SeekBar - android:id="@+id/sbPosition" - android:layout_width="0dp" - android:layout_height="wrap_content" - android:layout_centerVertical="true" - android:layout_marginLeft="8dp" - android:layout_marginRight="8dp" - android:layout_marginTop="16dp" - android:layout_toLeftOf="@id/txtvLength" - android:layout_toRightOf="@id/txtvPosition" - android:max="500" + android:scaleType="fitCenter" + android:src="?attr/av_skip_big" + android:contentDescription="@string/skip_episode_label" + tools:src="@drawable/ic_skip_white_36dp" tools:background="@android:color/holo_green_dark" /> </RelativeLayout> - <FrameLayout - android:id="@+id/contentView" - android:layout_width="match_parent" - android:layout_height="0px" - android:layout_above="@id/playtime_layout" - android:layout_alignParentTop="true" - android:foreground="?android:windowContentOverlay" - tools:background="@android:color/holo_orange_light" /> + </LinearLayout> - </RelativeLayout> + <android.support.v4.view.ViewPager + xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@+id/pager" + android:layout_width="match_parent" + android:layout_height="0dp" + android:layout_above="@id/playtime_layout" + android:layout_below="@id/appBar" + android:foreground="?android:windowContentOverlay" + tools:background="@android:color/holo_orange_light" /> + <View + android:id="@+id/shadow" + android:layout_width="match_parent" + android:layout_height="4dp" + android:layout_below="@id/appBar" + android:background="@drawable/shadow" /> - </LinearLayout> + </RelativeLayout> <include layout="@layout/nav_list" /> diff --git a/app/src/main/res/layout/choose_speed_dialog.xml b/app/src/main/res/layout/choose_speed_dialog.xml deleted file mode 100644 index 1b461c77e..000000000 --- a/app/src/main/res/layout/choose_speed_dialog.xml +++ /dev/null @@ -1,45 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<LinearLayout - xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="match_parent" - android:layout_height="match_parent"> - - <android.support.v7.widget.CardView - xmlns:card_view="http://schemas.android.com/apk/res-auto" - android:id="@+id/card_view" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_gravity="center" - android:layout_margin="16dp" - card_view:cardElevation="12dp" - card_view:cardCornerRadius="4dp" - card_view:cardUseCompatPadding="true" - card_view:cardBackgroundColor="?attr/overlay_background"> - - <LinearLayout - xmlns:android="http://schemas.android.com/apk/res/android" - android:orientation="vertical" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_gravity="center_vertical" - android:gravity="center"> - - <TextView - android:id="@+id/txtvSelectedSpeed" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_marginTop="8dp" - android:textSize="22sp" - android:textStyle="bold"/> - - <SeekBar - android:id="@+id/sbSelectSpeed" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_marginBottom="8dp"/> - - </LinearLayout> - - </android.support.v7.widget.CardView> - -</LinearLayout> diff --git a/app/src/main/res/layout/cover_fragment.xml b/app/src/main/res/layout/cover_fragment.xml index 4bbdeae06..13cfb0add 100644 --- a/app/src/main/res/layout/cover_fragment.xml +++ b/app/src/main/res/layout/cover_fragment.xml @@ -1,19 +1,66 @@ <?xml version="1.0" encoding="utf-8"?> -<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + +<android.support.percent.PercentRelativeLayout + 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/cover_fragment_root" android:layout_width="match_parent" android:layout_height="match_parent" - android:orientation="vertical" > + android:background="@color/actionbar_gray"> <ImageView android:id="@+id/imgvCover" + android:layout_width="0dp" + android:layout_height="0dp" + android:layout_centerInParent="true" android:contentDescription="@string/cover_label" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:layout_gravity="center" - android:adjustViewBounds="true" android:scaleType="fitCenter" + app:layout_aspectRatio="100%" + app:layout_widthPercent="82%" tools:src="@android:drawable/sym_def_app_icon" /> -</RelativeLayout> + <LinearLayout + android:layout_width="match_parent" + android:layout_height="match_parent" + android:gravity="center" + android:orientation="vertical" + android:layout_above="@id/imgvCover"> + + <TextView + android:id="@+id/txtvPodcastTitle" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginLeft="8dp" + android:layout_marginRight="8dp" + android:layout_marginStart="8dp" + android:layout_marginEnd="8dp" + android:gravity="center" + android:maxLines="2" + android:ellipsize="end" + android:text="Podcast" /> + + </LinearLayout> + + <LinearLayout + android:layout_width="match_parent" + android:layout_height="match_parent" + android:gravity="center" + android:orientation="vertical" + android:layout_below="@id/imgvCover"> + + <TextView + android:id="@+id/txtvEpisodeTitle" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginLeft="8dp" + android:layout_marginRight="8dp" + android:layout_marginStart="8dp" + android:layout_marginEnd="8dp" + android:gravity="center" + android:maxLines="2" + android:ellipsize="end" + android:text="Episode" /> + + </LinearLayout> + +</android.support.percent.PercentRelativeLayout> diff --git a/app/src/main/res/layout/feeditem_fragment.xml b/app/src/main/res/layout/feeditem_fragment.xml index 3dd4e134d..c18e5fd6c 100644 --- a/app/src/main/res/layout/feeditem_fragment.xml +++ b/app/src/main/res/layout/feeditem_fragment.xml @@ -20,43 +20,33 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_gravity="center_horizontal" - android:orientation="horizontal" android:layout_marginTop="16dp" android:layout_marginLeft="16dp" android:layout_marginRight="16dp"> <ImageView android:id="@+id/imgvCover" + android:layout_alignParentTop="true" + android:layout_alignParentLeft="true" + android:layout_alignParentStart="true" android:layout_width="50dp" android:layout_height="50dp" - android:layout_gravity="center_vertical" android:contentDescription="@string/cover_label" android:gravity="center_vertical" tools:src="@drawable/ic_stat_antenna_default" tools:background="@android:color/holo_green_dark" /> <TextView - android:id="@+id/txtvPublished" - style="@style/AntennaPod.TextView.ListItemSecondaryTitle" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_alignParentTop="true" - android:layout_alignParentRight="true" - android:layout_marginLeft="8dp" - tools:text="Jan\n23" - tools:background="@android:color/holo_green_dark" - android:layout_below="@+id/txtvTitle"/> - - <TextView android:id="@+id/txtvTitle" - style="@style/TextAppearance.AppCompat.Widget.ActionBar.Title" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_alignTop="@id/imgvCover" android:layout_marginLeft="16dp" - android:layout_toLeftOf="@id/txtvPublished" + android:layout_alignTop="@id/imgvCover" android:layout_toRightOf="@id/imgvCover" android:includeFontPadding="false" + android:textSize="16sp" + android:textColor="?android:attr/textColorPrimary" + android:ellipsize="end" android:maxLines="5" tools:text="Podcast title" tools:background="@android:color/holo_green_dark" /> @@ -72,6 +62,17 @@ tools:text="00:42:23" tools:background="@android:color/holo_green_dark"/> + <TextView + android:id="@+id/txtvPublished" + style="@style/AntennaPod.TextView.ListItemSecondaryTitle" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignParentRight="true" + android:layout_below="@id/txtvTitle" + android:layout_marginLeft="8dp" + tools:text="Jan\n23" + tools:background="@android:color/holo_green_dark" /> + </RelativeLayout> <ProgressBar @@ -89,7 +90,6 @@ android:layout_height="wrap_content" android:layout_marginLeft="16dp" android:layout_marginRight="16dp" - android:layout_marginBottom="8dp" android:orientation="horizontal" tools:background="@android:color/holo_blue_bright"> |