You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by gr...@apache.org on 2026/04/01 07:10:28 UTC
(royale-asjs) 04/05: unit propagation.
This is an automated email from the ASF dual-hosted git repository.
gregdove pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
commit 473d7df2b4c63b7a6279be408adf6c290971d0d7
Author: greg-dove <gr...@gmail.com>
AuthorDate: Wed Apr 1 20:08:22 2026 +1300
unit propagation.
---
.../org/apache/royale/style/stylebeads/StyleBeadBase.as | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/frameworks/projects/Style/src/main/royale/org/apache/royale/style/stylebeads/StyleBeadBase.as b/frameworks/projects/Style/src/main/royale/org/apache/royale/style/stylebeads/StyleBeadBase.as
index 1bbe48762f..53d97140d3 100644
--- a/frameworks/projects/Style/src/main/royale/org/apache/royale/style/stylebeads/StyleBeadBase.as
+++ b/frameworks/projects/Style/src/main/royale/org/apache/royale/style/stylebeads/StyleBeadBase.as
@@ -76,6 +76,9 @@ package org.apache.royale.style.stylebeads
style.parentStyle = parentStyle;
if(style is ILeafStyleBead)
(style as ILeafStyleBead).unit = unit;
+ else if (style is StyleBeadBase)
+ (style as StyleBeadBase).unit = unit;
+
if(style.isLeaf)
{
retVal.push(style);
@@ -131,6 +134,16 @@ package org.apache.royale.style.stylebeads
public function set unit(value:String):void
{
_unit = value;
+ if (styles)
+ {
+ for each(var style:IStyleBead in styles)
+ {
+ if(style is ILeafStyleBead)
+ (style as ILeafStyleBead).unit = value;
+ else if (style is StyleBeadBase)
+ (style as StyleBeadBase).unit = value;
+ }
+ }
}
public function decorateChildStyle(style:ILeafStyleBead, decorations:Array):void
{