]> gitweb.stoutner.com Git - PrivacyBrowserAndroid.git/blobdiff - app/src/main/res/layout/bookmarks_coordinatorlayout.xml
Change the night access color to light violet. https://redmine.stoutner.com/issues/572
[PrivacyBrowserAndroid.git] / app / src / main / res / layout / bookmarks_coordinatorlayout.xml
index 783a19bc0257b200fe8e11a5c466999cfec63611..798759336d438ca38c2eff6f61133546324d14e6 100644 (file)
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
 
 <!--
-  Copyright 2016 Soren Stoutner <soren@stoutner.com>.
+  Copyright © 2016-2020 Soren Stoutner <soren@stoutner.com>.
 
   This file is part of Privacy Browser <https://www.stoutner.com/privacy-browser>.
 
   You should have received a copy of the GNU General Public License
   along with Privacy Browser.  If not, see <http://www.gnu.org/licenses/>. -->
 
-<!-- android:fitsSystemWindows="true" moves the AppBar below the status bar.
-  When it is specified the theme should include <item name="android:windowTranslucentStatus">true</item>
-  to make the status bar a transparent, darkened overlay. -->
-<android.support.design.widget.CoordinatorLayout
+<androidx.coordinatorlayout.widget.CoordinatorLayout
     android:id="@+id/bookmarks_coordinatorlayout"
     xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:app="http://schemas.android.com/apk/res-auto"
     android:layout_height="match_parent"
-    android:layout_width="match_parent"
-    android:fitsSystemWindows="true" >
+    android:layout_width="match_parent" >
 
-    <!-- the LinearLayout with orientation="vertical" moves the content below the AppBarLayout. -->
+    <!-- The linear layout with `orientation="vertical"` moves the content below the app bar layout. -->
     <LinearLayout
         android:layout_height="match_parent"
         android:layout_width="match_parent"
         android:orientation="vertical" >
 
-        <android.support.design.widget.AppBarLayout
+        <com.google.android.material.appbar.AppBarLayout
             android:id="@+id/bookmarks_appbarlayout"
             android:layout_height="wrap_content"
             android:layout_width="match_parent"
-            android:theme="@style/AppBarOverlay" >
+            android:background="?android:attr/colorBackground" >
 
-            <!-- android:theme="@style/PrivacyBrowser.DarkAppBar" makes the text and icons in the AppBar white. -->
-            <android.support.v7.widget.Toolbar
+            <androidx.appcompat.widget.Toolbar
                 android:id="@+id/bookmarks_toolbar"
                 android:layout_height="wrap_content"
-                android:layout_width="match_parent"
-                android:background="@color/blue"
-                android:theme="@style/DarkAppBar"
-                app:popupTheme="@style/LightPopupOverlay" />
-        </android.support.design.widget.AppBarLayout>
+                android:layout_width="match_parent" />
+        </com.google.android.material.appbar.AppBarLayout>
 
-        <!-- android:choiceMode="multipleChoiceModal" allows the contextual action menu to select more than one item at a time.
-            android:dividerHeight must be specified with android:divider or the height will be 0dp.
-            In our case we want the height to be 0dp. -->
+        <!-- `android:choiceMode="multipleChoiceModal"` allows the contextual action menu to select more than one item at a time.
+            `android:dividerHeight` must be at least `1dp` or the list view is inconsistent in calculating how many bookmarks are displayed. -->
         <ListView
             android:id="@+id/bookmarks_listview"
             android:layout_height="match_parent"
             android:layout_width="match_parent"
             android:choiceMode="multipleChoiceModal"
-            android:divider="@color/white"
-            android:dividerHeight="0dp" />
+            android:divider="@color/transparent"
+            android:dividerHeight="1dp" />
     </LinearLayout>
 
-    <android.support.design.widget.FloatingActionButton
+    <com.google.android.material.floatingactionbutton.FloatingActionButton
+        android:id="@+id/create_bookmark_folder_fab"
+        android:layout_height="wrap_content"
+        android:layout_width="wrap_content"
+        android:layout_gravity="bottom|end"
+        android:layout_marginEnd="16dp"
+        android:layout_marginBottom="85dp"
+        android:src="@drawable/create_folder"
+        android:tint="?attr/fabIconTintColor" />
+
+    <com.google.android.material.floatingactionbutton.FloatingActionButton
         android:id="@+id/create_bookmark_fab"
         android:layout_height="wrap_content"
         android:layout_width="wrap_content"
         android:layout_gravity="bottom|end"
         android:layout_margin="16dp"
-        android:src="@drawable/add" />
-</android.support.design.widget.CoordinatorLayout>
\ No newline at end of file
+        android:src="@drawable/create_bookmark"
+        android:tint="?attr/fabIconTintColor" />
+</androidx.coordinatorlayout.widget.CoordinatorLayout>
\ No newline at end of file