diff options
author | Keunes <11229646+keunes@users.noreply.github.com> | 2023-01-14 14:46:19 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-14 14:46:19 +0100 |
commit | f995fd96df96d4ad9bcb9fd92b1ffdc08ec13e27 (patch) | |
tree | c47777699d901a5d8a9d42d5114d59b7d13d9948 /app | |
parent | 63e9d7f6965a859947209a4f287469b2e8789403 (diff) | |
download | AntennaPod-f995fd96df96d4ad9bcb9fd92b1ffdc08ec13e27.zip |
Synchronisation label changes (#6213)
Diffstat (limited to 'app')
6 files changed, 82 insertions, 53 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/synchronization/NextcloudAuthenticationFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/preferences/synchronization/NextcloudAuthenticationFragment.java index 3578dace5..14440be47 100644 --- a/app/src/main/java/de/danoeh/antennapod/fragment/preferences/synchronization/NextcloudAuthenticationFragment.java +++ b/app/src/main/java/de/danoeh/antennapod/fragment/preferences/synchronization/NextcloudAuthenticationFragment.java @@ -39,9 +39,9 @@ public class NextcloudAuthenticationFragment extends DialogFragment viewBinding = NextcloudAuthDialogBinding.inflate(getLayoutInflater()); dialog.setView(viewBinding.getRoot()); - viewBinding.loginButton.setOnClickListener(v -> { + viewBinding.chooseHostButton.setOnClickListener(v -> { viewBinding.errorText.setVisibility(View.GONE); - viewBinding.loginButton.setVisibility(View.GONE); + viewBinding.chooseHostButton.setVisibility(View.GONE); viewBinding.loginProgressContainer.setVisibility(View.VISIBLE); nextcloudLoginFlow = new NextcloudLoginFlow(AntennapodHttpClient.getHttpClient(), viewBinding.serverUrlText.getText().toString(), getContext(), this); @@ -87,6 +87,6 @@ public class NextcloudAuthenticationFragment extends DialogFragment viewBinding.loginProgressContainer.setVisibility(View.GONE); viewBinding.errorText.setVisibility(View.VISIBLE); viewBinding.errorText.setText(errorMessage); - viewBinding.loginButton.setVisibility(View.VISIBLE); + viewBinding.chooseHostButton.setVisibility(View.VISIBLE); } } diff --git a/app/src/main/res/layout/gpodnetauth_credentials.xml b/app/src/main/res/layout/gpodnetauth_credentials.xml index e318f11d9..a5b8c594d 100644 --- a/app/src/main/res/layout/gpodnetauth_credentials.xml +++ b/app/src/main/res/layout/gpodnetauth_credentials.xml @@ -7,11 +7,17 @@ android:orientation="vertical"> <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginBottom="16dp" + android:text="@string/synchronization_credentials_explanation" /> + + <TextView android:id="@+id/createAccountWarning" android:layout_width="match_parent" android:layout_height="wrap_content" android:text="@string/gpodnetauth_encryption_warning" - android:textColor="#F44336" + android:textColor="?attr/icon_red" android:textStyle="bold" android:visibility="invisible" /> @@ -25,6 +31,7 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:hint="@string/username_label" + android:inputType="textNoSuggestions" android:lines="1" android:imeOptions="actionNext|flagNoFullscreen" /> @@ -33,6 +40,7 @@ <com.google.android.material.textfield.TextInputLayout android:layout_width="match_parent" android:layout_height="wrap_content" + android:layout_marginBottom="16dp" style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"> <com.google.android.material.textfield.TextInputEditText @@ -43,42 +51,33 @@ android:inputType="textPassword" android:lines="1" android:imeOptions="actionNext|flagNoFullscreen" - android:imeActionLabel="@string/gpodnetauth_login_butLabel" /> + android:imeActionLabel="@string/synchronization_login_butLabel" /> </com.google.android.material.textfield.TextInputLayout> - <LinearLayout - android:layout_width="match_parent" + <ProgressBar + android:id="@+id/progBarLogin" + android:layout_width="wrap_content" android:layout_height="wrap_content" - android:orientation="horizontal" - android:gravity="end|center_vertical"> - - <TextView - android:id="@+id/credentialsError" - android:layout_width="0dp" - android:layout_height="wrap_content" - android:layout_weight="1" - android:textColor="?attr/icon_red" - android:textSize="@dimen/text_size_small" - android:maxLines="2" - android:ellipsize="end" - android:gravity="center" - tools:text="Error message" - tools:background="@android:color/holo_green_dark" /> - - <ProgressBar - android:id="@+id/progBarLogin" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:visibility="gone" - android:layout_gravity="right" /> + android:visibility="gone" + android:layout_gravity="right" /> - <Button - android:id="@+id/butLogin" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:text="@string/gpodnetauth_login_butLabel" /> + <TextView + android:id="@+id/credentialsError" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:textColor="?attr/icon_red" + android:textSize="@dimen/text_size_small" + android:maxLines="2" + android:ellipsize="end" + android:gravity="center" + android:visibility="gone" + tools:text=" message" /> - </LinearLayout> + <Button + android:id="@+id/butLogin" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:text="@string/synchronization_login_butLabel" /> </LinearLayout> diff --git a/app/src/main/res/layout/gpodnetauth_device.xml b/app/src/main/res/layout/gpodnetauth_device.xml index cb133f684..6e051ecf3 100644 --- a/app/src/main/res/layout/gpodnetauth_device.xml +++ b/app/src/main/res/layout/gpodnetauth_device.xml @@ -6,6 +6,12 @@ android:layout_height="wrap_content" android:orientation="vertical"> + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginBottom="16dp" + android:text="@string/synchronization_selectDevice_explanation" /> + <com.google.android.material.textfield.TextInputLayout android:layout_width="match_parent" android:layout_height="wrap_content" diff --git a/app/src/main/res/layout/gpodnetauth_dialog.xml b/app/src/main/res/layout/gpodnetauth_dialog.xml index a70b76a49..b5814a4e5 100644 --- a/app/src/main/res/layout/gpodnetauth_dialog.xml +++ b/app/src/main/res/layout/gpodnetauth_dialog.xml @@ -1,20 +1,31 @@ <?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="wrap_content" - android:padding="16dp" - android:clipToPadding="false"> +<ScrollView + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:padding="16dp" + android:clipToPadding="false"> + <ViewFlipper android:id="@+id/viewflipper" android:layout_width="match_parent" android:layout_height="wrap_content" + android:measureAllChildren="false" android:inAnimation="@anim/slide_right_in" android:outAnimation="@anim/slide_left_out"> - <include layout="@layout/gpodnetauth_host" /> - <include layout="@layout/gpodnetauth_credentials" /> - <include layout="@layout/gpodnetauth_device" /> - <include layout="@layout/gpodnetauth_finish" /> + <include + layout="@layout/gpodnetauth_host" /> + + <include + layout="@layout/gpodnetauth_credentials" /> + + <include + layout="@layout/gpodnetauth_device" /> + + <include + layout="@layout/gpodnetauth_finish" /> </ViewFlipper> -</ScrollView>
\ No newline at end of file + +</ScrollView> diff --git a/app/src/main/res/layout/gpodnetauth_host.xml b/app/src/main/res/layout/gpodnetauth_host.xml index bcee9b880..7f2d16f11 100644 --- a/app/src/main/res/layout/gpodnetauth_host.xml +++ b/app/src/main/res/layout/gpodnetauth_host.xml @@ -3,18 +3,26 @@ xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="wrap_content" - android:orientation="vertical"> + android:orientation="vertical" + android:clipToPadding="false"> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginBottom="16dp" + android:text="@string/synchronization_host_explanation" /> <com.google.android.material.textfield.TextInputLayout android:layout_width="match_parent" android:layout_height="wrap_content" + android:layout_marginBottom="16dp" style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"> <com.google.android.material.textfield.TextInputEditText android:id="@+id/serverUrlText" android:layout_width="match_parent" android:layout_height="wrap_content" - android:hint="@string/gpodnetauth_host" + android:hint="@string/synchronization_host_label" android:inputType="textNoSuggestions" android:lines="1" android:imeOptions="actionNext|flagNoFullscreen" /> @@ -23,9 +31,8 @@ <Button android:id="@+id/chooseHostButton" - android:layout_width="wrap_content" + android:layout_width="match_parent" android:layout_height="wrap_content" - android:layout_gravity="right|end" - android:text="@string/gpodnetauth_select_server" /> + android:text="@string/proceed_to_login_butLabel" /> </LinearLayout> diff --git a/app/src/main/res/layout/nextcloud_auth_dialog.xml b/app/src/main/res/layout/nextcloud_auth_dialog.xml index 08cf05ef9..c08c5b969 100644 --- a/app/src/main/res/layout/nextcloud_auth_dialog.xml +++ b/app/src/main/res/layout/nextcloud_auth_dialog.xml @@ -7,6 +7,12 @@ android:orientation="vertical" android:clipToPadding="false"> + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginBottom="16dp" + android:text="@string/synchronization_host_explanation" /> + <com.google.android.material.textfield.TextInputLayout android:id="@+id/serverUrlTextInput" android:layout_width="match_parent" @@ -18,7 +24,7 @@ android:id="@+id/serverUrlText" android:layout_width="match_parent" android:layout_height="wrap_content" - android:hint="@string/gpodnetauth_host" + android:hint="@string/synchronization_host_label" android:inputType="textNoSuggestions" android:lines="1" android:imeOptions="actionNext|flagNoFullscreen" /> @@ -55,9 +61,9 @@ android:layout_marginBottom="16dp" /> <Button - android:id="@+id/loginButton" + android:id="@+id/chooseHostButton" android:layout_width="match_parent" android:layout_height="wrap_content" - android:text="@string/gpodnetauth_login_butLabel" /> + android:text="@string/proceed_to_login_butLabel" /> </LinearLayout> |