From: raster Date: Wed, 11 Aug 2010 05:12:22 +0000 (+0000) Subject: work around a gl driver bug X-Git-Tag: 2.0_alpha~194^2~790 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5c2a784de22421c52ca77e3f222ff42108b84d31;p=framework%2Fuifw%2Fecore.git work around a gl driver bug export ECORE_EVAS_GL_FIRST_MAP_BUG=1 if you end up with blank empty windows when using evas gl engine in them git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/ecore@50981 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/lib/ecore_evas/ecore_evas_x.c b/src/lib/ecore_evas/ecore_evas_x.c index da9533b..82a5762 100644 --- a/src/lib/ecore_evas/ecore_evas_x.c +++ b/src/lib/ecore_evas/ecore_evas_x.c @@ -988,12 +988,23 @@ _ecore_evas_x_event_window_show(void *data __UNUSED__, int type __UNUSED__, void { Ecore_Evas *ee; Ecore_X_Event_Window_Show *e; - + static int first_map_bug = -1; + e = event; ee = ecore_event_window_match(e->win); if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */ if (e->win != ee->prop.window) return ECORE_CALLBACK_PASS_ON; - if (ee->visible) return ECORE_CALLBACK_DONE; /* dont pass it on */ + if (first_map_bug < 0) + { + if (getenv("ECORE_EVAS_GL_FIRST_MAP_BUG")) + first_map_bug = atoi(getenv("ECORE_EVAS_GL_FIRST_MAP_BUG")); + else + first_map_bug = 0; + if ((first_map_bug) && + (!strcmp(ee->driver, "opengl_x11"))) + evas_damage_rectangle_add(ee->evas, 0, 0, ee->w, ee->h); + } + if (ee->visible) return ECORE_CALLBACK_PASS_ON; // printf("SHOW EVENT %p\n", ee); ee->visible = 1; if (ee->func.fn_show) ee->func.fn_show(ee); @@ -1010,7 +1021,7 @@ _ecore_evas_x_event_window_hide(void *data __UNUSED__, int type __UNUSED__, void ee = ecore_event_window_match(e->win); if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */ if (e->win != ee->prop.window) return ECORE_CALLBACK_PASS_ON; - if (!ee->visible) return ECORE_CALLBACK_DONE; /* dont pass it on */ + if (!ee->visible) return ECORE_CALLBACK_PASS_ON; // printf("HIDE EVENT %p\n", ee); ee->visible = 0; if (ee->func.fn_hide) ee->func.fn_hide(ee);