You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by ah...@apache.org on 2019/12/05 21:53:00 UTC

[royale-asjs] branch develop updated (3707953 -> 2bf5997)

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

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


    from 3707953  make panels look better
     new ae7b2d0  tune last row viewing.  Should fix #609
     new 2bf5997  horizontalscrollpolicy==off

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as   | 9 +++++++++
 .../MXRoyale/src/main/royale/mx/core/ScrollControlBase.as        | 9 +++++++++
 2 files changed, 18 insertions(+)


[royale-asjs] 01/02: tune last row viewing. Should fix #609

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit ae7b2d021ec487f9b3c6ed4655541def910d91a5
Author: Alex Harui <ah...@apache.org>
AuthorDate: Thu Dec 5 13:35:35 2019 -0800

    tune last row viewing.  Should fix #609
---
 .../royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as     | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as
index 1adf495..a499ef0 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as
@@ -121,6 +121,13 @@ package mx.controls.beads.layouts
                         // the lists are "absolute" so they float over the spacer
                         spacer.style.height = totalHeight.toString() + "px";
                         topSpacerHeight = Math.min(topSpacerHeight, totalHeight - useHeight);
+                        // if we have enough to scroll, then make the columns a row taller because
+                        // the virtual scrolling neds to shift the column lists
+                        if (totalHeight > useHeight)
+                        {
+                            var numVisibleRows:int = Math.floor(useHeight / actualRowHeight);
+                            useHeight = actualRowHeight * (numVisibleRows + 1);
+                        }
                     }
                 }
                 for (var i:int = 0; i < n; i++)


[royale-asjs] 02/02: horizontalscrollpolicy==off

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 2bf5997433c1f2877f192265c13c0204f800b422
Author: Alex Harui <ah...@apache.org>
AuthorDate: Thu Dec 5 13:52:39 2019 -0800

    horizontalscrollpolicy==off
---
 .../royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as   | 2 ++
 .../MXRoyale/src/main/royale/mx/core/ScrollControlBase.as        | 9 +++++++++
 2 files changed, 11 insertions(+)

diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as
index a499ef0..01c3468 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/beads/layouts/AdvancedDataGridLayout.as
@@ -128,6 +128,8 @@ package mx.controls.beads.layouts
                             var numVisibleRows:int = Math.floor(useHeight / actualRowHeight);
                             useHeight = actualRowHeight * (numVisibleRows + 1);
                         }
+                        if (uiHost.element.style["overflow-x"] == "hidden")
+                            listArea.element.style["overflow-x"] = "hidden";
                     }
                 }
                 for (var i:int = 0; i < n; i++)
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/core/ScrollControlBase.as b/frameworks/projects/MXRoyale/src/main/royale/mx/core/ScrollControlBase.as
index ff40934..cf56df3 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/core/ScrollControlBase.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/core/ScrollControlBase.as
@@ -1475,5 +1475,14 @@ public class ScrollControlBase extends UIComponent
 	{
 
 	}
+    
+    COMPILE::JS
+    override public function addedToParent():void
+    {
+        super.addedToParent();
+        if (_horizontalScrollPolicy == ScrollPolicy.OFF)
+            element.style["overflow-x"] = "hidden";
+            
+    }
 }
 }