fix bug where newly-added desktop gadgets wouldn't initiate edit mode correctly and would be undeletable
SVN revision: 76906
This commit is contained in:
parent
21c3a90d88
commit
791ec69614
|
@ -98,7 +98,7 @@ _gcc_add(E_Config_Dialog_Data *cfdata, int type __UNUSED__, E_Event_Gadcon_Clien
|
|||
l = eina_list_data_find_list(cfdata->waiting, ev->gcc->gadcon);
|
||||
if (!l) return ECORE_CALLBACK_RENEW;
|
||||
if (ev->gcc->cf != eina_list_data_get(eina_list_last(ev->gcc->gadcon->cf->clients))) return ECORE_CALLBACK_RENEW;
|
||||
gadman_gadget_edit_start(ev->gcc);
|
||||
ev->gcc->gadcon->drag_gcc = ev->gcc;
|
||||
ev->gcc->cf->style = eina_stringshare_add(ev->gcc->client_class->default_style);
|
||||
ev->gcc->cf->geom.pos_x = DEFAULT_POS_X;
|
||||
ev->gcc->cf->geom.pos_y = DEFAULT_POS_Y;
|
||||
|
|
|
@ -394,12 +394,13 @@ gadman_gadget_edit_start(E_Gadcon_Client *gcc)
|
|||
Evas_Object *mover;
|
||||
int x, y, w, h;
|
||||
|
||||
gc = gcc->gadcon;
|
||||
if (gc->editing) return;
|
||||
gc->editing = 1;
|
||||
|
||||
/* this gets an unref in e_gadcon_drag_finished_cb() */
|
||||
e_object_ref(E_OBJECT(gcc));
|
||||
|
||||
gc = gcc->gadcon;
|
||||
gc->editing = 1;
|
||||
|
||||
/* Move/resize the correct mover */
|
||||
mover = _get_mover(gcc);
|
||||
if (!mover) return;
|
||||
|
@ -1506,8 +1507,8 @@ on_move(void *data, Evas_Object *o __UNUSED__, const char *em __UNUSED__, const
|
|||
int action = (int)(long)data;
|
||||
E_Gadcon *gc;
|
||||
|
||||
gc = eina_list_data_get(Man->gadcons[0]);
|
||||
|
||||
gc = eina_list_data_get(Man->gadcons[GADMAN_LAYER_BG]);
|
||||
if (!gc->drag_gcc) return;
|
||||
mover = _get_mover(gc->drag_gcc);
|
||||
|
||||
/* DRAG_START */
|
||||
|
|
Loading…
Reference in New Issue