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

Unified Diff: ui/views/controls/button/button_dropdown.cc

Issue 8909002: views: Convert IsEnabled() to just enabled() since it's just a simple accessor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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 | « ui/views/accessible_pane_view.cc ('k') | ui/views/controls/button/custom_button.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/button/button_dropdown.cc
diff --git a/ui/views/controls/button/button_dropdown.cc b/ui/views/controls/button/button_dropdown.cc
index a9cbb947d665e9ff929296c34050b65593adb899..83afae88adbe8e23016b4c6c263efd3ca4c988d8 100644
--- a/ui/views/controls/button/button_dropdown.cc
+++ b/ui/views/controls/button/button_dropdown.cc
@@ -49,7 +49,7 @@ ButtonDropDown::~ButtonDropDown() {
////////////////////////////////////////////////////////////////////////////////
bool ButtonDropDown::OnMousePressed(const MouseEvent& event) {
- if (IsEnabled() && IsTriggerableEvent(event) && HitTest(event.location())) {
+ if (enabled() && IsTriggerableEvent(event) && HitTest(event.location())) {
// Store the y pos of the mouse coordinates so we can use them later to
// determine if the user dragged the mouse down (which should pop up the
// drag down menu immediately, instead of waiting for the timer)
@@ -91,7 +91,7 @@ void ButtonDropDown::OnMouseReleased(const MouseEvent& event) {
if (IsTriggerableEvent(event))
show_menu_factory_.InvalidateWeakPtrs();
- if (IsEnabled() && event.IsRightMouseButton() && HitTest(event.location())) {
+ if (enabled() && event.IsRightMouseButton() && HitTest(event.location())) {
show_menu_factory_.InvalidateWeakPtrs();
ShowDropDownMenu(GetWidget()->GetNativeView());
}
« no previous file with comments | « ui/views/accessible_pane_view.cc ('k') | ui/views/controls/button/custom_button.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698