mirror of https://github.com/M66B/FairEmail.git
Small improment/fix
This commit is contained in:
parent
a848bacf4f
commit
e4add1e049
|
@ -77,6 +77,7 @@ public class FragmentFolder extends FragmentBase {
|
||||||
private ContentLoadingProgressBar pbWait;
|
private ContentLoadingProgressBar pbWait;
|
||||||
private Group grpParent;
|
private Group grpParent;
|
||||||
private Group grpPoll;
|
private Group grpPoll;
|
||||||
|
private Group grpAutoDelete;
|
||||||
|
|
||||||
private long id = -1;
|
private long id = -1;
|
||||||
private long account = -1;
|
private long account = -1;
|
||||||
|
@ -132,6 +133,7 @@ public class FragmentFolder extends FragmentBase {
|
||||||
pbWait = view.findViewById(R.id.pbWait);
|
pbWait = view.findViewById(R.id.pbWait);
|
||||||
grpParent = view.findViewById(R.id.grpParent);
|
grpParent = view.findViewById(R.id.grpParent);
|
||||||
grpPoll = view.findViewById(R.id.grpPoll);
|
grpPoll = view.findViewById(R.id.grpPoll);
|
||||||
|
grpAutoDelete = view.findViewById(R.id.grpAutoDelete);
|
||||||
|
|
||||||
btnColor.setOnClickListener(new View.OnClickListener() {
|
btnColor.setOnClickListener(new View.OnClickListener() {
|
||||||
@Override
|
@Override
|
||||||
|
@ -204,7 +206,7 @@ public class FragmentFolder extends FragmentBase {
|
||||||
tvParent.setText(parent);
|
tvParent.setText(parent);
|
||||||
grpParent.setVisibility(parent == null ? View.GONE : View.VISIBLE);
|
grpParent.setVisibility(parent == null ? View.GONE : View.VISIBLE);
|
||||||
Helper.setViewsEnabled(view, false);
|
Helper.setViewsEnabled(view, false);
|
||||||
cbAutoDelete.setVisibility(View.GONE);
|
grpAutoDelete.setVisibility(View.GONE);
|
||||||
btnSave.setEnabled(false);
|
btnSave.setEnabled(false);
|
||||||
pbSave.setVisibility(View.GONE);
|
pbSave.setVisibility(View.GONE);
|
||||||
pbWait.setVisibility(View.VISIBLE);
|
pbWait.setVisibility(View.VISIBLE);
|
||||||
|
@ -260,13 +262,13 @@ public class FragmentFolder extends FragmentBase {
|
||||||
else
|
else
|
||||||
etKeepDays.setText(Integer.toString(folder == null ? EntityFolder.DEFAULT_KEEP : folder.keep_days));
|
etKeepDays.setText(Integer.toString(folder == null ? EntityFolder.DEFAULT_KEEP : folder.keep_days));
|
||||||
|
|
||||||
if (folder == null || folder.read_only)
|
if (folder != null && folder.read_only)
|
||||||
cbAutoDelete.setVisibility(View.GONE);
|
grpAutoDelete.setVisibility(View.GONE);
|
||||||
else {
|
else {
|
||||||
cbAutoDelete.setText(EntityFolder.TRASH.equals(folder.type)
|
cbAutoDelete.setText(folder != null && EntityFolder.TRASH.equals(folder.type)
|
||||||
? R.string.title_auto_delete : R.string.title_auto_trash);
|
? R.string.title_auto_delete : R.string.title_auto_trash);
|
||||||
cbAutoDelete.setChecked(folder.auto_delete);
|
cbAutoDelete.setChecked(folder != null && folder.auto_delete);
|
||||||
cbAutoDelete.setVisibility(View.VISIBLE);
|
grpAutoDelete.setVisibility(View.VISIBLE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -347,5 +347,11 @@
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
app:constraint_referenced_ids="etPoll,tvMultiply,tvPoll" />
|
app:constraint_referenced_ids="etPoll,tvMultiply,tvPoll" />
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.Group
|
||||||
|
android:id="@+id/grpAutoDelete"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
app:constraint_referenced_ids="cbAutoDelete,tvAutoDeleteHint" />
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</eu.faircode.email.ScrollViewEx>
|
</eu.faircode.email.ScrollViewEx>
|
||||||
|
|
Loading…
Reference in New Issue