Simplification

pull/198/head
M66B 4 years ago
parent 802270160b
commit 3bff0b11a8

@ -4216,7 +4216,7 @@ public class AdapterMessage extends RecyclerView.Adapter<AdapterMessage.ViewHold
onActionMove(message, true);
return true;
} else if (itemId == R.id.menu_delete) {
onMenuDelete(message);
onActionDelete(message);
return true;
} else if (itemId == R.id.menu_resync) {
onMenuResync(message);
@ -4587,19 +4587,6 @@ public class AdapterMessage extends RecyclerView.Adapter<AdapterMessage.ViewHold
}.execute(context, owner, args, "importance:set");
}
private void onMenuDelete(final TupleMessageEx message) {
Bundle aargs = new Bundle();
aargs.putString("question", context.getString(R.string.title_ask_delete));
aargs.putString("remark", message.getRemark());
aargs.putLong("id", message.id);
aargs.putBoolean("warning", true);
FragmentDialogAsk ask = new FragmentDialogAsk();
ask.setArguments(aargs);
ask.setTargetFragment(parentFragment, FragmentMessages.REQUEST_MESSAGE_DELETE);
ask.show(parentFragment.getParentFragmentManager(), "message:delete");
}
private void onMenuResync(TupleMessageEx message) {
Bundle args = new Bundle();
args.putLong("id", message.id);

Loading…
Cancel
Save