You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by cf...@apache.org on 2012/12/07 22:17:51 UTC
svn commit: r1418481 [3/3] - in
/incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid:
Interaction/ Properties/ Properties/Baselines/ SWFs/
Modified: incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/Baselines/column_withRenderer_test001_lastPage.png
URL: http://svn.apache.org/viewvc/incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/Baselines/column_withRenderer_test001_lastPage.png?rev=1418481&r1=1418480&r2=1418481&view=diff
==============================================================================
Binary files - no diff available.
Modified: incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/Baselines/column_withRenderer_test001_page1.png
URL: http://svn.apache.org/viewvc/incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/Baselines/column_withRenderer_test001_page1.png?rev=1418481&r1=1418480&r2=1418481&view=diff
==============================================================================
Binary files - no diff available.
Modified: incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_Properties_editable.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_Properties_editable.mxml?rev=1418481&r1=1418480&r2=1418481&view=diff
==============================================================================
--- incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_Properties_editable.mxml (original)
+++ incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_Properties_editable.mxml Fri Dec 7 21:17:50 2012
@@ -1261,26 +1261,27 @@
<TestCase testID="Mirroring_rtl_editor_test1" keywords="[DataGrid, Mirroring]" description="verify mirroring layout=rtl, datagrid displays editors as expected">
<setup>
- <ResetComponent target="dataGrid2" className="components.DataGrid_editable_comp1" waitEvent="updateComplete"/>
- <SetProperty target="dataGrid2" propertyName="height" value="200" waitEvent="updateComplete" waitTarget="dataGrid2" />
- <SetProperty target="dataGrid2" propertyName="width" value="450" waitEvent="updateComplete" waitTarget="dataGrid2" />
- <SetProperty target="dataGrid2" propertyName="dataProvider" valueExpression="value=FlexGlobals.topLevelApplication.dataGrid2.dp2" waitEvent="enterFrame" waitTarget="stage" />
- <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="2"/>
+ <ResetComponent target="dataGrid2" className="components.DataGrid_editable_comp1" waitEvent="updateComplete"/>
+ <SetProperty target="dataGrid2" propertyName="height" value="200" waitEvent="updateComplete" waitTarget="dataGrid2" />
+ <SetProperty target="dataGrid2" propertyName="width" value="450" waitEvent="updateComplete" waitTarget="dataGrid2" />
+ <SetProperty target="dataGrid2" propertyName="dataProvider" valueExpression="value=FlexGlobals.topLevelApplication.dataGrid2.dp2" waitEvent="enterFrame" waitTarget="stage" />
+ <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="2"/>
+
</setup>
<body>
<SetStyle target="dataGrid2" styleName="layoutDirection" value="rtl" waitEvent="updateComplete" waitTarget="dataGrid2" />
- <SetStyle target="dataGrid2" styleName="direction" value="rtl" waitEvent="updateComplete" waitTarget="dataGrid2" />
- <!-- check editor layout, check input for editor, using the one no text insertion -->
- <RunCode code="FlexGlobals.topLevelApplication.dataGrid2.setFocus()" waitEvent="focusIn" waitTarget="dataGrid2"/>
-
- <AssertMethodValue method="value=FlexGlobals.topLevelApplication.dataGrid2.setSelectedCell(0,1)" value="true"/>
-
- <DispatchMouseClickEvent target="dataGrid2.grid" localX="200" localY="10" waitEvent="click" waitTarget="dataGrid2"/>
- <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="2"/>
- <CompareBitmap url="../Properties/baselines/$testID.png" numColorVariances="20" maxColorVariance="20" target="dataGrid2"/>
+ <SetStyle target="dataGrid2" styleName="direction" value="rtl" waitEvent="updateComplete" waitTarget="dataGrid2" />
+ <!-- check editor layout, check input for editor, using the one no text insertion -->
+ <RunCode code="FlexGlobals.topLevelApplication.dataGrid2.setFocus()" waitEvent="focusIn" waitTarget="dataGrid2"/>
+
+ <AssertMethodValue method="value=FlexGlobals.topLevelApplication.dataGrid2.setSelectedCell(0,1)" value="true"/>
+
+ <DispatchMouseClickEvent target="dataGrid2.grid" localX="200" localY="10" waitEvent="click" waitTarget="dataGrid2"/>
+ <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="2"/>
+ <CompareBitmap url="../Properties/baselines/$testID.png" numColorVariances="20" maxColorVariance="20" target="dataGrid2"/>
+
</body>
- </TestCase>
-
+ </TestCase>
<TestCase testID="Mirroring_rtl_editing_test1" keywords="[DataGrid, Mirroring]" description="verify mirroring layout=rtl, input text, verify input is in right layout">
<setup>
<ResetComponent target="dataGrid3" className="components.DataGrid_editable_size" waitEvent="updateComplete"/>
@@ -1698,4 +1699,4 @@
</body>
</TestCase>
</testCases>
-</UnitTester>
+</UnitTester>
\ No newline at end of file
Modified: incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_Properties_sortable.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_Properties_sortable.mxml?rev=1418481&r1=1418480&r2=1418481&view=diff
==============================================================================
--- incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_Properties_sortable.mxml (original)
+++ incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_Properties_sortable.mxml Fri Dec 7 21:17:50 2012
@@ -50,7 +50,6 @@
import spark.components.DataGrid;
import spark.components.gridClasses.GridSelectionMode;
import spark.components.gridClasses.GridColumn;
- import spark.components.gridClasses.IGridItemRenderer;
import spark.events.GridSortEvent;
import components.*;
@@ -59,12 +58,24 @@
public var tobeCheckedCells:ArrayList;
public var arrList:ArrayList;
public var rowsHolder:ArrayList=new ArrayList();
- public var indices:Vector.<int>;
- public var xmlListColl:XMLListCollection;
- public var temp:String="";
- public var vTemp:Vector.<int>=Vector.<int>([0,1,2]);
- public var vTemp2:Vector.<int>;
- public var newItem:Object={index:101, firstName:"New Name",lastName:"Earl",food:"Almonds",drink:"DrinkD",imageURL:"../../../../../Assets/Images/smallbluerect.jpg", numberValue:3, birthDay:"2004/08/08" };
+ public var indices:Vector.<int>;
+ public var xmlListColl:XMLListCollection;
+ public var temp:String="";
+ public var vTemp:Vector.<int>=Vector.<int>([0,1,2]);
+ public var vTemp2:Vector.<int>;
+ public var newItem:Object={index:101, firstName:"New Name",lastName:"Earl",food:"Almonds",drink:"DrinkD",imageURL:"../../../../../Assets/Images/smallbluerect.jpg", numberValue:3, birthDay:"2004/08/08" };
+
+
+
+ /**
+ * this method is to set a editorClass on a dataGrid based on columnIndex
+ */
+ public function setCellEditorOnColumn(dg:DataGrid, editorClass:Class, index:int):void
+ {
+ var gc:GridColumn=(GridColumn)(dg.columns.getItemAt(index));
+ gc.itemEditor=new ClassFactory(editorClass);
+ gc.editable=true;
+ }
}
]]>
@@ -956,36 +967,33 @@
<AssertMethodValue method="value=FlexGlobals.topLevelApplication.dg1.selectionContainsCell(4,1)" value="false"/>
</body>
- </TestCase>
-
- <TestCase testID="column_withRenderer_test001" keywords="[DataGrid, Property, Sortable]" description="verify after sorting, column with renderer should show updated, sorted data">
- <setup>
- <ResetComponent target="dg3" className="components.DataGrid_Custom_IRs2" waitEvent="updateComplete"/>
- <RunCode code="var headerRenderer:IGridItemRenderer = dg3.columnHeaderGroup.getHeaderRendererAt(1)"/>
- </setup>
- <body>
- <DispatchMouseClickEvent target="headerRenderer" localX="{headerRenderer.x + 5}" localY="{headerRenderer.y + 5}" waitEvent="click"/>
- <WaitForLayoutManager/>
- <CompareBitmap url="../Properties/baselines/$testID_page1.png" numColorVariances="20" maxColorVariance="20" target="dg3" />
-
- <RunCode code="FlexGlobals.topLevelApplication.dg3.ensureCellIsVisible(FlexGlobals.topLevelApplication.dg3.dataProvider.length-1)" />
- <WaitForLayoutManager/>
- <CompareBitmap url="../Properties/baselines/$testID_lastPage.png" numColorVariances="20" maxColorVariance="20" target="dg3" />
-
- <!-- reverse sort -->
- <!--DispatchMouseClickEvent target="dg3.columnHeaderGroup" localX="200" localY="10" waitEvent="click" waitTarget="dg3"/-->
- <DispatchMouseClickEvent target="headerRenderer" localX="{headerRenderer.x + 5}" localY="{headerRenderer.y + 5}" waitEvent="click"/>
- <WaitForLayoutManager/>
-
- <!-- sort again, back to the first sort state-->
- <DispatchMouseClickEvent target="headerRenderer" localX="{headerRenderer.x + 5}" localY="{headerRenderer.y + 5}" waitEvent="click"/>
- <WaitForLayoutManager/>
-
- <RunCode code="FlexGlobals.topLevelApplication.dg3.ensureCellIsVisible(FlexGlobals.topLevelApplication.dg3.dataProvider.length-1)" />
- <WaitForLayoutManager/>
- <CompareBitmap url="../Properties/baselines/$testID_lastPage.png" numColorVariances="20" maxColorVariance="20" target="dg3" />
-
- </body>
+ </TestCase>
+ <TestCase testID="column_withRenderer_test001" keywords="[DataGrid, Property, Sortable]" description="verify after sorting, column with renderer should show updated, sorted data">
+ <setup>
+ <ResetComponent target="dg3" className="components.DataGrid_Custom_IRs2" waitEvent="updateComplete"/>
+ </setup>
+ <body>
+ <DispatchMouseClickEvent target="dg3.columnHeaderGroup" localX="200" localY="10" waitEvent="click" waitTarget="dg3"/>
+ <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="4"/>
+ <CompareBitmap url="../Properties/baselines/$testID_page1.png" numColorVariances="20" maxColorVariance="20" target="dg3" />
+
+ <RunCode code="FlexGlobals.topLevelApplication.dg3.ensureCellIsVisible(FlexGlobals.topLevelApplication.dg3.dataProvider.length-1)" />
+ <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="4"/>
+ <CompareBitmap url="../Properties/baselines/$testID_lastPage.png" numColorVariances="20" maxColorVariance="20" target="dg3" />
+
+ <!-- reverse sort -->
+ <DispatchMouseClickEvent target="dg3.columnHeaderGroup" localX="200" localY="10" waitEvent="click" waitTarget="dg3"/>
+ <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="4"/>
+
+ <!-- sort again, back to the first sort state-->
+ <DispatchMouseClickEvent target="dg3.columnHeaderGroup" localX="200" localY="10" waitEvent="click" waitTarget="dg3"/>
+ <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="4"/>
+
+ <RunCode code="FlexGlobals.topLevelApplication.dg3.ensureCellIsVisible(FlexGlobals.topLevelApplication.dg3.dataProvider.length-1)" />
+ <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="4"/>
+ <CompareBitmap url="../Properties/baselines/$testID_lastPage.png" numColorVariances="20" maxColorVariance="20" target="dg3" />
+
+ </body>
</TestCase>
@@ -1440,4 +1448,4 @@
</body>
</TestCase>
</testCases>
-</UnitTester>
+</UnitTester>
\ No newline at end of file
Modified: incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_dataProvider_test002.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_dataProvider_test002.mxml?rev=1418481&r1=1418480&r2=1418481&view=diff
==============================================================================
--- incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_dataProvider_test002.mxml (original)
+++ incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/Properties/DataGrid_dataProvider_test002.mxml Fri Dec 7 21:17:50 2012
@@ -130,9 +130,9 @@
<body>
<AssertMethodValue method="value=FlexGlobals.topLevelApplication.dg7.requireSelection" value="true" />
<RunCode code="FlexGlobals.topLevelApplication.insertItems(FlexGlobals.topLevelApplication.dg7,0)"/>
- <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="2"/>
- <CompareBitmap url="../Properties/baselines/$testID.png" numColorVariances="20" maxColorVariance="20" target="dg7" />
- <CompareBitmap url="../Properties/baselines/$testID_label7.png" numColorVariances="20" maxColorVariance="20" target="label7" />
+ <WaitForEvent target="stage" eventName="enterFrame" numExpectedEvents="2"/>
+ <CompareBitmap url="../Properties/baselines/$testID.png" numColorVariances="20" maxColorVariance="20" target="dg7" />
+
</body>
</TestCase>
<TestCase testID="dataProvider_columnNodata_test1" keywords="[DataGrid, Property, dataProvider]" description="dataGrid has a column not data mapping">
@@ -624,4 +624,4 @@
</body>
</TestCase>
</testCases>
-</UnitTester>
+</UnitTester>
\ No newline at end of file
Modified: incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/SWFs/DataGrid_basic_001.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/SWFs/DataGrid_basic_001.mxml?rev=1418481&r1=1418480&r2=1418481&view=diff
==============================================================================
--- incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/SWFs/DataGrid_basic_001.mxml (original)
+++ incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/SWFs/DataGrid_basic_001.mxml Fri Dec 7 21:17:50 2012
@@ -22,7 +22,7 @@
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
xmlns:local="*" xmlns:comps="components.*"
- width="800" height="1500">
+ width="800" height="800">
<fx:Style>
@namespace s "library://ns.adobe.com/flex/spark";
@namespace mx "library://ns.adobe.com/flex/mx";
@@ -560,7 +560,6 @@
<s:HorizontalLayout/>
</s:layout>
<s:VGroup>
- <comps:DataGrid_Custom_IRs2 id="dg3"/>
<s:Label id="label1" text="label holder" height="100"/>
<s:VGroup id="vg" height="{dataGrid.height+25}">
<comps:DataGrid_comp1 id="dataGrid" />
@@ -571,10 +570,11 @@
<comps:DataGrid_sort_noData id="dg1" />
<comps:DataGrid_no_explicit_columns id="dg2" />
</s:HGroup>
+ <comps:DataGrid_Custom_IRs2 id="dg3"/>
</s:VGroup>
<s:HGroup>
<comps:DataGrid_editable_comp1 id="dg4"/>
<comps:DataGrid_sort_locale id="dg5" />
</s:HGroup>
-</s:Application>
+</s:Application>
\ No newline at end of file
Modified: incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/SWFs/DataGrid_basic_002.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/SWFs/DataGrid_basic_002.mxml?rev=1418481&r1=1418480&r2=1418481&view=diff
==============================================================================
--- incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/SWFs/DataGrid_basic_002.mxml (original)
+++ incubator/flex/sdk/branches/develop/mustella/tests/gumbo/components/DataGrid/SWFs/DataGrid_basic_002.mxml Fri Dec 7 21:17:50 2012
@@ -470,10 +470,9 @@
<s:Label text="dataProvider is null " />
<s:DataGrid id="dg4" dataProvider="{null}" />
<s:DataGrid id="dg7" requireSelection="true"/>
- <s:Label id="label7" text="{dg7.width} x {dg7.height}"/>
<comps:DataGrid_dp_none id="dg5"/>
<!-- DG: has more columns, first column has no data matching -->
<comps:DataGrid_dp_columns id="dg6"/>
-</s:Application>
+</s:Application>
\ No newline at end of file