7 #endif /* ifdef HAVE_CONFIG_H */
10 #include "ecore_x_private.h"
12 #include "Ecore_X_Atoms.h"
15 static XineramaScreenInfo *_xin_info = NULL;
16 static int _xin_scr_num = 0;
17 #endif /* ifdef ECORE_XINERAMA */
20 ecore_x_xinerama_screen_count_get(void)
23 int event_base, error_base;
25 LOGFN(__FILE__, __LINE__, __FUNCTION__);
30 if (XineramaQueryExtension(_ecore_x_disp, &event_base, &error_base))
32 _xin_info = XineramaQueryScreens(_ecore_x_disp, &_xin_scr_num);
37 #endif /* ifdef ECORE_XINERAMA */
39 } /* ecore_x_xinerama_screen_count_get */
42 ecore_x_xinerama_screen_geometry_get(int screen, int *x, int *y, int *w, int *h)
44 LOGFN(__FILE__, __LINE__, __FUNCTION__);
50 for (i = 0; i < _xin_scr_num; i++)
52 if (_xin_info[i].screen_number == screen)
55 *x = _xin_info[i].x_org;
58 *y = _xin_info[i].y_org;
61 *w = _xin_info[i].width;
64 *h = _xin_info[i].height;
71 #endif /* ifdef ECORE_XINERAMA */
79 *w = DisplayWidth(_ecore_x_disp, 0);
82 *h = DisplayHeight(_ecore_x_disp, 0);
85 } /* ecore_x_xinerama_screen_geometry_get */