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] - Enables side borders on SWF platform.
Date Tue, 18 Apr 2017 13:35:28 GMT
Repository: flex-asjs
Updated Branches:
  refs/heads/develop 8a23e1e9f -> b1ba88e8f


Enables side borders on SWF platform.


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

Branch: refs/heads/develop
Commit: b1ba88e8f618894463e34d4f84060acc9daef268
Parents: 8a23e1e
Author: Peter Ent <pent@apache.org>
Authored: Tue Apr 18 09:35:21 2017 -0400
Committer: Peter Ent <pent@apache.org>
Committed: Tue Apr 18 09:35:21 2017 -0400

----------------------------------------------------------------------
 .../org/apache/flex/html/beads/DataGridView.as  |  2 +-
 .../org/apache/flex/html/beads/GroupView.as     | 23 ++++++++++++++++----
 2 files changed, 20 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b1ba88e8/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataGridView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataGridView.as
b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataGridView.as
index 68e5d95..3b387d9 100644
--- a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataGridView.as
+++ b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/DataGridView.as
@@ -134,7 +134,7 @@ package org.apache.flex.html.beads
 					_listArea.element.style["flex-grow"] = "1";
 				}
 				
-				IEventDispatcher(_strand).addEventListener("initComplete", finishSetup);
+				IEventDispatcher(_strand).addEventListener("beadsAdded", finishSetup);
 			}
 			
 			/**

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b1ba88e8/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/GroupView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/GroupView.as
b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/GroupView.as
index acd805d..2a982c2 100644
--- a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/GroupView.as
+++ b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/beads/GroupView.as
@@ -304,26 +304,41 @@ package org.apache.flex.html.beads
 					host.addBead( new c() as IBead );
 				}
 			}
-
+			
+			if (setupForBorder(host, "border")) return;
+			if (setupForBorder(host, "border-top")) return;
+			if (setupForBorder(host, "border-bottom")) return;
+			if (setupForBorder(host, "border-left")) return;
+			if (setupForBorder(host, "border-right")) return;
+		}
+		
+		COMPILE::SWF
+		protected function setupForBorder(host:UIBase, borderType:String):Boolean
+		{
+			var result:Boolean = false;
+			
 			var borderStyle:String;
-			var borderStyles:Object = ValuesManager.valuesImpl.getValue(host, "border");
+			var borderStyles:Object = ValuesManager.valuesImpl.getValue(host, borderType);
 			if (borderStyles is Array)
 			{
 				borderStyle = borderStyles[1];
 			}
 			if (borderStyle == null)
 			{
-				borderStyle = ValuesManager.valuesImpl.getValue(host, "border-style") as String;
+				borderStyle = ValuesManager.valuesImpl.getValue(host, borderType+"-style") as String;
 			}
 			if (borderStyle != null && borderStyle != "none")
 			{
 				if (host.getBeadByType(IBorderBead) == null) {
-					c = ValuesManager.valuesImpl.getValue(host, "iBorderBead");
+					var c:Class = ValuesManager.valuesImpl.getValue(host, "iBorderBead");
 					if (c) {
 						host.addBead( new c() as IBead );
+						result = true;
 					}
 				}
 			}
+			
+			return result;
 		}
 	}
 }


Mime
View raw message