colorselector: Remove unnecessary pointer redirection.
authorDaniel Juyung Seo <seojuyung2@gmail.com>
Fri, 16 Jan 2015 05:13:30 +0000 (14:13 +0900)
committerDaniel Juyung Seo <seojuyung2@gmail.com>
Wed, 21 Jan 2015 22:39:34 +0000 (07:39 +0900)
Elm_Colorselector_Data pointer is already there.

src/lib/elm_colorselector.c

index ca49b9304ad15c630feae6dfa2f0e98d438e0c85..4a296937ed76bdcc2781e0319b360915a63b97a1 100644 (file)
@@ -1170,13 +1170,11 @@ _item_sizing_eval(Elm_Color_Item_Data *item)
 
 /* fix size hints of color palette items, so that the box gets it */
 static void
-_palette_sizing_eval(Evas_Object *obj)
+_palette_sizing_eval(Elm_Colorselector_Data *sd)
 {
    Eina_List *elist;
    Elm_Object_Item *eo_item;
 
-   ELM_COLORSELECTOR_DATA_GET(obj, sd);
-
    EINA_LIST_FOREACH(sd->items, elist, eo_item)
      {
         ELM_COLOR_ITEM_DATA_GET(eo_item, item);
@@ -1185,13 +1183,11 @@ _palette_sizing_eval(Evas_Object *obj)
 }
 
 static void
-_component_sizing_eval(Evas_Object *obj)
+_component_sizing_eval(Elm_Colorselector_Data *sd)
 {
    Evas_Coord minw = -1, minh = -1;
    int i;
 
-   ELM_COLORSELECTOR_DATA_GET(obj, sd);
-
    for (i = 0; i < 4; i++)
      {
         if (sd->cb_data[i])
@@ -1212,10 +1208,10 @@ _component_sizing_eval(Evas_Object *obj)
 }
 
 static void
-_full_sizing_eval(Evas_Object *obj)
+_full_sizing_eval(Elm_Colorselector_Data *sd)
 {
-   _palette_sizing_eval(obj);
-   _component_sizing_eval(obj);
+   _palette_sizing_eval(sd);
+   _component_sizing_eval(sd);
 }
 
 static void
@@ -1241,15 +1237,15 @@ _elm_colorselector_elm_layout_sizing_eval(Eo *obj, Elm_Colorselector_Data *sd)
    switch (sd->mode)
      {
       case ELM_COLORSELECTOR_PALETTE:
-        _palette_sizing_eval(obj);
+        _palette_sizing_eval(sd);
         break;
 
       case ELM_COLORSELECTOR_COMPONENTS:
-        _component_sizing_eval(obj);
+        _component_sizing_eval(sd);
         break;
 
       case ELM_COLORSELECTOR_BOTH:
-        _full_sizing_eval(obj);
+        _full_sizing_eval(sd);
         break;
 
       case ELM_COLORSELECTOR_PICKER:
@@ -1257,7 +1253,7 @@ _elm_colorselector_elm_layout_sizing_eval(Eo *obj, Elm_Colorselector_Data *sd)
         break;
 
       case ELM_COLORSELECTOR_ALL:
-        _full_sizing_eval(obj);
+        _full_sizing_eval(sd);
         break;
 
       default: