summaryrefslogtreecommitdiff
path: root/app/src/main/res/layout
diff options
context:
space:
mode:
authorfupduck <fupduck@riseup.net>2018-02-26 10:14:30 -0800
committerfupduck <fupduck@riseup.net>2018-02-26 10:14:30 -0800
commit64dfeed947ed79abc8ff4208b9331689f525dac5 (patch)
treeffc72ccc9a45266502bbca2c78a39d52511c03fc /app/src/main/res/layout
parent45065d30e0f2c61ca654587bab765959fdf4931f (diff)
parente02f1648353dad012c3c556f996a667640da11ce (diff)
Merge branch '#8754_reduce_battery_consumption' into '0.9.8'
#8754 reduce battery consumption See merge request leap/bitmask_android!54
Diffstat (limited to 'app/src/main/res/layout')
-rw-r--r--app/src/main/res/layout/drawer_main.xml48
-rw-r--r--app/src/main/res/layout/switch_list_item.xml15
2 files changed, 48 insertions, 15 deletions
diff --git a/app/src/main/res/layout/drawer_main.xml b/app/src/main/res/layout/drawer_main.xml
index 26267bbb..54614f3f 100644
--- a/app/src/main/res/layout/drawer_main.xml
+++ b/app/src/main/res/layout/drawer_main.xml
@@ -1,13 +1,13 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:tools="http://schemas.android.com/tools"
- xmlns:app="http://schemas.android.com/apk/res-auto"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:orientation="vertical"
- android:background="@color/colorBackground"
- tools:context="se.leap.bitmaskclient.drawer.NavigationDrawerFragment"
- android:clickable="true"
- android:focusable="true">
+ xmlns:tools="http://schemas.android.com/tools"
+ xmlns:app="http://schemas.android.com/apk/res-auto"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical"
+ android:background="@color/colorBackground"
+ tools:context="se.leap.bitmaskclient.drawer.NavigationDrawerFragment"
+ android:clickable="true"
+ android:focusable="true">
<FrameLayout
android:layout_width="match_parent"
@@ -28,7 +28,6 @@
android:layout_height="wrap_content"
app:srcCompat="@drawable/mask" />
</FrameLayout>
-
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
@@ -37,14 +36,33 @@
<ListView
android:id="@+id/accountList"
android:layout_width="match_parent"
- android:layout_height="wrap_content" />
+ android:layout_height="wrap_content"
+ android:isScrollContainer="false"
+ />
- <ListView
- android:id="@+id/settingsList"
+ <View
+ android:id="@+id/divider"
+ android:layout_below="@id/accountList"
+ android:layout_width="match_parent"
+ android:layout_height="1px"
+ android:background="@android:color/darker_gray"
+ />
+
+ <FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_gravity="bottom"
- android:layout_alignParentBottom="true" />
+ android:layout_alignTop="@id/divider"
+ android:layout_alignParentBottom="true"
+ >
+ <ListView
+ android:id="@+id/settingsList"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_gravity="bottom"
+ />
+ </FrameLayout>
+
+
</RelativeLayout>
diff --git a/app/src/main/res/layout/switch_list_item.xml b/app/src/main/res/layout/switch_list_item.xml
new file mode 100644
index 00000000..bdb9a74c
--- /dev/null
+++ b/app/src/main/res/layout/switch_list_item.xml
@@ -0,0 +1,15 @@
+<android.support.v7.widget.SwitchCompat xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:tools="http://schemas.android.com/tools"
+ android:id="@android:id/text1"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:textAppearance="?android:attr/textAppearanceListItemSmall"
+ android:gravity="center_vertical"
+ android:paddingStart="?android:attr/listPreferredItemPaddingStart"
+ android:paddingLeft="?android:attr/listPreferredItemPaddingLeft"
+ android:paddingEnd="?android:attr/listPreferredItemPaddingEnd"
+ android:paddingRight="?android:attr/listPreferredItemPaddingRight"
+ android:background="?android:attr/activatedBackgroundIndicator"
+ android:minHeight="?android:attr/listPreferredItemHeightSmall"
+ android:checked="false"
+ tools:text="someOption" /> \ No newline at end of file