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

Side by Side Diff: ash/mus/accelerators/accelerator_handler.h

Issue 2761233003: Adds ability for accelerators to add key/value pairs to KeyEvent (Closed)
Patch Set: feedback and compile Created 3 years, 9 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
« no previous file with comments | « ash/mus/accelerators/accelerator_controller_registrar.cc ('k') | ash/mus/window_manager.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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_MUS_ACCELERATORS_ACCELERATOR_HANDLER_H_ 5 #ifndef ASH_MUS_ACCELERATORS_ACCELERATOR_HANDLER_H_
6 #define ASH_MUS_ACCELERATORS_ACCELERATOR_HANDLER_H_ 6 #define ASH_MUS_ACCELERATORS_ACCELERATOR_HANDLER_H_
7 7
8 #include <stdint.h>
9
10 #include <string>
11 #include <unordered_map>
12 #include <vector>
13
8 #include "services/ui/public/interfaces/window_manager.mojom.h" 14 #include "services/ui/public/interfaces/window_manager.mojom.h"
9 15
10 namespace ash { 16 namespace ash {
11 namespace mus { 17 namespace mus {
12 18
13 // Used by WindowManager for handling accelerators. 19 // Used by WindowManager for handling accelerators.
14 class AcceleratorHandler { 20 class AcceleratorHandler {
15 public: 21 public:
16 virtual ui::mojom::EventResult OnAccelerator(uint32_t id, 22 // See WindowManagerDelegate for details on |properties|.
17 const ui::Event& event) = 0; 23 virtual ui::mojom::EventResult OnAccelerator(
24 uint32_t id,
25 const ui::Event& event,
26 std::unordered_map<std::string, std::vector<uint8_t>>* properties) = 0;
18 27
19 protected: 28 protected:
20 virtual ~AcceleratorHandler() {} 29 virtual ~AcceleratorHandler() {}
21 }; 30 };
22 31
23 } // namespace mus 32 } // namespace mus
24 } // namespace ash 33 } // namespace ash
25 34
26 #endif // ASH_MUS_ACCELERATORS_ACCELERATOR_HANDLER_H_ 35 #endif // ASH_MUS_ACCELERATORS_ACCELERATOR_HANDLER_H_
OLDNEW
« no previous file with comments | « ash/mus/accelerators/accelerator_controller_registrar.cc ('k') | ash/mus/window_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698