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

Unified Diff: ui/aura/dispatcher_linux.cc

Issue 9958036: aura: Add RootWindowObserver::OnKeyboardMappingChanged(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/aura/root_window.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/dispatcher_linux.cc
diff --git a/ui/aura/dispatcher_linux.cc b/ui/aura/dispatcher_linux.cc
index 802d389a08e511532dce7e545be8912edc799c74..a10fba522072634683c1862bca2dbe40aacf9cfd 100644
--- a/ui/aura/dispatcher_linux.cc
+++ b/ui/aura/dispatcher_linux.cc
@@ -37,6 +37,18 @@ base::MessagePumpDispatcher::DispatchStatus DispatcherLinux::Dispatch(
ui::UpdateDeviceList();
return EVENT_PROCESSED;
}
+
+ // MappingNotify events (meaning that the keyboard or pointer buttons have
+ // been remapped) aren't associated with a window; send them to all
+ // dispatchers.
+ if (xev->type == MappingNotify) {
+ for (DispatchersMap::const_iterator it = dispatchers_.begin();
+ it != dispatchers_.end(); ++it) {
+ it->second->Dispatch(xev);
+ }
+ return EVENT_PROCESSED;
+ }
+
MessageLoop::Dispatcher* dispatcher = GetDispatcherForXEvent(xev);
return dispatcher ? dispatcher->Dispatch(xev) : EVENT_IGNORED;
}
« no previous file with comments | « no previous file | ui/aura/root_window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698