englebass pushed a commit to branch master. http://git.enlightenment.org/core/enlightenment.git/commit/?id=8b5153130a4cd38a5d4fe08b8f90e1befe4265b0
commit 8b5153130a4cd38a5d4fe08b8f90e1befe4265b0 Author: Sebastian Dransfeld <s...@tango.flipp.net> Date: Wed Mar 5 12:04:19 2014 +0100 randr: Use already fetched root window --- src/bin/e_randr.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/bin/e_randr.c b/src/bin/e_randr.c index 0a46f6a..49a84d7 100644 --- a/src/bin/e_randr.c +++ b/src/bin/e_randr.c @@ -14,7 +14,7 @@ static Eina_Bool _e_randr_config_cb_timer(void *data); static void _e_randr_load(void); static void _e_randr_apply(void); static void _e_randr_output_mode_update(E_Randr_Output *cfg); -static E_Config_Randr_Output *_e_randr_config_output_new(unsigned int id); +static E_Config_Randr_Output *_e_randr_config_output_new(Ecore_X_Window root, unsigned int id); static E_Config_Randr_Output *_e_randr_config_output_find(Ecore_X_Randr_Output output); static E_Randr_Crtc *_e_randr_crtc_find(Ecore_X_Randr_Crtc xid); static E_Randr_Output *_e_randr_output_find(Ecore_X_Randr_Output xid); @@ -350,7 +350,7 @@ _e_randr_load(void) output_cfg = _e_randr_config_output_find(outputs[j]); if (!output_cfg) - output_cfg = _e_randr_config_output_new(outputs[j]); + output_cfg = _e_randr_config_output_new(root, outputs[j]); if (!output_cfg) continue; output = E_NEW(E_Randr_Output, 1); @@ -803,20 +803,15 @@ error: } static E_Config_Randr_Output * -_e_randr_config_output_new(unsigned int id) +_e_randr_config_output_new(Ecore_X_Window root, unsigned int id) { E_Config_Randr_Output *cfg = NULL; if ((cfg = E_NEW(E_Config_Randr_Output, 1))) { - Ecore_X_Window root = 0; - /* assign output xid */ cfg->xid = id; - /* grab the root window */ - root = ecore_x_window_root_first_get(); - /* get the crtc for this output */ cfg->crtc = ecore_x_randr_output_crtc_get(root, cfg->xid); --