aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/res/layout
diff options
context:
space:
mode:
authorAllan Wang <me@allanwang.ca>2019-12-26 16:49:06 -0800
committerAllan Wang <me@allanwang.ca>2019-12-26 16:49:06 -0800
commit6779b1118d9fd2f1e659679d9f2cad3127d0c822 (patch)
treea85a14a15b3cbd3a4f1bca16d414d91d3e817c1f /app/src/main/res/layout
parent42a23c00ae98a0e4a6f493b7d6ce9a23d717e5f6 (diff)
downloadfrost-6779b1118d9fd2f1e659679d9f2cad3127d0c822.tar.gz
frost-6779b1118d9fd2f1e659679d9f2cad3127d0c822.tar.bz2
frost-6779b1118d9fd2f1e659679d9f2cad3127d0c822.zip
Switch to viewbinding and styles and prepare layout wrapper
Diffstat (limited to 'app/src/main/res/layout')
-rw-r--r--app/src/main/res/layout/activity_main.xml16
-rw-r--r--app/src/main/res/layout/activity_main_bottom_tabs.xml23
-rw-r--r--app/src/main/res/layout/activity_main_drawer_wrapper.xml18
3 files changed, 46 insertions, 11 deletions
diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml
index 8fa9283f..f46175d1 100644
--- a/app/src/main/res/layout/activity_main.xml
+++ b/app/src/main/res/layout/activity_main.xml
@@ -13,14 +13,22 @@
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay">
- <include layout="@layout/view_main_toolbar" />
+ <androidx.appcompat.widget.Toolbar
+ android:id="@+id/toolbar"
+ style="@style/Main.Toolbar" />
- <include layout="@layout/view_main_tab_layout" />
+ <com.google.android.material.tabs.TabLayout
+ android:id="@+id/tabs"
+ style="@style/Main.TabLayout" />
</com.google.android.material.appbar.AppBarLayout>
- <include layout="@layout/view_main_viewpager" />
+ <com.pitchedapps.frost.views.FrostViewPager
+ android:id="@+id/viewpager"
+ style="@style/Main.ViewPager" />
- <include layout="@layout/view_main_fab" />
+ <com.google.android.material.floatingactionbutton.FloatingActionButton
+ android:id="@+id/fab"
+ style="@style/Main.Fab" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>
diff --git a/app/src/main/res/layout/activity_main_bottom_tabs.xml b/app/src/main/res/layout/activity_main_bottom_tabs.xml
index 2c2527cd..419bbc33 100644
--- a/app/src/main/res/layout/activity_main_bottom_tabs.xml
+++ b/app/src/main/res/layout/activity_main_bottom_tabs.xml
@@ -3,15 +3,16 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:orientation="vertical">
+ android:fitsSystemWindows="true"
+ android:orientation="vertical"
+ tools:context=".activities.MainActivity">
<androidx.coordinatorlayout.widget.CoordinatorLayout
android:id="@+id/main_content"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
- android:fitsSystemWindows="true"
- tools:context=".activities.MainActivity">
+ android:fitsSystemWindows="true">
<com.google.android.material.appbar.AppBarLayout
android:id="@+id/appbar"
@@ -19,17 +20,25 @@
android:layout_height="wrap_content"
android:theme="@style/AppTheme.AppBarOverlay">
- <include layout="@layout/view_main_toolbar" />
+ <androidx.appcompat.widget.Toolbar
+ android:id="@+id/toolbar"
+ style="@style/Main.Toolbar" />
</com.google.android.material.appbar.AppBarLayout>
- <include layout="@layout/view_main_viewpager" />
+ <com.pitchedapps.frost.views.FrostViewPager
+ android:id="@+id/viewpager"
+ style="@style/Main.ViewPager" />
- <include layout="@layout/view_main_fab" />
+ <com.google.android.material.floatingactionbutton.FloatingActionButton
+ android:id="@+id/fab"
+ style="@style/Main.Fab" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>
- <include layout="@layout/view_main_tab_layout" />
+ <com.google.android.material.tabs.TabLayout
+ android:id="@+id/tabs"
+ style="@style/Main.TabLayout" />
</LinearLayout>
diff --git a/app/src/main/res/layout/activity_main_drawer_wrapper.xml b/app/src/main/res/layout/activity_main_drawer_wrapper.xml
new file mode 100644
index 00000000..4eebf56a
--- /dev/null
+++ b/app/src/main/res/layout/activity_main_drawer_wrapper.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<androidx.drawerlayout.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:fitsSystemWindows="true">
+
+ <FrameLayout
+ android:id="@+id/main_container"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:fitsSystemWindows="true" />
+
+ <com.google.android.material.navigation.NavigationView
+ android:id="@+id/navigation"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:visibility="gone" />
+</androidx.drawerlayout.widget.DrawerLayout> \ No newline at end of file