Enlightenment CVS committal Author : ningerso Project : e17 Module : libs/ewl
Dir : e17/libs/ewl/src/lib Modified Files: ewl_widget.c Log Message: Outline stubs for widget dragging support. =================================================================== RCS file: /cvs/e/e17/libs/ewl/src/lib/ewl_widget.c,v retrieving revision 1.105 retrieving revision 1.106 diff -u -3 -r1.105 -r1.106 --- ewl_widget.c 6 Nov 2006 16:12:20 -0000 1.105 +++ ewl_widget.c 15 Nov 2006 16:19:16 -0000 1.106 @@ -2887,6 +2887,11 @@ if (DISABLED(w)) DRETURN(DLEVEL_STABLE); + if (ewl_object_state_has(EWL_OBJECT(w), EWL_FLAG_STATE_DND)) { + ewl_object_state_remove(EWL_OBJECT(w), EWL_FLAG_STATE_DND); + /* FIXME: Stop DND here */ + } + snprintf(state, 14, "mouse,up,%i", e->button); ewl_widget_state_set(w, state, EWL_STATE_TRANSIENT); @@ -2923,11 +2928,23 @@ ewl_widget_cb_mouse_move(Ewl_Widget *w, void *ev_data __UNUSED__, void *user_data __UNUSED__) { + Ewl_Object *o; + DENTER_FUNCTION(DLEVEL_STABLE); DCHECK_PARAM_PTR("w", w); DCHECK_TYPE("w", w, EWL_WIDGET_TYPE); + o = EWL_OBJECT(w); + ewl_widget_state_set(w, "mouse,move", EWL_STATE_TRANSIENT); + if (ewl_object_state_has(o, EWL_FLAG_STATE_PRESSED) && + ewl_object_flags_has(o, EWL_FLAG_PROPERTY_DND_SOURCE, + EWL_FLAGS_PROPERTY_MASK)) { + if (!ewl_object_state_has(o, EWL_FLAG_STATE_DND)) { + ewl_object_state_add(o, EWL_FLAG_STATE_DND); + /* FIXME: Start DND here. */ + } + } DLEAVE_FUNCTION(DLEVEL_STABLE); } ------------------------------------------------------------------------- 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