Added export password hint

This commit is contained in:
M66B 2021-02-26 14:54:53 +01:00
parent 8c3c160aa8
commit fc7b243746
3 changed files with 14 additions and 1 deletions

View File

@ -1311,6 +1311,7 @@ public class ActivitySetup extends ActivityBase implements FragmentManager.OnBac
TextView tvCaption = dview.findViewById(R.id.tvCaption);
etPassword1 = dview.findViewById(R.id.tilPassword1);
etPassword2 = dview.findViewById(R.id.tilPassword2);
TextView tvExportHint = dview.findViewById(R.id.tvExportHint);
TextView tvImportHint = dview.findViewById(R.id.tvImportHint);
tvCaption.setText(export ? R.string.title_setup_export : R.string.title_setup_import);
@ -1321,6 +1322,7 @@ public class ActivitySetup extends ActivityBase implements FragmentManager.OnBac
}
etPassword2.setVisibility(export ? View.VISIBLE : View.GONE);
tvExportHint.setVisibility(export ? View.VISIBLE : View.GONE);
tvImportHint.setVisibility(export ? View.GONE : View.VISIBLE);
return new AlertDialog.Builder(getContext())

View File

@ -61,6 +61,16 @@
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
</com.google.android.material.textfield.TextInputLayout>
<eu.faircode.email.FixedTextView
android:id="@+id/tvExportHint"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="12dp"
android:text="@string/title_setup_export_do"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/tilPassword2" />
<eu.faircode.email.FixedTextView
android:id="@+id/tvImportHint"
android:layout_width="wrap_content"
@ -69,6 +79,6 @@
android:text="@string/title_setup_import_do"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/tilPassword2" />
app:layout_constraintTop_toBottomOf="@id/tvExportHint" />
</androidx.constraintlayout.widget.ConstraintLayout>
</eu.faircode.email.ScrollViewEx>

View File

@ -223,6 +223,7 @@
<string name="title_setup_export">Export settings</string>
<string name="title_setup_import">Import settings</string>
<string name="title_setup_export_do">The password is used to encrypt the settings and is required to import the settings again</string>
<string name="title_setup_import_do">Imported accounts will be added without overwriting any existing ones</string>
<string name="title_setup_password">Password</string>
<string name="title_setup_password_chars">Password contains control or whitespace characters</string>