Enlightenment CVS committal Author : rbdpngn Project : e17 Module : libs/ewl
Dir : e17/libs/ewl/src/lib Modified Files: ewl_theme.c Log Message: Don't set the theme to the default theme when the widget is initialized. This should restore theme heirarchy functionality but keep the speed as we can move quickly up the object tree. Could someone valgrind this? I noticed some corruption during testing, but I believe it's been fixed. =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_theme.c,v retrieving revision 1.10 retrieving revision 1.11 diff -u -3 -r1.10 -r1.11 --- ewl_theme.c 17 Jul 2005 21:41:52 -0000 1.10 +++ ewl_theme.c 20 Jul 2005 05:28:34 -0000 1.11 @@ -234,7 +234,8 @@ DENTER_FUNCTION(DLEVEL_STABLE); DCHECK_PARAM_PTR_RET("w", w, FALSE); - w->theme = def_theme_data; + w->theme = NULL; + /* w->theme = def_theme_data; */ DRETURN_INT(TRUE, DLEVEL_STABLE); } @@ -413,16 +414,22 @@ */ temp = key; while (w && temp && !ret) { + + /* + * Find a widget with theme data. + */ + while (w && !w->theme) + w = w->parent; + if (w && w->theme) ret = ecore_hash_get(w->theme, temp); if (ret) { - if (ret != NOMATCH) { + if (ret != NOMATCH) ret = strdup(ret); - } - break; } + temp++; temp = strchr(temp, '/'); if (!temp && w && w->parent) { @@ -438,8 +445,11 @@ temp = key; while (temp && !ret) { ret = ecore_hash_get(def_theme_data, temp); - if (ret) + if (ret) { + if (ret != NOMATCH) + ret = strdup(ret); break; + } /* * Resort to looking in the edje. ------------------------------------------------------- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies from IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs