flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p...@apache.org
Subject git commit: [flex-asjs] [refs/heads/develop] - Adding missing code that includes values from custom styles.
Date Tue, 07 Jan 2014 19:51:26 GMT
Updated Branches:
  refs/heads/develop b33292384 -> eb3bcdb05


Adding missing code that includes values from custom styles.


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/eb3bcdb0
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/eb3bcdb0
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/eb3bcdb0

Branch: refs/heads/develop
Commit: eb3bcdb05a1306cef3b1523f88bef84e0984efc0
Parents: b332923
Author: Peter Ent <pent@apache.org>
Authored: Tue Jan 7 14:51:16 2014 -0500
Committer: Peter Ent <pent@apache.org>
Committed: Tue Jan 7 14:51:16 2014 -0500

----------------------------------------------------------------------
 .../org/apache/flex/core/SimpleCSSValuesImpl.js | 24 ++++++++++++++++++++
 1 file changed, 24 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/eb3bcdb0/frameworks/js/FlexJS/src/org/apache/flex/core/SimpleCSSValuesImpl.js
----------------------------------------------------------------------
diff --git a/frameworks/js/FlexJS/src/org/apache/flex/core/SimpleCSSValuesImpl.js b/frameworks/js/FlexJS/src/org/apache/flex/core/SimpleCSSValuesImpl.js
index d09c3a1..cb6d734 100644
--- a/frameworks/js/FlexJS/src/org/apache/flex/core/SimpleCSSValuesImpl.js
+++ b/frameworks/js/FlexJS/src/org/apache/flex/core/SimpleCSSValuesImpl.js
@@ -58,6 +58,30 @@ org.apache.flex.core.SimpleCSSValuesImpl.prototype.getValue =
   var cName;
   var selectorName;
 
+  if ('className' in thisObject)
+  {
+    cName = thisObject.className;
+    if (state)
+    {
+        selectorName = cName + ':' + state;
+        o = values['.' + selectorName];
+        if (o)
+        {
+            value = o[valueName];
+            if (value !== undefined)
+                return value;
+        }
+    }
+
+    o = values['.' + cName];
+    if (o)
+    {
+        value = o[valueName];
+        if (value !== undefined)
+          return value;
+    }
+  }
+
   cName = thisObject.FLEXJS_CLASS_INFO.names[0].qName;
   if (state)
   {


Mime
View raw message