diff options
author | cyberta <cyberta@riseup.net> | 2021-11-24 09:26:40 +0000 |
---|---|---|
committer | cyberta <cyberta@riseup.net> | 2021-11-24 09:26:40 +0000 |
commit | 68ca9c827da3c3fad9e70c74960f113560fd6711 (patch) | |
tree | dda6f99c2ef2b222d4f07d0ef80d5d0cc373604e /app/src/main/res/layout | |
parent | 9b2b57d8617e60c0b69713e1e5f14dbb8e57c70a (diff) | |
parent | e3cd28aa6ef16d9bde179a3e1117cdfa585939a4 (diff) |
Merge branch 'simply_secure_UI_changes' into 'master'
Gateway selection UI overhaul
Closes #9047
See merge request leap/bitmask_android!140
Diffstat (limited to 'app/src/main/res/layout')
24 files changed, 648 insertions, 267 deletions
diff --git a/app/src/main/res/layout/allowed_application_layout.xml b/app/src/main/res/layout/allowed_application_layout.xml index d8d846f9..61fc12c3 100644 --- a/app/src/main/res/layout/allowed_application_layout.xml +++ b/app/src/main/res/layout/allowed_application_layout.xml @@ -23,11 +23,11 @@ android:layout_rowSpan="1" android:layout_marginEnd="8dip" android:scaleType="centerInside" - tools:background="@drawable/icon" + tools:background="@drawable/ic_btn_on_connecting" android:contentDescription="@null" /> - <TextView - tools:text="@string/app" + <androidx.appcompat.widget.AppCompatTextView + tools:text="@string/app_name" android:id="@+id/app_name" android:layout_width="0dip" android:layout_columnSpan="2" @@ -39,23 +39,12 @@ android:textAppearance="?android:attr/textAppearanceMedium" android:textAlignment="viewStart" /> - <CheckBox android:id="@+id/app_selected" - android:layout_marginStart="8dip" + <se.leap.bitmaskclient.base.views.SimpleCheckBox + android:id="@+id/app_selected" + android:layout_height="32dp" + android:layout_width="32dp" android:layout_gravity="center_vertical" android:layout_rowSpan="1" android:visibility="visible" /> -<!-- <TextView - android:id="@+id/app_size" - android:layout_width="0dip" - android:layout_gravity="fill_horizontal|top" - android:textAppearance="?android:attr/textAppearanceSmall" - android:textAlignment="viewStart" /> --> - - <!-- <TextView - android:id="@+id/app_disabled" - android:layout_marginStart="8dip" - android:layout_gravity="top" - android:textAppearance="?android:attr/textAppearanceSmall" /> --> - </GridLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout/allowed_vpn_apps.xml b/app/src/main/res/layout/allowed_vpn_apps.xml index c1711d56..f76b5f4f 100644 --- a/app/src/main/res/layout/allowed_vpn_apps.xml +++ b/app/src/main/res/layout/allowed_vpn_apps.xml @@ -10,7 +10,7 @@ tools:ignore="RtlCompat" android:layout_height="match_parent"> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:gravity="center" @@ -50,7 +50,7 @@ android:layout_width="wrap_content" android:layout_height="wrap_content" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceSmall" diff --git a/app/src/main/res/layout/custom_toast.xml b/app/src/main/res/layout/custom_toast.xml index 70a9df8c..c267fb86 100644 --- a/app/src/main/res/layout/custom_toast.xml +++ b/app/src/main/res/layout/custom_toast.xml @@ -13,7 +13,7 @@ android:layout_marginRight="8dp" android:layout_gravity="center" /> - <TextView android:id="@+id/text" + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/text" android:textAppearance="@style/Base.TextAppearance.AppCompat.Medium" android:layout_width="wrap_content" android:layout_height="wrap_content" diff --git a/app/src/main/res/layout/donation_reminder_dialog.xml b/app/src/main/res/layout/donation_reminder_dialog.xml index 3af36086..d6b6ea80 100644 --- a/app/src/main/res/layout/donation_reminder_dialog.xml +++ b/app/src/main/res/layout/donation_reminder_dialog.xml @@ -11,7 +11,7 @@ android:gravity="center" android:orientation="vertical"> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/tvTitle" android:layout_width="match_parent" android:layout_height="wrap_content" @@ -24,7 +24,7 @@ android:textSize="28sp" android:textStyle="bold" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/tvMessage" android:layout_width="match_parent" android:layout_height="wrap_content" diff --git a/app/src/main/res/layout/f_about.xml b/app/src/main/res/layout/f_about.xml index ec7369ef..b10cc555 100644 --- a/app/src/main/res/layout/f_about.xml +++ b/app/src/main/res/layout/f_about.xml @@ -12,7 +12,7 @@ android:layout_height="wrap_content" android:orientation="vertical" > - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/version" android:layout_width="match_parent" android:layout_height="wrap_content" @@ -22,7 +22,7 @@ android:layout_width="match_parent" android:layout_height="10sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/terms_of_service" android:layout_width="match_parent" android:layout_height="wrap_content" @@ -31,7 +31,7 @@ android:paddingBottom="12dp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:autoLink="all" @@ -41,7 +41,7 @@ android:layout_width="match_parent" android:layout_height="10sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:autoLink="all" @@ -52,13 +52,13 @@ android:layout_width="match_parent" android:layout_height="10sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:autoLink="all" android:text="@string/repository_url_text" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:autoLink="all" @@ -68,7 +68,7 @@ android:layout_width="match_parent" android:layout_height="10sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:autoLink="all" @@ -78,7 +78,7 @@ android:layout_width="match_parent" android:layout_height="10sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:autoLink="all" @@ -88,7 +88,7 @@ android:layout_width="match_parent" android:layout_height="10sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_others" /> @@ -97,7 +97,7 @@ android:layout_width="match_parent" android:layout_height="10sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/openvpn" @@ -110,7 +110,7 @@ android:src="@drawable/openvpnLogo" /> --> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/opevpn_copyright" /> @@ -119,13 +119,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/lzo" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/lzo_copyright" /> @@ -134,13 +134,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/openssl" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_openssl" /> @@ -149,13 +149,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/okhttp" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_okhttp" /> @@ -164,13 +164,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/mbetTLS" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:autoLink="web" @@ -180,13 +180,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/asio" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_asio" /> @@ -195,13 +195,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/openvpn3" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_openvpn3" /> @@ -210,13 +210,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/shapeshifter_library" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_shapeshifter_library" /> @@ -225,13 +225,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/shapeshifter_dispatcher" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_shapeshifter_dispatcher" /> @@ -240,13 +240,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/shapeshifter_transports" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_shapeshifter_transports" /> @@ -255,13 +255,13 @@ android:layout_width="match_parent" android:layout_height="20sp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/circleImageView" android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/copyright_circleImageView" /> diff --git a/app/src/main/res/layout/f_drawer_main.xml b/app/src/main/res/layout/f_drawer_main.xml index 1f1df7f2..65179857 100644 --- a/app/src/main/res/layout/f_drawer_main.xml +++ b/app/src/main/res/layout/f_drawer_main.xml @@ -101,14 +101,14 @@ <se.leap.bitmaskclient.base.views.IconTextEntry android:id="@+id/manualGatewaySelection" app:text="@string/gateway_selection_title" - app:subtitle="@string/gateway_selection_best_location" - app:icon="@drawable/ic_map_marker_star_black_36dp" + app:subtitle="@string/gateway_selection_recommended_location" + app:icon="@drawable/ic_web" android:layout_height="wrap_content" android:layout_width="wrap_content" android:visibility="gone" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/show_experimental_features" android:layout_width="match_parent" android:layout_height="wrap_content" diff --git a/app/src/main/res/layout/f_eip.xml b/app/src/main/res/layout/f_eip.xml index 3309eb5d..b5af785d 100644 --- a/app/src/main/res/layout/f_eip.xml +++ b/app/src/main/res/layout/f_eip.xml @@ -1,4 +1,8 @@ <?xml version="1.0" encoding="utf-8"?> +<!-- + This is the default layout for landscape, portrait can be found + in layout-port +--> <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" @@ -12,9 +16,8 @@ android:layout_height="0dp" android:orientation="horizontal" app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintRight_toRightOf="parent" - app:layout_constraintGuide_percent="0.225" - /> + app:layout_constraintGuide_percent="0.1" + app:layout_constraintRight_toRightOf="parent" /> <androidx.constraintlayout.widget.Guideline android:id="@+id/guideline_vertical_left" @@ -22,8 +25,7 @@ android:layout_height="0dp" android:orientation="vertical" app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintGuide_percent="0.225" - /> + app:layout_constraintGuide_percent="0.3" /> <androidx.constraintlayout.widget.Guideline @@ -32,18 +34,34 @@ android:layout_height="0dp" android:orientation="horizontal" app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintRight_toRightOf="parent" - app:layout_constraintGuide_percent="0.775" + app:layout_constraintGuide_percent="0.55" + app:layout_constraintRight_toRightOf="parent" /> + + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_horizontal_button_top" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="horizontal" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.8" /> <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_horizontal_button_bottom" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="horizontal" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.98" + app:layout_constraintRight_toRightOf="parent" /> + + <androidx.constraintlayout.widget.Guideline android:id="@+id/guideline_vertical_right" android:layout_width="0dp" android:layout_height="0dp" android:orientation="vertical" app:layout_constraintBottom_toBottomOf="parent" - app:layout_constraintGuide_percent="0.775" - /> + app:layout_constraintGuide_percent="0.7" /> <androidx.appcompat.widget.AppCompatImageView android:id="@+id/background" @@ -53,83 +71,73 @@ app:srcCompat="@drawable/background_eip" /> - <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/eipLabel" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:paddingLeft="@dimen/stdpadding" - android:paddingRight="@dimen/stdpadding" - android:paddingStart="@dimen/stdpadding" - android:paddingEnd="@dimen/stdpadding" - android:paddingTop="@dimen/stdpadding" - android:text="@string/eip_service_label" - android:textAppearance="?android:attr/textAppearanceMedium" - android:gravity="center" - app:layout_constraintEnd_toEndOf="parent" - app:layout_constraintStart_toStartOf="parent" - app:layout_constraintTop_toTopOf="parent" /> - - - <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" + app:layout_constraintTop_toBottomOf="@id/guideline_horizontal_top" app:layout_constraintBottom_toTopOf="@+id/guideline_horizontal_bottom" app:layout_constraintEnd_toStartOf="@+id/guideline_vertical_right" app:layout_constraintStart_toStartOf="@+id/guideline_vertical_left" - app:layout_constraintTop_toTopOf="@+id/guideline_horizontal_top" app:layout_constraintDimensionRatio="1:1" /> - <androidx.appcompat.widget.AppCompatButton - android:id="@+id/vpn_main_button" - android:layout_width="wrap_content" - android:layout_height="32dp" - android:minWidth="150dp" - android:layout_marginBottom="@dimen/stdpadding" - android:layout_marginEnd="@dimen/stdpadding" - android:layout_marginStart="@dimen/stdpadding" - android:layout_marginTop="@dimen/stdpadding" - android:layout_marginLeft="@dimen/stdpadding" - android:layout_marginRight="@dimen/stdpadding" - android:paddingLeft="@dimen/stdpadding" - android:paddingRight="@dimen/stdpadding" - app:layout_constraintBottom_toBottomOf="@+id/background" - app:layout_constraintEnd_toEndOf="parent" - app:layout_constraintStart_toStartOf="parent" - android:text="@string/vpn.button.turn.on" - tools:text="Turn on in another language" - style="@style/BitmaskButtonBlack" - /> - <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/routed_text" + android:id="@+id/main_description" android:layout_width="wrap_content" android:layout_height="wrap_content" + app:layout_constraintTop_toBottomOf="@id/guideline_horizontal_bottom" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintBottom_toTopOf="@+id/sub_description" android:paddingLeft="@dimen/stdpadding" - android:paddingRight="@dimen/stdpadding" android:paddingStart="@dimen/stdpadding" + android:paddingRight="@dimen/stdpadding" android:paddingEnd="@dimen/stdpadding" - android:paddingTop="@dimen/stdpadding" - android:text="@string/vpn_securely_routed" - android:gravity="center" - android:visibility="visible" - app:layout_constraintEnd_toEndOf="parent" - app:layout_constraintStart_toStartOf="parent" - app:layout_constraintTop_toBottomOf="@+id/eipLabel" /> + android:textAppearance="@android:style/TextAppearance.DeviceDefault.Large" + android:textStyle="bold" + android:textColor="@color/colorEipFragmentFont" + app:layout_constraintDimensionRatio="1:1" + tools:text="CONNETION SECURE" + /> <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/vpn_route" + android:id="@+id/sub_description" android:layout_width="wrap_content" android:layout_height="wrap_content" + app:layout_constraintTop_toBottomOf="@id/main_description" + app:layout_constraintStart_toStartOf="parent" + app:layout_constraintEnd_toEndOf="parent" + app:layout_constraintBottom_toTopOf="@+id/gateway_location_button" + android:textAppearance="@android:style/TextAppearance.DeviceDefault.Medium" + android:textStyle="bold" + android:textColor="@color/colorEipFragmentFont" android:paddingLeft="@dimen/stdpadding" - android:paddingRight="@dimen/stdpadding" android:paddingStart="@dimen/stdpadding" + android:paddingRight="@dimen/stdpadding" android:paddingEnd="@dimen/stdpadding" + android:paddingBottom="@dimen/stdpadding" + app:layout_constraintDimensionRatio="1:1" + tools:text="Your traffic is securly routed through \n another" + android:maxLines="2" android:gravity="center" + /> + + <se.leap.bitmaskclient.base.views.LocationButton + android:id="@+id/gateway_location_button" + android:layout_width="match_parent" + android:layout_height="0dp" + android:layout_marginEnd="@dimen/stdpadding" + android:layout_marginStart="@dimen/stdpadding" + + android:layout_marginLeft="@dimen/stdpadding" + android:layout_marginRight="@dimen/stdpadding" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" - app:layout_constraintTop_toBottomOf="@+id/routed_text" /> + app:layout_constraintTop_toBottomOf="@id/guideline_horizontal_button_top" + app:layout_constraintBottom_toBottomOf="@+id/guideline_horizontal_button_bottom" + tools:text="SEATTLE" + android:gravity="center_vertical" /> </androidx.constraintlayout.widget.ConstraintLayout> diff --git a/app/src/main/res/layout/f_gateway_selection.xml b/app/src/main/res/layout/f_gateway_selection.xml index f96b9c08..643ae988 100644 --- a/app/src/main/res/layout/f_gateway_selection.xml +++ b/app/src/main/res/layout/f_gateway_selection.xml @@ -3,7 +3,7 @@ xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" - xmlns:app="http://schemas.android.com/apk/res-auto" + android:padding="@dimen/stdpadding" tools:context=".base.fragments.GatewaySelectionFragment"> <LinearLayout @@ -11,59 +11,57 @@ android:orientation="vertical" android:layout_width="match_parent" android:layout_height="wrap_content" - android:visibility="gone" + android:visibility="visible" tools:visibility="visible" + android:layout_alignParentTop="true" > - <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/current_location_description" + <LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" - android:textAppearance="?android:attr/textAppearanceMedium" - android:paddingTop="@dimen/activity_vertical_margin" - android:paddingStart="@dimen/activity_horizontal_margin" - android:paddingLeft="@dimen/activity_horizontal_margin" - android:paddingEnd="@dimen/activity_horizontal_margin" - android:paddingRight="@dimen/activity_horizontal_margin" - android:paddingBottom="@dimen/activity_vertical_margin" - android:text="@string/vpn_securely_routed" /> + android:orientation="horizontal"> + <androidx.appcompat.widget.AppCompatTextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:id="@+id/recommended_title" + android:textAppearance="?android:attr/textAppearanceLarge" + android:textStyle="bold" + android:text="@string/gateway_selection_recommended" + android:layout_gravity="bottom" + /> + <androidx.appcompat.widget.AppCompatImageView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:src="@drawable/ic_lightning_bolt" + /> - <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/current_location" + </LinearLayout> + + <se.leap.bitmaskclient.base.views.SelectLocationEntry + android:id="@+id/recommended_location" android:layout_width="match_parent" android:layout_height="wrap_content" - android:gravity="center" - android:textAppearance="?android:attr/textAppearanceLarge" - android:paddingTop="@dimen/activity_vertical_margin" - android:paddingStart="@dimen/activity_horizontal_margin" - android:paddingLeft="@dimen/activity_horizontal_margin" - android:paddingEnd="@dimen/activity_horizontal_margin" - android:paddingRight="@dimen/activity_horizontal_margin" - android:paddingBottom="@dimen/activity_vertical_margin" - tools:text="Paris" /> + android:layout_marginStart="4dp" + android:layout_marginLeft="4dp" + android:clickable="true" + android:focusable="true" + /> + <androidx.appcompat.widget.AppCompatTextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:id="@+id/manual_title" + android:textAppearance="?android:attr/textAppearanceLarge" + android:textStyle="normal" + android:paddingTop="15dp" + android:text="@string/gateway_selection_manually" + android:layout_gravity="bottom" + /> </LinearLayout> - - - <se.leap.bitmaskclient.base.views.IconSwitchEntry - android:id="@+id/automatic_gateway_switch" - android:layout_below="@id/current_location_container" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:paddingTop="@dimen/stdpadding" - android:paddingStart="@dimen/stdpadding" - android:paddingLeft="@dimen/stdpadding" - android:paddingEnd="@dimen/stdpadding" - android:paddingRight="@dimen/stdpadding" - app:text="@string/gateway_selection_automatic" - app:subtitle="@string/gateway_selection_warning" - app:icon="@drawable/ic_map_marker_star_black_36dp" - /> - <androidx.recyclerview.widget.RecyclerView android:id="@+id/gatewaySelection_list" - android:layout_below="@id/automatic_gateway_switch" - android:layout_above="@+id/vpn_button_container" + android:layout_below="@id/current_location_container" + android:layout_alignParentBottom="true" android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingStart="@dimen/stdpadding" @@ -74,26 +72,8 @@ android:visibility="gone" tools:visibility="visible" android:scrollbars="vertical" + tools:listitem="@layout/v_select_text_list_item" > - </androidx.recyclerview.widget.RecyclerView> - <LinearLayout - android:id="@+id/vpn_button_container" - android:orientation="horizontal" - android:gravity="end" - android:layout_alignParentBottom="true" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:padding="@dimen/activity_margin" - > - <androidx.appcompat.widget.AppCompatButton - android:id="@+id/vpn_button" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="end" - android:text="@string/vpn.button.turn.on" /> - </LinearLayout> - - </RelativeLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout/f_log.xml b/app/src/main/res/layout/f_log.xml index 47a80e50..ac77abd5 100644 --- a/app/src/main/res/layout/f_log.xml +++ b/app/src/main/res/layout/f_log.xml @@ -21,7 +21,7 @@ <include layout="@layout/f_log_sliders"/> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:text="@string/speed_waiting" android:singleLine="true" android:id="@+id/speed" diff --git a/app/src/main/res/layout/f_log_sliders.xml b/app/src/main/res/layout/f_log_sliders.xml index 4196e243..ea444b3d 100644 --- a/app/src/main/res/layout/f_log_sliders.xml +++ b/app/src/main/res/layout/f_log_sliders.xml @@ -16,7 +16,7 @@ android:layout_width="wrap_content" android:layout_height="wrap_content"> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/log_verbosity_level"/> @@ -29,7 +29,7 @@ tools:max="5" android:indeterminate="false"/> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/timestamps"/> diff --git a/app/src/main/res/layout/s_layout.xml b/app/src/main/res/layout/s_layout.xml deleted file mode 100644 index d5717a5b..00000000 --- a/app/src/main/res/layout/s_layout.xml +++ /dev/null @@ -1,12 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<ScrollView xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="match_parent" - android:layout_height="match_parent"> - - <Button - android:id="@+id/buttontest" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:text="A"/> - -</ScrollView> diff --git a/app/src/main/res/layout/v_icon_select_text_list_item.xml b/app/src/main/res/layout/v_icon_select_text_list_item.xml index f38bac6e..801a372a 100644 --- a/app/src/main/res/layout/v_icon_select_text_list_item.xml +++ b/app/src/main/res/layout/v_icon_select_text_list_item.xml @@ -15,7 +15,7 @@ tools:src="@drawable/ic_bluetooth" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@android:id/text1" android:layout_width="match_parent" android:layout_height="wrap_content" diff --git a/app/src/main/res/layout/v_icon_text_list_item.xml b/app/src/main/res/layout/v_icon_text_list_item.xml index 0b2d5b11..06b70a2e 100644 --- a/app/src/main/res/layout/v_icon_text_list_item.xml +++ b/app/src/main/res/layout/v_icon_text_list_item.xml @@ -14,7 +14,7 @@ android:paddingLeft="?android:attr/listPreferredItemPaddingLeft" tools:src="@drawable/ic_add_circle_outline_grey600_24dp" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@android:id/text1" android:layout_width="match_parent" android:layout_height="wrap_content" @@ -33,7 +33,7 @@ android:layout_above="@+id/subtitle" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/subtitle" android:layout_width="match_parent" android:layout_height="wrap_content" diff --git a/app/src/main/res/layout/v_location_button.xml b/app/src/main/res/layout/v_location_button.xml new file mode 100644 index 00000000..8cba9d70 --- /dev/null +++ b/app/src/main/res/layout/v_location_button.xml @@ -0,0 +1,92 @@ +<?xml version="1.0" encoding="utf-8"?> +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:tools="http://schemas.android.com/tools" + android:orientation="horizontal" + android:layout_width="match_parent" + android:layout_gravity="center_vertical" + android:padding="@dimen/stdpadding" + android:background="@drawable/cust_button_primary_rect" + android:layout_height="match_parent"> + + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/world_icn" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignTop="@+id/text_location" + android:layout_alignBottom="@+id/text_location" + android:scaleType="fitXY" + android:src="@drawable/ic_web" + android:layout_gravity="center" + /> + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/recommended_icn" + android:scaleType="fitXY" + android:layout_marginRight="-13dp" + android:layout_marginEnd="-13dp" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignTop="@id/text_location" + android:layout_alignBottom="@+id/text_location" + android:layout_toEndOf="@id/world_icn" + android:layout_toRightOf="@id/world_icn" + android:src="@drawable/ic_lightning_bolt" + android:visibility="gone" + tools:visibility="visible" + /> + <androidx.appcompat.widget.AppCompatTextView + android:id="@+id/text_location" + android:paddingStart="@dimen/stdpadding" + android:paddingLeft="@dimen/stdpadding" + android:paddingEnd="@dimen/stdpadding" + android:paddingRight="@dimen/stdpadding" + android:maxLines="1" + android:ellipsize="end" + android:layout_height="wrap_content" + android:layout_width="wrap_content" + android:layout_toEndOf="@id/recommended_icn" + android:layout_toRightOf="@+id/recommended_icn" + android:layout_toLeftOf="@+id/bridge_icn" + android:layout_toStartOf="@+id/bridge_icn" + android:layout_gravity="center_vertical" + android:layout_centerInParent="true" + android:textAppearance="@style/TextAppearance.AppCompat.Large" + android:textStyle="bold" + android:textColor="@color/white" + tools:text="Seattle along message" + /> + + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/bridge_icn" + android:paddingRight="@dimen/stdpadding" + android:paddingEnd="@dimen/stdpadding" + android:paddingStart="@dimen/stdpadding" + android:paddingLeft="@dimen/stdpadding" + android:layout_marginBottom="-5dp" + android:layout_marginTop="-5dp" + android:scaleType="fitXY" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignTop="@id/text_location" + android:layout_alignBottom="@+id/text_location" + android:layout_toStartOf="@id/load_indicator" + android:layout_toLeftOf="@id/load_indicator" + android:src="@drawable/ic_bridge_36" + android:visibility="gone" + /> + + <se.leap.bitmaskclient.base.views.LocationIndicator + android:id="@+id/load_indicator" + android:layout_marginBottom="4dp" + android:layout_width="48dp" + android:layout_height="wrap_content" + android:layout_alignTop="@id/text_location" + android:layout_alignBottom="@id/text_location" + android:layout_alignParentEnd="true" + android:layout_alignParentRight="true" + android:visibility="visible" + android:layout_gravity="center_vertical" + /> + + + +</RelativeLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout/v_location_status_indicator.xml b/app/src/main/res/layout/v_location_status_indicator.xml new file mode 100644 index 00000000..548a965f --- /dev/null +++ b/app/src/main/res/layout/v_location_status_indicator.xml @@ -0,0 +1,193 @@ +<?xml version="1.0" encoding="utf-8"?> +<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + xmlns:tools="http://schemas.android.com/tools" + android:orientation="horizontal" + android:layout_width="match_parent" + android:layout_height="match_parent" + > + + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_vertical_first" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="vertical" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.166" + /> + + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_vertical_second" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="vertical" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.334" + /> + + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_vertical_third" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="vertical" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.5" + /> + + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_vertical_fourth" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="vertical" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.666" + /> + + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_vertical_fifth" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="vertical" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.833" + /> + + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_horizontal_top" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="horizontal" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.166" + /> + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_horizontal_upper" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="horizontal" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.333" + /> + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_hoizontal_mid" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="horizontal" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.5" + /> + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_hoizontal_lower" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="horizontal" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.666" + /> + <androidx.constraintlayout.widget.Guideline + android:id="@+id/guideline_hoizontal_bottom" + android:layout_width="0dp" + android:layout_height="0dp" + android:orientation="horizontal" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintGuide_percent="0.833" + /> + + + <View + android:id="@+id/level1" + android:layout_width="0dp" + android:layout_height="0dp" + android:background="@color/red200" + android:visibility="visible" + app:layout_constraintRight_toLeftOf="@+id/guideline_vertical_first" + app:layout_constraintLeft_toLeftOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintTop_toBottomOf="@id/guideline_hoizontal_bottom" + android:layout_marginLeft="1dp" + android:layout_marginRight="1dp" + android:layout_marginStart="1dp" + android:layout_marginEnd="1dp" + /> + + <View + android:id="@+id/level1_2" + android:layout_width="0dp" + android:layout_height="0dp" + android:background="@color/red200" + android:visibility="visible" + app:layout_constraintRight_toLeftOf="@+id/guideline_vertical_second" + app:layout_constraintLeft_toRightOf="@id/guideline_vertical_first" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintTop_toBottomOf="@id/guideline_hoizontal_lower" + android:layout_marginLeft="1dp" + android:layout_marginRight="1dp" + android:layout_marginStart="1dp" + android:layout_marginEnd="1dp" + /> + + <View + android:id="@+id/level2" + android:layout_width="0dp" + android:layout_height="0dp" + android:background="@color/yellow200" + android:visibility="visible" + app:layout_constraintRight_toLeftOf="@+id/guideline_vertical_third" + app:layout_constraintLeft_toRightOf="@id/guideline_vertical_second" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintTop_toBottomOf="@id/guideline_hoizontal_mid" + android:layout_marginLeft="1dp" + android:layout_marginRight="1dp" + android:layout_marginStart="1dp" + android:layout_marginEnd="1dp" + /> + + <View + android:id="@+id/level2_2" + android:layout_width="0dp" + android:layout_height="0dp" + android:background="@color/yellow200" + android:visibility="visible" + app:layout_constraintRight_toLeftOf="@+id/guideline_vertical_fourth" + app:layout_constraintLeft_toRightOf="@id/guideline_vertical_third" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintTop_toBottomOf="@id/guideline_horizontal_upper" + android:layout_marginLeft="1dp" + android:layout_marginRight="1dp" + android:layout_marginStart="1dp" + android:layout_marginEnd="1dp" + /> + + <View + android:id="@+id/level3" + android:layout_width="0dp" + android:layout_height="0dp" + android:background="@color/green200" + android:visibility="visible" + app:layout_constraintRight_toLeftOf="@+id/guideline_vertical_fifth" + app:layout_constraintLeft_toRightOf="@id/guideline_vertical_fourth" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintTop_toBottomOf="@id/guideline_horizontal_top" + android:layout_marginLeft="1dp" + android:layout_marginRight="1dp" + android:layout_marginStart="1dp" + android:layout_marginEnd="1dp" + /> + + <View + android:id="@+id/level3_2" + android:layout_width="0dp" + android:layout_height="0dp" + android:background="@color/green200" + android:visibility="visible" + app:layout_constraintRight_toRightOf="parent" + app:layout_constraintLeft_toLeftOf="@id/guideline_vertical_fifth" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintTop_toTopOf="parent" + android:layout_marginLeft="1dp" + android:layout_marginRight="1dp" + android:layout_marginStart="1dp" + android:layout_marginEnd="1dp" + /> + +</androidx.constraintlayout.widget.ConstraintLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout/v_log_item.xml b/app/src/main/res/layout/v_log_item.xml index 713c3b1f..5f809523 100644 --- a/app/src/main/res/layout/v_log_item.xml +++ b/app/src/main/res/layout/v_log_item.xml @@ -4,7 +4,7 @@ android:layout_height="wrap_content" android:layout_width="match_parent" > - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@android:id/text1" android:layout_width="match_parent" android:layout_height="wrap_content" 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..c4c7a600 --- /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/colorMainBtnHighlight" + /> + + + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/vpn_btn_shadow_dark" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + app:srcCompat="@drawable/main_btn_shadow" + 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 diff --git a/app/src/main/res/layout/v_main_button.xml b/app/src/main/res/layout/v_main_button.xml index d8ae211c..741fc88f 100644 --- a/app/src/main/res/layout/v_main_button.xml +++ b/app/src/main/res/layout/v_main_button.xml @@ -102,6 +102,7 @@ app:layout_constraintEnd_toEndOf="@id/border_guideline_right" app:layout_constraintStart_toStartOf="@id/border_guideline_left" app:layout_constraintTop_toTopOf="@id/border_guideline_top" + app:layout_constraintDimensionRatio="1:1" android:indeterminate="true" android:indeterminateDuration="800" android:indeterminateDrawable="@drawable/progressbar_circle" @@ -117,16 +118,19 @@ app:layout_constraintEnd_toStartOf="@+id/vpn_btn_guideline_right" app:layout_constraintStart_toStartOf="@+id/vpn_btn_guideline_left" app:layout_constraintTop_toTopOf="@+id/vpn_btn_guideline_top" + app:layout_constraintDimensionRatio="1:1" app:srcCompat="@drawable/black_circle" /> <androidx.appcompat.widget.AppCompatImageView android:id="@+id/vpn_state_key" android:layout_width="0dp" android:layout_height="0dp" - app:layout_constraintBottom_toTopOf="@id/icn_guideline_bottom" - app:layout_constraintEnd_toStartOf="@id/icn_guideline_right" - app:layout_constraintStart_toStartOf="@id/icn_guideline_left" - app:layout_constraintTop_toTopOf="@id/icn_guideline_top" - app:srcCompat="@drawable/vpn_connected" /> + app:layout_constraintBottom_toTopOf="@+id/icn_guideline_bottom" + app:layout_constraintEnd_toStartOf="@+id/icn_guideline_right" + app:layout_constraintStart_toStartOf="@+id/icn_guideline_left" + app:layout_constraintTop_toTopOf="@+id/icn_guideline_top" + app:layout_constraintDimensionRatio="1:1" + app:layout_constraintVertical_bias="0.35" + app:srcCompat="@drawable/ic_btn_on_disabled" /> </androidx.constraintlayout.widget.ConstraintLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout/v_provider_list_item.xml b/app/src/main/res/layout/v_provider_list_item.xml index 1f0e135b..b4f41793 100644 --- a/app/src/main/res/layout/v_provider_list_item.xml +++ b/app/src/main/res/layout/v_provider_list_item.xml @@ -10,7 +10,7 @@ android:minHeight="?android:attr/listPreferredItemHeight" > - <TextView android:id="@+id/provider_domain" + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/provider_domain" android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingStart="?android:attr/listPreferredItemPaddingStart" @@ -21,7 +21,7 @@ android:textAppearance="?android:attr/textAppearanceListItem" /> - <TextView android:id="@+id/provider_name" + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/provider_name" android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingStart="?android:attr/listPreferredItemPaddingStart" diff --git a/app/src/main/res/layout/v_select_text_list_item.xml b/app/src/main/res/layout/v_select_text_list_item.xml index 07187016..44e82906 100644 --- a/app/src/main/res/layout/v_select_text_list_item.xml +++ b/app/src/main/res/layout/v_select_text_list_item.xml @@ -1,63 +1,105 @@ -<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" +<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:tools="http://schemas.android.com/tools" android:id="@+id/item_container" - android:layout_height="?android:attr/listPreferredItemHeightSmall" + android:layout_height="wrap_content" android:layout_width="match_parent" - android:orientation="horizontal" - xmlns:tools="http://schemas.android.com/tools"> + android:orientation="vertical" + android:background="?attr/selectableItemBackground"> - <!-- views are composed right to left --> - <androidx.appcompat.widget.AppCompatImageView - android:id="@+id/checked_icon" - android:layout_width="?android:attr/listPreferredItemHeightSmall" - android:layout_height="?android:attr/listPreferredItemHeightSmall" - android:layout_gravity="center" - android:padding="10dp" - android:layout_alignParentEnd="true" - android:layout_alignParentRight="true" - tools:src="@drawable/ic_check_bold" - android:visibility="visible" - tools:visibility="visible" - /> + <LinearLayout + android:layout_width="match_parent" + android:layout_height="match_parent" + android:orientation="horizontal" + > + <se.leap.bitmaskclient.base.views.SimpleCheckBox + android:id="@+id/selected" + android:layout_width="32dp" + android:layout_height="32dp" + android:layout_marginStart="4dp" + android:layout_marginLeft="4dp" + android:layout_gravity="center" + android:src="@drawable/ic_check_bold" + android:tint="@color/green200" + android:visibility="visible" + tools:visibility="visible" /> - <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/quality" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:textAppearance="?android:attr/textAppearanceListItem" - android:gravity="center_vertical" - android:paddingStart="@dimen/standard_margin" - android:paddingLeft="@dimen/standard_margin" - android:paddingEnd="@dimen/standard_margin" - android:paddingRight="@dimen/standard_margin" - android:minHeight="?android:attr/listPreferredItemHeightSmall" - android:layout_toLeftOf="@id/checked_icon" - android:layout_toStartOf="@id/checked_icon" - tools:text="GOOD" - /> + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:paddingEnd="@dimen/standard_margin" + android:paddingRight="@dimen/standard_margin" + android:paddingStart="@dimen/standard_margin" + android:paddingLeft="@dimen/standard_margin" + > + <androidx.appcompat.widget.AppCompatTextView + android:id="@+id/title" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:ellipsize="end" + android:gravity="center_vertical" + android:paddingTop="10dp" + android:textAppearance="?android:attr/textAppearanceListItemSmall" + tools:text="this is an interesting text" + android:visibility="gone" + tools:visibility="visible" + /> - <androidx.appcompat.widget.AppCompatTextView - android:id="@+id/location" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_alignParentStart="true" - android:layout_alignParentLeft="true" - android:layout_toStartOf="@id/quality" - android:layout_toLeftOf="@id/quality" - android:ellipsize="end" - android:gravity="center_vertical" - android:minHeight="?android:attr/listPreferredItemHeightLarge" - android:paddingStart="@dimen/standard_margin" - android:paddingLeft="@dimen/standard_margin" - android:paddingEnd="@dimen/standard_margin" - android:paddingRight="@dimen/standard_margin" - android:textAppearance="?android:attr/textAppearanceListItem" - android:textStyle="bold" - tools:text="Paris" /> + <LinearLayout + android:id="@+id/location_container" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="horizontal" + android:weightSum="1" + android:visibility="visible" + tools:visibility="visible" + > + <androidx.appcompat.widget.AppCompatTextView + android:id="@+id/location" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:ellipsize="end" + android:gravity="center_vertical" + android:minHeight="?android:attr/listPreferredItemHeightSmall" + android:paddingTop="8dp" + android:textAppearance="?android:attr/textAppearanceListItem" + android:textStyle="bold" + tools:visibility="visible" + android:visibility="visible" + tools:text="Paris" + android:layout_weight="1" + /> + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/bridge_image" + android:layout_width="wrap_content" + android:layout_height="32dp" + android:scaleType="fitXY" + android:src="@drawable/ic_bridge_36" + tools:visibility="visible" + android:visibility="visible" + android:layout_gravity="center_vertical" + /> + <se.leap.bitmaskclient.base.views.LocationIndicator + android:id="@+id/quality" + android:layout_width="30dp" + android:layout_height="25dp" + android:layout_marginLeft="@dimen/standard_margin" + android:layout_marginRight="@dimen/standard_margin" + tools:visibility="visible" + android:visibility="visible" + android:gravity="center_vertical" + android:layout_gravity="center_vertical" + /> + </LinearLayout> + </LinearLayout> + </LinearLayout> <View + android:id="@+id/divider" android:layout_width="match_parent" android:layout_height="1px" android:background="@android:color/darker_gray" - android:layout_alignParentBottom="true" + android:layout_marginTop="@dimen/stdpadding" + android:visibility="visible" /> -</RelativeLayout> +</LinearLayout> diff --git a/app/src/main/res/layout/v_simple_checkbox.xml b/app/src/main/res/layout/v_simple_checkbox.xml new file mode 100644 index 00000000..8bae20b9 --- /dev/null +++ b/app/src/main/res/layout/v_simple_checkbox.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8"?> +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + android:layout_width="match_parent" android:layout_height="match_parent" + > + + <View + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignTop="@+id/check_view" + android:layout_alignBottom="@+id/check_view" + android:layout_alignLeft="@+id/check_view" + android:layout_alignRight="@+id/check_view" + android:layout_alignStart="@+id/check_view" + android:layout_alignEnd="@+id/check_view" + android:layout_marginTop="8dp" + android:layout_marginLeft="2dp" + android:layout_marginRight="8dp" + android:layout_marginBottom="2dp" + android:background="@drawable/cust_checkbox" + /> + <androidx.appcompat.widget.AppCompatImageView + android:id="@+id/check_view" + android:layout_width="match_parent" + android:layout_height="match_parent" + app:srcCompat="@drawable/check_bold" + android:tint="@color/colorSuccess" + android:layout_centerInParent="true" + android:visibility="invisible" + /> + + +</RelativeLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout/v_single_list_item.xml b/app/src/main/res/layout/v_single_list_item.xml index 652cb693..7b35bf7f 100644 --- a/app/src/main/res/layout/v_single_list_item.xml +++ b/app/src/main/res/layout/v_single_list_item.xml @@ -1,4 +1,4 @@ -<TextView xmlns:android="http://schemas.android.com/apk/res/android" +<androidx.appcompat.widget.AppCompatTextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@android:id/text1" android:layout_width="match_parent" android:layout_height="wrap_content" diff --git a/app/src/main/res/layout/v_switch_list_item.xml b/app/src/main/res/layout/v_switch_list_item.xml index 1686a99d..5bd4de1b 100644 --- a/app/src/main/res/layout/v_switch_list_item.xml +++ b/app/src/main/res/layout/v_switch_list_item.xml @@ -27,7 +27,7 @@ android:minHeight="?android:attr/listPreferredItemHeightSmall" android:layout_width="wrap_content" android:layout_height="wrap_content"> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/title" android:layout_width="wrap_content" android:layout_height="wrap_content" @@ -41,7 +41,7 @@ android:textAppearance="?android:attr/textAppearanceListItemSmall" tools:text=".,m.,msdflksdjflksjdflkjsdflksdlsdflkj lskjdf lkjsdf lkjsdf fsdls" /> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/subtitle" android:layout_width="wrap_content" android:layout_height="wrap_content" diff --git a/app/src/main/res/layout/v_vpn_status.xml b/app/src/main/res/layout/v_vpn_status.xml index 3b464b62..ce8e6928 100644 --- a/app/src/main/res/layout/v_vpn_status.xml +++ b/app/src/main/res/layout/v_vpn_status.xml @@ -13,20 +13,20 @@ android:layout_height="wrap_content"/> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:text="@string/uploaded_data" style="@style/logWindowStatusTitle"/> - <TextView + <androidx.appcompat.widget.AppCompatTextView style="@style/logWindowStatusText" android:id="@+id/speedUp" tools:text="4 Mbit/s 6.7 GB"/> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:text="@string/downloaded_data" style="@style/logWindowStatusTitle"/> - <TextView + <androidx.appcompat.widget.AppCompatTextView style="@style/logWindowStatusText" android:id="@+id/speedDown" tools:text="2 Mbit/s 4.7 GB"/> @@ -38,11 +38,11 @@ android:layout_height="wrap_content"/> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:text="@string/vpn_status" style="@style/logWindowStatusTitle"/> - <TextView + <androidx.appcompat.widget.AppCompatTextView android:id="@+id/speedStatus" tools:text="Connected to a very long ipv4 and 3483489348238824829482384928" |