pull/184/head
M66B 4 years ago
parent aaa528434a
commit 46d15e9f79

@ -1600,12 +1600,16 @@ public class FragmentCompose extends FragmentBase {
popupMenu.setOnMenuItemClickListener(new PopupMenu.OnMenuItemClickListener() { popupMenu.setOnMenuItemClickListener(new PopupMenu.OnMenuItemClickListener() {
@Override @Override
public boolean onMenuItemClick(MenuItem target) { public boolean onMenuItemClick(MenuItem target) {
Intent intent = target.getIntent();
if (intent == null)
return false;
if (!ActivityBilling.isPro(getContext())) { if (!ActivityBilling.isPro(getContext())) {
startActivity(new Intent(getContext(), ActivityBilling.class)); startActivity(new Intent(getContext(), ActivityBilling.class));
return true; return true;
} }
long id = target.getIntent().getLongExtra("id", -1); long id = intent.getLongExtra("id", -1);
for (EntityAnswer answer : answers) for (EntityAnswer answer : answers)
if (answer.id.equals(id)) { if (answer.id.equals(id)) {
if (etSubject.getText().length() == 0) if (etSubject.getText().length() == 0)

@ -2450,6 +2450,10 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
popupMenu.setOnMenuItemClickListener(new PopupMenu.OnMenuItemClickListener() { popupMenu.setOnMenuItemClickListener(new PopupMenu.OnMenuItemClickListener() {
@Override @Override
public boolean onMenuItemClick(MenuItem target) { public boolean onMenuItemClick(MenuItem target) {
Intent intent = target.getIntent();
if (intent == null)
return false;
if (!ActivityBilling.isPro(getContext())) { if (!ActivityBilling.isPro(getContext())) {
startActivity(new Intent(getContext(), ActivityBilling.class)); startActivity(new Intent(getContext(), ActivityBilling.class));
return true; return true;
@ -2458,7 +2462,7 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
startActivity(new Intent(getContext(), ActivityCompose.class) startActivity(new Intent(getContext(), ActivityCompose.class)
.putExtra("action", "reply") .putExtra("action", "reply")
.putExtra("reference", message.id) .putExtra("reference", message.id)
.putExtra("answer", target.getIntent().getLongExtra("id", -1))); .putExtra("answer", intent.getLongExtra("id", -1)));
return true; return true;
} }
}); });

Loading…
Cancel
Save