Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(196)

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java

Issue 416273003: Merge 280882 "Update setupImageButton() in AppMenuAdapter to res..." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/2062/src/
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java
===================================================================
--- chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java (revision 285441)
+++ chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java (working copy)
@@ -206,7 +206,11 @@
}
private void setupImageButton(ImageButton button, final MenuItem item) {
+ // Store and recover the level of image as button.setimageDrawable
+ // resets drawable to default level.
+ int currentLevel = item.getIcon().getLevel();
button.setImageDrawable(item.getIcon());
+ item.getIcon().setLevel(currentLevel);
button.setContentDescription(item.getTitle());
button.setEnabled(item.isEnabled());
button.setFocusable(item.isEnabled());
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698