diff options
-rw-r--r-- | src/com/android/dialer/dialpad/DialpadFragment.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/com/android/dialer/dialpad/DialpadFragment.java b/src/com/android/dialer/dialpad/DialpadFragment.java index ce6c46daa..84f1c64bf 100644 --- a/src/com/android/dialer/dialpad/DialpadFragment.java +++ b/src/com/android/dialer/dialpad/DialpadFragment.java @@ -650,11 +650,14 @@ public class DialpadFragment extends AnalyticsFragment mSmsPackageComponentName = DialerUtils.getSmsComponent(activity); + // Populate the overflow menu in onResume instead of onCreate, so that if the SMS activity + // is disabled while Dialer is paused, the "Send a text message" option can be correctly + // removed when resumed. mOverflowMenuButton = mDialpadView.getOverflowMenuButton(); mOverflowPopupMenu = buildOptionsMenu(mOverflowMenuButton); mOverflowMenuButton.setOnTouchListener(mOverflowPopupMenu.getDragToOpenListener()); mOverflowMenuButton.setOnClickListener(this); - mOverflowMenuButton.setVisibility(View.INVISIBLE); + mOverflowMenuButton.setVisibility(isDigitsEmpty() ? View.INVISIBLE : View.VISIBLE); } @Override |