replace OVERRIDE and FINAL with override and final in ash/
[chromium-blink-merge.git] / ash / accelerators / accelerator_delegate.h
blob7027d68f25fd0261508faae40c760f2ab3dc4873
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.
5 #ifndef ASH_ACCELERATORS_ACCELERATOR_DELEGATE_H_
6 #define ASH_ACCELERATORS_ACCELERATOR_DELEGATE_H_
8 #include "ash/ash_export.h"
9 #include "base/macros.h"
10 #include "ui/wm/core/accelerator_delegate.h"
12 namespace ash {
14 class ASH_EXPORT AcceleratorDelegate
15 : NON_EXPORTED_BASE(public wm::AcceleratorDelegate) {
16 public:
17 AcceleratorDelegate();
18 virtual ~AcceleratorDelegate();
20 // wm::AcceleratorDelegate:
21 virtual bool ProcessAccelerator(const ui::KeyEvent& event,
22 const ui::Accelerator& accelerator,
23 KeyType key_type) override;
25 private:
26 // Returns true if the window should be allowed a chance to handle
27 // system keys.
28 bool CanConsumeSystemKeys(const ui::KeyEvent& event);
30 bool ShouldProcessAcceleratorNow(const ui::KeyEvent& event,
31 const ui::Accelerator& accelerator);
33 DISALLOW_COPY_AND_ASSIGN(AcceleratorDelegate);
36 } // namespace ash
38 #endif // ASH_ACCELERATORS_ACCELERATOR_DELEGATE_H_