cedric pushed a commit to branch master.

commit 93b0fbfe6593f7d84b0239686dd42a161d695b43
Author: Cedric Bail <[email protected]>
Date:   Wed Aug 7 15:02:52 2013 +0900

    edje: add warning when not finding the exact match.
    
    This will close T223.
---
 src/bin/edje/edje_cc_handlers.c               |  7 +++++++
 src/tests/edje/tests/edje_inherit_nearest.edc | 28 +++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)

diff --git a/src/bin/edje/edje_cc_handlers.c b/src/bin/edje/edje_cc_handlers.c
index 2953335..2dde595 100644
--- a/src/bin/edje/edje_cc_handlers.c
+++ b/src/bin/edje/edje_cc_handlers.c
@@ -5080,6 +5080,13 @@ st_collections_group_parts_part_description_inherit(void)
                          }
                     }
                }
+
+            if (min_dst)
+              {
+                  WRN("%s:%i: couldn't find an exact match in part '%s' when 
looking for '%s' %lf. Falling back to nearest one '%s' %lf.",
+                      file_in, line - 1, ep->name, parent_name, parent_val, 
parent->state.name, parent->state.value);
+               }
+                    
           }
 
         if (!parent)
diff --git a/src/tests/edje/tests/edje_inherit_nearest.edc 
b/src/tests/edje/tests/edje_inherit_nearest.edc
new file mode 100644
index 0000000..555db13
--- /dev/null
+++ b/src/tests/edje/tests/edje_inherit_nearest.edc
@@ -0,0 +1,28 @@
+collections
+{
+   group
+   {
+      name: "test";
+      min:200 200;
+      parts
+      {
+         part
+         {
+            name: "bug";
+            type: RECT;
+            description
+            {
+               state: "default" 0;
+               min:50 50;
+               max: 50 50;
+               color: 255 255 0 255;
+            }
+            description
+            {
+               state: "inherit-test" 0;
+               inherit: "default" 1; // edje_cc should throw error or warning.
+            }
+         }
+      }
+   }
+}

-- 

------------------------------------------------------------------------------
Get 100% visibility into Java/.NET code with AppDynamics Lite!
It's a free troubleshooting tool designed for production.
Get down to code-level detail for bottlenecks, with <2% overhead. 
Download for free and get started troubleshooting in minutes. 
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk

Reply via email to