Merge branch 'master' of github.com:M66B/FairEmail

This commit is contained in:
M66B
2020-07-26 17:00:51 +02:00
7 changed files with 26 additions and 12 deletions

View File

@@ -714,6 +714,7 @@ public class AdapterFolder extends RecyclerView.Adapter<AdapterFolder.ViewHolder
aargs.putString("question", context.getString(R.string.title_empty_spam_ask));
else
throw new IllegalArgumentException("Invalid folder type=" + type);
aargs.putString("remark", context.getString(R.string.title_empty_all));
aargs.putLong("folder", folder.id);
aargs.putString("type", type);

View File

@@ -40,13 +40,17 @@ public class FragmentDialogAsk extends FragmentDialogBase {
@Override
public Dialog onCreateDialog(@Nullable Bundle savedInstanceState) {
String question = getArguments().getString("question");
String remark = getArguments().getString("remark");
String notagain = getArguments().getString("notagain");
View dview = LayoutInflater.from(getContext()).inflate(R.layout.dialog_ask_again, null);
TextView tvMessage = dview.findViewById(R.id.tvMessage);
TextView tvRemark = dview.findViewById(R.id.tvRemark);
CheckBox cbNotAgain = dview.findViewById(R.id.cbNotAgain);
tvMessage.setText(question);
tvRemark.setText(remark);
tvRemark.setVisibility(remark == null ? View.GONE : View.VISIBLE);
cbNotAgain.setVisibility(notagain == null ? View.GONE : View.VISIBLE);
if (notagain != null)

View File

@@ -3768,6 +3768,7 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
account < 0 ? R.string.title_empty_spam_all_ask : R.string.title_empty_spam_ask));
else
throw new IllegalArgumentException("Invalid folder type=" + type);
aargs.putString("remark", getString(R.string.title_empty_all));
aargs.putLong("account", account);
aargs.putString("type", type);
@@ -4157,14 +4158,6 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
updateExpanded();
// This is to workaround not drawing when the search is expanded
new Handler().post(new Runnable() {
@Override
public void run() {
rvMessage.requestLayout();
}
});
initialized = true;
updateListState("Observed", SimpleTask.getCount(), messages.size());

View File

@@ -99,6 +99,9 @@ public class ServiceSend extends ServiceBase {
} catch (Throwable ex) {
Log.w(ex);
}
if (unsent == null || unsent.count == 0)
stopSelf();
}
}
});
@@ -110,9 +113,6 @@ public class ServiceSend extends ServiceBase {
if (operations == null)
operations = new ArrayList<>();
if (operations.size() == 0)
stopSelf();
final List<TupleOperationEx> process = new ArrayList<>();
List<Long> ops = new ArrayList<>();