summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorcyBerta <cyberta@riseup.net>2023-08-04 03:23:24 +0200
committercyBerta <cyberta@riseup.net>2023-08-04 03:23:24 +0200
commite81a0f4007d658c644330f4e8e5806236dd1a70d (patch)
treea1949e55130fd20936dc737091b4b592f8e1a57a /app
parent361e2d7867c23430c7b07c58cedfe32313284b0c (diff)
tweak next/cancel button designs
Diffstat (limited to 'app')
-rw-r--r--app/src/main/res/drawable/cust_setup_button_primary.xml8
-rw-r--r--app/src/main/res/drawable/cust_setup_button_primary_disabled.xml19
-rw-r--r--app/src/main/res/drawable/cust_setup_button_primary_pressed.xml10
-rw-r--r--app/src/main/res/drawable/cust_setup_button_primary_released.xml19
-rw-r--r--app/src/main/res/layout/activity_setup.xml2
-rw-r--r--app/src/main/res/values/styles.xml12
6 files changed, 69 insertions, 1 deletions
diff --git a/app/src/main/res/drawable/cust_setup_button_primary.xml b/app/src/main/res/drawable/cust_setup_button_primary.xml
new file mode 100644
index 00000000..245544c3
--- /dev/null
+++ b/app/src/main/res/drawable/cust_setup_button_primary.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="utf-8"?>
+<selector xmlns:android="http://schemas.android.com/apk/res/android" >
+
+ <item android:state_enabled="false" android:drawable="@drawable/cust_setup_button_primary_disabled"/>
+ <item android:state_pressed="true" android:drawable="@drawable/cust_setup_button_primary_pressed"/>
+ <item android:state_focused="true" android:drawable="@drawable/cust_setup_button_primary_pressed"/>
+ <item android:drawable="@drawable/cust_setup_button_primary_released"/>
+</selector> \ No newline at end of file
diff --git a/app/src/main/res/drawable/cust_setup_button_primary_disabled.xml b/app/src/main/res/drawable/cust_setup_button_primary_disabled.xml
new file mode 100644
index 00000000..a8ccfbe1
--- /dev/null
+++ b/app/src/main/res/drawable/cust_setup_button_primary_disabled.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
+ <item>
+ <shape android:shape="rectangle" >
+ <corners android:radius="8dp" />
+ <solid android:color="@color/colorPrimary_transparent"/>
+ </shape>
+ </item>
+ <item
+ android:bottom="@dimen/button_bevel"
+ >
+ <shape android:shape="rectangle">
+ <corners android:radius="8dp" />
+ <padding android:right="2dp"/>
+ <padding android:left="8dp" android:right="8dp"/>
+ <solid android:color="@color/colorDisabled"/>
+ </shape>
+ </item>
+</layer-list> \ No newline at end of file
diff --git a/app/src/main/res/drawable/cust_setup_button_primary_pressed.xml b/app/src/main/res/drawable/cust_setup_button_primary_pressed.xml
new file mode 100644
index 00000000..6fb664d9
--- /dev/null
+++ b/app/src/main/res/drawable/cust_setup_button_primary_pressed.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
+ <item>
+ <shape android:shape="rectangle" >
+ <corners android:radius="8dp" />
+ <padding android:left="8dp" android:right="8dp"/>
+ <solid android:color="@color/colorPrimaryDark"/>
+ </shape>
+ </item>
+</layer-list> \ No newline at end of file
diff --git a/app/src/main/res/drawable/cust_setup_button_primary_released.xml b/app/src/main/res/drawable/cust_setup_button_primary_released.xml
new file mode 100644
index 00000000..80fc091b
--- /dev/null
+++ b/app/src/main/res/drawable/cust_setup_button_primary_released.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
+ <item>
+ <shape android:shape="rectangle" >
+ <corners android:radius="8dp" />
+ <solid android:color="@color/colorPrimary_transparent"/>
+ </shape>
+ </item>
+ <item
+ android:bottom="@dimen/button_bevel"
+ >
+ <shape android:shape="rectangle" >
+ <corners android:radius="8dp" />
+ <padding android:right="2dp"/>
+ <padding android:left="8dp" android:right="8dp"/>
+ <solid android:color="@color/colorPrimary"/>
+ </shape>
+ </item>
+</layer-list> \ No newline at end of file
diff --git a/app/src/main/res/layout/activity_setup.xml b/app/src/main/res/layout/activity_setup.xml
index bb1682d7..26ef2285 100644
--- a/app/src/main/res/layout/activity_setup.xml
+++ b/app/src/main/res/layout/activity_setup.xml
@@ -130,6 +130,7 @@
</LinearLayout>
<Button
+ style="@style/BitmaskSetupButton"
android:id="@+id/setup_next_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -139,6 +140,7 @@
/>
<Button
+ style="@style/BitmaskSetupButton"
android:id="@+id/setup_cancel_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml
index f42be3c1..d59b5150 100644
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -4,7 +4,7 @@
~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt
-->
-<resources>
+<resources xmlns:tools="http://schemas.android.com/tools">
<style name="blinkt.baseTheme" parent="android:Theme.DeviceDefault.Light" />
<style name="blinkt" parent="blinkt.baseTheme" />
@@ -68,6 +68,16 @@
<item name="android:textColor">@color/color_font_btn</item>
</style>
+ <style name="BitmaskSetupButton" parent="android:Widget.Button">
+ <item name="android:background">@drawable/cust_setup_button_primary</item>
+ <item name="android:textAllCaps">false</item>
+ <item name="android:height">36dp</item>
+ <item name="android:minWidth">75dp</item>
+ <item name="android:textColor">@color/colorActionBarTitleFont</item>
+ <item name="android:textFontWeight" tools:targetApi="p">900</item>
+ <item name="android:textStyle">bold</item>
+ </style>
+
<style name="BitmaskActivity">
</style>