widget/gtk/nsScreenManagerGtk.h

branch
TOR_BUG_9701
changeset 10
ac0c01689b40
equal deleted inserted replaced
-1:000000000000 0:1dae513ad915
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5
6 #ifndef nsScreenManagerGtk_h___
7 #define nsScreenManagerGtk_h___
8
9 #include "nsIScreenManager.h"
10 #include "nsIScreen.h"
11 #include "nsCOMPtr.h"
12 #include "nsCOMArray.h"
13 #include "prlink.h"
14 #include "gdk/gdk.h"
15 #ifdef MOZ_X11
16 #include <X11/Xlib.h>
17 #endif
18
19 //------------------------------------------------------------------------
20
21 class nsScreenManagerGtk : public nsIScreenManager
22 {
23 public:
24 nsScreenManagerGtk ( );
25 virtual ~nsScreenManagerGtk();
26
27 NS_DECL_ISUPPORTS
28 NS_DECL_NSISCREENMANAGER
29
30 #ifdef MOZ_X11
31 Atom NetWorkareaAtom() { return mNetWorkareaAtom; }
32 #endif
33
34 // For internal use, or reinitialization from change notification.
35 nsresult Init();
36
37 private:
38
39 nsresult EnsureInit();
40
41 // Cached screen array. Its length is the number of screens we have.
42 nsCOMArray<nsIScreen> mCachedScreenArray;
43
44 PRLibrary *mXineramalib;
45
46 GdkWindow *mRootWindow;
47 #ifdef MOZ_X11
48 Atom mNetWorkareaAtom;
49 #endif
50 };
51
52 #endif // nsScreenManagerGtk_h___

mercurial