blob: 49bd6c29f3a407345ca1ca78a2de6f2695050a41 [file] [log] [blame]
Patrik Stridvallab121e71999-02-04 11:11:01 +00001/*
2 * X11 desktop driver
3 *
4 * Copyright 1998 Patrik Stridvall
5 *
6 */
7
8#include "config.h"
9
10#ifndef X_DISPLAY_MISSING
11
Alexandre Julliard359f497e1999-07-04 16:02:24 +000012#include "debugtools.h"
Patrik Stridvallab121e71999-02-04 11:11:01 +000013#include "desktop.h"
14#include "monitor.h"
15#include "options.h"
16#include "win.h"
Jim Aston2e1cafa1999-03-14 16:35:05 +000017#include "windef.h"
Patrik Stridvallab121e71999-02-04 11:11:01 +000018#include "x11drv.h"
19
20/***********************************************************************
21 * X11DRV_DESKTOP_GetXScreen
22 *
23 * Return the X screen associated to the desktop.
24 */
25Screen *X11DRV_DESKTOP_GetXScreen(DESKTOP *pDesktop)
26{
27 return X11DRV_MONITOR_GetXScreen(pDesktop->pPrimaryMonitor);
28}
29
30/***********************************************************************
31 * X11DRV_DESKTOP_GetXRootWindow
32 *
33 * Return the X root window associated to the desktop.
34 */
35Window X11DRV_DESKTOP_GetXRootWindow(DESKTOP *pDesktop)
36{
37 return X11DRV_MONITOR_GetXRootWindow(pDesktop->pPrimaryMonitor);
38}
39
40/***********************************************************************
41 * X11DRV_DESKTOP_Initialize
42 */
43void X11DRV_DESKTOP_Initialize(DESKTOP *pDesktop)
44{
45 pDesktop->pPrimaryMonitor = &MONITOR_PrimaryMonitor;
46}
47
48/***********************************************************************
49 * X11DRV_DESKTOP_Finalize
50 */
51void X11DRV_DESKTOP_Finalize(DESKTOP *pDesktop)
52{
53}
54
55/***********************************************************************
56 * X11DRV_DESKTOP_GetScreenWidth
57 *
58 * Return the width of the screen associated to the desktop.
59 */
60int X11DRV_DESKTOP_GetScreenWidth(DESKTOP *pDesktop)
61{
62 return MONITOR_GetWidth(pDesktop->pPrimaryMonitor);
63}
64
65/***********************************************************************
66 * X11DRV_DESKTOP_GetScreenHeight
67 *
68 * Return the width of the screen associated to the desktop.
69 */
70int X11DRV_DESKTOP_GetScreenHeight(DESKTOP *pDesktop)
71{
72 return MONITOR_GetHeight(pDesktop->pPrimaryMonitor);
73}
74
75/***********************************************************************
76 * X11DRV_DESKTOP_GetScreenDepth
77 *
78 * Return the depth of the screen associated to the desktop.
79 */
80int X11DRV_DESKTOP_GetScreenDepth(DESKTOP *pDesktop)
81{
82 return MONITOR_GetDepth(pDesktop->pPrimaryMonitor);
83}
84
85#endif /* X_DISPLAY_MISSING */