[Android] UI : Action Bar size Material freak adjustment
Alexandre Perraud
git at videolan.org
Tue Mar 31 18:12:36 CEST 2015
vlc-ports/android | branch: master | Alexandre Perraud <4leyx4ndre at gmail.com> | Tue Mar 31 18:11:18 2015 +0200| [18930fa30341ec152d25130439bea15a0e8cedb9] | committer: Alexandre Perraud
UI : Action Bar size Material freak adjustment
> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=18930fa30341ec152d25130439bea15a0e8cedb9
---
vlc-android/res/layout/main.xml | 2 +-
vlc-android/res/layout/sidebar.xml | 2 +-
vlc-android/res/layout/toolbar.xml | 2 +-
vlc-android/res/values-land/dimens.xml | 5 +++++
vlc-android/res/values/dimens.xml | 1 +
vlc-android/res/values/styles.xml | 3 +--
6 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/vlc-android/res/layout/main.xml b/vlc-android/res/layout/main.xml
index 174c0e6..a5489b5 100644
--- a/vlc-android/res/layout/main.xml
+++ b/vlc-android/res/layout/main.xml
@@ -30,7 +30,7 @@
<View
android:layout_width="fill_parent"
- android:layout_height="?attr/actionBarSize"
+ android:layout_height="@dimen/actionBarSize"
android:background="?attr/background_actionbar" />
<FrameLayout
diff --git a/vlc-android/res/layout/sidebar.xml b/vlc-android/res/layout/sidebar.xml
index f15a0d1..6389e4e 100644
--- a/vlc-android/res/layout/sidebar.xml
+++ b/vlc-android/res/layout/sidebar.xml
@@ -10,7 +10,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:focusable="true"
- android:paddingTop="?attr/actionBarSize"
+ android:paddingTop="@dimen/actionBarSize"
android:layout_above="@+id/sidebar_separator_settings"
android:nextFocusForward="@id/sidelist"
android:nextFocusUp="@id/sidelist"
diff --git a/vlc-android/res/layout/toolbar.xml b/vlc-android/res/layout/toolbar.xml
index 1140180..5306785 100644
--- a/vlc-android/res/layout/toolbar.xml
+++ b/vlc-android/res/layout/toolbar.xml
@@ -4,7 +4,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/main_toolbar"
android:layout_width="match_parent"
- android:layout_height="?attr/actionBarSize"
+ android:layout_height="@dimen/actionBarSize"
app:navigationContentDescription="@string/abc_action_bar_up_description"
app:theme="@style/Toolbar.VLC"
app:popupTheme="?attr/toolbar_popup_style"
diff --git a/vlc-android/res/values-land/dimens.xml b/vlc-android/res/values-land/dimens.xml
new file mode 100644
index 0000000..094fb9b
--- /dev/null
+++ b/vlc-android/res/values-land/dimens.xml
@@ -0,0 +1,5 @@
+<resources>
+ <!-- Default -->
+ <dimen name="actionBarSize">48dp</dimen>
+
+</resources>
\ No newline at end of file
diff --git a/vlc-android/res/values/dimens.xml b/vlc-android/res/values/dimens.xml
index 4106c87..8a080bf 100644
--- a/vlc-android/res/values/dimens.xml
+++ b/vlc-android/res/values/dimens.xml
@@ -30,5 +30,6 @@
<!-- Default -->
<dimen name="default_margin">16dp</dimen>
+ <dimen name="actionBarSize">56dp</dimen>
</resources>
\ No newline at end of file
diff --git a/vlc-android/res/values/styles.xml b/vlc-android/res/values/styles.xml
index c366065..e95f09f 100644
--- a/vlc-android/res/values/styles.xml
+++ b/vlc-android/res/values/styles.xml
@@ -4,7 +4,6 @@
<style name="Theme.VLC" parent="Theme.VLC.7"/>
<style name="Theme.VLC.7" parent="Theme.VLC.Apearance">
<item name="actionBarStyle">@style/ActionBar</item>
- <item name="actionBarSize">50dp</item>
<item name="windowActionBarOverlay">true</item>
<item name="drawerArrowStyle">@style/ActionBar.ArrowToggle</item>
</style>
@@ -76,7 +75,6 @@
<style name="Theme.VLC.Black" parent="Theme.VLC.Black.7"/>
<style name="Theme.VLC.Black.7" parent="Theme.VLC.Apearance.Black">
<item name="actionBarStyle">@style/ActionBar</item>
- <item name="actionBarSize">50dp</item>
<item name="windowActionBarOverlay">true</item>
<item name="drawerArrowStyle">@style/ActionBar.ArrowToggle</item>
</style>
@@ -174,6 +172,7 @@
<style name="ActionBar" parent="Widget.AppCompat.Light.ActionBar">
<item name="titleTextStyle">@style/ActionBar.Text</item>
+ <item name="android:height">@dimen/actionBarSize</item>
</style>
<style name="ActionBar.Text" parent="TextAppearance.AppCompat.Widget.ActionBar.Title">
More information about the Android
mailing list