OLD | NEW |
(Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef UI_VIEWS_TOUCHUI_TOUCH_SELECTION_MENU_RUNNER_VIEWS_H_ |
| 6 #define UI_VIEWS_TOUCHUI_TOUCH_SELECTION_MENU_RUNNER_VIEWS_H_ |
| 7 |
| 8 #include "ui/touch_selection/touch_selection_menu_runner.h" |
| 9 #include "ui/views/touchui/touch_editing_menu.h" |
| 10 #include "ui/views/views_export.h" |
| 11 |
| 12 namespace views { |
| 13 |
| 14 // ... |
| 15 class VIEWS_EXPORT TouchSelectionMenuRunnerViews |
| 16 : public ui::TouchSelectionMenuRunner, |
| 17 public TouchEditingMenuController { |
| 18 public: |
| 19 TouchSelectionMenuRunnerViews(); |
| 20 ~TouchSelectionMenuRunnerViews() override; |
| 21 |
| 22 private: |
| 23 // Overriden from ui::TouchSelectionMenuRunner. |
| 24 void RunMenu(ui::TouchSelectionMenuClient* client, |
| 25 const gfx::Rect& anchor_rect, |
| 26 const gfx::Size& handle_image_size, |
| 27 aura::Window* context) override; |
| 28 void CloseMenu() override; |
| 29 bool IsRunning() const override; |
| 30 |
| 31 // Overriden from TouchEditingMenuController. |
| 32 bool IsCommandIdEnabled(int command_id) const override; |
| 33 void ExecuteCommand(int command_id, int event_flags) override; |
| 34 void OpenContextMenu() override; |
| 35 void OnMenuClosed(TouchEditingMenuView* menu) override; |
| 36 |
| 37 TouchEditingMenuView* menu_; |
| 38 ui::TouchSelectionMenuClient* client_; |
| 39 |
| 40 DISALLOW_COPY_AND_ASSIGN(TouchSelectionMenuRunnerViews); |
| 41 }; |
| 42 |
| 43 } // namespace views |
| 44 |
| 45 #endif // UI_VIEWS_TOUCHUI_TOUCH_SELECTION_MENU_RUNNER_VIEWS_H_ |
OLD | NEW |