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

Unified Diff: ui/app_list/app_list_item_view.cc

Issue 11068012: Add new views::LabelButton and LabelButtonBorder. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix unit test build error; remove stray line. Created 8 years, 2 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 | ui/views/bubble/bubble_border.h » ('j') | ui/views/controls/button/button_border.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/app_list_item_view.cc
diff --git a/ui/app_list/app_list_item_view.cc b/ui/app_list/app_list_item_view.cc
index 39279cd5a58900cdc5bb1a9da87bb8e1937a7407..6db3fb63caa6847213fbf378995c9e7e68be5cee 100644
--- a/ui/app_list/app_list_item_view.cc
+++ b/ui/app_list/app_list_item_view.cc
@@ -54,21 +54,6 @@ const gfx::Font& GetTitleFont() {
return *font;
}
-// An image view that is not interactive.
-class StaticImageView : public views::ImageView {
- public:
- StaticImageView() : ImageView() {
- }
-
- private:
- // views::View overrides:
- virtual bool HitTestRect(const gfx::Rect& rect) const OVERRIDE {
- return false;
- }
-
- DISALLOW_COPY_AND_ASSIGN(StaticImageView);
-};
-
} // namespace
// static
@@ -79,8 +64,10 @@ AppListItemView::AppListItemView(AppsGridView* apps_grid_view,
: CustomButton(apps_grid_view),
model_(model),
apps_grid_view_(apps_grid_view),
- icon_(new StaticImageView),
+ icon_(new views::ImageView),
title_(new views::Label) {
+ icon_->set_interactive(false);
+
title_->SetBackgroundColor(0);
title_->SetAutoColorReadabilityEnabled(false);
title_->SetEnabledColor(kTitleColor);
« no previous file with comments | « no previous file | ui/views/bubble/bubble_border.h » ('j') | ui/views/controls/button/button_border.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698