From 9a073713bb715e13d4bdf706048354bb62f37e23 Mon Sep 17 00:00:00 2001 From: Christian Schabesberger Date: Wed, 25 Oct 2017 15:20:57 +0200 Subject: [PATCH] put tabs on top --- .../fragments/list/feed/FeedFragment.java | 2 +- .../subscription/SubscriptionFragment.java | 1 + app/src/main/res/layout/fragment_blank.xml | 6 + app/src/main/res/layout/fragment_channel.xml | 6 + app/src/main/res/layout/fragment_feed.xml | 6 + app/src/main/res/layout/fragment_kiosk.xml | 7 + app/src/main/res/layout/fragment_main.xml | 5 +- app/src/main/res/layout/fragment_playlist.xml | 6 + app/src/main/res/layout/fragment_search.xml | 6 + .../main/res/layout/fragment_subscription.xml | 6 + .../main/res/layout/fragment_video_detail.xml | 682 +++++++++--------- app/src/main/res/layout/toolbar_layout.xml | 5 - 12 files changed, 395 insertions(+), 343 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/fragments/list/feed/FeedFragment.java b/app/src/main/java/org/schabi/newpipe/fragments/list/feed/FeedFragment.java index 379ec591a..835647eec 100644 --- a/app/src/main/java/org/schabi/newpipe/fragments/list/feed/FeedFragment.java +++ b/app/src/main/java/org/schabi/newpipe/fragments/list/feed/FeedFragment.java @@ -121,7 +121,7 @@ public class FeedFragment extends BaseListFragment, Voi } if(useAsFrontPage) { - supportActionBar.setDisplayHomeAsUpEnabled(false); + supportActionBar.setDisplayShowTitleEnabled(true); //supportActionBar.setDisplayShowTitleEnabled(false); } } diff --git a/app/src/main/java/org/schabi/newpipe/fragments/subscription/SubscriptionFragment.java b/app/src/main/java/org/schabi/newpipe/fragments/subscription/SubscriptionFragment.java index afb2f078e..3ff56a163 100644 --- a/app/src/main/java/org/schabi/newpipe/fragments/subscription/SubscriptionFragment.java +++ b/app/src/main/java/org/schabi/newpipe/fragments/subscription/SubscriptionFragment.java @@ -62,6 +62,7 @@ public class SubscriptionFragment extends BaseStateFragment + + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_channel.xml b/app/src/main/res/layout/fragment_channel.xml index 460f95a7a..67691fc81 100644 --- a/app/src/main/res/layout/fragment_channel.xml +++ b/app/src/main/res/layout/fragment_channel.xml @@ -62,4 +62,10 @@ android:visibility="gone" tools:visibility="visible"/> + + diff --git a/app/src/main/res/layout/fragment_feed.xml b/app/src/main/res/layout/fragment_feed.xml index 0f2d0b675..0868d8233 100644 --- a/app/src/main/res/layout/fragment_feed.xml +++ b/app/src/main/res/layout/fragment_feed.xml @@ -34,4 +34,10 @@ android:visibility="gone" tools:visibility="visible"/> + + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_kiosk.xml b/app/src/main/res/layout/fragment_kiosk.xml index a85c30cb1..4730e66c8 100644 --- a/app/src/main/res/layout/fragment_kiosk.xml +++ b/app/src/main/res/layout/fragment_kiosk.xml @@ -4,6 +4,7 @@ android:orientation="vertical" android:layout_width="match_parent" android:layout_height="match_parent"> + + + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_main.xml b/app/src/main/res/layout/fragment_main.xml index dac5478ff..b1dd3e20b 100644 --- a/app/src/main/res/layout/fragment_main.xml +++ b/app/src/main/res/layout/fragment_main.xml @@ -10,13 +10,14 @@ android:id="@+id/main_tab_layout" android:layout_width="match_parent" android:layout_height="wrap_content" - android:layout_alignParentBottom="true" + android:layout_alignParentTop="true" + android:background="@color/dark_youtube_primary_color" app:tabGravity="fill"/> + android:layout_below="@id/main_tab_layout"/> diff --git a/app/src/main/res/layout/fragment_playlist.xml b/app/src/main/res/layout/fragment_playlist.xml index d5ef26a63..37c609fa4 100644 --- a/app/src/main/res/layout/fragment_playlist.xml +++ b/app/src/main/res/layout/fragment_playlist.xml @@ -62,4 +62,10 @@ android:visibility="gone" tools:visibility="visible"/> + + diff --git a/app/src/main/res/layout/fragment_search.xml b/app/src/main/res/layout/fragment_search.xml index 04b10347c..d49d23175 100644 --- a/app/src/main/res/layout/fragment_search.xml +++ b/app/src/main/res/layout/fragment_search.xml @@ -81,4 +81,10 @@ android:visibility="gone" tools:visibility="visible"/> + + diff --git a/app/src/main/res/layout/fragment_subscription.xml b/app/src/main/res/layout/fragment_subscription.xml index 35cfbfeb7..e0d0348dc 100644 --- a/app/src/main/res/layout/fragment_subscription.xml +++ b/app/src/main/res/layout/fragment_subscription.xml @@ -35,4 +35,10 @@ android:visibility="gone" tools:visibility="visible"/> + + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_video_detail.xml b/app/src/main/res/layout/fragment_video_detail.xml index 0d87809fc..b067db7bc 100644 --- a/app/src/main/res/layout/fragment_video_detail.xml +++ b/app/src/main/res/layout/fragment_video_detail.xml @@ -1,345 +1,308 @@ - - - + + android:focusableInTouchMode="true"> - - + android:layout_height="match_parent" + android:visibility="visible" + app:parallax_factor="1.9"> - - + + android:orientation="vertical"> - - - - - - - - - - + - - + android:foreground="?attr/selectableItemBackground"> + android:id="@+id/detail_thumbnail_image_view" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="@android:color/transparent" + android:contentDescription="@string/detail_thumbnail_view_description" + android:scaleType="centerCrop" + tools:ignore="RtlHardcoded" + tools:layout_height="200dp" + tools:src="@drawable/dummy_thumbnail"/> + + - - - - - - - - + + android:background="?android:windowBackground"> - - - - - - - - - - - - - - - - - - - - - - - - + - - - + android:paddingRight="12dp"> + tools:text="Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed a ultricies ex. Integer sit amet sodales risus. Duis non mi et urna pretium bibendum. Nunc eleifend est quis ipsum porttitor egestas. Sed facilisis, nisl quis eleifend pellentesque, orci metus egestas dolor, at accumsan eros metus quis libero."/> - - + android:layout_marginLeft="5dp" + android:src="@drawable/arrow_down" + tools:ignore="ContentDescription,RtlHardcoded"/> - + - - + + + + + + + - + + android:layout_marginTop="6dp" + android:baselineAligned="false" + android:orientation="horizontal"> - + + + + + + + + + + + + + + + + + + + + + android:background="?attr/selectableItemBackground" + android:gravity="center_vertical" + android:orientation="horizontal" + android:paddingBottom="8dp" + android:paddingLeft="12dp" + android:paddingRight="12dp" + android:paddingTop="8dp"> + + + + + + + + - - - - - - - + - - + android:layout_marginTop="5dp" + android:orientation="vertical" + android:visibility="gone" + tools:visibility="visible"> + + + + + + + + + + + + + + + + + + - - - - - + + + + + + + + diff --git a/app/src/main/res/layout/toolbar_layout.xml b/app/src/main/res/layout/toolbar_layout.xml index 36ab6454e..096974c03 100644 --- a/app/src/main/res/layout/toolbar_layout.xml +++ b/app/src/main/res/layout/toolbar_layout.xml @@ -36,9 +36,4 @@ - - \ No newline at end of file