From 47fbc4db7c69ca907711038bed9dbffc0c013a91 Mon Sep 17 00:00:00 2001 From: mhutti1 Date: Sat, 28 Jan 2017 21:00:26 +0000 Subject: [PATCH] Added more comprehensive night mode #353 --- AndroidManifest.xml | 1 - res/layout/activity_bookmarks.xml | 98 ++++++++++--------- res/layout/activity_library.xml | 6 +- res/layout/download_management.xml | 6 +- res/layout/language_selection.xml | 3 +- res/layout/search.xml | 25 +++-- res/layout/settings.xml | 38 ++++--- res/layout/toolbar.xml | 2 +- res/layout/zim_list.xml | 4 +- res/values/colors.xml | 7 +- res/values/styles.xml | 13 ++- .../kiwix/kiwixmobile/BookmarksActivity.java | 11 ++- .../kiwixmobile/KiwixMobileActivity.java | 12 ++- src/org/kiwix/kiwixmobile/SearchActivity.java | 6 ++ .../kiwix/kiwixmobile/ZimManageActivity.java | 6 ++ .../settings/KiwixSettingsActivity.java | 5 + 16 files changed, 156 insertions(+), 87 deletions(-) diff --git a/AndroidManifest.xml b/AndroidManifest.xml index e35595b21..e94c97544 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -40,7 +40,6 @@ diff --git a/res/layout/activity_bookmarks.xml b/res/layout/activity_bookmarks.xml index 4e2f8418c..6203673ad 100644 --- a/res/layout/activity_bookmarks.xml +++ b/res/layout/activity_bookmarks.xml @@ -1,65 +1,73 @@ - + - + + + app:popupTheme="@style/AppTheme.PopupOverlay" + app:theme="@style/AppTheme.AppBarOverlay" /> - - - - + android:layout_height="match_parent"> + + - - - - - + android:visibility="gone" + > - + + + + + - + + + - + diff --git a/res/layout/activity_library.xml b/res/layout/activity_library.xml index 1ba94b914..3fa673821 100644 --- a/res/layout/activity_library.xml +++ b/res/layout/activity_library.xml @@ -8,14 +8,16 @@ + android:layout_height="match_parent" + android:background="?attr/listBackground"> + android:divider="@null" + android:background="?attr/listBackground"/> + android:orientation="vertical" + android:background="?attr/listBackground"> + android:layout_height="wrap_content" + android:background="?attr/listBackground"/> \ No newline at end of file diff --git a/res/layout/language_selection.xml b/res/layout/language_selection.xml index cd755033e..c1e38cff3 100644 --- a/res/layout/language_selection.xml +++ b/res/layout/language_selection.xml @@ -7,6 +7,7 @@ + android:layout_height="wrap_content" + android:background="?attr/listBackground"/> \ No newline at end of file diff --git a/res/layout/search.xml b/res/layout/search.xml index 907c12c76..d1307d4b9 100644 --- a/res/layout/search.xml +++ b/res/layout/search.xml @@ -1,21 +1,30 @@ - - - + + + - + diff --git a/res/layout/settings.xml b/res/layout/settings.xml index 9cb541423..3689c61bc 100644 --- a/res/layout/settings.xml +++ b/res/layout/settings.xml @@ -1,19 +1,29 @@ - + + + android:layout_height="match_parent"> - - - + android:layout_height="?actionBarSize" + android:background="?colorPrimaryDark" + app:popupTheme="@style/AppTheme.PopupOverlay" + app:theme="@style/AppTheme.AppBarOverlay" /> - \ No newline at end of file + + + + \ No newline at end of file diff --git a/res/layout/toolbar.xml b/res/layout/toolbar.xml index 89d6fe4c7..dd09898bc 100644 --- a/res/layout/toolbar.xml +++ b/res/layout/toolbar.xml @@ -18,7 +18,7 @@ android:layout_width="match_parent" android:layout_height="3dp" android:layout_alignParentBottom="true" - app:backgroundColor="@color/primary_dark" + app:backgroundColor="?attr/progressBackgroundColor" app:bidirectionalAnimate="false" app:progressColor="@color/accent"/> diff --git a/res/layout/zim_list.xml b/res/layout/zim_list.xml index b9e19de72..1cb8bc2af 100644 --- a/res/layout/zim_list.xml +++ b/res/layout/zim_list.xml @@ -3,7 +3,8 @@ xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" - android:orientation="vertical"> + android:orientation="vertical" + android:background="?attr/listBackground"> diff --git a/res/values/colors.xml b/res/values/colors.xml index 918f2ab4f..7e560d1e1 100644 --- a/res/values/colors.xml +++ b/res/values/colors.xml @@ -2,7 +2,9 @@ #000000 + #283c64 #000000 + #283c64 #ffffff #304e9a #212121 @@ -11,12 +13,13 @@ #304e9a #FAFAFA #0d000000 - #ffffff + #ffffff + #5a5a5a #0F000000 #2b3f6a #BDBDBD #212121 - #808080 + #5a5a5a #ECEFF1 @android:color/white \ No newline at end of file diff --git a/res/values/styles.xml b/res/values/styles.xml index 57c441240..33a57a005 100644 --- a/res/values/styles.xml +++ b/res/values/styles.xml @@ -18,16 +18,23 @@ true @drawable/ic_action_back @drawable/ic_action_forward - @color/drawer_background + @color/drawer_background_day @drawable/ic_action_plus @drawable/ic_action_delete @color/divider_light @drawable/list_bg_light @color/primary_light + true -