From e9515515312d0a5e20281f4fa30dee85ed14346e Mon Sep 17 00:00:00 2001 From: chenjuntao Date: Wed, 27 Feb 2019 10:39:50 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=BA=86=E7=AD=94=E6=A1=88?= =?UTF-8?q?=E8=AF=A6=E6=83=85=E7=82=B9=E5=87=BB=E6=9B=B4=E5=A4=9A=E4=BC=9A?= =?UTF-8?q?=E9=97=AA=E9=80=80=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../gh/gamecenter/qa/answer/detail/AnswerDetailFragment.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/gh/gamecenter/qa/answer/detail/AnswerDetailFragment.java b/app/src/main/java/com/gh/gamecenter/qa/answer/detail/AnswerDetailFragment.java index 0c3efdf8b7..150844302d 100644 --- a/app/src/main/java/com/gh/gamecenter/qa/answer/detail/AnswerDetailFragment.java +++ b/app/src/main/java/com/gh/gamecenter/qa/answer/detail/AnswerDetailFragment.java @@ -586,6 +586,7 @@ public class AnswerDetailFragment extends NormalFragment { public void onMenuItemClick(MenuItem menuItem) { switch (menuItem.getItemId()) { case R.id.menu_more: + if (mDetailEntity == null) return; showMoreItemDialog(); break; case R.id.menu_collect: @@ -644,7 +645,7 @@ public class AnswerDetailFragment extends NormalFragment { } private void showMoreItemDialog() { - if (getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.STARTED) || mDetailEntity != null) { + if (getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.STARTED)) { View view = LayoutInflater.from(getContext()).inflate(R.layout.menu_answer_detail_more, null); Dialog dialog = new Dialog(getActivity()); dialog.setContentView(view);