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 4674365  DataGridList parent can be a Basic ContainerContentArea, so 
we don't want to assume it's a UIComponent.
4674365 is described below

commit 46743655c73c48c7b2c0b7a3fb080dfd363592b4
Author: Yishay Weiss <[email protected]>
AuthorDate: Sun Nov 7 07:40:55 2021 +0200

    DataGridList parent can be a Basic ContainerContentArea, so we don't want 
to assume it's a UIComponent.
    
    This might cause problems further down the line, but for now we want to a 
avoid a known runtime error.
---
 .../src/main/royale/mx/controls/listClasses/DataGridListBase.as        | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git 
a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/listClasses/DataGridListBase.as
 
b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/listClasses/DataGridListBase.as
index 88b2e26..79696e7 100644
--- 
a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/listClasses/DataGridListBase.as
+++ 
b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/listClasses/DataGridListBase.as
@@ -67,6 +67,7 @@ import mx.events.FlexEvent;
 import mx.events.ListEvent;
 
 import org.apache.royale.core.IChild;
+import org.apache.royale.core.ILayoutChild;
 import org.apache.royale.core.IDataProviderNotifier;
 import org.apache.royale.core.IIndexedItemRenderer;
 import org.apache.royale.core.IItemRenderer;
@@ -605,7 +606,7 @@ public class DataGridListBase extends ListBase /* extends 
UIComponent
                                // if we're sized to content and parent doesn't 
have explicitWidth
                                // meaning it is sizedToContent or may be % but 
depending on
                                // minHeight measurement, then force a layout
-                               if (isHeightSizedToContent() && isNaN((parent 
as UIComponent).explicitHeight))                  
+                               if (isHeightSizedToContent() && isNaN((parent 
as ILayoutChild).explicitHeight))                 
                                        (parent as 
IEventDispatcher).dispatchEvent(new Event("layoutNeeded"));
                        }
                }

Reply via email to