]> git.ktnx.net Git - mobile-ledger.git/blob - app/src/main/res/layout/main_navigation.xml
whitespace
[mobile-ledger.git] / app / src / main / res / layout / main_navigation.xml
1 <?xml version="1.0" encoding="utf-8"?><!--
2   ~ Copyright © 2020 Damyan Ivanov.
3   ~ This file is part of MoLe.
4   ~ MoLe is free software: you can distribute it and/or modify it
5   ~ under the term of the GNU General Public License as published by
6   ~ the Free Software Foundation, either version 3 of the License, or
7   ~ (at your opinion), any later version.
8   ~
9   ~ MoLe is distributed in the hope that it will be useful,
10   ~ but WITHOUT ANY WARRANTY; without even the implied warranty of
11   ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12   ~ GNU General Public License terms for details.
13   ~
14   ~ You should have received a copy of the GNU General Public License
15   ~ along with MoLe. If not, see <https://www.gnu.org/licenses/>.
16   -->
17
18 <com.google.android.material.navigation.NavigationView xmlns:android="http://schemas.android.com/apk/res/android"
19     xmlns:app="http://schemas.android.com/apk/res-auto"
20     android:id="@+id/nav_view"
21     android:layout_width="wrap_content"
22     android:layout_height="match_parent"
23     android:layout_gravity="start"
24     android:fitsSystemWindows="true"
25     >
26
27
28     <androidx.constraintlayout.widget.ConstraintLayout
29         android:layout_width="match_parent"
30         android:layout_height="match_parent"
31         android:layout_marginBottom="0dp"
32         android:animateLayoutChanges="true"
33         android:orientation="vertical">
34
35         <LinearLayout
36             android:id="@+id/nav_fixed_items"
37             android:layout_width="match_parent"
38             android:layout_height="wrap_content"
39             android:divider="@drawable/list_divider"
40             android:elevation="2dp"
41             android:orientation="vertical"
42             android:showDividers="beginning"
43             android:visibility="gone"
44             app:layout_constraintBottom_toBottomOf="parent">
45
46             <TextView
47                 android:id="@+id/textView2"
48                 style="@style/nav_button"
49                 android:layout_weight="1"
50                 android:drawableStart="@drawable/ic_settings_black_24dp"
51                 android:text="@string/action_settings" />
52
53         </LinearLayout>
54
55         <ScrollView
56             android:layout_width="0dp"
57             android:layout_height="0dp"
58             app:layout_constraintBottom_toTopOf="@+id/nav_fixed_items"
59             app:layout_constraintEnd_toEndOf="parent"
60             app:layout_constraintLeft_toLeftOf="parent"
61             app:layout_constraintStart_toStartOf="parent"
62             app:layout_constraintTop_toTopOf="parent">
63
64             <LinearLayout
65                 android:id="@+id/nav_upper"
66                 android:layout_width="match_parent"
67                 android:layout_height="wrap_content"
68                 android:animateLayoutChanges="true"
69                 android:orientation="vertical"
70                 android:showDividers="beginning"
71                 app:layout_constraintBottom_toTopOf="@+id/nav_fixed_items"
72                 app:layout_constraintTop_toBottomOf="@+id/nav_header">
73
74                 <include layout="@layout/nav_header_layout" />
75
76                 <LinearLayout
77                     android:id="@+id/nav_actions"
78                     android:layout_width="match_parent"
79                     android:layout_height="match_parent"
80                     android:orientation="vertical">
81
82                     <TextView
83                         android:id="@+id/nav_account_summary"
84                         style="@style/nav_button"
85                         android:drawableStart="@drawable/ic_home_black_24dp"
86                         android:onClick="onAccountSummaryClicked"
87                         android:text="@string/account_summary_title" />
88
89                     <TextView
90                         android:id="@+id/nav_latest_transactions"
91                         style="@style/nav_button"
92                         android:drawableStart="@drawable/ic_event_note_black_24dp"
93                         android:onClick="onLatestTransactionsClicked"
94                         android:text="@string/nav_transactions_title" />
95
96                     <TextView
97                         android:id="@+id/textView5"
98                         style="@style/nav_button"
99                         android:drawableStart="@drawable/ic_assignment_black_24dp"
100                         android:text="@string/nav_reports_title"
101                         android:visibility="gone" />
102
103                     <include
104                         android:id="@+id/nav_profile_list_head_layout"
105                         layout="@layout/nav_profile_list_head" />
106
107                     <LinearLayout
108                         android:id="@+id/nav_profile_list_container"
109                         android:layout_width="match_parent"
110                         android:layout_height="wrap_content"
111                         android:animateLayoutChanges="true"
112                         android:nestedScrollingEnabled="false"
113                         android:orientation="vertical">
114
115                         <androidx.recyclerview.widget.RecyclerView
116                             android:id="@+id/nav_profile_list"
117                             android:layout_width="match_parent"
118                             android:layout_height="wrap_content"
119                             android:isScrollContainer="false"
120                             android:nestedScrollingEnabled="false"
121                             android:orientation="vertical">
122
123                         </androidx.recyclerview.widget.RecyclerView>
124
125                     </LinearLayout>
126
127                 </LinearLayout>
128
129             </LinearLayout>
130         </ScrollView>
131
132     </androidx.constraintlayout.widget.ConstraintLayout>
133
134 </com.google.android.material.navigation.NavigationView>