You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flex.apache.org by Alex Harui <ah...@adobe.com> on 2013/06/07 20:00:25 UTC

New Mustella Failures

Hi Folks,

On last night's Mac run, some new failures showed up.  If you made changes
in these areas, please review your work.

1) ADG mirroring.  The failing bitmap shows the text flipped (as if viewed
in a mirror).  I think mirrored in Flex is supposed to flip everything but
text widgets so the font glyphs themselves are not mirrored, just laid out
RTL or LTR depending on the characters.
     [java] 
components/AdvancedDataGrid/Properties/advanceddatagrid_columngroup
use_grouped_data_mirroring Failed CompareBitmap(body:step 3)  compare
returned[object BitmapData]


2) These 3 are all related to a change in DividedBox.

     [java] 
components/DataGrid/DataGrid_HaloSkin/Bugs/Datagrid_Bug_ResizeHDBox_halo
datagrid_Bug_157493_halo Failed TypeError: Error #1009: Cannot access a
property or method of a null object reference.
     [java] 	at 
mx.containers::DividedBox/styleChanged()[/Users/aharui/git/flex/master/flex
-sdk/frameworks/projects/mx/src/mx/containers/DividedBox.as:749]
     [java] 	at 
mx.styles::StyleProtoChain$/setStyle()[/Users/aharui/git/flex/master/flex-s
dk/frameworks/projects/framework/src/mx/styles/StyleProtoChain.as:717]
     [java] 	at 
mx.core::UIComponent/setStyle()[/Users/aharui/git/flex/master/flex-sdk/fram
eworks/projects/framework/src/mx/core/UIComponent.as:11162]
     [java] 	at 
mx.core::Container/removeEventListener()[/Users/aharui/git/flex/master/flex
-sdk/frameworks/projects/mx/src/mx/core/Container.as:2474]
     [java] 	at 
TestStep/stepComplete()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3
/src/mustella/TestStep.as:164]
     [java] 	at 
TestStep/waitEventHandler()[/Users/aharui/git/flex/master/flex-sdk/mustella
/as3/src/mustella/TestStep.as:151]
     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
     [java] 	at flash.events::EventDispatcher/dispatchEvent()
     [java] 	at 
mx.managers::SystemManager/mouseEventHandler()[/Users/aharui/git/flex/maste
r/flex-sdk/frameworks/projects/framework/src/mx/managers/SystemManager.as:2
926]
     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
     [java] 	at flash.events::EventDispatcher/dispatchEvent()
     [java] 	at 
DispatchMouseEvent/doStep()[/Users/aharui/git/flex/master/flex-sdk/mustella
/as3/src/mustella/DispatchMouseEvent.as:181]
     [java] 	at 
TestStep/execute()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src/
mustella/TestStep.as:65]
     [java] 	at 
DispatchMouseEvent/execute()[/Users/aharui/git/flex/master/flex-sdk/mustell
a/as3/src/mustella/DispatchMouseEvent.as:60]
     [java] 	at 
TestCase/runSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
/mustella/TestCase.as:418]
     [java] 	at 
TestCase/runBody()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src/
mustella/TestCase.as:298]
     [java] 	at 
TestCase/runNextSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3
/src/mustella/TestCase.as:465]
     [java] 
     [java] containers/DividedBox/Events/DivBoxEventTester
div_events_dividerRelease Failed TypeError: Error #1009: Cannot access a
property or method of a null object reference.
     [java] 	at 
mx.containers::DividedBox/styleChanged()[/Users/aharui/git/flex/master/flex
-sdk/frameworks/projects/mx/src/mx/containers/DividedBox.as:749]
     [java] 	at 
mx.styles::StyleProtoChain$/setStyle()[/Users/aharui/git/flex/master/flex-s
dk/frameworks/projects/framework/src/mx/styles/StyleProtoChain.as:717]
     [java] 	at 
mx.core::UIComponent/setStyle()[/Users/aharui/git/flex/master/flex-sdk/fram
eworks/projects/framework/src/mx/core/UIComponent.as:11162]
     [java] 	at 
mx.core::Container/removeEventListener()[/Users/aharui/git/flex/master/flex
-sdk/frameworks/projects/mx/src/mx/core/Container.as:2474]
     [java] 	at 
TestStep/stepComplete()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3
/src/mustella/TestStep.as:164]
     [java] 	at 
TestStep/waitEventHandler()[/Users/aharui/git/flex/master/flex-sdk/mustella
/as3/src/mustella/TestStep.as:151]
     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
     [java] 	at flash.events::EventDispatcher/dispatchEvent()
     [java] 	at 
mx.managers::SystemManager/mouseEventHandler()[/Users/aharui/git/flex/maste
r/flex-sdk/frameworks/projects/framework/src/mx/managers/SystemManager.as:2
926]
     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
     [java] 	at flash.events::EventDispatcher/dispatchEvent()
     [java] 	at 
DispatchMouseEvent/doStep()[/Users/aharui/git/flex/master/flex-sdk/mustella
/as3/src/mustella/DispatchMouseEvent.as:181]
     [java] 	at 
TestStep/execute()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src/
mustella/TestStep.as:65]
     [java] 	at 
DispatchMouseEvent/execute()[/Users/aharui/git/flex/master/flex-sdk/mustell
a/as3/src/mustella/DispatchMouseEvent.as:60]
     [java] 	at 
TestCase/runSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
/mustella/TestCase.as:418]
     [java] 	at 
TestCase/runBody()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src/
mustella/TestCase.as:298]
     [java] 	at 
TestCase/runNextSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3
/src/mustella/TestCase.as:465]
     [java] 
     [java] containers/DividedBox/Events/DivBoxEventTester_spark
div_events_dividerRelease_spark Failed TypeError: Error #1009: Cannot
access a property or method of a null object reference.
     [java] 	at 
mx.containers::DividedBox/styleChanged()[/Users/aharui/git/flex/master/flex
-sdk/frameworks/projects/mx/src/mx/containers/DividedBox.as:749]
     [java] 	at 
mx.styles::StyleProtoChain$/setStyle()[/Users/aharui/git/flex/master/flex-s
dk/frameworks/projects/framework/src/mx/styles/StyleProtoChain.as:717]
     [java] 	at 
mx.core::UIComponent/setStyle()[/Users/aharui/git/flex/master/flex-sdk/fram
eworks/projects/framework/src/mx/core/UIComponent.as:11162]
     [java] 	at 
mx.core::Container/removeEventListener()[/Users/aharui/git/flex/master/flex
-sdk/frameworks/projects/mx/src/mx/core/Container.as:2474]
     [java] 	at 
TestStep/stepComplete()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3
/src/mustella/TestStep.as:164]
     [java] 	at 
TestStep/waitEventHandler()[/Users/aharui/git/flex/master/flex-sdk/mustella
/as3/src/mustella/TestStep.as:151]
     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
     [java] 	at flash.events::EventDispatcher/dispatchEvent()
     [java] 	at 
mx.managers::SystemManager/mouseEventHandler()[/Users/aharui/git/flex/maste
r/flex-sdk/frameworks/projects/framework/src/mx/managers/SystemManager.as:2
926]
     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
     [java] 	at flash.events::EventDispatcher/dispatchEvent()
     [java] 	at 
DispatchMouseEvent/doStep()[/Users/aharui/git/flex/master/flex-sdk/mustella
/as3/src/mustella/DispatchMouseEvent.as:181]
     [java] 	at 
TestStep/execute()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src/
mustella/TestStep.as:65]
     [java] 	at 
DispatchMouseEvent/execute()[/Users/aharui/git/flex/master/flex-sdk/mustell
a/as3/src/mustella/DispatchMouseEvent.as:60]
     [java] 	at 
TestCase/runSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
/mustella/TestCase.as:418]
     [java] 	at 
TestCase/runBody()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src/
mustella/TestCase.as:298]
     [java] 	at 
TestCase/runNextSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3
/src/mustella/TestCase.as:465]
     [java] 



Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

The test passes with that change, I'm not going to have any internet access for a while so I've checked the change  in. Revert if you feel it's not the right solution.

Thanks,
Justin

Re: New Mustella Failures

Posted by Alex Harui <ah...@adobe.com>.

On 6/12/13 9:50 AM, "Justin Mclean" <ju...@classsoftware.com> wrote:

>Hi,
>
>> IMO, it is risky to leave the ADG's renderers in this state.
>Fair enough and I'm sure you know more about the ADG innards than me.
>
>>  But the question is, what about some third-party who extended the
>>renderer and added another style
>> not in this list?
>They could override the setStyle method?
>
>The fix in question I had in several ADGs in production for several years
>and not run into any issues (including navigation key support), but they
>are not using any RTL ADGs.
Yeah, and it turns out that most styles you set cause a full recalc of the
renderers which is why you probably haven't seen any side-effects.  So
we're definitely not talking about the majority case, but I generally
prefer fixing the root problem instead of just the symptoms.
>
>> 3) Changing this styleProp "if" to a lookup on some mx_internal
>
>> object/map.  Rating: -0.1.  Again this leaves the flag set to true, but
>>at
>> least gives someone a way to hack in other properties (plus the check
>>will
>> be much faster).
>Don't think speed is a huge issue here when changing layoutDirection. How
>often would you change the layoutDirection in a real application?
It isn't about layoutDirection, any style property change comes through
styleChanged and that long list of styleProps to check.  If you switch to
a hashmap it will go faster and someone could add other properties if they
get trapped by this scenario.
>
>I have a look at the options in more detail once I get some time - likely
>to be end of the week/next week.
OK, good luck.

-Alex


Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

> IMO, it is risky to leave the ADG's renderers in this state.
Fair enough and I'm sure you know more about the ADG innards than me.

>  But the question is, what about some third-party who extended the renderer and added another style
> not in this list?
They could override the setStyle method?

The fix in question I had in several ADGs in production for several years and not run into any issues (including navigation key support), but they are not using any RTL ADGs.

> 3) Changing this styleProp "if" to a lookup on some mx_internal

> object/map.  Rating: -0.1.  Again this leaves the flag set to true, but at
> least gives someone a way to hack in other properties (plus the check will
> be much faster).
Don't think speed is a huge issue here when changing layoutDirection. How often would you change the layoutDirection in a real application?

> 4) Change AdvancedDataGridItemRenderer to always register for validation
> when invalidateDisplayList() is called.  Rating: 0.5.  This will make the
> renderer conform to the lifecycle "spec", but will simply result in
> validateNow() being called on the renderer, which you were trying to
> eliminate.
The fix doesn't try to remove it altogether just stop it from being called multiple times when it not required. The speed improvement is noticeable.

The initial issue is that it gets called multiple times per cell when scrolling/moving about the ADG. There are other issues with entire rows changes when they shouldn't but that's enough issue. There's some code in my whiteboard that demonstrates this.

I have a look at the options in more detail once I get some time - likely to be end of the week/next week.

Thanks,
Justin

Re: New Mustella Failures

Posted by Alex Harui <ah...@adobe.com>.

On 6/13/13 3:45 AM, "Justin Mclean" <ju...@classsoftware.com> wrote:

>Hi,
>
>> In my version of the test case, after you hit "grouped data" and "expand
>> all", if you were to pause the app and examine the renderers in question
>> in the debugger, they all have their invalidateDisplayListFlag set to
>> true.
>
>Not 100% sure that is the issue in UI Text Field notice the callLater to
>validateNow
>
>        if (!invalidateDisplayListFlag)
>        {
>            invalidateDisplayListFlag = true;
>            if ("callLater" in parent)
>                Object(parent).callLater(validateNow);
>        }
>
>In validateNow it sets it back to false (last line) and validateNow is
>being called when setStyle is on the ADG is being called.
For me, I do not see validateNow get called for the renderers that contain
the '2 million' etc, only for the "Company" renderers (which do show up
correctly).  Could you be seeing that as well?  It only hits the
breakpoint for AdvancedDataGridItemRenderer's validateNow about six times
or so (UITextField.validateNow() picks up more calls from things like
scrollbar buttons, etc).

If not, can you provide more detail on where you set your breakpoints and
did your analysis?

Thanks,
-Alex


Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

> In my version of the test case, after you hit "grouped data" and "expand
> all", if you were to pause the app and examine the renderers in question
> in the debugger, they all have their invalidateDisplayListFlag set to
> true.

Not 100% sure that is the issue in UI Text Field notice the callLater to validateNow

        if (!invalidateDisplayListFlag)
        {
            invalidateDisplayListFlag = true;
            if ("callLater" in parent)
                Object(parent).callLater(validateNow);
        }

In validateNow it sets it back to false (last line) and validateNow is  being called when setStyle is on the ADG is being called.

Thanks,
Justin

Re: New Mustella Failures

Posted by Alex Harui <ah...@adobe.com>.

On 6/12/13 1:22 AM, "Justin Mclean" <ju...@classsoftware.com> wrote:

>HI,
>
>> Well, I'm not sure it is only an issue with the test.
>
>From a quick look it the setStyle that's not causing everything to
>refresh. The extra validateNow fixed that but was also called when
>scrolling, editing etc etc slowing the ADG down.
Well, that's a correct observation of the symptom, but not the cause.

In my version of the test case, after you hit "grouped data" and "expand
all", if you were to pause the app and examine the renderers in question
in the debugger, they all have their invalidateDisplayListFlag set to
true.  That is because the validateNow() that was removed was preceded by
an invalidateDisplayList() call which set the flag to true, but no code
ran to validate the renderer.  Then subsequent calls to setStyle,
depending on the style property will not update because the framework will
not re-register the renderer for validation if it already has
invalidateDisplayListFlag==true (it assumes that means it is already
registered).

IMO, it is risky to leave the ADG's renderers in this state.  Articles and
forum posts that I and others have written about invalidateDisplayListFlag
and the other lifecycle methods and properties pretty much state that you
should never find these flags set to true unless they are registered for
later validation.  Your proposed solution fixes this symptom by forcing
the entire ADG to recalculate the renderers.  But the question is, what
about some third-party who extended the renderer and added another style
not in this list?  Or calls setStyle that only directly affects the
renderers, bypassing the ADG (like changing a type-selector for the
renderer class).  Has anybody done this?  We'll be breaking that person's
app.  Will anybody do this?  I honestly don't know.

I think there are several possible solutions and directions to explore.
Here's the list I thought of and my personal opinions, but I'm going try
to leave it up to you to  decide what risks you want to take.

1) Leave the code "as-is" even without the this proposed change of adding
layoutDirection to the if statement.  Rating -0.5 since I don't like
leaving invalidateDisplayList==true, but one could argue that nobody is
going to change layoutDirection late in the startup, and nobody will
notice that the flag is set to true otherwise.  I haven't tried it, but it
expect that moving setStyle in the test up earlier will not cause any
problems because the expandAll will  refresh all renderers

2) This proposed change of adding layoutDirection to this list of
styleProps.  Rating: -0.4.  It leaves the flag set to true and doesn't
allow for anyone else to workaround another symptom like if they have
their own custom style that isn't getting updated in the renderer.

3) Changing this styleProp "if" to a lookup on some mx_internal
object/map.  Rating: -0.1.  Again this leaves the flag set to true, but at
least gives someone a way to hack in other properties (plus the check will
be much faster).

4) Change AdvancedDataGridItemRenderer to always register for validation
when invalidateDisplayList() is called.  Rating: 0.5.  This will make the
renderer conform to the lifecycle "spec", but will simply result in
validateNow() being called on the renderer, which you were trying to
eliminate

5) Add a flag to drawItem() to know if it is called from within
makeRowsAndColumns and skip calling updateDisplayOfItemRenderer.  Rating:
0.5 (if it works).  I don't know if that will work or not, but I think
this is fundamentally what you are trying to do by removing the
validateNow() call.  drawItem and updateDisplayOfItemRenderer looks like
it might be needed in other situations like keyboard selection where the
entire set of renderers is not refreshed, but it seems like it is
duplicate work when refreshing renderers in makeRowsAndColumns (which is
also used during scrolling).

So, it may be that some combination of #4 and #5 would create a "more
correct" solution with fewer or no side-effects.

Thoughts?
-Alex


>
>Then perhaps a simple solution would to be this?  ie add layoutDirection
>to the styleChanged method.
>
>    override public function styleChanged(styleProp:String):void
>    {
>        super.styleChanged(styleProp);
>
>        if (styleProp == "sortFontFamily"
>            || styleProp == "sortFontSize"
>            || styleProp == "sortFontStyle"
>	    || styleProp == "sortFontWeight"
>	    || styleProp == "layoutDirection")
>        {
>            itemsSizeChanged = true;
>            rendererChanged = true;
>            invalidateProperties();
>            invalidateDisplayList();
>        }
>    }
>
>Probably "direction" should also be in there.
>
>Justin
>


Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
HI,

> Well, I'm not sure it is only an issue with the test. 

From a quick look it the setStyle that's not causing everything to refresh. The extra validateNow fixed that but was also called when scrolling, editing etc etc slowing the ADG down.

Then perhaps a simple solution would to be this?  ie add layoutDirection to the styleChanged method. 

    override public function styleChanged(styleProp:String):void
    {
        super.styleChanged(styleProp);

        if (styleProp == "sortFontFamily"
            || styleProp == "sortFontSize"
            || styleProp == "sortFontStyle"
	    || styleProp == "sortFontWeight"
	    || styleProp == "layoutDirection")
        {
            itemsSizeChanged = true;
            rendererChanged = true;
            invalidateProperties();
            invalidateDisplayList();
        }
    }

Probably "direction" should also be in there.

Justin


Re: New Mustella Failures

Posted by Alex Harui <ah...@adobe.com>.

On 6/11/13 3:36 PM, "Justin Mclean" <ju...@classsoftware.com> wrote:

>Hi,
>
>Given that there's only an issue with the test and it work fine in the
>browser and in 99% of cases (an assumption but not an unreasonable one)
>the performance is significantly better I think we try and get the test
>to pass rather than adding back the validateNow.
Well, I'm not sure it is only an issue with the test.  Here's a
modification of the test case you sent out.  All it does is spread out the
work of the old init() method into buttons so the renderers have to update
after the ADG creation is complete.  Start the app, hit the "Grouped Data"
button, then the "Expand All" button, then the "rtl" button.  Compare with
4.9.  I haven't looked into it any further, but this kind of difference in
behavior makes me nervous.

Thoughts?
-Alex

<?xml version="1.0" encoding="utf-8"?>
<mx:Application layout="vertical" height="700" width="850"
                xmlns:fx="http://ns.adobe.com/mxml/2009"
                xmlns:s="library://ns.adobe.com/flex/spark"
                xmlns:mx="library://ns.adobe.com/flex/mx"
creationComplete="init(event)">
    <fx:Script>
        <![CDATA[
            import mx.events.FlexEvent;
            
            import mx.collections.*;
            import mx.controls.NumericStepper;
            import mx.formatters.CurrencyFormatter;
            import mx.styles.StyleManager;
            import mx.controls.advancedDataGridClasses.*;
            
            protected function init(event:FlexEvent):void
            {
                createColumnGroups();
            }
            
            
            [Bindable]
            private var ac:ArrayCollection = new ArrayCollection();
            
            public var companies:AdvancedDataGridColumn = new
AdvancedDataGridColumn("Company");
            public  var quarters:AdvancedDataGridColumn = new
AdvancedDataGridColumn("Quarter");
            public  var india:AdvancedDataGridColumn = new
AdvancedDataGridColumn("India");
            public  var veeranistan:AdvancedDataGridColumn = new
AdvancedDataGridColumn("Veeranistan");
            public  var pareestan:AdvancedDataGridColumn = new
AdvancedDataGridColumn("Pareestan");
            public  var licenses:AdvancedDataGridColumn = new
AdvancedDataGridColumn("Licenses");
            public var countries:AdvancedDataGridColumnGroup = new
AdvancedDataGridColumnGroup();
            public var toplevel:AdvancedDataGridColumnGroup = new
AdvancedDataGridColumnGroup();
            [Bindable]
            public var hierarch_data:Array = [
                
                { feature:"ADG", children:[
                    { feature:"ADG", subFeature:"Multi column sorting",
startDate:{day:"Monday", Year:2007}, endDate:"1/07/07" },
                    { feature:"ADG", subFeature:"Custom rows",
startDate:{day:"Monday", Year:2009}, endDate:"01/18/07" },
                    { feature:"ADG", subFeature:"Tree Views",
startDate:{day:"Monday", Year:2006}, endDate:"01/29/07" },
                    { feature:"ADG", subFeature:"Collections",
startDate:{day:"Monday", Year:2004},  endDate:"04/25/07" }
                ] }
                
            ];
            
            [Bindable]
            private var mydata:ArrayCollection = new ArrayCollection ([
                {Company:"Adobe", Quarter:1, India:"2 million",
Veeranistan:"2 million", Pareestan:"3 million", Licenses:433764538},
                {Company:"IBM", Quarter:1, India:"9 million",
Veeranistan:"1 million", Pareestan:"5 million", Licenses:456789002},
                {Company:"KaashifSoft", Quarter:1, India:"99 million",
Veeranistan:"99 million", Pareestan:"99 million", Licenses:456712340},
                {Company:"NisheetSoft", Quarter:1, India:"0 million",
Veeranistan:"0 million", Pareestan:"0 million", Licenses:456782313},
                {Company:"Microsoft", Quarter:1, India:"6 million",
Veeranistan:"5 million", Pareestan:"6 million", Licenses:354216789},
                {Company:"Satyam", Quarter:1, India:"1 million",
Veeranistan:"3 million", Pareestan:"2 million", Licenses:325146789},
                {Company:"Subex", Quarter:1, India:"2 million",
Veeranistan:"9 million", Pareestan:"1 million", Licenses:321456978},
                {Company:"Infosys", Quarter:1, India:"0.89 million",
Veeranistan:"12 million", Pareestan:"4.5 million", Licenses:321475689},
    
                {Company:"MCAfee", Quarter:1, India:"3 million",
Veeranistan:"5.98 million", Pareestan:"6.2 million", Licenses:321467589},
                {Company:"MPhasis", Quarter:1, India:"2 million",
Veeranistan:"1.5 million", Pareestan:"6.7 million", Licenses:123456789},
                {Company:"Symphony", Quarter:1, India:"3.4 million",
Veeranistan:"6.1 million", Pareestan:"7.8 million", Licenses:341256789},
                {Company:"Wipro", Quarter:1, India:"5 million",
Veeranistan:"2 million", Pareestan:"7 million", Licenses:321654789},
                {Company:"Google", Quarter:1, India:"3 million",
Veeranistan:"4 million", Pareestan:"1 million", Licenses:321458769 } ]);
            
            public function createColumnGroups():void {		
                countries.headerText="Countries";
                
                toplevel.headerText="Top Level";
                
                var countriesarr:Array = new Array();
                var toplevelarr:Array = new Array();
                countriesarr.push(india);
                countriesarr.push(pareestan);
                countriesarr.push(veeranistan);
                toplevelarr.push(quarters);
                mydatagrid.dataProvider=mydata;
                countries.children = countriesarr;
                toplevelarr.push(countries);
                toplevel.children=toplevelarr;
                mydatagrid.groupedColumns=[companies, toplevel, licenses];
                mydatagrid.dataProvider.refresh();
                companies.dataField="Company";
                quarters.dataField="Quarter";
                licenses.dataField="Licenses";
            }
            
            public function groupedData():void {
                var mygroup:GroupingCollection2 = new
GroupingCollection2();
                mygroup.source=mydata;
                var group:Grouping = new Grouping();
                group.fields = [new GroupingField("Company"), new
GroupingField("Licenses")];
                group.label = "Company";
                mygroup.grouping = group;
                mygroup.refresh();
                mydatagrid.dataProvider = mygroup;
                mydatagrid.validateNow();
            }
            
            public function insertColumns():void {			
                var mycols:AdvancedDataGridColumn = new
AdvancedDataGridColumn("ggg");
                var mycolsarr:Array = mydatagrid.groupedColumns;
                mycolsarr.push(mycols);
                mydatagrid.groupedColumns = mycolsarr;
            }
            
            public function insertColumngroups():void
            {
                var mycolgroup:AdvancedDataGridColumnGroup = new
AdvancedDataGridColumnGroup();
                mycolgroup.headerText = "topmost ";
                var mycolsarr:Array = new
Array(mydatagrid.groupedColumns[0]);
                mycolgroup.children = mycolsarr;
                var tempCols:Array =
mydatagrid.groupedColumns.slice(1,mydatagrid.groupedColumns.length);
                mydatagrid.groupedColumns = [mycolgroup].concat(tempCols);
			
            }
            
            public function hierarchicaldata_setter():void {
                var hierarchs:HierarchicalData = new HierarchicalData();
                hierarchs.source = hierarch_data;
                mydatagrid..dataProvider = hierarchs;
                companies.dataField = "feature";
                quarters.dataField = "subFeature";
                licenses.dataField = "endDate";
            }
            
            public function vrHeight():void {				
                for(var i:int=0;i<20;i++)
                {
                    var rnd:* = Math.random();
                    var obj:Object =
{Company:"column-A0",Quarter:"column-B"+rnd,India:"column-C"+rnd,Veeranista
n:"Column-D"+rnd,Pareestan:"Column-E"+rnd,Licenses:"Column-F"+rnd}
                    ac.addItem(obj);
                }
                
                mydatagrid.dataProvider = ac;
                mydatagrid.variableRowHeight = true;
                mydatagrid.wordWrap = true;
            }
            
            public function headerRenderer():void {
                countries.headerRenderer = new
ClassFactory(mx.controls.NumericStepper);
                toplevel.headerRenderer = new
ClassFactory(mx.controls.TextArea);
                quarters.headerRenderer = new
ClassFactory(mx.controls.TextInput);			
            }
            
            public function customHeaderRenderer():void {
                //toplevel.headerRenderer = new ClassFactory(myheads);		
            }
            
            public function visibleColumns():void {
                toplevel.visible = false;
            }
            
            public function headerSkin():void {
                
//StyleManager.getStyleDeclaration("AdvancedDataGrid").setStyle("headerHori
zontalSeparatorSkin",myhorskin);
            }
            
            public function
myStyleFunction(data:Object,col:AdvancedDataGridColumn):Object          {
                return { color:0xFF0000};
            }
            
            public function myFormatting():void {				
                mydatagrid.styleFunction = myStyleFunction;
                mydata.refresh();
                var forms:CurrencyFormatter = new CurrencyFormatter();
                forms.currencySymbol = "$";
                createColumnGroups();
                licenses.formatter = forms;
                mydatagrid.dataProvider.refresh();			
            }
            
            public function myColumnSpan():void {			
                var renders:AdvancedDataGridRendererProvider = new
AdvancedDataGridRendererProvider();
                renders.column = companies;
                var renderarr:Array = new Array();
                renders.dataField = "Company";
                renders.columnSpan = 2;
                renders.renderer = new
ClassFactory(mx.controls.NumericStepper);
                renderarr.push(renders);
                mydatagrid.rendererProviders = renderarr;
            }
            
            public function generateXML():void {			
                mydatagrid.dataProvider = comps;
            }
            
            
        ]]>
    </fx:Script>
    <fx:Declarations>
        <fx:XMLList id="comps">
            <companylist>
                <Company>AalishaanSoft</Company>
                <Quarter> 1 </Quarter>
                <India>34 million</India>
                <Veeranistan>1.5 million</Veeranistan>
                <Pareestan>5 million</Pareestan>
                <Licenses>321475987</Licenses>
            </companylist>
            <companylist>
                <Company>MughaleAzamSoft</Company>
                <Quarter> 1 </Quarter>
                <India>3.4 million</India>
                <Veeranistan>2 million</Veeranistan>
                <Pareestan>5.4 million</Pareestan>
                <Licenses>321475987</Licenses>
            </companylist>
            <companylist>
                <Company>SheeshMahalSoft</Company>
                <Quarter> 1 </Quarter>
                <India>45 million</India>
                <Veeranistan>15 million</Veeranistan>
                <Pareestan>5.1 million</Pareestan>
                <Licenses>321745987</Licenses>
            </companylist>
            <companylist>
                <Company>AjnabeeSoft</Company>
                <Quarter> 1 </Quarter>
                <India>14 million</India>
                <Veeranistan>11 million</Veeranistan>
                <Pareestan>5.7 million</Pareestan>
                <Licenses>321479587</Licenses>
            </companylist>
        </fx:XMLList>
    </fx:Declarations>
    <mx:VBox>
    <mx:Canvas id="box" width="100%" height="100%">
        <mx:AdvancedDataGrid id="mydatagrid" />
    </mx:Canvas>
    <mx:TextInput id="ti"/>
        <mx:HBox>
            <mx:Button label="grouped data" click="groupedData()" />
            <mx:Button label="expand all" click="mydatagrid.expandAll();"
/>
            <mx:Button label="rtl"
click="mydatagrid.setStyle('layoutDirection', 'rtl')" />
            <mx:Button label="color" click="mydatagrid.setStyle('color',
0xFF0000)" />
        </mx:HBox>
    </mx:VBox>
</mx:Application>





Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

Given that there's only an issue with the test and it work fine in the browser and in 99% of cases (an assumption but not an unreasonable one) the performance is significantly better I think we try and get the test to pass rather than adding back the validateNow.

Thanks,
Justin

Re: New Mustella Failures

Posted by Alex Harui <ah...@adobe.com>.

On 6/9/13 2:28 AM, "Justin Mclean" <ju...@classsoftware.com> wrote:

>Hi,
>
>> Don't know OTOH.  One possibility is that now that validateNow isn't
>>being
>> called it gets validated and the text is "fixed" on some later frame,
>> which could be after compareBitmap does its thing.
>As far as I can see the text shouldn't be changed/reversed/RTL or
>anything as only the layoutDirection is changed. All that should do is
>show columns in reverse order.
>> 
>> I can put this on my list of things to dig into after I get other
>>mustella
>> failures on the VM resolved.  Let me know.
>If you could that would be a great help.
Ok, finally got around to looking at this.  The issue is that the renderer
is based on UITextField which has different logic around invalidation.
Just calling invalidateDisplayList on the renderer does not put it in the
queue for later validation.    I honestly don't know why we did that,
maybe a performance optimization as UITextFields are usually subcomponents
and are usually validated by their parent components.

So, by removing the validateNow() call on the renderer, it leaves its
invalidateDisplayList flag set but not in the queue which means that
subsequent calls won't put it in the queue either, so it never get flipped
back like it should.

Putting the renderer in the queue on invalidateDisplayList() seems like a
reasonable solution, but that will just re-introduce the calls to
validateNow() defeating what I think you were trying to achieve, and means
that other code that knows to call validateNow() will still end up calling
validateNow() and then the LayoutManager will again, so there could be a
performance hit.  There aren't good checks on validateNow() to bail early
if there isn't anything to do.

So, I'll leave it up to you to decide whether to bring back that
validateNow() and/or find a way to be smarter about not calling it, or
adding queueing to the renderer (and maybe also do it for regular
DGItemRenderer as well).

HTH,
-Alex



Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

> Don't know OTOH.  One possibility is that now that validateNow isn't being
> called it gets validated and the text is "fixed" on some later frame,
> which could be after compareBitmap does its thing.
As far as I can see the text shouldn't be changed/reversed/RTL or anything as only the layoutDirection is changed. All that should do is show columns in reverse order.
> 
> I can put this on my list of things to dig into after I get other mustella
> failures on the VM resolved.  Let me know.
If you could that would be a great help.

Thanks,
Justin

Re: New Mustella Failures

Posted by Alex Harui <ah...@adobe.com>.

On 6/8/13 11:15 AM, "Justin Mclean" <ju...@classsoftware.com> wrote:

>The validate now was being called multiple times - removing it
>significantly improved performance.
>
>Why is the text reversed in the bitmap only the columns should be in
>reverse order.
Don't know OTOH.  One possibility is that now that validateNow isn't being
called it gets validated and the text is "fixed" on some later frame,
which could be after compareBitmap does its thing.

I can put this on my list of things to dig into after I get other mustella
failures on the VM resolved.  Let me know.

-Alex


Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
The validate now was being called multiple times - removing it
significantly improved performance.

Why is the text reversed in the bitmap only the columns should be in
reverse order.

Re: New Mustella Failures

Posted by Alex Harui <ah...@adobe.com>.
IIRC, you added or removed a validateNow()?  That could affect timing, so
the CompareBitmap may need or not need to WaitForLayoutManager.  But if
waiting helps, consider that this could mean an app that's busy so the
frame rate slows might see a flicker.

On 6/8/13 2:34 AM, "Justin Mclean" <ju...@classsoftware.com> wrote:

>Hi,
>
>>> 1) ADG mirroring.  The failing bitmap shows the text flipped (as if
>>>viewed
>>> in a mirror).  
>
>Look closer at the test it setting the layout direction RTL not the
>direction so only the columns should be reverse order not the text.
>
>Look like there's an issue with the test as the same code run in a
>browser doesn't show the text mirrored.
>
>here's the code:
>
><?xml version="1.0" encoding="utf-8"?>
><mx:Application layout="vertical" height="700" width="850"
>			xmlns:fx="http://ns.adobe.com/mxml/2009"
>			xmlns:s="library://ns.adobe.com/flex/spark"
>			xmlns:mx="library://ns.adobe.com/flex/mx" initialize="init(event)">
>	<fx:Script>
>		<![CDATA[
>			import mx.events.FlexEvent;
>			
>			import mx.collections.*;
>			import mx.controls.NumericStepper;
>			import mx.formatters.CurrencyFormatter;
>			import mx.styles.StyleManager;
>			import mx.controls.advancedDataGridClasses.*;
>			
>			protected function init(event:FlexEvent):void
>			{
>				createColumnGroups();
>				groupedData();
>				mydatagrid.expandAll();
>			}
>				
>				[Bindable]
>				private var ac:ArrayCollection = new ArrayCollection();
>
>				public var companies:AdvancedDataGridColumn = new
>AdvancedDataGridColumn("Company");
>				public  var quarters:AdvancedDataGridColumn = new
>AdvancedDataGridColumn("Quarter");
>				public  var india:AdvancedDataGridColumn = new
>AdvancedDataGridColumn("India");
>				public  var veeranistan:AdvancedDataGridColumn = new
>AdvancedDataGridColumn("Veeranistan");
>				public  var pareestan:AdvancedDataGridColumn = new
>AdvancedDataGridColumn("Pareestan");
>				public  var licenses:AdvancedDataGridColumn = new
>AdvancedDataGridColumn("Licenses");
>				public var countries:AdvancedDataGridColumnGroup = new
>AdvancedDataGridColumnGroup();
>				public var toplevel:AdvancedDataGridColumnGroup = new
>AdvancedDataGridColumnGroup();
>				[Bindable]
>				public var hierarch_data:Array = [
>				
>				{ feature:"ADG", children:[
>				{ feature:"ADG", subFeature:"Multi column sorting",
>startDate:{day:"Monday", Year:2007}, endDate:"1/07/07" },
>				{ feature:"ADG", subFeature:"Custom rows", startDate:{day:"Monday",
>Year:2009}, endDate:"01/18/07" },
>				{ feature:"ADG", subFeature:"Tree Views", startDate:{day:"Monday",
>Year:2006}, endDate:"01/29/07" },
>				{ feature:"ADG", subFeature:"Collections", startDate:{day:"Monday",
>Year:2004},  endDate:"04/25/07" }
>				] }
>				
>				];
>				
>				[Bindable]
>				private var mydata:ArrayCollection = new ArrayCollection ([
>				{Company:"Adobe", Quarter:1, India:"2 million", Veeranistan:"2
>million", Pareestan:"3 million", Licenses:433764538},
>				{Company:"IBM", Quarter:1, India:"9 million", Veeranistan:"1
>million", Pareestan:"5 million", Licenses:456789002},
>				{Company:"KaashifSoft", Quarter:1, India:"99 million",
>Veeranistan:"99 million", Pareestan:"99 million", Licenses:456712340},
>				{Company:"NisheetSoft", Quarter:1, India:"0 million", Veeranistan:"0
>million", Pareestan:"0 million", Licenses:456782313},
>				{Company:"Microsoft", Quarter:1, India:"6 million", Veeranistan:"5
>million", Pareestan:"6 million", Licenses:354216789},
>				{Company:"Satyam", Quarter:1, India:"1 million", Veeranistan:"3
>million", Pareestan:"2 million", Licenses:325146789},
>				{Company:"Subex", Quarter:1, India:"2 million", Veeranistan:"9
>million", Pareestan:"1 million", Licenses:321456978},
>				{Company:"Infosys", Quarter:1, India:"0.89 million", Veeranistan:"12
>million", Pareestan:"4.5 million", Licenses:321475689},
>				{Company:"MCAfee", Quarter:1, India:"3 million", Veeranistan:"5.98
>million", Pareestan:"6.2 million", Licenses:321467589},
>				{Company:"MPhasis", Quarter:1, India:"2 million", Veeranistan:"1.5
>million", Pareestan:"6.7 million", Licenses:123456789},
>				{Company:"Symphony", Quarter:1, India:"3.4 million", Veeranistan:"6.1
>million", Pareestan:"7.8 million", Licenses:341256789},
>				{Company:"Wipro", Quarter:1, India:"5 million", Veeranistan:"2
>million", Pareestan:"7 million", Licenses:321654789},
>				{Company:"Google", Quarter:1, India:"3 million", Veeranistan:"4
>million", Pareestan:"1 million", Licenses:321458769 } ]);
>				
>				public function createColumnGroups():void {		
>					countries.headerText="Countries";
>					
>					toplevel.headerText="Top Level";
>					
>					var countriesarr:Array = new Array();
>					var toplevelarr:Array = new Array();
>					countriesarr.push(india);
>					countriesarr.push(pareestan);
>					countriesarr.push(veeranistan);
>					toplevelarr.push(quarters);
>					mydatagrid.dataProvider=mydata;
>					countries.children = countriesarr;
>					toplevelarr.push(countries);
>					toplevel.children=toplevelarr;
>					mydatagrid.groupedColumns=[companies, toplevel, licenses];
>					mydatagrid.dataProvider.refresh();
>					companies.dataField="Company";
>					quarters.dataField="Quarter";
>					licenses.dataField="Licenses";
>				}
>				
>				public function groupedData():void {
>					var mygroup:GroupingCollection2 = new GroupingCollection2();
>					mygroup.source=mydata;
>					var group:Grouping = new Grouping();
>					group.fields = [new GroupingField("Company"), new
>GroupingField("Licenses")];
>					group.label = "Company";
>					mygroup.grouping = group;
>					mygroup.refresh();
>					mydatagrid.dataProvider = mygroup;
>					mydatagrid.validateNow();
>				}
>				
>				public function insertColumns():void {			
>					var mycols:AdvancedDataGridColumn = new
>AdvancedDataGridColumn("ggg");
>					var mycolsarr:Array = mydatagrid.groupedColumns;
>					mycolsarr.push(mycols);
>					mydatagrid.groupedColumns = mycolsarr;
>				}
>				
>				public function insertColumngroups():void
>				{
>					var mycolgroup:AdvancedDataGridColumnGroup = new
>AdvancedDataGridColumnGroup();
>					mycolgroup.headerText = "topmost ";
>					var mycolsarr:Array = new Array(mydatagrid.groupedColumns[0]);
>					mycolgroup.children = mycolsarr;
>					var tempCols:Array =
>mydatagrid.groupedColumns.slice(1,mydatagrid.groupedColumns.length);
>					mydatagrid.groupedColumns = [mycolgroup].concat(tempCols); 			
>				}
>				
>				public function hierarchicaldata_setter():void {
>					var hierarchs:HierarchicalData = new HierarchicalData();
>					hierarchs.source = hierarch_data;
>					mydatagrid..dataProvider = hierarchs;
>					companies.dataField = "feature";
>					quarters.dataField = "subFeature";
>					licenses.dataField = "endDate";
>				}
>				
>				public function vrHeight():void {				
>					for(var i:int=0;i<20;i++)
>					{
>						var rnd:* = Math.random();
>						var obj:Object =
>{Company:"column-A0",Quarter:"column-B"+rnd,India:"column-C"+rnd,Veeranist
>an:"Column-D"+rnd,Pareestan:"Column-E"+rnd,Licenses:"Column-F"+rnd}
>						ac.addItem(obj);
>					}
>					
>					mydatagrid.dataProvider = ac;
>					mydatagrid.variableRowHeight = true;
>					mydatagrid.wordWrap = true;
>				}
>				
>				public function headerRenderer():void {
>					countries.headerRenderer = new
>ClassFactory(mx.controls.NumericStepper);
>					toplevel.headerRenderer = new ClassFactory(mx.controls.TextArea);
>					quarters.headerRenderer = new ClassFactory(mx.controls.TextInput);			
>				}
>				
>				public function customHeaderRenderer():void {
>					//toplevel.headerRenderer = new ClassFactory(myheads);		
>				}
>				
>				public function visibleColumns():void {
>					toplevel.visible = false;
>				}
>				
>				public function headerSkin():void {
>					//StyleManager.getStyleDeclaration("AdvancedDataGrid").setStyle("head
>erHorizontalSeparatorSkin",myhorskin);
>				}
>				
>				public function
>myStyleFunction(data:Object,col:AdvancedDataGridColumn):Object          {
>					return { color:0xFF0000};
>				}
>				
>				public function myFormatting():void {				
>					mydatagrid.styleFunction = myStyleFunction;
>					mydata.refresh();
>					var forms:CurrencyFormatter = new CurrencyFormatter();
>					forms.currencySymbol = "$";
>					createColumnGroups();
>					licenses.formatter = forms;
>					mydatagrid.dataProvider.refresh();			
>				}
>				
>				public function myColumnSpan():void {			
>					var renders:AdvancedDataGridRendererProvider = new
>AdvancedDataGridRendererProvider();
>					renders.column = companies;
>					var renderarr:Array = new Array();
>					renders.dataField = "Company";
>					renders.columnSpan = 2;
>					renders.renderer = new ClassFactory(mx.controls.NumericStepper);
>					renderarr.push(renders);
>					mydatagrid.rendererProviders = renderarr;
>				}
>				
>				public function generateXML():void {			
>					mydatagrid.dataProvider = comps;
>				}
>		
>			
>		]]>
>	</fx:Script>
>	<fx:Declarations>
>		<fx:XMLList id="comps">
>			<companylist>
>				<Company>AalishaanSoft</Company>
>				<Quarter> 1 </Quarter>
>				<India>34 million</India>
>				<Veeranistan>1.5 million</Veeranistan>
>				<Pareestan>5 million</Pareestan>
>				<Licenses>321475987</Licenses>
>			</companylist>
>			<companylist>
>				<Company>MughaleAzamSoft</Company>
>				<Quarter> 1 </Quarter>
>				<India>3.4 million</India>
>				<Veeranistan>2 million</Veeranistan>
>				<Pareestan>5.4 million</Pareestan>
>				<Licenses>321475987</Licenses>
>			</companylist>
>			<companylist>
>				<Company>SheeshMahalSoft</Company>
>				<Quarter> 1 </Quarter>
>				<India>45 million</India>
>				<Veeranistan>15 million</Veeranistan>
>				<Pareestan>5.1 million</Pareestan>
>				<Licenses>321745987</Licenses>
>			</companylist>
>			<companylist>
>				<Company>AjnabeeSoft</Company>
>				<Quarter> 1 </Quarter>
>				<India>14 million</India>
>				<Veeranistan>11 million</Veeranistan>
>				<Pareestan>5.7 million</Pareestan>
>				<Licenses>321479587</Licenses>
>			</companylist>
>		</fx:XMLList>
>	</fx:Declarations>
>	<mx:Canvas id="box" width="100%" height="100%">
>		<mx:AdvancedDataGrid id="mydatagrid" layoutDirection="rtl" />
>	</mx:Canvas>
>	<mx:TextInput id="ti"/>
></mx:Application>
>
>
>Thanks,
>Justin
>
>
>


Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

>> 1) ADG mirroring.  The failing bitmap shows the text flipped (as if viewed
>> in a mirror).  

Look closer at the test it setting the layout direction RTL not the direction so only the columns should be reverse order not the text.

Look like there's an issue with the test as the same code run in a browser doesn't show the text mirrored.

here's the code:

<?xml version="1.0" encoding="utf-8"?>
<mx:Application layout="vertical" height="700" width="850"
			xmlns:fx="http://ns.adobe.com/mxml/2009" 
			xmlns:s="library://ns.adobe.com/flex/spark" 
			xmlns:mx="library://ns.adobe.com/flex/mx" initialize="init(event)">
	<fx:Script>
		<![CDATA[
			import mx.events.FlexEvent;
			
			import mx.collections.*;
			import mx.controls.NumericStepper;
			import mx.formatters.CurrencyFormatter;
			import mx.styles.StyleManager; 
			import mx.controls.advancedDataGridClasses.*;
			
			protected function init(event:FlexEvent):void
			{
				createColumnGroups();
				groupedData();
				mydatagrid.expandAll();
			}
				
				[Bindable]
				private var ac:ArrayCollection = new ArrayCollection(); 

				public var companies:AdvancedDataGridColumn = new AdvancedDataGridColumn("Company");
				public  var quarters:AdvancedDataGridColumn = new AdvancedDataGridColumn("Quarter");
				public  var india:AdvancedDataGridColumn = new AdvancedDataGridColumn("India");
				public  var veeranistan:AdvancedDataGridColumn = new AdvancedDataGridColumn("Veeranistan");
				public  var pareestan:AdvancedDataGridColumn = new AdvancedDataGridColumn("Pareestan");
				public  var licenses:AdvancedDataGridColumn = new AdvancedDataGridColumn("Licenses");
				public var countries:AdvancedDataGridColumnGroup = new AdvancedDataGridColumnGroup();
				public var toplevel:AdvancedDataGridColumnGroup = new AdvancedDataGridColumnGroup();
				[Bindable]
				public var hierarch_data:Array = [ 
				
				{ feature:"ADG", children:[ 
				{ feature:"ADG", subFeature:"Multi column sorting", startDate:{day:"Monday", Year:2007}, endDate:"1/07/07" },
				{ feature:"ADG", subFeature:"Custom rows", startDate:{day:"Monday", Year:2009}, endDate:"01/18/07" },
				{ feature:"ADG", subFeature:"Tree Views", startDate:{day:"Monday", Year:2006}, endDate:"01/29/07" }, 
				{ feature:"ADG", subFeature:"Collections", startDate:{day:"Monday", Year:2004},  endDate:"04/25/07" }
				] }
				
				];
				
				[Bindable]
				private var mydata:ArrayCollection = new ArrayCollection ([
				{Company:"Adobe", Quarter:1, India:"2 million", Veeranistan:"2 million", Pareestan:"3 million", Licenses:433764538},
				{Company:"IBM", Quarter:1, India:"9 million", Veeranistan:"1 million", Pareestan:"5 million", Licenses:456789002},
				{Company:"KaashifSoft", Quarter:1, India:"99 million", Veeranistan:"99 million", Pareestan:"99 million", Licenses:456712340},
				{Company:"NisheetSoft", Quarter:1, India:"0 million", Veeranistan:"0 million", Pareestan:"0 million", Licenses:456782313},
				{Company:"Microsoft", Quarter:1, India:"6 million", Veeranistan:"5 million", Pareestan:"6 million", Licenses:354216789},
				{Company:"Satyam", Quarter:1, India:"1 million", Veeranistan:"3 million", Pareestan:"2 million", Licenses:325146789},
				{Company:"Subex", Quarter:1, India:"2 million", Veeranistan:"9 million", Pareestan:"1 million", Licenses:321456978},
				{Company:"Infosys", Quarter:1, India:"0.89 million", Veeranistan:"12 million", Pareestan:"4.5 million", Licenses:321475689},        
				{Company:"MCAfee", Quarter:1, India:"3 million", Veeranistan:"5.98 million", Pareestan:"6.2 million", Licenses:321467589},
				{Company:"MPhasis", Quarter:1, India:"2 million", Veeranistan:"1.5 million", Pareestan:"6.7 million", Licenses:123456789},
				{Company:"Symphony", Quarter:1, India:"3.4 million", Veeranistan:"6.1 million", Pareestan:"7.8 million", Licenses:341256789},
				{Company:"Wipro", Quarter:1, India:"5 million", Veeranistan:"2 million", Pareestan:"7 million", Licenses:321654789},
				{Company:"Google", Quarter:1, India:"3 million", Veeranistan:"4 million", Pareestan:"1 million", Licenses:321458769 } ]);
				
				public function createColumnGroups():void {		
					countries.headerText="Countries";
					
					toplevel.headerText="Top Level";
					
					var countriesarr:Array = new Array();
					var toplevelarr:Array = new Array();
					countriesarr.push(india);
					countriesarr.push(pareestan);
					countriesarr.push(veeranistan);
					toplevelarr.push(quarters);
					mydatagrid.dataProvider=mydata;
					countries.children = countriesarr;
					toplevelarr.push(countries);
					toplevel.children=toplevelarr;
					mydatagrid.groupedColumns=[companies, toplevel, licenses]; 
					mydatagrid.dataProvider.refresh();
					companies.dataField="Company";
					quarters.dataField="Quarter";
					licenses.dataField="Licenses";
				}
				
				public function groupedData():void {
					var mygroup:GroupingCollection2 = new GroupingCollection2();
					mygroup.source=mydata;
					var group:Grouping = new Grouping();
					group.fields = [new GroupingField("Company"), new GroupingField("Licenses")];
					group.label = "Company";
					mygroup.grouping = group; 
					mygroup.refresh();
					mydatagrid.dataProvider = mygroup;
					mydatagrid.validateNow();
				}
				
				public function insertColumns():void {			
					var mycols:AdvancedDataGridColumn = new AdvancedDataGridColumn("ggg");
					var mycolsarr:Array = mydatagrid.groupedColumns;
					mycolsarr.push(mycols);
					mydatagrid.groupedColumns = mycolsarr;
				}
				
				public function insertColumngroups():void
				{
					var mycolgroup:AdvancedDataGridColumnGroup = new AdvancedDataGridColumnGroup();
					mycolgroup.headerText = "topmost ";
					var mycolsarr:Array = new Array(mydatagrid.groupedColumns[0]);
					mycolgroup.children = mycolsarr;            
					var tempCols:Array = mydatagrid.groupedColumns.slice(1,mydatagrid.groupedColumns.length); 
					mydatagrid.groupedColumns = [mycolgroup].concat(tempCols); 			
				}
				
				public function hierarchicaldata_setter():void {
					var hierarchs:HierarchicalData = new HierarchicalData();
					hierarchs.source = hierarch_data;
					mydatagrid..dataProvider = hierarchs;
					companies.dataField = "feature";    
					quarters.dataField = "subFeature";
					licenses.dataField = "endDate";
				}
				
				public function vrHeight():void {				
					for(var i:int=0;i<20;i++)
					{
						var rnd:* = Math.random();
						var obj:Object = {Company:"column-A0",Quarter:"column-B"+rnd,India:"column-C"+rnd,Veeranistan:"Column-D"+rnd,Pareestan:"Column-E"+rnd,Licenses:"Column-F"+rnd}
						ac.addItem(obj);
					}
					
					mydatagrid.dataProvider = ac;
					mydatagrid.variableRowHeight = true;
					mydatagrid.wordWrap = true;
				}
				
				public function headerRenderer():void {
					countries.headerRenderer = new ClassFactory(mx.controls.NumericStepper);
					toplevel.headerRenderer = new ClassFactory(mx.controls.TextArea);
					quarters.headerRenderer = new ClassFactory(mx.controls.TextInput);			
				}
				
				public function customHeaderRenderer():void {
					//toplevel.headerRenderer = new ClassFactory(myheads);		
				}
				
				public function visibleColumns():void {
					toplevel.visible = false;
				}
				
				public function headerSkin():void {
					//StyleManager.getStyleDeclaration("AdvancedDataGrid").setStyle("headerHorizontalSeparatorSkin",myhorskin);
				}
				
				public function myStyleFunction(data:Object,col:AdvancedDataGridColumn):Object          {
					return { color:0xFF0000};
				}
				
				public function myFormatting():void {				
					mydatagrid.styleFunction = myStyleFunction;
					mydata.refresh();
					var forms:CurrencyFormatter = new CurrencyFormatter();
					forms.currencySymbol = "$";
					createColumnGroups();
					licenses.formatter = forms;
					mydatagrid.dataProvider.refresh();			
				}
				
				public function myColumnSpan():void {			
					var renders:AdvancedDataGridRendererProvider = new AdvancedDataGridRendererProvider();      
					renders.column = companies;
					var renderarr:Array = new Array();
					renders.dataField = "Company";
					renders.columnSpan = 2;
					renders.renderer = new ClassFactory(mx.controls.NumericStepper);
					renderarr.push(renders);
					mydatagrid.rendererProviders = renderarr;
				}
				
				public function generateXML():void {			
					mydatagrid.dataProvider = comps;
				}
		
			
		]]>
	</fx:Script>
	<fx:Declarations>
		<fx:XMLList id="comps">
			<companylist>
				<Company>AalishaanSoft</Company>
				<Quarter> 1 </Quarter>
				<India>34 million</India>
				<Veeranistan>1.5 million</Veeranistan>
				<Pareestan>5 million</Pareestan>
				<Licenses>321475987</Licenses>
			</companylist>
			<companylist>
				<Company>MughaleAzamSoft</Company>
				<Quarter> 1 </Quarter>
				<India>3.4 million</India>
				<Veeranistan>2 million</Veeranistan>
				<Pareestan>5.4 million</Pareestan>
				<Licenses>321475987</Licenses>
			</companylist>
			<companylist>
				<Company>SheeshMahalSoft</Company>
				<Quarter> 1 </Quarter>
				<India>45 million</India>
				<Veeranistan>15 million</Veeranistan>
				<Pareestan>5.1 million</Pareestan>
				<Licenses>321745987</Licenses>
			</companylist>
			<companylist>
				<Company>AjnabeeSoft</Company>  
				<Quarter> 1 </Quarter> 
				<India>14 million</India>
				<Veeranistan>11 million</Veeranistan> 
				<Pareestan>5.7 million</Pareestan>
				<Licenses>321479587</Licenses>
			</companylist>
		</fx:XMLList>
	</fx:Declarations>
	<mx:Canvas id="box" width="100%" height="100%">
		<mx:AdvancedDataGrid id="mydatagrid" layoutDirection="rtl" />
	</mx:Canvas>
	<mx:TextInput id="ti"/>
</mx:Application>


Thanks,
Justin




Re: New Mustella Failures

Posted by Justin Mclean <ju...@classsoftware.com>.
Hi,

> 1) ADG mirroring.  The failing bitmap shows the text flipped (as if viewed
> in a mirror).  I think mirrored in Flex is supposed to flip everything but
> text widgets so the font glyphs themselves are not mirrored, just laid out
> RTL or LTR depending on the characters.
I did ask about this a while back, the test bitmap is incorrect as far as I can see as it doesn't show the text as RTL. 

> 2) These 3 are all related to a change in DividedBox.
Should now be fixed.

Thanks,
Justin

Re: New Mustella Failures

Posted by Alex Harui <ah...@adobe.com>.
A fourth test is also failing because of the DividedBox changes:
     [java] MarshallPlan/ManagerTests/MP_CursorManager_Tests
MP_CursorManager_DividedBox_compatibility Failed Timed out




On 6/7/13 11:00 AM, "Alex Harui" <ah...@adobe.com> wrote:

>Hi Folks,
>
>On last night's Mac run, some new failures showed up.  If you made changes
>in these areas, please review your work.
>
>1) ADG mirroring.  The failing bitmap shows the text flipped (as if viewed
>in a mirror).  I think mirrored in Flex is supposed to flip everything but
>text widgets so the font glyphs themselves are not mirrored, just laid out
>RTL or LTR depending on the characters.
>     [java] 
>components/AdvancedDataGrid/Properties/advanceddatagrid_columngroup
>use_grouped_data_mirroring Failed CompareBitmap(body:step 3)  compare
>returned[object BitmapData]
>
>
>2) These 3 are all related to a change in DividedBox.
>
>     [java] 
>components/DataGrid/DataGrid_HaloSkin/Bugs/Datagrid_Bug_ResizeHDBox_halo
>datagrid_Bug_157493_halo Failed TypeError: Error #1009: Cannot access a
>property or method of a null object reference.
>     [java] 	at 
>mx.containers::DividedBox/styleChanged()[/Users/aharui/git/flex/master/fle
>x
>-sdk/frameworks/projects/mx/src/mx/containers/DividedBox.as:749]
>     [java] 	at 
>mx.styles::StyleProtoChain$/setStyle()[/Users/aharui/git/flex/master/flex-
>s
>dk/frameworks/projects/framework/src/mx/styles/StyleProtoChain.as:717]
>     [java] 	at 
>mx.core::UIComponent/setStyle()[/Users/aharui/git/flex/master/flex-sdk/fra
>m
>eworks/projects/framework/src/mx/core/UIComponent.as:11162]
>     [java] 	at 
>mx.core::Container/removeEventListener()[/Users/aharui/git/flex/master/fle
>x
>-sdk/frameworks/projects/mx/src/mx/core/Container.as:2474]
>     [java] 	at 
>TestStep/stepComplete()[/Users/aharui/git/flex/master/flex-sdk/mustella/as
>3
>/src/mustella/TestStep.as:164]
>     [java] 	at 
>TestStep/waitEventHandler()[/Users/aharui/git/flex/master/flex-sdk/mustell
>a
>/as3/src/mustella/TestStep.as:151]
>     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
>     [java] 	at flash.events::EventDispatcher/dispatchEvent()
>     [java] 	at 
>mx.managers::SystemManager/mouseEventHandler()[/Users/aharui/git/flex/mast
>e
>r/flex-sdk/frameworks/projects/framework/src/mx/managers/SystemManager.as:
>2
>926]
>     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
>     [java] 	at flash.events::EventDispatcher/dispatchEvent()
>     [java] 	at 
>DispatchMouseEvent/doStep()[/Users/aharui/git/flex/master/flex-sdk/mustell
>a
>/as3/src/mustella/DispatchMouseEvent.as:181]
>     [java] 	at 
>TestStep/execute()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
>/
>mustella/TestStep.as:65]
>     [java] 	at 
>DispatchMouseEvent/execute()[/Users/aharui/git/flex/master/flex-sdk/mustel
>l
>a/as3/src/mustella/DispatchMouseEvent.as:60]
>     [java] 	at 
>TestCase/runSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/sr
>c
>/mustella/TestCase.as:418]
>     [java] 	at 
>TestCase/runBody()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
>/
>mustella/TestCase.as:298]
>     [java] 	at 
>TestCase/runNextSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as
>3
>/src/mustella/TestCase.as:465]
>     [java] 
>     [java] containers/DividedBox/Events/DivBoxEventTester
>div_events_dividerRelease Failed TypeError: Error #1009: Cannot access a
>property or method of a null object reference.
>     [java] 	at 
>mx.containers::DividedBox/styleChanged()[/Users/aharui/git/flex/master/fle
>x
>-sdk/frameworks/projects/mx/src/mx/containers/DividedBox.as:749]
>     [java] 	at 
>mx.styles::StyleProtoChain$/setStyle()[/Users/aharui/git/flex/master/flex-
>s
>dk/frameworks/projects/framework/src/mx/styles/StyleProtoChain.as:717]
>     [java] 	at 
>mx.core::UIComponent/setStyle()[/Users/aharui/git/flex/master/flex-sdk/fra
>m
>eworks/projects/framework/src/mx/core/UIComponent.as:11162]
>     [java] 	at 
>mx.core::Container/removeEventListener()[/Users/aharui/git/flex/master/fle
>x
>-sdk/frameworks/projects/mx/src/mx/core/Container.as:2474]
>     [java] 	at 
>TestStep/stepComplete()[/Users/aharui/git/flex/master/flex-sdk/mustella/as
>3
>/src/mustella/TestStep.as:164]
>     [java] 	at 
>TestStep/waitEventHandler()[/Users/aharui/git/flex/master/flex-sdk/mustell
>a
>/as3/src/mustella/TestStep.as:151]
>     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
>     [java] 	at flash.events::EventDispatcher/dispatchEvent()
>     [java] 	at 
>mx.managers::SystemManager/mouseEventHandler()[/Users/aharui/git/flex/mast
>e
>r/flex-sdk/frameworks/projects/framework/src/mx/managers/SystemManager.as:
>2
>926]
>     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
>     [java] 	at flash.events::EventDispatcher/dispatchEvent()
>     [java] 	at 
>DispatchMouseEvent/doStep()[/Users/aharui/git/flex/master/flex-sdk/mustell
>a
>/as3/src/mustella/DispatchMouseEvent.as:181]
>     [java] 	at 
>TestStep/execute()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
>/
>mustella/TestStep.as:65]
>     [java] 	at 
>DispatchMouseEvent/execute()[/Users/aharui/git/flex/master/flex-sdk/mustel
>l
>a/as3/src/mustella/DispatchMouseEvent.as:60]
>     [java] 	at 
>TestCase/runSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/sr
>c
>/mustella/TestCase.as:418]
>     [java] 	at 
>TestCase/runBody()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
>/
>mustella/TestCase.as:298]
>     [java] 	at 
>TestCase/runNextSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as
>3
>/src/mustella/TestCase.as:465]
>     [java] 
>     [java] containers/DividedBox/Events/DivBoxEventTester_spark
>div_events_dividerRelease_spark Failed TypeError: Error #1009: Cannot
>access a property or method of a null object reference.
>     [java] 	at 
>mx.containers::DividedBox/styleChanged()[/Users/aharui/git/flex/master/fle
>x
>-sdk/frameworks/projects/mx/src/mx/containers/DividedBox.as:749]
>     [java] 	at 
>mx.styles::StyleProtoChain$/setStyle()[/Users/aharui/git/flex/master/flex-
>s
>dk/frameworks/projects/framework/src/mx/styles/StyleProtoChain.as:717]
>     [java] 	at 
>mx.core::UIComponent/setStyle()[/Users/aharui/git/flex/master/flex-sdk/fra
>m
>eworks/projects/framework/src/mx/core/UIComponent.as:11162]
>     [java] 	at 
>mx.core::Container/removeEventListener()[/Users/aharui/git/flex/master/fle
>x
>-sdk/frameworks/projects/mx/src/mx/core/Container.as:2474]
>     [java] 	at 
>TestStep/stepComplete()[/Users/aharui/git/flex/master/flex-sdk/mustella/as
>3
>/src/mustella/TestStep.as:164]
>     [java] 	at 
>TestStep/waitEventHandler()[/Users/aharui/git/flex/master/flex-sdk/mustell
>a
>/as3/src/mustella/TestStep.as:151]
>     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
>     [java] 	at flash.events::EventDispatcher/dispatchEvent()
>     [java] 	at 
>mx.managers::SystemManager/mouseEventHandler()[/Users/aharui/git/flex/mast
>e
>r/flex-sdk/frameworks/projects/framework/src/mx/managers/SystemManager.as:
>2
>926]
>     [java] 	at flash.events::EventDispatcher/dispatchEventFunction()
>     [java] 	at flash.events::EventDispatcher/dispatchEvent()
>     [java] 	at 
>DispatchMouseEvent/doStep()[/Users/aharui/git/flex/master/flex-sdk/mustell
>a
>/as3/src/mustella/DispatchMouseEvent.as:181]
>     [java] 	at 
>TestStep/execute()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
>/
>mustella/TestStep.as:65]
>     [java] 	at 
>DispatchMouseEvent/execute()[/Users/aharui/git/flex/master/flex-sdk/mustel
>l
>a/as3/src/mustella/DispatchMouseEvent.as:60]
>     [java] 	at 
>TestCase/runSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/sr
>c
>/mustella/TestCase.as:418]
>     [java] 	at 
>TestCase/runBody()[/Users/aharui/git/flex/master/flex-sdk/mustella/as3/src
>/
>mustella/TestCase.as:298]
>     [java] 	at 
>TestCase/runNextSteps()[/Users/aharui/git/flex/master/flex-sdk/mustella/as
>3
>/src/mustella/TestCase.as:465]
>     [java] 
>
>