aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/res
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/res')
-rw-r--r--src/main/res/drawable-hdpi/switch_thumb_disable.pngbin0 -> 1926 bytes
-rw-r--r--src/main/res/drawable-hdpi/switch_thumb_off_normal.pngbin0 -> 1949 bytes
-rw-r--r--src/main/res/drawable-hdpi/switch_thumb_off_pressed.pngbin0 -> 3478 bytes
-rw-r--r--src/main/res/drawable-hdpi/switch_thumb_on_normal.pngbin0 -> 1920 bytes
-rw-r--r--src/main/res/drawable-hdpi/switch_thumb_on_pressed.pngbin0 -> 3571 bytes
-rw-r--r--src/main/res/drawable-mdpi/switch_thumb_disable.pngbin0 -> 1239 bytes
-rw-r--r--src/main/res/drawable-mdpi/switch_thumb_off_normal.pngbin0 -> 1267 bytes
-rw-r--r--src/main/res/drawable-mdpi/switch_thumb_off_pressed.pngbin0 -> 2233 bytes
-rw-r--r--src/main/res/drawable-mdpi/switch_thumb_on_normal.pngbin0 -> 1256 bytes
-rw-r--r--src/main/res/drawable-mdpi/switch_thumb_on_pressed.pngbin0 -> 2286 bytes
-rw-r--r--src/main/res/drawable-xhdpi/switch_thumb_disable.pngbin0 -> 2762 bytes
-rw-r--r--src/main/res/drawable-xhdpi/switch_thumb_off_normal.pngbin0 -> 2817 bytes
-rw-r--r--src/main/res/drawable-xhdpi/switch_thumb_off_pressed.pngbin0 -> 5050 bytes
-rw-r--r--src/main/res/drawable-xhdpi/switch_thumb_on_normal.pngbin0 -> 2789 bytes
-rw-r--r--src/main/res/drawable-xhdpi/switch_thumb_on_pressed.pngbin0 -> 5328 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/switch_thumb_disable.pngbin0 -> 4539 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/switch_thumb_off_normal.pngbin0 -> 4602 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/switch_thumb_off_pressed.pngbin0 -> 8315 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/switch_thumb_on_normal.pngbin0 -> 4557 bytes
-rw-r--r--src/main/res/drawable-xxhdpi/switch_thumb_on_pressed.pngbin0 -> 8899 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/switch_thumb_disable.pngbin0 -> 6854 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/switch_thumb_off_normal.pngbin0 -> 7000 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/switch_thumb_off_pressed.pngbin0 -> 11984 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/switch_thumb_on_normal.pngbin0 -> 7037 bytes
-rw-r--r--src/main/res/drawable-xxxhdpi/switch_thumb_on_pressed.pngbin0 -> 12753 bytes
-rw-r--r--src/main/res/drawable/switch_back_off.xml15
-rw-r--r--src/main/res/drawable/switch_back_on.xml16
-rw-r--r--src/main/res/drawable/switch_thumb.xml12
-rw-r--r--src/main/res/layout/account_row.xml5
-rw-r--r--src/main/res/values/styles.xml14
30 files changed, 58 insertions, 4 deletions
diff --git a/src/main/res/drawable-hdpi/switch_thumb_disable.png b/src/main/res/drawable-hdpi/switch_thumb_disable.png
new file mode 100644
index 00000000..1e9b151b
--- /dev/null
+++ b/src/main/res/drawable-hdpi/switch_thumb_disable.png
Binary files differ
diff --git a/src/main/res/drawable-hdpi/switch_thumb_off_normal.png b/src/main/res/drawable-hdpi/switch_thumb_off_normal.png
new file mode 100644
index 00000000..b7c1fc11
--- /dev/null
+++ b/src/main/res/drawable-hdpi/switch_thumb_off_normal.png
Binary files differ
diff --git a/src/main/res/drawable-hdpi/switch_thumb_off_pressed.png b/src/main/res/drawable-hdpi/switch_thumb_off_pressed.png
new file mode 100644
index 00000000..ca6e4909
--- /dev/null
+++ b/src/main/res/drawable-hdpi/switch_thumb_off_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-hdpi/switch_thumb_on_normal.png b/src/main/res/drawable-hdpi/switch_thumb_on_normal.png
new file mode 100644
index 00000000..cbcda5d4
--- /dev/null
+++ b/src/main/res/drawable-hdpi/switch_thumb_on_normal.png
Binary files differ
diff --git a/src/main/res/drawable-hdpi/switch_thumb_on_pressed.png b/src/main/res/drawable-hdpi/switch_thumb_on_pressed.png
new file mode 100644
index 00000000..234b12dc
--- /dev/null
+++ b/src/main/res/drawable-hdpi/switch_thumb_on_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/switch_thumb_disable.png b/src/main/res/drawable-mdpi/switch_thumb_disable.png
new file mode 100644
index 00000000..968de345
--- /dev/null
+++ b/src/main/res/drawable-mdpi/switch_thumb_disable.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/switch_thumb_off_normal.png b/src/main/res/drawable-mdpi/switch_thumb_off_normal.png
new file mode 100644
index 00000000..51fb4d7a
--- /dev/null
+++ b/src/main/res/drawable-mdpi/switch_thumb_off_normal.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/switch_thumb_off_pressed.png b/src/main/res/drawable-mdpi/switch_thumb_off_pressed.png
new file mode 100644
index 00000000..ca788445
--- /dev/null
+++ b/src/main/res/drawable-mdpi/switch_thumb_off_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/switch_thumb_on_normal.png b/src/main/res/drawable-mdpi/switch_thumb_on_normal.png
new file mode 100644
index 00000000..6a93d5f7
--- /dev/null
+++ b/src/main/res/drawable-mdpi/switch_thumb_on_normal.png
Binary files differ
diff --git a/src/main/res/drawable-mdpi/switch_thumb_on_pressed.png b/src/main/res/drawable-mdpi/switch_thumb_on_pressed.png
new file mode 100644
index 00000000..e8d7bd0f
--- /dev/null
+++ b/src/main/res/drawable-mdpi/switch_thumb_on_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/switch_thumb_disable.png b/src/main/res/drawable-xhdpi/switch_thumb_disable.png
new file mode 100644
index 00000000..7f677324
--- /dev/null
+++ b/src/main/res/drawable-xhdpi/switch_thumb_disable.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/switch_thumb_off_normal.png b/src/main/res/drawable-xhdpi/switch_thumb_off_normal.png
new file mode 100644
index 00000000..4199d322
--- /dev/null
+++ b/src/main/res/drawable-xhdpi/switch_thumb_off_normal.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/switch_thumb_off_pressed.png b/src/main/res/drawable-xhdpi/switch_thumb_off_pressed.png
new file mode 100644
index 00000000..2b86888f
--- /dev/null
+++ b/src/main/res/drawable-xhdpi/switch_thumb_off_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/switch_thumb_on_normal.png b/src/main/res/drawable-xhdpi/switch_thumb_on_normal.png
new file mode 100644
index 00000000..daa30990
--- /dev/null
+++ b/src/main/res/drawable-xhdpi/switch_thumb_on_normal.png
Binary files differ
diff --git a/src/main/res/drawable-xhdpi/switch_thumb_on_pressed.png b/src/main/res/drawable-xhdpi/switch_thumb_on_pressed.png
new file mode 100644
index 00000000..6aab47c9
--- /dev/null
+++ b/src/main/res/drawable-xhdpi/switch_thumb_on_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/switch_thumb_disable.png b/src/main/res/drawable-xxhdpi/switch_thumb_disable.png
new file mode 100644
index 00000000..db7c1df4
--- /dev/null
+++ b/src/main/res/drawable-xxhdpi/switch_thumb_disable.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/switch_thumb_off_normal.png b/src/main/res/drawable-xxhdpi/switch_thumb_off_normal.png
new file mode 100644
index 00000000..f747b559
--- /dev/null
+++ b/src/main/res/drawable-xxhdpi/switch_thumb_off_normal.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/switch_thumb_off_pressed.png b/src/main/res/drawable-xxhdpi/switch_thumb_off_pressed.png
new file mode 100644
index 00000000..b9fe6d46
--- /dev/null
+++ b/src/main/res/drawable-xxhdpi/switch_thumb_off_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/switch_thumb_on_normal.png b/src/main/res/drawable-xxhdpi/switch_thumb_on_normal.png
new file mode 100644
index 00000000..88199024
--- /dev/null
+++ b/src/main/res/drawable-xxhdpi/switch_thumb_on_normal.png
Binary files differ
diff --git a/src/main/res/drawable-xxhdpi/switch_thumb_on_pressed.png b/src/main/res/drawable-xxhdpi/switch_thumb_on_pressed.png
new file mode 100644
index 00000000..7a4fed54
--- /dev/null
+++ b/src/main/res/drawable-xxhdpi/switch_thumb_on_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/switch_thumb_disable.png b/src/main/res/drawable-xxxhdpi/switch_thumb_disable.png
new file mode 100644
index 00000000..3970168c
--- /dev/null
+++ b/src/main/res/drawable-xxxhdpi/switch_thumb_disable.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/switch_thumb_off_normal.png b/src/main/res/drawable-xxxhdpi/switch_thumb_off_normal.png
new file mode 100644
index 00000000..ea8d4f89
--- /dev/null
+++ b/src/main/res/drawable-xxxhdpi/switch_thumb_off_normal.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/switch_thumb_off_pressed.png b/src/main/res/drawable-xxxhdpi/switch_thumb_off_pressed.png
new file mode 100644
index 00000000..84d667b1
--- /dev/null
+++ b/src/main/res/drawable-xxxhdpi/switch_thumb_off_pressed.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/switch_thumb_on_normal.png b/src/main/res/drawable-xxxhdpi/switch_thumb_on_normal.png
new file mode 100644
index 00000000..06b190eb
--- /dev/null
+++ b/src/main/res/drawable-xxxhdpi/switch_thumb_on_normal.png
Binary files differ
diff --git a/src/main/res/drawable-xxxhdpi/switch_thumb_on_pressed.png b/src/main/res/drawable-xxxhdpi/switch_thumb_on_pressed.png
new file mode 100644
index 00000000..79c30d1e
--- /dev/null
+++ b/src/main/res/drawable-xxxhdpi/switch_thumb_on_pressed.png
Binary files differ
diff --git a/src/main/res/drawable/switch_back_off.xml b/src/main/res/drawable/switch_back_off.xml
new file mode 100644
index 00000000..20d2fb14
--- /dev/null
+++ b/src/main/res/drawable/switch_back_off.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+
+ <item android:state_enabled="false"><shape android:shape="rectangle">
+ <solid android:color="#D5D5D5" />
+
+ <corners android:radius="99dp" />
+ </shape></item>
+ <item android:state_enabled="true"><shape android:shape="rectangle">
+ <solid android:color="#939393" />
+
+ <corners android:radius="99dp" />
+ </shape></item>
+
+</selector> \ No newline at end of file
diff --git a/src/main/res/drawable/switch_back_on.xml b/src/main/res/drawable/switch_back_on.xml
new file mode 100644
index 00000000..45117a98
--- /dev/null
+++ b/src/main/res/drawable/switch_back_on.xml
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:state_enabled="false">
+ <shape android:shape="rectangle">
+ <solid android:color="#D5D5D5"/>
+ <corners android:radius="99dp"/>
+ </shape>
+ </item>
+ <item android:state_enabled="true">
+ <shape android:shape="rectangle">
+ <!-- 30% accent on white -->
+ <solid android:color="#b3ddf7"/>
+ <corners android:radius="99dp"/>
+ </shape>
+ </item>
+</selector> \ No newline at end of file
diff --git a/src/main/res/drawable/switch_thumb.xml b/src/main/res/drawable/switch_thumb.xml
new file mode 100644
index 00000000..ba3d1c45
--- /dev/null
+++ b/src/main/res/drawable/switch_thumb.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+
+ <item android:drawable="@drawable/switch_thumb_disable" android:state_enabled="false"/>
+ <item android:drawable="@drawable/switch_thumb_on_pressed" android:state_checked="true" android:state_pressed="true"/>
+ <item android:drawable="@drawable/switch_thumb_on_pressed" android:state_checked="true" android:state_focused="true"/>
+ <item android:drawable="@drawable/switch_thumb_on_normal" android:state_checked="true"/>
+ <item android:drawable="@drawable/switch_thumb_off_pressed" android:state_checked="false" android:state_pressed="true"/>
+ <item android:drawable="@drawable/switch_thumb_off_pressed" android:state_checked="false" android:state_focused="true"/>
+ <item android:drawable="@drawable/switch_thumb_off_normal" android:state_checked="false"/>
+
+</selector> \ No newline at end of file
diff --git a/src/main/res/layout/account_row.xml b/src/main/res/layout/account_row.xml
index 06716a10..077170b2 100644
--- a/src/main/res/layout/account_row.xml
+++ b/src/main/res/layout/account_row.xml
@@ -45,13 +45,14 @@
android:textStyle="bold" />
</LinearLayout>
- <Switch
+ <eu.siacs.conversations.ui.widget.Switch
+ style="@style/MD"
android:id="@+id/tgl_account_status"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
- android:padding="8dp"
+ android:padding="16dp"
android:focusable="false"/>
</RelativeLayout> \ No newline at end of file
diff --git a/src/main/res/values/styles.xml b/src/main/res/values/styles.xml
index b98a37fc..e8572d9d 100644
--- a/src/main/res/values/styles.xml
+++ b/src/main/res/values/styles.xml
@@ -4,8 +4,18 @@
<item name="android:layout_height">1.5dp</item>
<item name="android:background">@color/black12</item>
</style>
- <style name="Tag">
-
+ <style name="MD">
+ <item name="animationVelocity">6</item>
+ <item name="insetBottom">16dp</item>
+ <item name="insetTop">16dp</item>
+ <item name="insetLeft">16dp</item>
+ <item name="insetRight">16dp</item>
+ <item name="measureFactor">1.4</item>
+ <item name="offDrawable">@drawable/switch_back_off</item>
+ <item name="onDrawable">@drawable/switch_back_on</item>
+ <item name="thumbDrawable">@drawable/switch_thumb</item>
+ <item name="thumb_margin">-17dp</item>
+ <item name="android:padding">16dp</item>
</style>
</resources> \ No newline at end of file