diff options
author | fluxgen <fluxgen> | 2002-03-19 14:30:43 (GMT) |
---|---|---|
committer | fluxgen <fluxgen> | 2002-03-19 14:30:43 (GMT) |
commit | 95aeda26271cce3061a46a3ca0b122bc13c8f5c8 (patch) | |
tree | aaa01d20e77a2445a20a0522d86296b981049b8e /src/BaseDisplay.hh | |
parent | 1871169b06d8b9909ff26b761d24a40a65ef18f9 (diff) | |
download | fluxbox-95aeda26271cce3061a46a3ca0b122bc13c8f5c8.zip fluxbox-95aeda26271cce3061a46a3ca0b122bc13c8f5c8.tar.bz2 |
Xinerama support
Diffstat (limited to 'src/BaseDisplay.hh')
-rw-r--r-- | src/BaseDisplay.hh | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/src/BaseDisplay.hh b/src/BaseDisplay.hh index ffc2b8d..3cf8d40 100644 --- a/src/BaseDisplay.hh +++ b/src/BaseDisplay.hh | |||
@@ -22,7 +22,7 @@ | |||
22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
23 | // DEALINGS IN THE SOFTWARE. | 23 | // DEALINGS IN THE SOFTWARE. |
24 | 24 | ||
25 | // $Id: BaseDisplay.hh,v 1.15 2002/03/18 23:39:53 fluxgen Exp $ | 25 | // $Id: BaseDisplay.hh,v 1.16 2002/03/19 14:30:42 fluxgen Exp $ |
26 | 26 | ||
27 | #ifndef BASEDISPLAY_HH | 27 | #ifndef BASEDISPLAY_HH |
28 | #define BASEDISPLAY_HH | 28 | #define BASEDISPLAY_HH |
@@ -31,6 +31,12 @@ | |||
31 | #include "FbAtoms.hh" | 31 | #include "FbAtoms.hh" |
32 | #include <X11/Xlib.h> | 32 | #include <X11/Xlib.h> |
33 | 33 | ||
34 | #ifdef XINERAMA | ||
35 | extern "C" { | ||
36 | #include <X11/extensions/Xinerama.h> | ||
37 | } | ||
38 | #endif // XINERAMA | ||
39 | |||
34 | #include <list> | 40 | #include <list> |
35 | #include <vector> | 41 | #include <vector> |
36 | 42 | ||
@@ -145,6 +151,7 @@ protected: | |||
145 | class ScreenInfo { | 151 | class ScreenInfo { |
146 | public: | 152 | public: |
147 | ScreenInfo(BaseDisplay *, int); | 153 | ScreenInfo(BaseDisplay *, int); |
154 | ~ScreenInfo(void); | ||
148 | 155 | ||
149 | inline BaseDisplay *getBaseDisplay(void) { return basedisplay; } | 156 | inline BaseDisplay *getBaseDisplay(void) { return basedisplay; } |
150 | 157 | ||
@@ -158,6 +165,17 @@ public: | |||
158 | inline const unsigned int getWidth(void) const { return width; } | 165 | inline const unsigned int getWidth(void) const { return width; } |
159 | inline const unsigned int getHeight(void) const { return height; } | 166 | inline const unsigned int getHeight(void) const { return height; } |
160 | 167 | ||
168 | #ifdef XINERAMA | ||
169 | inline bool hasXinerama(void) { return m_hasXinerama; } | ||
170 | inline int getNumHeads(void) { return xineramaNumHeads; } | ||
171 | unsigned int getHead(int x, int y); | ||
172 | unsigned int getCurrHead(void); | ||
173 | unsigned int getHeadWidth(unsigned int head); | ||
174 | unsigned int getHeadHeight(unsigned int head); | ||
175 | int getHeadX(unsigned int head); | ||
176 | int getHeadY(unsigned int head); | ||
177 | #endif // XINERAMA | ||
178 | |||
161 | private: | 179 | private: |
162 | BaseDisplay *basedisplay; | 180 | BaseDisplay *basedisplay; |
163 | Visual *visual; | 181 | Visual *visual; |
@@ -169,5 +187,10 @@ private: | |||
169 | 187 | ||
170 | }; | 188 | }; |
171 | 189 | ||
190 | #ifdef XINERAMA | ||
191 | bool m_hasXinerama; | ||
192 | int xineramaMajor, xineramaMinor, xineramaNumHeads, xineramaLastHead; | ||
193 | XineramaScreenInfo *xineramaInfos; | ||
194 | #endif // XINERAMA | ||
172 | 195 | ||
173 | #endif // BASEDISPLAY_HH | 196 | #endif // BASEDISPLAY_HH |