diff options
author | Mike Blumenkrantz <zmike@osg.samsung.com> | 2016-07-12 12:49:03 -0400 |
---|---|---|
committer | Mike Blumenkrantz <zmike@osg.samsung.com> | 2016-07-12 12:51:00 -0400 |
commit | c6ef590e9e726b2c83e918c3411c3ec9ecfdc3dc (patch) | |
tree | e1d7d60175f13e35a8de1a5558178bb573d6a605 | |
parent | 08aaeffade0321cc9a41f2fca8a22a1a1bda8d2d (diff) | |
download | enlightenment-c6ef590e9e726b2c83e918c3411c3ec9ecfdc3dc.tar.gz |
set x11 randr iface for wl_x11 based on wm presence, not composited state
fixes usage in non-composited x11 environments (eg. openbox)
-rw-r--r-- | src/modules/wl_x11/e_mod_main.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/modules/wl_x11/e_mod_main.c b/src/modules/wl_x11/e_mod_main.c index 5f8ee713d3..a0332e05f2 100644 --- a/src/modules/wl_x11/e_mod_main.c +++ b/src/modules/wl_x11/e_mod_main.c @@ -15,6 +15,8 @@ E_API void * e_modapi_init(E_Module *m) { int w = 0, h = 0; + Ecore_X_Window root, win; + Eina_Bool managed; printf("LOAD WL_X11 MODULE\n"); @@ -23,6 +25,9 @@ e_modapi_init(E_Module *m) fprintf(stderr, "X11 connect failed!\n"); return NULL; } + root = ecore_x_window_root_first_get(); + managed = !!ecore_x_window_prop_window_get(root, ECORE_X_ATOM_NET_SUPPORTING_WM_CHECK, + &win, 1); e_comp_x_randr_canvas_new(ecore_x_window_root_first_get(), 1, 1); if (!e_comp->ee) @@ -35,7 +40,7 @@ e_modapi_init(E_Module *m) ecore_evas_name_class_set(e_comp->ee, "E", "compositor"); ecore_evas_screen_geometry_get(e_comp->ee, NULL, NULL, &w, &h); - if (!ecore_x_screen_is_composited(0)) + if (!managed) e_comp_x_randr_screen_iface_set(); if (!e_comp_wl_init()) return NULL; if (!e_comp_canvas_init(w, h)) return NULL; |