diff --git a/src/bin/e_box.c b/src/bin/e_box.c index 3b1604744..e1c8791d3 100644 --- a/src/bin/e_box.c +++ b/src/bin/e_box.c @@ -649,18 +649,24 @@ static void _e_box_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new("e_box", - _e_box_smart_add, - _e_box_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_box_smart_move, - _e_box_smart_resize, - _e_box_smart_show, - _e_box_smart_hide, - _e_box_smart_color_set, - _e_box_smart_clip_set, - _e_box_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + "e_box", + EVAS_SMART_CLASS_VERSION, + _e_box_smart_add, + _e_box_smart_del, + _e_box_smart_move, + _e_box_smart_resize, + _e_box_smart_show, + _e_box_smart_hide, + _e_box_smart_color_set, + _e_box_smart_clip_set, + _e_box_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } static void diff --git a/src/bin/e_editable.c b/src/bin/e_editable.c index 6731043f5..7c2921ccc 100644 --- a/src/bin/e_editable.c +++ b/src/bin/e_editable.c @@ -74,18 +74,22 @@ e_editable_add(Evas *evas) { if (!_e_editable_smart) { - _e_editable_smart = evas_smart_new("e_editable", - _e_editable_smart_add, /* add */ - _e_editable_smart_del, /* del */ - NULL, NULL, NULL, NULL, NULL, /* stacking */ - _e_editable_smart_move, /* move */ - _e_editable_smart_resize, /* resize */ - _e_editable_smart_show, /* show */ - _e_editable_smart_hide, /* hide */ - _e_editable_color_set, /* color_set */ - _e_editable_clip_set, /* clip_set */ - _e_editable_clip_unset, /* clip_unset */ - NULL); /* data*/ + static const Evas_Smart_Class sc = + { + "e_editable", + EVAS_SMART_CLASS_VERSION, + _e_editable_smart_add, + _e_editable_smart_del, + _e_editable_smart_move, + _e_editable_smart_resize, + _e_editable_smart_show, + _e_editable_smart_hide, + _e_editable_color_set, + _e_editable_clip_set, + _e_editable_clip_unset, + NULL + }; + _e_editable_smart = evas_smart_class_new(&sc); _e_editable_smart_use = 0; } diff --git a/src/bin/e_entry.c b/src/bin/e_entry.c index 78270298f..9f6d62e80 100644 --- a/src/bin/e_entry.c +++ b/src/bin/e_entry.c @@ -70,18 +70,22 @@ e_entry_add(Evas *evas) { if (!_e_entry_smart) { - _e_entry_smart = evas_smart_new("e_entry", - _e_entry_smart_add, /* add */ - _e_entry_smart_del, /* del */ - NULL, NULL, NULL, NULL, NULL, /* stacking */ - _e_entry_smart_move, /* move */ - _e_entry_smart_resize, /* resize */ - _e_entry_smart_show, /* show */ - _e_entry_smart_hide, /* hide */ - _e_entry_color_set, /* color_set */ - _e_entry_clip_set, /* clip_set */ - _e_entry_clip_unset, /* clip_unset */ - NULL); /* data*/ + static const Evas_Smart_Class sc = + { + "e_entry", + EVAS_SMART_CLASS_VERSION, + _e_entry_smart_add, + _e_entry_smart_del, + _e_entry_smart_move, + _e_entry_smart_resize, + _e_entry_smart_show, + _e_entry_smart_hide, + _e_entry_color_set, + _e_entry_clip_set, + _e_entry_clip_unset, + NULL + }; + _e_entry_smart = evas_smart_class_new(&sc); _e_entry_smart_use = 0; } diff --git a/src/bin/e_flowlayout.c b/src/bin/e_flowlayout.c index 83e6258c4..d7a27db7d 100644 --- a/src/bin/e_flowlayout.c +++ b/src/bin/e_flowlayout.c @@ -822,18 +822,23 @@ static void _e_flowlayout_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new("e_flowlayout", - _e_flowlayout_smart_add, - _e_flowlayout_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_flowlayout_smart_move, - _e_flowlayout_smart_resize, - _e_flowlayout_smart_show, - _e_flowlayout_smart_hide, - _e_flowlayout_smart_color_set, - _e_flowlayout_smart_clip_set, - _e_flowlayout_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + "e_flowlayout", + _e_flowlayout_smart_add, + _e_flowlayout_smart_del, + _e_flowlayout_smart_move, + _e_flowlayout_smart_resize, + _e_flowlayout_smart_show, + _e_flowlayout_smart_hide, + _e_flowlayout_smart_color_set, + _e_flowlayout_smart_clip_set, + _e_flowlayout_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } static void diff --git a/src/bin/e_fm.c b/src/bin/e_fm.c index 0751e3648..1a6a47c7f 100644 --- a/src/bin/e_fm.c +++ b/src/bin/e_fm.c @@ -369,18 +369,24 @@ e_fm2_init(void) ecore_file_mkpath(path); _e_fm2_meta_path = strdup(path); - _e_fm2_smart = evas_smart_new("e_fm", - _e_fm2_smart_add, /* add */ - _e_fm2_smart_del, /* del */ - NULL, NULL, NULL, NULL, NULL, - _e_fm2_smart_move, /* move */ - _e_fm2_smart_resize, /* resize */ - _e_fm2_smart_show,/* show */ - _e_fm2_smart_hide,/* hide */ - _e_fm2_smart_color_set, /* color_set */ - _e_fm2_smart_clip_set, /* clip_set */ - _e_fm2_smart_clip_unset, /* clip_unset */ - NULL); /* data*/ + { + static const Evas_Smart_Class sc = + { + "e_fm", + EVAS_SMART_CLASS_VERSION, + _e_fm2_smart_add, /* add */ + _e_fm2_smart_del, /* del */ + _e_fm2_smart_move, /* move */ + _e_fm2_smart_resize, /* resize */ + _e_fm2_smart_show,/* show */ + _e_fm2_smart_hide,/* hide */ + _e_fm2_smart_color_set, /* color_set */ + _e_fm2_smart_clip_set, /* clip_set */ + _e_fm2_smart_clip_unset, /* clip_unset */ + NULL + }; + _e_fm2_smart = evas_smart_class_new(&sc); + } // _e_fm2_client_spawn(); e_fm2_custom_file_init(); efreet_mime_init(); diff --git a/src/bin/e_gadcon.c b/src/bin/e_gadcon.c index 72ca41ed2..dbd656feb 100644 --- a/src/bin/e_gadcon.c +++ b/src/bin/e_gadcon.c @@ -2924,18 +2924,24 @@ static void _e_gadcon_layout_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new("e_gadcon_layout", - _e_gadcon_layout_smart_add, - _e_gadcon_layout_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_gadcon_layout_smart_move, - _e_gadcon_layout_smart_resize, - _e_gadcon_layout_smart_show, - _e_gadcon_layout_smart_hide, - _e_gadcon_layout_smart_color_set, - _e_gadcon_layout_smart_clip_set, - _e_gadcon_layout_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + "e_gadcon_layout", + EVAS_SMART_CLASS_VERSION, + _e_gadcon_layout_smart_add, + _e_gadcon_layout_smart_del, + _e_gadcon_layout_smart_move, + _e_gadcon_layout_smart_resize, + _e_gadcon_layout_smart_show, + _e_gadcon_layout_smart_hide, + _e_gadcon_layout_smart_color_set, + _e_gadcon_layout_smart_clip_set, + _e_gadcon_layout_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } static void diff --git a/src/bin/e_icon.c b/src/bin/e_icon.c index fdd2fad4f..8a7610a07 100644 --- a/src/bin/e_icon.c +++ b/src/bin/e_icon.c @@ -272,18 +272,24 @@ static void _e_icon_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new("e_icon", - _e_icon_smart_add, - _e_icon_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_icon_smart_move, - _e_icon_smart_resize, - _e_icon_smart_show, - _e_icon_smart_hide, - _e_icon_smart_color_set, - _e_icon_smart_clip_set, - _e_icon_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + "e_icon", + EVAS_SMART_CLASS_VERSION, + _e_icon_smart_add, + _e_icon_smart_del, + _e_icon_smart_move, + _e_icon_smart_resize, + _e_icon_smart_show, + _e_icon_smart_hide, + _e_icon_smart_color_set, + _e_icon_smart_clip_set, + _e_icon_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } static void diff --git a/src/bin/e_ilist.c b/src/bin/e_ilist.c index ebeaece11..8dd6f7ed8 100644 --- a/src/bin/e_ilist.c +++ b/src/bin/e_ilist.c @@ -712,11 +712,24 @@ static void _e_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new(SMART_NAME, _e_smart_add, _e_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_smart_move, _e_smart_resize, _e_smart_show, - _e_smart_hide, _e_smart_color_set, - _e_smart_clip_set, _e_smart_clip_unset, NULL); + { + static const Evas_Smart_Class sc = + { + SMART_NAME, + EVAS_SMART_CLASS_VERSION, + _e_smart_add, + _e_smart_del, + _e_smart_move, + _e_smart_resize, + _e_smart_show, + _e_smart_hide, + _e_smart_color_set, + _e_smart_clip_set, + _e_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } static void diff --git a/src/bin/e_int_config_modules.c b/src/bin/e_int_config_modules.c index 5371600b5..3d9061b34 100644 --- a/src/bin/e_int_config_modules.c +++ b/src/bin/e_int_config_modules.c @@ -572,7 +572,14 @@ _cb_unload(void *data, void *data2) if (!item->selected) continue; lbl = e_widget_ilist_nth_label_get(cfdata->o_loaded, idx); mod = _get_module(cfdata, lbl); - if ((mod) && (mod->enabled)) e_module_disable(mod); + if ((mod) && (mod->enabled)) + { + e_module_disable(mod); +// FIXME: we need to UNLOAD modules by deleting their objects too! right now +// this is done next restart +// cfdata->modules = evas_list_remove(cfdata->modules, mod); +// e_object_del(E_OBJECT(mod)); + } } if (l) evas_list_free(l); } diff --git a/src/bin/e_layout.c b/src/bin/e_layout.c index f01d7ad1c..e0a60faaa 100644 --- a/src/bin/e_layout.c +++ b/src/bin/e_layout.c @@ -350,18 +350,24 @@ static void _e_layout_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new("e_layout", - _e_layout_smart_add, - _e_layout_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_layout_smart_move, - _e_layout_smart_resize, - _e_layout_smart_show, - _e_layout_smart_hide, - _e_layout_smart_color_set, - _e_layout_smart_clip_set, - _e_layout_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + "e_layout", + EVAS_SMART_CLASS_VERSION, + _e_layout_smart_add, + _e_layout_smart_del, + _e_layout_smart_move, + _e_layout_smart_resize, + _e_layout_smart_show, + _e_layout_smart_hide, + _e_layout_smart_color_set, + _e_layout_smart_clip_set, + _e_layout_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } static void diff --git a/src/bin/e_livethumb.c b/src/bin/e_livethumb.c index 774503d03..33f1bec1f 100644 --- a/src/bin/e_livethumb.c +++ b/src/bin/e_livethumb.c @@ -196,17 +196,23 @@ static void _e_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new(SMART_NAME, - _e_smart_add, - _e_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_smart_move, - _e_smart_resize, - _e_smart_show, - _e_smart_hide, - _e_smart_color_set, - _e_smart_clip_set, - _e_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + SMART_NAME, + EVAS_SMART_CLASS_VERSION, + _e_smart_add, + _e_smart_del, + _e_smart_move, + _e_smart_resize, + _e_smart_show, + _e_smart_hide, + _e_smart_color_set, + _e_smart_clip_set, + _e_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } diff --git a/src/bin/e_module.c b/src/bin/e_module.c index b53b605e8..3e01e7147 100644 --- a/src/bin/e_module.c +++ b/src/bin/e_module.c @@ -73,11 +73,11 @@ e_module_all_load(void) evas_list_append(_e_modules_delayed, evas_stringshare_add(em->name)); } - else + else if (em->enabled) { m = NULL; if (em->name) m = e_module_new(em->name); - if ((m) && (em->enabled)) e_module_enable(m); + if (m) e_module_enable(m); } } } diff --git a/src/bin/e_pan.c b/src/bin/e_pan.c index 6f348cc52..6b9e13ff0 100644 --- a/src/bin/e_pan.c +++ b/src/bin/e_pan.c @@ -249,17 +249,23 @@ static void _e_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new(SMART_NAME, - _e_smart_add, - _e_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_smart_move, - _e_smart_resize, - _e_smart_show, - _e_smart_hide, - _e_smart_color_set, - _e_smart_clip_set, - _e_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + SMART_NAME, + EVAS_SMART_CLASS_VERSION, + _e_smart_add, + _e_smart_del, + _e_smart_move, + _e_smart_resize, + _e_smart_show, + _e_smart_hide, + _e_smart_color_set, + _e_smart_clip_set, + _e_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } diff --git a/src/bin/e_scrollframe.c b/src/bin/e_scrollframe.c index 3ed753380..96df0ee66 100644 --- a/src/bin/e_scrollframe.c +++ b/src/bin/e_scrollframe.c @@ -783,17 +783,23 @@ static void _e_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new(SMART_NAME, - _e_smart_add, - _e_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_smart_move, - _e_smart_resize, - _e_smart_show, - _e_smart_hide, - _e_smart_color_set, - _e_smart_clip_set, - _e_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + SMART_NAME, + EVAS_SMART_CLASS_VERSION, + _e_smart_add, + _e_smart_del, + _e_smart_move, + _e_smart_resize, + _e_smart_show, + _e_smart_hide, + _e_smart_color_set, + _e_smart_clip_set, + _e_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } diff --git a/src/bin/e_slider.c b/src/bin/e_slider.c index 71e36f170..1c2a91a7d 100644 --- a/src/bin/e_slider.c +++ b/src/bin/e_slider.c @@ -533,17 +533,23 @@ static void _e_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new(SMART_NAME, - _e_smart_add, - _e_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_smart_move, - _e_smart_resize, - _e_smart_show, - _e_smart_hide, - _e_smart_color_set, - _e_smart_clip_set, - _e_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + SMART_NAME, + EVAS_SMART_CLASS_VERSION, + _e_smart_add, + _e_smart_del, + _e_smart_move, + _e_smart_resize, + _e_smart_show, + _e_smart_hide, + _e_smart_color_set, + _e_smart_clip_set, + _e_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } diff --git a/src/bin/e_spectrum.c b/src/bin/e_spectrum.c index 31ad42249..b95935895 100644 --- a/src/bin/e_spectrum.c +++ b/src/bin/e_spectrum.c @@ -152,19 +152,25 @@ _e_spectrum_smart_clip_unset(Evas_Object *o) static void _e_spectrum_smart_init() { - if ( _e_spectrum_smart ) return; - _e_spectrum_smart = evas_smart_new("e_spectrum", - _e_spectrum_smart_add, - _e_spectrum_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_spectrum_smart_move, - _e_spectrum_smart_resize, - _e_spectrum_smart_show, - _e_spectrum_smart_hide, - _e_spectrum_smart_color_set, - _e_spectrum_smart_clip_set, - _e_spectrum_smart_clip_unset, - NULL); + if (_e_spectrum_smart) return; + { + static const Evas_Smart_Class sc = + { + "e_spectrum", + EVAS_SMART_CLASS_VERSION, + _e_spectrum_smart_add, + _e_spectrum_smart_del, + _e_spectrum_smart_move, + _e_spectrum_smart_resize, + _e_spectrum_smart_show, + _e_spectrum_smart_hide, + _e_spectrum_smart_color_set, + _e_spectrum_smart_clip_set, + _e_spectrum_smart_clip_unset, + NULL + }; + _e_spectrum_smart = evas_smart_class_new(&sc); + } } void diff --git a/src/bin/e_table.c b/src/bin/e_table.c index c02d94eec..26619951d 100644 --- a/src/bin/e_table.c +++ b/src/bin/e_table.c @@ -825,18 +825,24 @@ static void _e_table_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new("e_table", - _e_table_smart_add, - _e_table_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_table_smart_move, - _e_table_smart_resize, - _e_table_smart_show, - _e_table_smart_hide, - _e_table_smart_color_set, - _e_table_smart_clip_set, - _e_table_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + "e_table", + EVAS_SMART_CLASS_VERSION, + _e_table_smart_add, + _e_table_smart_del, + _e_table_smart_move, + _e_table_smart_resize, + _e_table_smart_show, + _e_table_smart_hide, + _e_table_smart_color_set, + _e_table_smart_clip_set, + _e_table_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } static void diff --git a/src/bin/e_tlist.c b/src/bin/e_tlist.c index 8a25807ee..eeb17ea5d 100644 --- a/src/bin/e_tlist.c +++ b/src/bin/e_tlist.c @@ -549,16 +549,23 @@ _e_smart_clip_unset(Evas_Object * obj) static void _e_smart_init(void) { - if (_e_smart) - return; - _e_smart = evas_smart_new(SMART_NAME, - _e_smart_add, - _e_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_smart_move, - _e_smart_resize, - _e_smart_show, - _e_smart_hide, - _e_smart_color_set, - _e_smart_clip_set, _e_smart_clip_unset, NULL); + if (_e_smart) return; + { + static const Evas_Smart_Class sc = + { + SMART_NAME, + EVAS_SMART_CLASS_VERSION, + _e_smart_add, + _e_smart_del, + _e_smart_move, + _e_smart_resize, + _e_smart_show, + _e_smart_hide, + _e_smart_color_set, + _e_smart_clip_set, + _e_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } } diff --git a/src/bin/e_widget.c b/src/bin/e_widget.c index 82a77c2da..3bfcb6801 100644 --- a/src/bin/e_widget.c +++ b/src/bin/e_widget.c @@ -563,16 +563,22 @@ static void _e_smart_init(void) { if (_e_smart) return; - _e_smart = evas_smart_new(SMART_NAME, - _e_smart_add, - _e_smart_del, - NULL, NULL, NULL, NULL, NULL, - _e_smart_move, - _e_smart_resize, - _e_smart_show, - _e_smart_hide, - _e_smart_color_set, - _e_smart_clip_set, - _e_smart_clip_unset, - NULL); + { + static const Evas_Smart_Class sc = + { + SMART_NAME, + EVAS_SMART_CLASS_VERSION, + _e_smart_add, + _e_smart_del, + _e_smart_move, + _e_smart_resize, + _e_smart_show, + _e_smart_hide, + _e_smart_color_set, + _e_smart_clip_set, + _e_smart_clip_unset, + NULL + }; + _e_smart = evas_smart_class_new(&sc); + } }