Enlightenment CVS committal Author : englebass Project : e17 Module : apps/e
Dir : e17/apps/e/src/bin Modified Files: e_gadcon.c Log Message: Drag gadcons off the shelf in edit mode to remove them. =================================================================== RCS file: /cvs/e/e17/apps/e/src/bin/e_gadcon.c,v retrieving revision 1.56 retrieving revision 1.57 diff -u -3 -r1.56 -r1.57 --- e_gadcon.c 30 Dec 2006 17:54:26 -0000 1.56 +++ e_gadcon.c 30 Dec 2006 18:12:53 -0000 1.57 @@ -1623,7 +1623,6 @@ if (e_gadcon_layout_orientation_get(gcc->gadcon->o_container)) { // TODO: Configure this value -#if 0 if (abs((y + gcc->dy) - gcc->drag.y) > 10) { E_Drag *drag; @@ -1650,9 +1649,7 @@ e_util_evas_fake_mouse_up_later(gcc->gadcon->evas, 1); return; } - else -#endif - if (x > 0) + else if (x > 0) { if (gcc->state_info.state != E_LAYOUT_ITEM_STATE_POS_INC) gcc->state_info.resist = 0; @@ -1904,53 +1901,31 @@ { // TODO: Need to check if we drop on the same gadcon as the drag begins. // This should result in a reorder, not a remove. -#if 0 E_Gadcon_Client *gcc; E_Gadcon *gc; - Evas_List *l; - int ok; E_Config_Gadcon *cf_gc = NULL; E_Config_Gadcon_Client *cf_gcc; gcc = drag->data; gc = gcc->gadcon; - ok = 0; - for (l = e_config->gadcons; l; l = l->next) - { - cf_gc = l->data; - if ((!strcmp(cf_gc->name, gc->name)) && - (!strcmp(cf_gc->id, gc->id))) - { - ok = 1; - break; - } - } - if (ok) + cf_gc = e_gadcon_config_get(gc->name, gc->id); + if (cf_gc) { - for (l = cf_gc->clients; l; l = l->next) + cf_gcc = e_gadcon_client_config_get(gc, gcc->name, gcc->id); + if (cf_gcc) { - E_Config_Gadcon_Client *cf_gcc; - - cf_gcc = l->data; - if (!cf_gcc) continue; - if (!cf_gcc->name) continue; - if ((!strcmp(cf_gcc->name, gcc->name)) && (!strcmp(cf_gcc->id, gcc->id))) - { - if (cf_gcc->name) evas_stringshare_del(cf_gcc->name); - if (cf_gcc->id) evas_stringshare_del(cf_gcc->id); - if (cf_gcc->style) evas_stringshare_del(cf_gcc->style); - cf_gc->clients = evas_list_remove(cf_gc->clients, cf_gcc); - free(cf_gcc); - break; - } + if (cf_gcc->name) evas_stringshare_del(cf_gcc->name); + if (cf_gcc->id) evas_stringshare_del(cf_gcc->id); + if (cf_gcc->style) evas_stringshare_del(cf_gcc->style); + cf_gc->clients = evas_list_remove(cf_gc->clients, cf_gcc); + free(cf_gcc); } } + e_object_unref(E_OBJECT(drag->data)); e_gadcon_unpopulate(gc); e_gadcon_populate(gc); e_config_save_queue(); -#endif - e_object_unref(E_OBJECT(drag->data)); } /* a smart object JUST for gadcon */ ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs