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

Unified Diff: ui/aura/client/accelerator_client.cc

Issue 9224001: Fixes issue with accelerators when a menu is open (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Changes as suggested by oshima Created 8 years, 11 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
Index: ui/aura/client/accelerator_client.cc
diff --git a/ui/aura/client/accelerator_client.cc b/ui/aura/client/accelerator_client.cc
new file mode 100644
index 0000000000000000000000000000000000000000..b24395085d295ff1330e78aa787df54125e549fb
--- /dev/null
+++ b/ui/aura/client/accelerator_client.cc
@@ -0,0 +1,25 @@
+// Copyright (c) 2012 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.
+
+#include "ui/aura/client/accelerator_client.h"
+
+#include "ui/aura/root_window.h"
+
+namespace aura {
+
+namespace client {
+
+const char kMenuAcceleratorClient[] = "AuraMenuAcceleratorClient";
+
+void SetAcceleratorClient(AcceleratorClient* client) {
+ RootWindow::GetInstance()->SetProperty(kMenuAcceleratorClient, client);
+}
+
+AcceleratorClient* GetAcceleratorClient() {
+ return reinterpret_cast<AcceleratorClient*>(
+ RootWindow::GetInstance()->GetProperty(kMenuAcceleratorClient));
+}
+
+} // namespace client
+} // namespace aura

Powered by Google App Engine
This is Rietveld 408576698