Index: ui/aura/dispatcher_linux.h |
diff --git a/ui/aura/dispatcher_linux.h b/ui/aura/dispatcher_linux.h |
index c18cc3073c19f29624868d4a55b09146b1849529..e7c7ef2e1df961402ae2aa45dbe3aad64d79a70d 100644 |
--- a/ui/aura/dispatcher_linux.h |
+++ b/ui/aura/dispatcher_linux.h |
@@ -7,6 +7,7 @@ |
#pragma once |
#include <map> |
+#include <vector> |
#include <X11/Xlib.h> |
// Get rid of a macro from Xlib.h that conflicts with Aura's RootWindow class. |
#undef RootWindow |
@@ -23,9 +24,14 @@ class DispatcherLinux : public MessageLoop::Dispatcher, |
DispatcherLinux(); |
virtual ~DispatcherLinux(); |
- void WindowDispatcherCreated(::Window window, |
- MessageLoop::Dispatcher* dispatcher); |
- void WindowDispatcherDestroying(::Window window); |
+ // Register/Unregister Dispatcher for the |window|. |
+ void RegisterDispatcher(::Window window, |
Daniel Erat
2012/05/22 14:33:42
nit: rename to RegisterWindowDispatcher() or Rende
oshima
2012/05/22 19:50:02
Agreed. Renamed to RegisterDispatcherFor{Root}Wind
|
+ MessageLoop::Dispatcher* dispatcher); |
+ void UnregisterDispatcher(::Window window); |
+ |
+ // Register/Unregister Dispatchers for RootWindow. |
Daniel Erat
2012/05/22 14:33:42
nit: reword this comment to something like:
// Re
oshima
2012/05/22 19:50:02
Done.
|
+ void RegisterRootWindowDispatcher(MessageLoop::Dispatcher* dispatcher); |
+ void UnregisterRootWindowDispatcher(MessageLoop::Dispatcher* dispatcher); |
// Overridden from MessageLoop::Dispatcher: |
virtual bool Dispatch(const base::NativeEvent& event) OVERRIDE; |
@@ -37,10 +43,15 @@ class DispatcherLinux : public MessageLoop::Dispatcher, |
private: |
typedef std::map< ::Window, MessageLoop::Dispatcher* > DispatchersMap; |
+ typedef std::vector<MessageLoop::Dispatcher*> Dispatchers; |
MessageLoop::Dispatcher* GetDispatcherForXEvent(XEvent* xev) const; |
+ void DispatchRootWindowEvent(XEvent* xev); |
DispatchersMap dispatchers_; |
+ Dispatchers root_window_dispatchers_; |
+ |
+ ::Window root_window_; |
Daniel Erat
2012/05/22 14:33:42
nit: rename to |x_root_window_|?
oshima
2012/05/22 19:50:02
Done.
|
DISALLOW_COPY_AND_ASSIGN(DispatcherLinux); |
}; |