This is an automated email from the ASF dual-hosted git repository.

yishayw pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git


The following commit(s) were added to refs/heads/develop by this push:
     new 9d8487cc41 Work around unexpected svg behavior when rotation transform 
is on
9d8487cc41 is described below

commit 9d8487cc41a7418ff099cd7a6e00d86b0feec358
Author: Yishay Weiss <[email protected]>
AuthorDate: Tue May 17 17:25:54 2022 +0300

    Work around unexpected svg behavior when rotation transform is on
---
 .../src/main/royale/mx/controls/sliderClasses/Slider.as        | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git 
a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/sliderClasses/Slider.as
 
b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/sliderClasses/Slider.as
index 3c45b1e865..2f1ffb7da6 100644
--- 
a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/sliderClasses/Slider.as
+++ 
b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/sliderClasses/Slider.as
@@ -2167,9 +2167,6 @@ package mx.controls.sliderClasses
             if (!ticks)
             {
                 ticks = new UIComponent();
-                ticks.percentWidth = 100;
-                ticks.percentHeight = 100;
-
                 innerSlider.addChild(ticks);
             }
         }
@@ -2255,6 +2252,13 @@ package mx.controls.sliderClasses
                 var val:Number = usePositions ? _tickValues[positionIndex++] : 
minimum;
                 
                 g.clear();
+                COMPILE::JS
+                {
+                    // clear sets width and height according to containing 
element, but these values can be skewed because of rotation
+                    var svg:Element = 
ticks.element.getElementsByTagName('svg')[0] as Element;
+                    svg.removeAttribute("width");
+                    svg.removeAttribute("height");
+                }
                 
                 if (_tickInterval > 0 || usePositions)
                 {

Reply via email to