Enlightenment CVS committal

Author  : dj2
Project : e17
Module  : libs/ewl

Dir     : e17/libs/ewl/src/lib


Modified Files:
        ewl_callback.c ewl_colordialog.c ewl_colorpicker.c ewl_embed.c 
        ewl_iconbox.c ewl_spectrum.c ewl_text.c ewl_text.h 


Log Message:
- minor todo changes
- fix warnings

===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_callback.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -3 -r1.7 -r1.8
--- ewl_callback.c      23 Oct 2005 16:33:11 -0000      1.7
+++ ewl_callback.c      2 Nov 2005 18:23:21 -0000       1.8
@@ -153,7 +153,7 @@
        }
 
        /* not the last position */
-       if (pos != (EWL_CALLBACK_LEN(w, t) - 1))
+       if ((int)pos != (EWL_CALLBACK_LEN(w, t) - 1))
        {
                memmove(w->callbacks[t].list + pos, 
                        w->callbacks[t].list + (pos + 1), 
@@ -213,7 +213,7 @@
        {
                /* only have to move if we aren't at the end (of the
                 * original lenth already */
-               if (pos != (w->callbacks[t].len - 1))
+               if ((int)pos != (w->callbacks[t].len - 1))
                {
                        memmove(w->callbacks[t].list + (pos + 1), 
                                w->callbacks[t].list + pos, 
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_colordialog.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -3 -r1.17 -r1.18
--- ewl_colordialog.c   2 Nov 2005 17:51:44 -0000       1.17
+++ ewl_colordialog.c   2 Nov 2005 18:23:21 -0000       1.18
@@ -276,9 +276,12 @@
 }
 
 void
-ewl_colordialog_cb_delete_window(Ewl_Widget *w, void *ev, void *data)
+ewl_colordialog_cb_delete_window(Ewl_Widget *w, void *ev __UNUSED__, 
+                                       void *data __UNUSED__)
 {
        DENTER_FUNCTION(DLEVEL_STABLE);
+       DCHECK_PARAM_PTR("w", w);
+       DCHECK_TYPE("w", w, "widget");
 
        ewl_colordialog_respond(EWL_COLORDIALOG(w), EWL_STOCK_CANCEL);
 
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_colorpicker.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -3 -r1.12 -r1.13
--- ewl_colorpicker.c   2 Nov 2005 17:51:44 -0000       1.12
+++ ewl_colorpicker.c   2 Nov 2005 18:23:21 -0000       1.13
@@ -548,7 +548,8 @@
 }
 
 void
-ewl_colorpicker_cb_square_change(Ewl_Widget *w, void *ev, void *data)
+ewl_colorpicker_cb_square_change(Ewl_Widget *w, void *ev __UNUSED__,
+                                                               void *data)
 {
        Ewl_Colorpicker *cp;
        unsigned int r, g, b;
@@ -568,7 +569,8 @@
 }
 
 void
-ewl_colorpicker_cb_vertical_change(Ewl_Widget *w, void *ev, void *data)
+ewl_colorpicker_cb_vertical_change(Ewl_Widget *w, void *ev __UNUSED__,
+                                                               void *data)
 {
        Ewl_Colorpicker *cp;
        unsigned int r, g, b;
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_embed.c,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -3 -r1.18 -r1.19
--- ewl_embed.c 1 Nov 2005 05:54:50 -0000       1.18
+++ ewl_embed.c 2 Nov 2005 18:23:21 -0000       1.19
@@ -959,7 +959,7 @@
 
        /* if we inserted before or at our currently focused item then we
         * need to advance our current item to the correct spot */
-       if (current_idx <= idx) current_idx ++;
+       if (current_idx <= (int)idx) current_idx ++;
        ecore_dlist_goto_index(e->tab_order, current_idx);
 
        DLEAVE_FUNCTION(DLEVEL_STABLE);
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_iconbox.c,v
retrieving revision 1.61
retrieving revision 1.62
diff -u -3 -r1.61 -r1.62
--- ewl_iconbox.c       30 Oct 2005 01:35:15 -0000      1.61
+++ ewl_iconbox.c       2 Nov 2005 18:23:21 -0000       1.62
@@ -420,7 +420,7 @@
                ewl_text_text_set(EWL_TEXT(icon->w_label), text);
 
                wrap = 10;
-               while (wrap < strlen(text)) {
+               while (wrap < (int)strlen(text)) {
                        ewl_text_cursor_position_set(EWL_TEXT(icon->w_label), 
wrap);
                        ewl_text_text_insert(EWL_TEXT(icon->w_label), "\n", 
wrap);
 
@@ -788,6 +788,8 @@
 {
        Ewl_IconBox* ib = EWL_ICONBOX(w);
 
+       return;
+       ib = NULL;
 }
 
 void ewl_iconbox_icon_destroy_cb(Ewl_Widget *w, void *ev_data __UNUSED__,
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_spectrum.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -3 -r1.14 -r1.15
--- ewl_spectrum.c      2 Nov 2005 17:51:44 -0000       1.14
+++ ewl_spectrum.c      2 Nov 2005 18:23:21 -0000       1.15
@@ -23,8 +23,8 @@
 static void ewl_spectrum_color_coord_map(Ewl_Spectrum *sp, int x, int y, 
                                        int w, int h, unsigned int *r, 
                                        unsigned int *g, unsigned int *b);
-static void ewl_spectrum_color_coord_map_vertical(Ewl_Spectrum *sp, int x, 
-                               int y, int img_w, int img_h, unsigned int *r, 
+static void ewl_spectrum_color_coord_map_vertical(Ewl_Spectrum *sp, int y, 
+                               int img_h, unsigned int *r, 
                                unsigned int *g, unsigned int *b);
 static void ewl_spectrum_color_coord_map_square(Ewl_Spectrum *sp, int x, 
                                int y, int img_w, int img_h, unsigned int *r, 
@@ -272,7 +272,8 @@
 }
 
 void
-ewl_spectrum_cb_configure(Ewl_Widget *w, void *ev, void *data)
+ewl_spectrum_cb_configure(Ewl_Widget *w, void *ev __UNUSED__,
+                                       void *data __UNUSED__)
 {
        Ewl_Spectrum *sp;
 
@@ -315,9 +316,9 @@
        x = e->x - CURRENT_X(w);
        y = e->y - CURRENT_Y(w);
 
-       if (x > (CURRENT_X(w) + CURRENT_W(w)))
+       if (x > (unsigned int)(CURRENT_X(w) + CURRENT_W(w)))
                x = (CURRENT_W(w) - CURRENT_X(w));
-       if (y > (CURRENT_Y(w) + CURRENT_H(w)))
+       if (y > (unsigned int)(CURRENT_Y(w) + CURRENT_H(w)))
                y = (CURRENT_H(w) - CURRENT_Y(w));
 
        ewl_spectrum_mouse_process(sp, x, y);
@@ -352,7 +353,8 @@
 }
 
 void
-ewl_spectrum_cb_mouse_up(Ewl_Widget *w, void *ev, void *data)
+ewl_spectrum_cb_mouse_up(Ewl_Widget *w __UNUSED__, void *ev __UNUSED__,
+                                                       void *data)
 {
        Ewl_Spectrum *sp;
 
@@ -360,7 +362,6 @@
        DCHECK_PARAM_PTR("data", data);
 
        sp = data;
-
        ewl_callback_del(sp->canvas, EWL_CALLBACK_MOUSE_MOVE,
                        ewl_spectrum_cb_mouse_move);
 
@@ -429,11 +430,11 @@
                unsigned int delta;
 
                delta = max - min;
-               if (sp->rgb.r == max)
+               if ((unsigned int)sp->rgb.r == max)
                        sp->hsv.h = (sp->rgb.g - sp->rgb.b) / (float)delta;
-               else if (sp->rgb.g == max)
+               else if ((unsigned int)sp->rgb.g == max)
                        sp->hsv.h = 2.0 + ((sp->rgb.b - sp->rgb.r) / 
(float)delta);
-               else if (sp->rgb.b == max)
+               else if ((unsigned int)sp->rgb.b == max)
                        sp->hsv.h = 4.0 + ((sp->rgb.r - sp->rgb.g) / 
(float)delta);
 
                sp->hsv.h *= 60.0;
@@ -585,8 +586,7 @@
        DCHECK_PARAM_PTR("sp", sp);
 
        if (sp->type == EWL_SPECTRUM_TYPE_VERTICAL)
-               ewl_spectrum_color_coord_map_vertical(sp, x, y, img_w, 
-                                                       img_h, r, g, b);
+               ewl_spectrum_color_coord_map_vertical(sp, y, img_h, r, g, b);
        else
                ewl_spectrum_color_coord_map_square(sp, x, y, img_w, 
                                                        img_h, r, g, b);
@@ -595,7 +595,7 @@
 }
 
 static void
-ewl_spectrum_color_coord_map_vertical(Ewl_Spectrum *sp, int x, int y, int 
img_w, int img_h,
+ewl_spectrum_color_coord_map_vertical(Ewl_Spectrum *sp, int y, int img_h,
                                        unsigned int *r, unsigned int *g, 
unsigned int *b)
 {
        unsigned int r_tmp, g_tmp, b_tmp;
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_text.c,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -3 -r1.40 -r1.41
--- ewl_text.c  2 Nov 2005 17:40:40 -0000       1.40
+++ ewl_text.c  2 Nov 2005 18:23:21 -0000       1.41
@@ -149,7 +149,7 @@
  * @param t: The Ewl_Text to get the length from
  * @return Returns the length of the text in the widget @a t
  */
-int
+unsigned int
 ewl_text_length_get(Ewl_Text *t)
 {
        DENTER_FUNCTION(DLEVEL_STABLE);
@@ -3890,7 +3890,7 @@
        else /* has to be in the tree somewhere */
        {
                Ewl_Text_BTree *child;
-               int sum = 0;
+               unsigned int sum = 0;
 
                ecore_list_goto_first(tree->children);
                while ((child = ecore_list_next(tree->children)))
@@ -3916,7 +3916,7 @@
                                unsigned int len)
 {
        Ewl_Text_BTree *child;
-       int sum = 0;
+       unsigned int sum = 0;
 
        DENTER_FUNCTION(DLEVEL_STABLE);
        DCHECK_PARAM_PTR("tree", tree);
@@ -4000,7 +4000,6 @@
        ecore_list_goto_first(tree->children);
        while ((child = ecore_list_next(tree->children)))
        {
-
                if ((sum <= idx) && ((sum + child->length) > idx))
                {
                        int new_len;
@@ -4025,7 +4024,7 @@
 ewl_text_btree_text_delete(Ewl_Text_BTree *tree, unsigned int idx, unsigned 
int len)
 {
        Ewl_Text_BTree *child;
-       int sum = 0;
+       unsigned int sum = 0;
 
        DENTER_FUNCTION(DLEVEL_STABLE);
        DCHECK_PARAM_PTR("tree", tree);
@@ -4053,7 +4052,7 @@
 
                if ((sum <= idx) && ((sum + child->length) > idx))
                {
-                       int del_length;
+                       unsigned int del_length;
                        int new_len;
 
                        del_length = (child->length - (idx - sum));
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/lib/ewl_text.h,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -3 -r1.16 -r1.17
--- ewl_text.h  27 Oct 2005 03:14:07 -0000      1.16
+++ ewl_text.h  2 Nov 2005 18:23:21 -0000       1.17
@@ -66,7 +66,7 @@
 Ewl_Widget     *ewl_text_new(void);
 int             ewl_text_init(Ewl_Text *t);
 
-int             ewl_text_length_get(Ewl_Text *t);
+unsigned int    ewl_text_length_get(Ewl_Text *t);
 
 void            ewl_text_index_geometry_map(Ewl_Text *t, unsigned int idx,
                                        int *x, int *y, int *w, int *h);




-------------------------------------------------------
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

Reply via email to