diff options
author | Adam Powell <adamp@android.com> | 2013-01-28 11:37:41 -0800 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2013-01-28 11:37:41 -0800 |
commit | 783fe4295372cee8d024388221414c253802c995 (patch) | |
tree | f1926ba581e4ed1bc371b8045835ac38e405cd09 /core | |
parent | 0b515aece642283a25c6a4416f0aecdaf17bdb58 (diff) | |
parent | e305e5f68df8338cb3c4bdcf099d23ec9abce564 (diff) | |
download | frameworks_base-783fe4295372cee8d024388221414c253802c995.zip frameworks_base-783fe4295372cee8d024388221414c253802c995.tar.gz frameworks_base-783fe4295372cee8d024388221414c253802c995.tar.bz2 |
am e305e5f6: Merge "show SELECT ALL icon with text in landscape mode"
# By Sungmin Choi
# Via Gerrit Code Review (1) and Sungmin Choi (1)
* commit 'e305e5f68df8338cb3c4bdcf099d23ec9abce564':
show SELECT ALL icon with text in landscape mode
Diffstat (limited to 'core')
-rw-r--r-- | core/java/android/widget/Editor.java | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/core/java/android/widget/Editor.java b/core/java/android/widget/Editor.java index 30d022c..8892316 100644 --- a/core/java/android/widget/Editor.java +++ b/core/java/android/widget/Editor.java @@ -2696,23 +2696,14 @@ public class Editor { TypedArray styledAttributes = mTextView.getContext().obtainStyledAttributes( com.android.internal.R.styleable.SelectionModeDrawables); - boolean allowText = mTextView.getContext().getResources().getBoolean( - com.android.internal.R.bool.config_allowActionMenuItemTextWithIcon); - mode.setTitle(mTextView.getContext().getString( com.android.internal.R.string.textSelectionCABTitle)); mode.setSubtitle(null); mode.setTitleOptionalHint(true); - int selectAllIconId = 0; // No icon by default - if (!allowText) { - // Provide an icon, text will not be displayed on smaller screens. - selectAllIconId = styledAttributes.getResourceId( - R.styleable.SelectionModeDrawables_actionModeSelectAllDrawable, 0); - } - menu.add(0, TextView.ID_SELECT_ALL, 0, com.android.internal.R.string.selectAll). - setIcon(selectAllIconId). + setIcon(styledAttributes.getResourceId( + R.styleable.SelectionModeDrawables_actionModeSelectAllDrawable, 0)). setAlphabeticShortcut('a'). setShowAsAction( MenuItem.SHOW_AS_ACTION_ALWAYS | MenuItem.SHOW_AS_ACTION_WITH_TEXT); |