File tree Expand file tree Collapse file tree 1 file changed +9
-18
lines changed
Expand file tree Collapse file tree 1 file changed +9
-18
lines changed Original file line number Diff line number Diff line change 11#include "checkOS.c"
22#include <stdio.h>
33
4+ struct DisplayInfo {
5+ int x ;
6+ int y ;
7+ int w ;
8+ int h ;
9+ };
10+
11+ static struct DisplayInfo displayInfos [10 ];
12+
413#if defined (UNIX )
514 #include <X11/Xlib.h>
615 #include <X11/extensions/Xrandr.h>
716 #include <X11/extensions/randr.h>
817
9- struct DisplayInfo {
10- int x ;
11- int y ;
12- int w ;
13- int h ;
14- };
15-
1618 struct DisplayInfo * getDisplays () {
17- static struct DisplayInfo displayInfos [10 ];
18-
1919 Display * dpy = XOpenDisplay (NULL );
2020 XRRScreenResources * screen = XRRGetScreenResources (dpy , DefaultRootWindow (dpy ));
2121 XRRCrtcInfo * crtcInfo ;
4848
4949#if defined (WINDOWS )
5050 #include <winuser.h>
51- #include <stdio.h>
52-
53- struct DisplayInfo {
54- int x ;
55- int y ;
56- int w ;
57- int h ;
58- };
5951
60- static struct DisplayInfo displayInfos [10 ];
6152 int turns = 0 ;
6253
6354 BOOL CALLBACK MonitorEnum (HMONITOR hMon , HDC hdc , LPRECT lprc , LPARAM dwData ) {
You can’t perform that action at this time.
0 commit comments