* edje: Another round of llvm warning removal.
authorCedric BAIL <cedric.bail@free.fr>
Wed, 7 Oct 2009 11:36:23 +0000 (11:36 +0000)
committerCedric BAIL <cedric.bail@free.fr>
Wed, 7 Oct 2009 11:36:23 +0000 (11:36 +0000)
SVN revision: 42932

legacy/edje/src/lib/edje_edit.c
legacy/edje/src/lib/edje_util.c

index 289b024..b0b1261 100644 (file)
@@ -5378,7 +5378,7 @@ _edje_generate_source(Evas_Object *obj)
    strcpy(tmpn, "/tmp/edje_edit.edc-tmp-XXXXXX");
    if (!(fd = mkstemp(tmpn))) return NULL;
    printf("*** tmp file: %s\n", tmpn);
-   if (!(f = fopen(tmpn, "w"))) return NULL;
+   if (!(f = fdopen(fd, "w"))) return NULL;
 
    /* Write edc into file */
    //TODO Probably we need to save the file before generation
index e260566..89c9e3b 100644 (file)
@@ -2369,33 +2369,34 @@ edje_object_size_min_restricted_calc(Evas_Object *obj, Evas_Coord *minw, Evas_Co
             w = ep->w - ep->req.w;
             h = ep->h - ep->req.h;
             didw = 0;
-            if (!((ep->chosen_description) &&
-                  (ep->chosen_description->fixed.w)))
+            if (ep->chosen_description)
               {
-                 if (w > maxw)
+                 if (!ep->chosen_description->fixed.w)
                    {
-                      maxw = w;
-                      ok = 1;
-                      pep = ep;
-                      didw = 1;
-                   }
-                 if ((ep->part->type == EDJE_PART_TYPE_TEXTBLOCK))
-                   {
-                      /* FIXME: do something */
-                   }
-              }
-            if (!((ep->chosen_description) &&
-                  (ep->chosen_description->fixed.h)))
-              {
-                 if (!((ep->part->type == EDJE_PART_TYPE_TEXTBLOCK) &&
-                       (!ep->chosen_description->text.min_x) &&
-                       (didw)))
-                   {
-                      if (h > maxh)
+                      if (w > maxw)
                         {
-                           maxh = h;
+                           maxw = w;
                            ok = 1;
                            pep = ep;
+                           didw = 1;
+                        }
+                      if ((ep->part->type == EDJE_PART_TYPE_TEXTBLOCK))
+                        {
+                           /* FIXME: do something */
+                        }
+                   }
+                 if (!ep->chosen_description->fixed.h)
+                   {
+                      if (!((ep->part->type == EDJE_PART_TYPE_TEXTBLOCK) &&
+                            (!ep->chosen_description->text.min_x) &&
+                            (didw)))
+                        {
+                           if (h > maxh)
+                             {
+                                maxh = h;
+                                ok = 1;
+                                pep = ep;
+                             }
                         }
                    }
               }
@@ -2472,7 +2473,7 @@ edje_object_part_state_get(const Evas_Object *obj, const char *part, double *val
        printf("part not found\n");
        return "";
      }
-   if (!rp->chosen_description)
+   if (rp->chosen_description)
      {
        if (val_ret) *val_ret = rp->chosen_description->state.value;
        if (rp->chosen_description->state.name)