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

Side by Side Diff: ash/shelf/shelf_button.h

Issue 287193002: Remove overrides of HitTestRect() which just return false (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: re-upload Created 6 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | ash/shelf/shelf_button.cc » ('j') | ash/shelf/shelf_button.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ASH_SHELF_SHELF_BUTTON_H_ 5 #ifndef ASH_SHELF_SHELF_BUTTON_H_
6 #define ASH_SHELF_SHELF_BUTTON_H_ 6 #define ASH_SHELF_SHELF_BUTTON_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ui/gfx/shadow_value.h" 9 #include "ui/gfx/shadow_value.h"
10 #include "ui/views/controls/button/custom_button.h" 10 #include "ui/views/controls/button/custom_button.h"
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 // independently of the rest. This can be subclassed to provide a custom 75 // independently of the rest. This can be subclassed to provide a custom
76 // implementation, by overriding CreateIconView(). 76 // implementation, by overriding CreateIconView().
77 class IconView : public views::ImageView { 77 class IconView : public views::ImageView {
78 public: 78 public:
79 IconView(); 79 IconView();
80 virtual ~IconView(); 80 virtual ~IconView();
81 81
82 void set_icon_size(int icon_size) { icon_size_ = icon_size; } 82 void set_icon_size(int icon_size) { icon_size_ = icon_size; }
83 int icon_size() const { return icon_size_; } 83 int icon_size() const { return icon_size_; }
84 84
85 // views::View overrides. 85 // ui::EventTarget:
86 virtual bool HitTestRect(const gfx::Rect& rect) const OVERRIDE; 86 virtual bool CanAcceptEvent(const ui::Event& event) OVERRIDE;
87 87
88 private: 88 private:
89 // Set to non-zero to force icons to be resized to fit within a square, 89 // Set to non-zero to force icons to be resized to fit within a square,
90 // while maintaining original proportions. 90 // while maintaining original proportions.
91 int icon_size_; 91 int icon_size_;
92 92
93 DISALLOW_COPY_AND_ASSIGN(IconView); 93 DISALLOW_COPY_AND_ASSIGN(IconView);
94 }; 94 };
95 95
96 // View overrides: 96 // View overrides:
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 // If non-null the destuctor sets this to true. This is set while the menu is 148 // If non-null the destuctor sets this to true. This is set while the menu is
149 // showing and used to detect if the menu was deleted while running. 149 // showing and used to detect if the menu was deleted while running.
150 bool* destroyed_flag_; 150 bool* destroyed_flag_;
151 151
152 DISALLOW_COPY_AND_ASSIGN(ShelfButton); 152 DISALLOW_COPY_AND_ASSIGN(ShelfButton);
153 }; 153 };
154 154
155 } // namespace ash 155 } // namespace ash
156 156
157 #endif // ASH_SHELF_SHELF_BUTTON_H_ 157 #endif // ASH_SHELF_SHELF_BUTTON_H_
OLDNEW
« no previous file with comments | « no previous file | ash/shelf/shelf_button.cc » ('j') | ash/shelf/shelf_button.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698