OLD | NEW |
---|---|
(Empty) | |
1 // Copyright (c) 2011 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. | |
4 | |
5 #ifndef UI_BASE_X_ROOT_WINDOW_PROPERTY_WATCHER_X_H_ | |
6 #define UI_BASE_X_ROOT_WINDOW_PROPERTY_WATCHER_X_H_ | |
7 #pragma once | |
8 | |
9 #include <gdk/gdk.h> | |
10 | |
11 #include "base/memory/singleton.h" | |
12 #include "ui/base/gtk/gtk_signal.h" | |
13 #include "ui/base/ui_export.h" | |
14 | |
15 namespace ui { | |
sky
2011/11/18 17:54:22
Put this in an internal namespace (ui::internal) i
prasadt
2011/11/18 22:31:42
Done.
| |
16 | |
17 // This class keeps track of changes to properties on root window. This is not | |
sky
2011/11/18 17:54:22
'on root' -> 'on the root'
prasadt
2011/11/18 22:31:42
Done.
| |
18 // to be used directly. Implement a watcher for the specific property you're | |
19 // interested in. | |
20 class UI_EXPORT RootWindowPropertyWatcherX { | |
21 public: | |
22 static RootWindowPropertyWatcherX* GetInstance(); | |
23 | |
24 private: | |
25 friend struct DefaultSingletonTraits<RootWindowPropertyWatcherX>; | |
26 | |
27 RootWindowPropertyWatcherX(); | |
28 ~RootWindowPropertyWatcherX(); | |
29 | |
30 // Callback for PropertyChange XEvents. | |
31 CHROMEG_CALLBACK_1(RootWindowPropertyWatcherX, GdkFilterReturn, | |
32 OnWindowXEvent, GdkXEvent*, GdkEvent*); | |
33 | |
34 DISALLOW_COPY_AND_ASSIGN(RootWindowPropertyWatcherX); | |
35 }; | |
36 | |
37 } // namespace ui | |
38 | |
39 #endif // UI_BASE_X_ROOT_WINDOW_PROPERTY_WATCHER_X_H_ | |
OLD | NEW |