Chromium Code Reviews| Index: ash/mus/accelerators/accelerator_controller_registrar.h |
| diff --git a/ash/mus/accelerators/accelerator_controller_registrar.h b/ash/mus/accelerators/accelerator_controller_registrar.h |
| index da2841f6979bc5b64bcfcb49f710e495ba346a34..cdf38de4bdda16f5f912f6ffdd3a62b6f58fe5cd 100644 |
| --- a/ash/mus/accelerators/accelerator_controller_registrar.h |
| +++ b/ash/mus/accelerators/accelerator_controller_registrar.h |
| @@ -8,6 +8,7 @@ |
| #include <stdint.h> |
| #include <map> |
| +#include <vector> |
| #include "ash/mus/accelerators/accelerator_handler.h" |
| #include "base/macros.h" |
| @@ -38,13 +39,22 @@ class AcceleratorControllerRegistrar : public AcceleratorHandler, |
| ui::mojom::EventResult OnAccelerator(uint32_t id, |
| const ui::Event& event) override; |
| - // ui::AcceleratorManagerDelegate: |
| - void OnAcceleratorRegistered(const ui::Accelerator& accelerator) override; |
| - void OnAcceleratorUnregistered(const ui::Accelerator& accelerator) override; |
| - |
| private: |
| friend class AcceleratorControllerRegistrarTestApi; |
| + // ui::AcceleratorManagerDelegate: |
| + void OnAcceleratorRegistered(const ui::Accelerator& accelerator); |
|
mfomitchev
2017/01/26 20:05:13
There's no reason to have this method anymore now
thanhph1
2017/01/26 20:33:08
Done, thanks! I also updated unit test comment.
|
| + void OnAcceleratorUnregistered(const ui::Accelerator& accelerator) override; |
| + void OnAcceleratorVectorRegistered( |
| + const std::vector<ui::Accelerator>& accelerators) override; |
| + |
| + // Generate id and add the corresponding accelerator to accelerator vector. |
| + // Creates a PRE_TARGET and POST_TARGET mojom accelerators for the provided |
| + // |accelerator| and adds them to the provided |accelerator_vector|. |
| + void AddAcceleratorToVector( |
| + const ui::Accelerator& accelerator, |
| + std::vector<ui::mojom::AcceleratorPtr>& accelerator_vector); |
| + |
| // The flow of accelerators in ash is: |
| // . wm::AcceleratorFilter() sees events first as it's a pre-target handler. |
| // . AcceleratorFilter forwards to its delegate, which indirectly is |