OLD | NEW |
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 #ifndef UI_VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ | 5 #ifndef UI_VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ |
6 #define UI_VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ | 6 #define UI_VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 const char* GetClassName() const override; | 70 const char* GetClassName() const override; |
71 void OnPaint(gfx::Canvas* canvas) override; | 71 void OnPaint(gfx::Canvas* canvas) override; |
72 bool OnMousePressed(const ui::MouseEvent& event) override; | 72 bool OnMousePressed(const ui::MouseEvent& event) override; |
73 void OnMouseReleased(const ui::MouseEvent& event) override; | 73 void OnMouseReleased(const ui::MouseEvent& event) override; |
74 void OnMouseEntered(const ui::MouseEvent& event) override; | 74 void OnMouseEntered(const ui::MouseEvent& event) override; |
75 void OnMouseExited(const ui::MouseEvent& event) override; | 75 void OnMouseExited(const ui::MouseEvent& event) override; |
76 void OnMouseMoved(const ui::MouseEvent& event) override; | 76 void OnMouseMoved(const ui::MouseEvent& event) override; |
77 void OnGestureEvent(ui::GestureEvent* event) override; | 77 void OnGestureEvent(ui::GestureEvent* event) override; |
78 bool OnKeyPressed(const ui::KeyEvent& event) override; | 78 bool OnKeyPressed(const ui::KeyEvent& event) override; |
79 bool OnKeyReleased(const ui::KeyEvent& event) override; | 79 bool OnKeyReleased(const ui::KeyEvent& event) override; |
| 80 bool AcceleratorPressed(const ui::Accelerator& accelerator) override; |
80 void GetAccessibleState(ui::AXViewState* state) override; | 81 void GetAccessibleState(ui::AXViewState* state) override; |
81 | 82 |
82 protected: | 83 protected: |
83 // Paint the menu marker image. | 84 // Paint the menu marker image. |
84 void PaintMenuMarker(gfx::Canvas* canvas); | 85 void PaintMenuMarker(gfx::Canvas* canvas); |
85 | 86 |
86 // Overridden from LabelButton: | 87 // Overridden from LabelButton: |
87 gfx::Rect GetChildAreaBounds() override; | 88 gfx::Rect GetChildAreaBounds() override; |
88 | 89 |
89 // Overridden from CustomButton: | 90 // Overridden from CustomButton: |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 bool should_disable_after_press_; | 136 bool should_disable_after_press_; |
136 | 137 |
137 base::WeakPtrFactory<MenuButton> weak_factory_; | 138 base::WeakPtrFactory<MenuButton> weak_factory_; |
138 | 139 |
139 DISALLOW_COPY_AND_ASSIGN(MenuButton); | 140 DISALLOW_COPY_AND_ASSIGN(MenuButton); |
140 }; | 141 }; |
141 | 142 |
142 } // namespace views | 143 } // namespace views |
143 | 144 |
144 #endif // UI_VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ | 145 #endif // UI_VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ |
OLD | NEW |