Enlightenment CVS committal Author : dj2 Project : e17 Module : libs/ewl
Dir : e17/libs/ewl/src/lib Modified Files: ewl_entry.c ewl_entry.h Log Message: - if an entry is disabled set it uneditable - if an entry is enabled set it editable =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_entry.c,v retrieving revision 1.48 retrieving revision 1.49 diff -u -3 -r1.48 -r1.49 --- ewl_entry.c 17 Feb 2006 06:43:33 -0000 1.48 +++ ewl_entry.c 19 Feb 2006 16:13:53 -0000 1.49 @@ -83,6 +83,10 @@ ewl_entry_cb_mouse_down, NULL); ewl_callback_append(w, EWL_CALLBACK_MOUSE_UP, ewl_entry_cb_mouse_up, NULL); + ewl_callback_append(w, EWL_CALLBACK_WIDGET_DISABLE, + ewl_entry_cb_disable, NULL); + ewl_callback_append(w, EWL_CALLBACK_WIDGET_ENABLE, + ewl_entry_cb_enable, NULL); DRETURN_INT(TRUE, DLEVEL_STABLE); } @@ -391,6 +395,30 @@ } void +ewl_entry_cb_disable(Ewl_Widget *w, void *ev __UNUSED__, void *data __UNUSED__) +{ + DENTER_FUNCTION(DLEVEL_STABLE); + DCHECK_PARAM_PTR("w", w); + DCHECK_TYPE("w", w, EWL_WIDGET_TYPE); + + ewl_entry_editable_set(EWL_ENTRY(w), FALSE); + + DLEAVE_FUNCTION(DLEVEL_STABLE); +} + +void +ewl_entry_cb_enable(Ewl_Widget *w, void *ev __UNUSED__, void *data __UNUSED__) +{ + DENTER_FUNCTION(DLEVEL_STABLE); + DCHECK_PARAM_PTR("w", w); + DCHECK_TYPE("w", w, EWL_WIDGET_TYPE); + + ewl_entry_editable_set(EWL_ENTRY(w), TRUE); + + DLEAVE_FUNCTION(DLEVEL_STABLE); +} + +void ewl_entry_cb_mouse_move(Ewl_Widget *w, void *ev __UNUSED__, void *data __UNUSED__) { =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_entry.h,v retrieving revision 1.17 retrieving revision 1.18 diff -u -3 -r1.17 -r1.18 --- ewl_entry.h 16 Feb 2006 17:06:43 -0000 1.17 +++ ewl_entry.h 19 Feb 2006 16:13:53 -0000 1.18 @@ -56,6 +56,8 @@ void ewl_entry_cb_mouse_move(Ewl_Widget *w, void *ev, void *data); void ewl_entry_cb_focus_in(Ewl_Widget *w, void *ev, void *data); void ewl_entry_cb_focus_out(Ewl_Widget *w, void *ev, void *data); +void ewl_entry_cb_disable(Ewl_Widget *w, void *ev, void *data); +void ewl_entry_cb_enable(Ewl_Widget *w, void *ev, void *data); void ewl_entry_cursor_move_left(Ewl_Entry *e); void ewl_entry_cursor_move_right(Ewl_Entry *e); ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642 _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs