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

Side by Side Diff: ui/views/controls/menu/menu_delegate.cc

Issue 10827271: Replace views::Event with ui::Event. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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 | « ui/views/controls/menu/menu_delegate.h ('k') | ui/views/controls/menu/menu_model_adapter.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "ui/views/controls/menu/menu_config.h" 5 #include "ui/views/controls/menu/menu_config.h"
6 #include "ui/views/controls/menu/menu_delegate.h" 6 #include "ui/views/controls/menu/menu_delegate.h"
7 7
8 namespace views { 8 namespace views {
9 9
10 MenuDelegate::~MenuDelegate() {} 10 MenuDelegate::~MenuDelegate() {}
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 51
52 bool MenuDelegate::ShouldCloseAllMenusOnExecute(int id) { 52 bool MenuDelegate::ShouldCloseAllMenusOnExecute(int id) {
53 return true; 53 return true;
54 } 54 }
55 55
56 void MenuDelegate::ExecuteCommand(int id, int mouse_event_flags) { 56 void MenuDelegate::ExecuteCommand(int id, int mouse_event_flags) {
57 ExecuteCommand(id); 57 ExecuteCommand(id);
58 } 58 }
59 59
60 bool MenuDelegate::IsTriggerableEvent(MenuItemView* source, 60 bool MenuDelegate::IsTriggerableEvent(MenuItemView* source,
61 const Event& e) { 61 const ui::Event& e) {
62 return e.type() == ui::ET_GESTURE_TAP || 62 return e.type() == ui::ET_GESTURE_TAP ||
63 e.type() == ui::ET_GESTURE_TAP_DOWN || 63 e.type() == ui::ET_GESTURE_TAP_DOWN ||
64 (e.IsMouseEvent() && (e.flags() & 64 (e.IsMouseEvent() && (e.flags() &
65 (ui::EF_LEFT_MOUSE_BUTTON | ui::EF_RIGHT_MOUSE_BUTTON))); 65 (ui::EF_LEFT_MOUSE_BUTTON | ui::EF_RIGHT_MOUSE_BUTTON)));
66 } 66 }
67 67
68 bool MenuDelegate::CanDrop(MenuItemView* menu, const OSExchangeData& data) { 68 bool MenuDelegate::CanDrop(MenuItemView* menu, const OSExchangeData& data) {
69 return false; 69 return false;
70 } 70 }
71 71
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 MenuConfig::instance().submenu_horizontal_margin_size, 133 MenuConfig::instance().submenu_horizontal_margin_size,
134 MenuConfig::instance().submenu_vertical_margin_size, 134 MenuConfig::instance().submenu_vertical_margin_size,
135 MenuConfig::instance().submenu_horizontal_margin_size); 135 MenuConfig::instance().submenu_horizontal_margin_size);
136 } 136 }
137 137
138 Background* MenuDelegate::CreateMenuBackground() { 138 Background* MenuDelegate::CreateMenuBackground() {
139 return NULL; 139 return NULL;
140 } 140 }
141 141
142 } // namespace views 142 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/controls/menu/menu_delegate.h ('k') | ui/views/controls/menu/menu_model_adapter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698