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

Unified Diff: ash/accelerators/accelerator_dispatcher.h

Issue 298703007: Refactor and move ash independent nested accelerator code to ui/wm/core (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: skip test if platform does not support PES Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ash/accelerators/accelerator_dispatcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/accelerators/accelerator_dispatcher.h
diff --git a/ash/accelerators/accelerator_dispatcher.h b/ash/accelerators/accelerator_dispatcher.h
deleted file mode 100644
index bcbf6e6930e74a891673d5c2d4c509d4407de06d..0000000000000000000000000000000000000000
--- a/ash/accelerators/accelerator_dispatcher.h
+++ /dev/null
@@ -1,58 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef ASH_ACCELERATORS_ACCELERATOR_DISPATCHER_H_
-#define ASH_ACCELERATORS_ACCELERATOR_DISPATCHER_H_
-
-#include "ash/ash_export.h"
-#include "base/macros.h"
-#include "base/memory/scoped_ptr.h"
-
-namespace base {
-class MessagePumpDispatcher;
-class RunLoop;
-}
-
-namespace ui {
-class KeyEvent;
-}
-
-namespace ash {
-
-// Dispatcher for handling accelerators from menu.
-//
-// Wraps a nested dispatcher to which control is passed if no accelerator key
-// has been pressed. If the nested dispatcher is NULL, then the control is
-// passed back to the default dispatcher.
-// TODO(pkotwicz): Add support for a |nested_dispatcher| which sends
-// events to a system IME.
-class ASH_EXPORT AcceleratorDispatcher {
- public:
- virtual ~AcceleratorDispatcher() {}
-
- static scoped_ptr<AcceleratorDispatcher> Create(
- base::MessagePumpDispatcher* nested_dispatcher);
-
- // Creates a base::RunLoop object to run a nested message loop.
- virtual scoped_ptr<base::RunLoop> CreateRunLoop() = 0;
-
- protected:
- AcceleratorDispatcher() {}
-
- // Closes any open menu if the key-event could potentially be a system
- // accelerator.
- // Returns whether a menu was closed.
- bool MenuClosedForPossibleAccelerator(const ui::KeyEvent& key_event);
-
- // Attempts to trigger an accelerator for the key-event.
- // Returns whether an accelerator was triggered.
- bool AcceleratorProcessedForKeyEvent(const ui::KeyEvent& key_event);
-
- private:
- DISALLOW_COPY_AND_ASSIGN(AcceleratorDispatcher);
-};
-
-} // namespace ash
-
-#endif // ASH_ACCELERATORS_ACCELERATOR_DISPATCHER_H_
« no previous file with comments | « no previous file | ash/accelerators/accelerator_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698