flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pio...@apache.org
Subject git commit: [flex-asjs] [refs/heads/develop] - - More clean up in DataBinding beads
Date Sat, 14 Jan 2017 12:29:48 GMT
Repository: flex-asjs
Updated Branches:
  refs/heads/develop ea4977cbc -> f7d3eda01


- More clean up in DataBinding beads


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

Branch: refs/heads/develop
Commit: f7d3eda01938abf9214b17c185dd2e3f8477acb3
Parents: ea4977c
Author: piotrz <piotrz@apache.org>
Authored: Sat Jan 14 13:29:44 2017 +0100
Committer: piotrz <piotrz@apache.org>
Committed: Sat Jan 14 13:29:44 2017 +0100

----------------------------------------------------------------------
 .../flex/org/apache/flex/binding/ContainerDataBinding.as  |  6 +++---
 .../main/flex/org/apache/flex/binding/ViewDataBinding.as  | 10 +++++-----
 2 files changed, 8 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f7d3eda0/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ContainerDataBinding.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ContainerDataBinding.as
b/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ContainerDataBinding.as
index c302bd0..eaf9993 100644
--- a/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ContainerDataBinding.as
+++ b/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ContainerDataBinding.as
@@ -79,19 +79,19 @@ package org.apache.flex.binding
 
         private function initCompleteHandler(event:Event):void
         {
+            if (!("_bindings" in _strand))
+                return;
             var fieldWatcher:Object;
             var sb:SimpleBinding;
             var cb:ConstantBinding;
-            if (!("_bindings" in _strand))
-                return;
             var bindingData:Array = _strand["_bindings"];
+            var binding:Object = {};
             var n:int = bindingData[0];
             var bindings:Array = [];
             var i:int;
             var index:int = 1;
             for (i = 0; i < n; i++)
             {
-                var binding:Object = {};
                 binding.source = bindingData[index++];
 				binding.destFunc = bindingData[index++];
                 binding.destination = bindingData[index++];

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f7d3eda0/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ViewDataBinding.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ViewDataBinding.as
b/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ViewDataBinding.as
index c55151d..c14f322 100644
--- a/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ViewDataBinding.as
+++ b/frameworks/projects/Binding/src/main/flex/org/apache/flex/binding/ViewDataBinding.as
@@ -76,19 +76,19 @@ package org.apache.flex.binding
 
         private function initCompleteHandler(event:Event):void
         {
-            var fieldWatcher:Object;
-            var isStatic:Boolean;
-            var sb:SimpleBinding;
             if (!("_bindings" in _strand))
                 return;
+
+            var fieldWatcher:Object;
+            var sb:SimpleBinding;
             var bindingData:Array = _strand["_bindings"];
             var n:int = bindingData[0];
             var bindings:Array = [];
+            var binding:Object = {};
             var i:int;
             var index:int = 1;
             for (i = 0; i < n; i++)
             {
-                var binding:Object = {};
                 binding.source = bindingData[index++];
 				binding.destFunc = bindingData[index++];
                 binding.destination = bindingData[index++];
@@ -108,7 +108,7 @@ package org.apache.flex.binding
                     }
                     else if (fieldWatcher.eventNames is String)
                     {
-                        isStatic = fieldWatcher.type == "static";
+                        var isStatic:Boolean = fieldWatcher.type == "static";
                         sb = new SimpleBinding(isStatic);
                         sb.destinationPropertyName = binding.destination[1];
                         sb.eventName = fieldWatcher.eventNames as String;


Mime
View raw message