diff options
author | cyBerta <cyberta@riseup.net> | 2021-11-15 14:09:17 +0100 |
---|---|---|
committer | cyBerta <cyberta@riseup.net> | 2021-11-15 14:09:17 +0100 |
commit | 580c97e368cd0d9fa47691f70cc31e9b711581ec (patch) | |
tree | c164b25493b9f4c7cb0c505a124d3cc30f6386ed /app/src/main/res/layout | |
parent | aeadefa699db964b1a4ca3ee2bbd45a80ae847a7 (diff) |
implement a new fancy on-off-button
Diffstat (limited to 'app/src/main/res/layout')
-rw-r--r-- | app/src/main/res/layout/f_eip.xml | 4 | ||||
-rw-r--r-- | app/src/main/res/layout/v_main_btn.xml | 52 |
2 files changed, 54 insertions, 2 deletions
diff --git a/app/src/main/res/layout/f_eip.xml b/app/src/main/res/layout/f_eip.xml index e3e8fe0a..b5af785d 100644 --- a/app/src/main/res/layout/f_eip.xml +++ b/app/src/main/res/layout/f_eip.xml @@ -71,8 +71,8 @@ app:srcCompat="@drawable/background_eip" /> - <se.leap.bitmaskclient.base.views.VpnStateImage - android:id="@+id/vpn_state_image" + <se.leap.bitmaskclient.base.views.MainButton + android:id="@+id/main_button" android:layout_width="0dp" android:layout_height="0dp" android:layout_margin="@dimen/stdpadding" diff --git a/app/src/main/res/layout/v_main_btn.xml b/app/src/main/res/layout/v_main_btn.xml new file mode 100644 index 00000000..cf2a3e33 --- /dev/null +++ b/app/src/main/res/layout/v_main_btn.xml @@ -0,0 +1,52 @@ +<?xml version="1.0" encoding="utf-8"?> +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:id="@+id/vpn_btn_container" + xmlns:app="http://schemas.android.com/apk/res-auto" + xmlns:tools="http://schemas.android.com/tools"> + + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/vpn_btn_glow" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:background="@drawable/main_btn_glow" + tools:visibility="visible" + android:visibility="gone" + android:backgroundTint="@color/colorSecondary" + /> + + + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/vpn_btn_shadow_dark" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + app:srcCompat="@drawable/on_off_btn_start_2_enabled" + android:visibility="visible" + /> + + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/vpn_btn_shadow_light" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + tools:visibility="gone" + android:visibility="gone" + /> + + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/vpn_btn_fill" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + app:srcCompat="@drawable/on_off_btn_start_2_no_shadow" + android:visibility="visible" + android:tint="@color/colorPrimaryDark" + /> + + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/vpn_btn_fill_overlay" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + app:srcCompat="@drawable/on_off_btn_fill" + tools:visibility="visible" + /> +</RelativeLayout>
\ No newline at end of file |