Enlightenment CVS committal Author : dj2 Project : e17 Module : libs/ewl
Dir : e17/libs/ewl/src/lib Modified Files: Ewl.h.in Makefile.am ewl_enums.h ewl_fileselector.c ewl_widget.h Added Files: ewl_attach.c ewl_attach.h Removed Files: ewl_tooltip.c ewl_tooltip.h Log Message: - getting rid of ewl_tooltip and making tooltips an attachment to widgets. this can also be used in the future to handle cursors for widgets. - this is API breakage. =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/Ewl.h.in,v retrieving revision 1.18 retrieving revision 1.19 diff -u -3 -r1.18 -r1.19 --- Ewl.h.in 7 Sep 2005 02:58:49 -0000 1.18 +++ Ewl.h.in 25 Sep 2005 05:02:19 -0000 1.19 @@ -262,6 +262,9 @@ #include <ewl_object.h> #include <ewl_widget.h> + +#include <ewl_attach.h> + #include <ewl_container.h> #include <ewl_callback.h> @@ -324,7 +327,6 @@ #include <ewl_selectionbar.h> #include <ewl_selectionbook.h> #include <ewl_statusbar.h> -#include <ewl_tooltip.h> #include <ewl_tree.h> =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/Makefile.am,v retrieving revision 1.10 retrieving revision 1.11 diff -u -3 -r1.10 -r1.11 --- Makefile.am 5 Sep 2005 14:12:15 -0000 1.10 +++ Makefile.am 25 Sep 2005 05:02:19 -0000 1.11 @@ -11,6 +11,7 @@ EWLHEADERS = \ Ewl.h \ + ewl_attach.h \ ewl_border.h \ ewl_box.h \ ewl_label.h \ @@ -66,7 +67,6 @@ ewl_text.h \ ewl_table.h \ ewl_tree.h \ - ewl_tooltip.h \ ewl_theme.h \ ewl_widget.h \ ewl_window.h @@ -77,6 +77,7 @@ endif EWLSOURCES= \ + ewl_attach.c \ ewl_border.c \ ewl_box.c \ ewl_label.c \ @@ -130,7 +131,6 @@ ewl_text.c \ ewl_theme.c \ ewl_tree.c \ - ewl_tooltip.c \ ewl_widget.c \ ewl_window.c \ ewl_private.h \ =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_enums.h,v retrieving revision 1.7 retrieving revision 1.8 diff -u -3 -r1.7 -r1.8 --- ewl_enums.h 16 Sep 2005 19:00:24 -0000 1.7 +++ ewl_enums.h 25 Sep 2005 05:02:19 -0000 1.8 @@ -320,8 +320,19 @@ }; typedef enum Ewl_Text_Trigger_Type Ewl_Text_Trigger_Type; +enum Ewl_Attach_Type { + EWL_ATTACH_TYPE_TOOLTIP +}; +typedef enum Ewl_Attach_Type Ewl_Attach_Type; + +enum Ewl_Attach_Data_Type { + EWL_ATTACH_DATA_TYPE_TEXT, + EWL_ATTACH_DATA_TYPE_WIDGET +}; +typedef enum Ewl_Attach_Data_Type Ewl_Attach_Data_Type; + /** * @} - */ - + */ #endif /* __EWL_ENUMS_H__ */ + =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_fileselector.c,v retrieving revision 1.20 retrieving revision 1.21 diff -u -3 -r1.20 -r1.21 --- ewl_fileselector.c 5 Sep 2005 14:12:15 -0000 1.20 +++ ewl_fileselector.c 25 Sep 2005 05:02:19 -0000 1.21 @@ -576,15 +576,6 @@ IF_FREE(fs->dfilter); } -void -ewl_fileselector_tooltip_destroy_cb(Ewl_Widget *w __UNUSED__, - void *ev_data __UNUSED__, - void *user_data) -{ - if (user_data) - ewl_widget_destroy(EWL_WIDGET(user_data)); -} - void ewl_fileselector_select_file_cb(Ewl_Widget *w, void *ev_data __UNUSED__, void *data) { @@ -821,16 +812,11 @@ static void ewl_fileselector_tooltip_add(Ewl_Widget * w, Ewl_Fileselector_Data * d) { Ewl_Widget *parent_win; - Ewl_Widget *tooltip; char *str; char *name, *size, *perm; parent_win = EWL_WIDGET(ewl_embed_widget_find(w)); - tooltip = ewl_tooltip_new(w); - ewl_tooltip_delay_set(EWL_TOOLTIP(tooltip), 1.0); - ewl_container_child_append(EWL_CONTAINER(parent_win), tooltip); - name = d->name; size = ewl_fileselector_size_string_get(d->size); perm = ewl_fileselector_perm_string_get(d->mode); @@ -846,11 +832,7 @@ memcpy(str + strlen(name) + strlen(size) + 2, perm, strlen(perm)); str[strlen(name) + strlen(size) + strlen(perm) + 2] = '\0'; - ewl_tooltip_text_set(EWL_TOOLTIP(tooltip), str); - - /* destroy tooltip when the row is destroyed */ - ewl_callback_append(EWL_WIDGET(w), EWL_CALLBACK_DESTROY, - ewl_fileselector_tooltip_destroy_cb, tooltip); + ewl_attach_tooltip_text_set(w, str); FREE(str); FREE(size); =================================================================== RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_widget.h,v retrieving revision 1.11 retrieving revision 1.12 diff -u -3 -r1.11 -r1.12 --- ewl_widget.h 16 Sep 2005 19:00:24 -0000 1.11 +++ ewl_widget.h 25 Sep 2005 05:02:19 -0000 1.12 @@ -14,6 +14,14 @@ * @{ */ +typedef struct Ewl_Attach_List Ewl_Attach_List; +struct Ewl_Attach_List +{ + void **list; + unsigned int direct:1; + unsigned int len:31; +}; + /** * Callback chain container a list and bitmask of chain properties. */ @@ -56,6 +64,7 @@ Ewl_Widget *parent; /**< The parent widget, actually a container */ Ewl_Callback_Chain callbacks[EWL_CALLBACK_MAX]; /**< Callback chain array */ + Ewl_Attach_List *attach; /**< List of attachments on the widget */ Evas_Object *fx_clip_box; /**< Clipping rectangle of widget */ ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs