Replaced info buttons by info links

pull/207/head
M66B 3 years ago
parent 0646092ea5
commit 673f735213

@ -100,13 +100,13 @@ public class FragmentSetup extends FragmentBase {
private TextView tvPermissionsDone;
private Button btnPermissions;
private ImageButton ibPermissions;
private TextView tvPermissionsWhy;
private TextView tvImportContacts;
private TextView tvDozeDone;
private Button btnDoze;
private TextView tvDoze12;
private ImageButton ibDoze;
private TextView tvDozeWhy;
private Button btnBackgroundRestricted;
private Button btnDataSaver;
@ -177,13 +177,13 @@ public class FragmentSetup extends FragmentBase {
tvPermissionsDone = view.findViewById(R.id.tvPermissionsDone);
btnPermissions = view.findViewById(R.id.btnPermissions);
ibPermissions = view.findViewById(R.id.ibPermissions);
tvPermissionsWhy = view.findViewById(R.id.tvPermissionsWhy);
tvImportContacts = view.findViewById(R.id.tvImportContacts);
tvDozeDone = view.findViewById(R.id.tvDozeDone);
btnDoze = view.findViewById(R.id.btnDoze);
tvDoze12 = view.findViewById(R.id.tvDoze12);
ibDoze = view.findViewById(R.id.ibDoze);
tvDozeWhy = view.findViewById(R.id.tvDozeWhy);
btnBackgroundRestricted = view.findViewById(R.id.btnBackgroundRestricted);
btnDataSaver = view.findViewById(R.id.btnDataSaver);
@ -492,7 +492,8 @@ public class FragmentSetup extends FragmentBase {
}
});
ibPermissions.setOnClickListener(new View.OnClickListener() {
tvPermissionsWhy.setPaintFlags(tvPermissionsWhy.getPaintFlags() | Paint.UNDERLINE_TEXT_FLAG);
tvPermissionsWhy.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
Helper.viewFAQ(v.getContext(), 1);
@ -533,7 +534,8 @@ public class FragmentSetup extends FragmentBase {
}
});
ibDoze.setOnClickListener(new View.OnClickListener() {
tvDozeWhy.setPaintFlags(tvDozeWhy.getPaintFlags() | Paint.UNDERLINE_TEXT_FLAG);
tvDozeWhy.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
Helper.viewFAQ(v.getContext(), 175, true);

@ -612,16 +612,19 @@
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/tvPermissions" />
<eu.faircode.email.FixedImageButton
android:id="@+id/ibPermissions"
<eu.faircode.email.FixedTextView
android:id="@+id/tvPermissionsWhy"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:contentDescription="@string/title_info"
android:tooltipText="@string/title_info"
android:layout_marginTop="12dp"
android:drawableEnd="@drawable/twotone_open_in_new_12"
android:drawablePadding="6dp"
android:drawableTint="?android:attr/textColorLink"
android:text="@string/title_setup_permission_why"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textColor="?android:attr/textColorLink"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/btnPermissions"
app:srcCompat="@drawable/twotone_info_24" />
app:layout_constraintTop_toBottomOf="@id/btnPermissions" />
<eu.faircode.email.FixedTextView
android:id="@+id/tvImportContacts"
@ -635,7 +638,7 @@
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textColor="?android:attr/textColorLink"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/ibPermissions" />
app:layout_constraintTop_toBottomOf="@id/tvPermissionsWhy" />
</eu.faircode.email.ConstraintLayoutEx>
</androidx.cardview.widget.CardView>
@ -742,16 +745,19 @@
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/tvDoze12" />
<eu.faircode.email.FixedImageButton
android:id="@+id/ibDoze"
<eu.faircode.email.FixedTextView
android:id="@+id/tvDozeWhy"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:contentDescription="@string/title_info"
android:tooltipText="@string/title_info"
android:drawableEnd="@drawable/twotone_open_in_new_12"
android:drawablePadding="6dp"
android:drawableTint="?android:attr/textColorLink"
android:text="@string/title_setup_doze_why"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textColor="?android:attr/textColorLink"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/tvDozeHint"
app:srcCompat="@drawable/twotone_info_24" />
app:layout_constraintTop_toBottomOf="@id/tvDozeHint" />
<eu.faircode.email.FixedTextView
android:id="@+id/tvBackgroundRestricted"
@ -766,7 +772,7 @@
android:textColor="?attr/colorWarning"
android:textStyle="bold"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/ibDoze" />
app:layout_constraintTop_toBottomOf="@id/tvDozeWhy" />
<Button
android:id="@+id/btnBackgroundRestricted"

@ -227,11 +227,13 @@
<string name="title_setup_permissions">Grant permissions</string>
<string name="title_setup_permissions_remark">To access contact information (optional)</string>
<string name="title_setup_permissions_explanation">Contact permissions are required to look up contact info and to suggest contacts</string>
<string name="title_setup_permission_why">Which permissions are needed and why?</string>
<string name="title_setup_permission_import_contacts">How can I import contacts?</string>
<string name="title_setup_doze">Disable battery optimizations</string>
<string name="title_setup_doze_remark">To send and receive email reliably in the background</string>
<string name="title_setup_doze_explanation">Battery optimizations should be disabled for the app to ensure reliable sending and receiving of messages in the background</string>
<string name="title_setup_doze_hint">Although this may sound contradictory, turning off battery optimizations for this app will result in less battery usage</string>
<string name="title_setup_doze_why">Why should battery optimizations be disabled?</string>
<string name="title_setup_doze_instructions">In the next Android dialog change "Not optimized" to "All apps", select this app and select "Don\'t optimize"</string>
<string name="title_setup_doze_battery">High battery usage?</string>
<string name="title_setup_doze_stopped">Sync stopped?</string>

Loading…
Cancel
Save