[extsharp commit] r80 - in trunk: . ExtJS2Parser/ExtJS2Parser ExtJS2Parser/ExtSharp ExtJS2Parser/ExtSharp/Propertie...

1 view
Skip to first unread message

codesite...@google.com

unread,
Jun 21, 2008, 12:16:09 AM6/21/08
to extsharp...@googlegroups.com
Author: teflon114
Date: Fri Jun 20 21:15:02 2008
New Revision: 80

Modified:
trunk/CHANGELOG.txt
trunk/ExtJS2Parser/ExtJS2Parser/SourceConverter.cs
trunk/ExtJS2Parser/ExtSharp/ExtSharpAdapter.debug.js
trunk/ExtJS2Parser/ExtSharp/ExtSharpAdapter.js
trunk/ExtJS2Parser/ExtSharp/Properties/AssemblyInfo.cs
trunk/ExtJS2Samples/SampleScripts/grid/GroupingGridScript.cs
trunk/ExtJS2Samples/Web/App_Scripts/ExtSharp.debug.js
trunk/ExtJS2Samples/Web/App_Scripts/ExtSharp.js
trunk/ExtJS2Samples/Web/App_Scripts/SampleScripts.debug.js
trunk/ExtJS2Samples/Web/App_Scripts/SampleScripts.js
trunk/ExtJS2Samples/Web/Bin/Script/SampleScripts.dll

Log:
* Fixed a bug introduced in ExtJS 2.1
- the problem occured when ExtJS called String.format in the
Date.formatCodeToRegex() function.
this will fail using Script#'s String.format function so I had to
revert it back to using
ExtJS's String.format function

Modified: trunk/CHANGELOG.txt
==============================================================================
--- trunk/CHANGELOG.txt (original)
+++ trunk/CHANGELOG.txt Fri Jun 20 21:15:02 2008
@@ -1,3 +1,9 @@
+06/21/2008 - teflon
+* Fixed a bug introduced in ExtJS 2.1
+ - the problem occured when ExtJS called String.format in the
Date.formatCodeToRegex() function.
+ this will fail using Script#'s String.format function so I had to
revert it back to using
+ ExtJS's String.format function
+
05/24/2008 - teflon
* Updated code to use Script# v0.5.0.0
* Finally think I nailed down inheritance. You have to call the base
class constructor like so:

Modified: trunk/ExtJS2Parser/ExtJS2Parser/SourceConverter.cs
==============================================================================
--- trunk/ExtJS2Parser/ExtJS2Parser/SourceConverter.cs (original)
+++ trunk/ExtJS2Parser/ExtJS2Parser/SourceConverter.cs Fri Jun 20
21:15:02 2008
@@ -147,6 +147,17 @@
sb.AppendLine("// stores a backup of the original method,
so I'll just revert the change back");
sb.AppendLine("// - sscorlib.debug.js, line #564");
sb.AppendLine("String.prototype.replace = String.prototype._replace;");
+ sb.AppendLine();
+ sb.AppendLine("// Revert back to ExtJS String.format
function because Date.formatCodeToRegex() will");
+ sb.AppendLine("// fail using Script#'s String.format function");
+ sb.AppendLine("String.format = function
String$format(format) {");
+ sb.AppendLine(" var args =
Array.prototype.slice.call(arguments, 1);");
+ sb.AppendLine(@" return format.replace(/\{(\d+)\}/g,
function(m, i){");
+ sb.AppendLine(" return args[i];");
+ sb.AppendLine(" });");
+ sb.AppendLine("}");
+ sb.AppendLine();
+ sb.AppendLine();

File.WriteAllText(OutputPath +
@"ExtSharpAdapter.debug.js", sb.ToString());
File.WriteAllText(OutputPath + @"ExtSharpAdapter.js", new JavaScriptMinifier().Minify(sb.ToString()));

Modified: trunk/ExtJS2Parser/ExtSharp/ExtSharpAdapter.debug.js
==============================================================================
--- trunk/ExtJS2Parser/ExtSharp/ExtSharpAdapter.debug.js (original)
+++ trunk/ExtJS2Parser/ExtSharp/ExtSharpAdapter.debug.js Fri Jun 20
21:15:02 2008
@@ -64,3 +64,14 @@
// stores a backup of the original method, so I'll just revert the
change back
// - sscorlib.debug.js, line #564
String.prototype.replace = String.prototype._replace;
+
+// Revert back to ExtJS String.format function because
Date.formatCodeToRegex() will
+// fail using Script#'s String.format function
+String.format = function String$format(format) {
+ var args = Array.prototype.slice.call(arguments, 1);
+ return format.replace(/\{(\d+)\}/g, function(m, i){
+ return args[i];
+ });
+}
+
+

Modified: trunk/ExtJS2Parser/ExtSharp/ExtSharpAdapter.js
==============================================================================
--- trunk/ExtJS2Parser/ExtSharp/ExtSharpAdapter.js (original)
+++ trunk/ExtJS2Parser/ExtSharp/ExtSharpAdapter.js Fri Jun 20 21:15:02 2008
@@ -1,4 +1,4 @@


ExtClass=Ext;Ext.UpdaterClass=Ext.Updater;Ext.SplitBarClass=Ext.SplitBar;Ext.ToolbarClass=Ext.Toolbar;Ext.WindowClass=Ext.Window;Ext.form.ActionClass=Ext.form.Action;Ext.layout.BorderLayoutClass=Ext.layout.BorderLayout;Ext.DomQuery.is_=Ext.DomQuery.is;Ext.Element.is_=Ext.Element.is;Ext.override_=Ext.override;Ext.namespace_=Ext.namespace;Ext.dd.DragDrop.lock_=Ext.dd.DragDrop.lock;Ext.dd.DragDropMgr.lock_=Ext.dd.DragDropMgr.lock;Ext.grid.AbstractSelectionModel.lock_=Ext.grid.AbstractSelectionModel.lock;Ext.form.Action.params_=Ext.form.Action.params;Ext.form.Checkbox.checked_=Ext.form.Checkbox.checked;Ext.grid.ColumnModel.fixed_=Ext.grid.ColumnModel.fixed;Ext.menu.CheckItem.checked_=Ext.menu.CheckItem.checked;Type.prototype._createClass=Type.prototype.createClass;Type.prototype.createClass=function(n,b,i){if(b){var
ct=b.prototype.ctype;var sp=typeof b.superclass!='undefined';if(sp||
(ct&&ct.substring(0,3)=='Ext')){eval('Ext.extend('+n+', b,
this.prototype);');delete this.__basePrototypePending;this.__typeName=n;this.__class=true;this.__baseType=Object;return;}}
this._createClass(n,b,i);}
-String.prototype.replace=String.prototype._replace;
\ No newline at end of file
+String.prototype.replace=String.prototype._replace;String.format=function
String$format(format){var
args=Array.prototype.slice.call(arguments,1);return
format.replace(/\{(\d+)\}/g,function(m,i){return args[i];});}
\ No newline at end of file

Modified: trunk/ExtJS2Parser/ExtSharp/Properties/AssemblyInfo.cs
==============================================================================
--- trunk/ExtJS2Parser/ExtSharp/Properties/AssemblyInfo.cs (original)
+++ trunk/ExtJS2Parser/ExtSharp/Properties/AssemblyInfo.cs Fri Jun 20
21:15:02 2008
@@ -24,7 +24,7 @@
//
// You can specify all the values or you can default the Revision and
Build Numbers
// by using the '*' as shown below:
-[assembly: AssemblyVersion("2.0.2.0")]
-[assembly: AssemblyFileVersion("2.0.2.0")]
+[assembly: AssemblyVersion("2.1.0.1")]
+[assembly: AssemblyFileVersion("2.1.0.1")]

[assembly: ScriptAssembly]

Modified: trunk/ExtJS2Samples/SampleScripts/grid/GroupingGridScript.cs
==============================================================================
--- trunk/ExtJS2Samples/SampleScripts/grid/GroupingGridScript.cs (original)
+++ trunk/ExtJS2Samples/SampleScripts/grid/GroupingGridScript.cs Fri
Jun 20 21:15:02 2008
@@ -42,13 +42,14 @@
new Dictionary("header", "Last Updated", "width",
20, "sortable", true, "renderer", Format.dateRenderer("m/d/Y"), "dataIndex", "lastChange")
};

+
GroupingView view = new GroupingView(new GroupingViewConfig()
.forceFit(true)
.groupTextTpl("{text} ({[values.rs.length]}
{[values.rs.length > 1 ? \"Items\" : \"Item\"]})")
.ToDictionary()
);

- Ext.grid.GridPanel grid = new Ext.grid.GridPanel(new Ext.grid.GridPanelConfig()
+ GridPanel grid = new GridPanel(new GridPanelConfig()
.ds(gds)
.columns(columns)
.view(view)
@@ -59,9 +60,9 @@
.animCollapse(false)
.title("Grouping Example")
.iconCls("icon-grid")
- .renderTo(Document.Body)
.ToDictionary()
);
+ grid.render(Document.Body);
}
private object[] GetData() {
return new object[] {

Modified: trunk/ExtJS2Samples/Web/App_Scripts/ExtSharp.debug.js
==============================================================================
--- trunk/ExtJS2Samples/Web/App_Scripts/ExtSharp.debug.js (original)
+++ trunk/ExtJS2Samples/Web/App_Scripts/ExtSharp.debug.js Fri Jun 20
21:15:02 2008
@@ -44503,3 +44503,14 @@
// stores a backup of the original method, so I'll just revert the
change back
// - sscorlib.debug.js, line #564
String.prototype.replace = String.prototype._replace;
+
+// Revert back to ExtJS String.format function because
Date.formatCodeToRegex() will
+// fail using Script#'s String.format function
+String.format = function String$format(format) {
+ var args = Array.prototype.slice.call(arguments, 1);
+ return format.replace(/\{(\d+)\}/g, function(m, i){
+ return args[i];
+ });
+}
+
+

Modified: trunk/ExtJS2Samples/Web/App_Scripts/ExtSharp.js
==============================================================================
--- trunk/ExtJS2Samples/Web/App_Scripts/ExtSharp.js (original)
+++ trunk/ExtJS2Samples/Web/App_Scripts/ExtSharp.js Fri Jun 20 21:15:02 2008
@@ -666,4 +666,4 @@


ExtClass=Ext;Ext.UpdaterClass=Ext.Updater;Ext.SplitBarClass=Ext.SplitBar;Ext.ToolbarClass=Ext.Toolbar;Ext.WindowClass=Ext.Window;Ext.form.ActionClass=Ext.form.Action;Ext.layout.BorderLayoutClass=Ext.layout.BorderLayout;Ext.DomQuery.is_=Ext.DomQuery.is;Ext.Element.is_=Ext.Element.is;Ext.override_=Ext.override;Ext.namespace_=Ext.namespace;Ext.dd.DragDrop.lock_=Ext.dd.DragDrop.lock;Ext.dd.DragDropMgr.lock_=Ext.dd.DragDropMgr.lock;Ext.grid.AbstractSelectionModel.lock_=Ext.grid.AbstractSelectionModel.lock;Ext.form.Action.params_=Ext.form.Action.params;Ext.form.Checkbox.checked_=Ext.form.Checkbox.checked;Ext.grid.ColumnModel.fixed_=Ext.grid.ColumnModel.fixed;Ext.menu.CheckItem.checked_=Ext.menu.CheckItem.checked;Type.prototype._createClass=Type.prototype.createClass;Type.prototype.createClass=function(n,b,i){if(b){var
ct=b.prototype.ctype;var sp=typeof b.superclass!='undefined';if(sp||
(ct&&ct.substring(0,3)=='Ext')){eval('Ext.extend('+n+', b,
this.prototype);');delete this.__basePrototypePending;this.__typeName=n;this.__class=true;this.__baseType=Object;return;}}
this._createClass(n,b,i);}
-String.prototype.replace=String.prototype._replace;
\ No newline at end of file
+String.prototype.replace=String.prototype._replace;String.format=function
String$format(format){var
args=Array.prototype.slice.call(arguments,1);return
format.replace(/\{(\d+)\}/g,function(m,i){return args[i];});}
\ No newline at end of file

Modified: trunk/ExtJS2Samples/Web/App_Scripts/SampleScripts.debug.js
==============================================================================
--- trunk/ExtJS2Samples/Web/App_Scripts/SampleScripts.debug.js (original)
+++ trunk/ExtJS2Samples/Web/App_Scripts/SampleScripts.debug.js Fri Jun
20 21:15:02 2008
@@ -145,7 +145,7 @@

init: function SampleScripts_grid_ArrayGridScript$init() {
var myData = this._getMyData();
- var ds = new Ext.data.Store(new
Ext.data.StoreConfig().reader(new Ext.data.ArrayReader({}, [ {
name: 'company' }, { name: 'price', type: 'float' }, { name: 'change',
type: 'float' }, { name: 'pctChange', type: 'float' }, {
name: 'lastChange', type: 'date' } ])).toDictionary());
+ var ds = new Ext.data.Store(new
Ext.data.StoreConfig().reader(new Ext.data.ArrayReader({}, [ {
name: 'company' }, { name: 'price', type: 'float' }, { name: 'change',
type: 'float' }, { name: 'pctChange', type: 'float' }, {
name: 'lastChange', type: 'date', dateFormat: 'n/j h:ia' } ])).toDictionary());
ds.loadData(myData);
var colModel = new Ext.grid.ColumnModel([ { id: 'company',
header: 'Company', width: 160, sortable: true, locked: false,
dataIndex: 'company' }, { header: 'Price', width: 75, sortable: true,
renderer: Delegate.create(null, Ext.util.Format.usMoney),
dataIndex: 'price' }, { header: 'Change', width: 75, sortable: true,
renderer: Delegate.create(this, this._change), dataIndex: 'change' }, {
header: '% Change', width: 75, sortable: true, renderer:
Delegate.create(this, this._pctChange), dataIndex: 'pctChange' }, {
header: 'Last Updated', width: 85, sortable: true, renderer:
Ext.util.Format.dateRenderer('m/d/Y'), dataIndex: 'lastChange' } ]);
var grid = new Ext.grid.GridPanel(new
Ext.grid.GridPanelConfig().el('grid-example').ds(ds).cm(colModel).autoExpandColumn('company').height(350).width(600).title('Array Grid').toDictionary());
@@ -283,7 +283,8 @@
var gds = new Ext.data.GroupingStore(new
Ext.data.GroupingStoreConfig().reader(reader).data(this._getData()).sortInfo({
field: 'company', direction: 'ASC' }).groupField('industry').toDictionary());
var columns = [ { id: 'company', header: 'Company', width: 60,
sortable: true, dataIndex: 'company' }, { header: 'Price', width: 20,
sortable: true, renderer: Delegate.create(null,
Ext.util.Format.usMoney), dataIndex: 'price' }, { header: 'Change',
width: 20, sortable: true, dataIndex: 'change', renderer:
Delegate.create(null, Ext.util.Format.usMoney) }, { header: 'Industry',
width: 20, sortable: true, dataIndex: 'industry' }, { header: 'Last
Updated', width: 20, sortable: true, renderer:
Ext.util.Format.dateRenderer('m/d/Y'), dataIndex: 'lastChange' } ];
var view = new Ext.grid.GroupingView(new
Ext.grid.GroupingViewConfig().forceFit(true).groupTextTpl('{text}
({[values.rs.length]} {[values.rs.length > 1 ? \"Items\" : \"Item\"]})').toDictionary());
- var grid = new Ext.grid.GridPanel(new
Ext.grid.GridPanelConfig().ds(gds).columns(columns).view(view).frame(true).width(700).height(400).collapsible(true).animCollapse(false).title('Grouping Example').iconCls('icon-grid').renderTo(document.body).toDictionary());
+ var grid = new Ext.grid.GridPanel(new
Ext.grid.GridPanelConfig().ds(gds).columns(columns).view(view).frame(true).width(700).height(400).collapsible(true).animCollapse(false).title('Grouping Example').iconCls('icon-grid').toDictionary());
+ grid.render(document.body);
},

_getData: function
SampleScripts_grid_GroupingGridScript$_getData() {

Modified: trunk/ExtJS2Samples/Web/App_Scripts/SampleScripts.js
==============================================================================
--- trunk/ExtJS2Samples/Web/App_Scripts/SampleScripts.js (original)
+++ trunk/ExtJS2Samples/Web/App_Scripts/SampleScripts.js Fri Jun 20
21:15:02 2008
@@ -28,7 +28,7 @@
Type.createNamespace('SampleScripts.grid');SampleScripts.grid.ArrayGridScript=function(){}
SampleScripts.grid.ArrayGridScript.main=function(args){ExtClass.onReady(Delegate.create(null,function(){
new SampleScripts.grid.ArrayGridScript().init();}));}
-SampleScripts.grid.ArrayGridScript.prototype={init:function(){var
$0=this.$3();var $1=new Ext.data.Store(new
Ext.data.StoreConfig().reader(new
Ext.data.ArrayReader({},[{name:'company'},{name:'price',type:'float'},{name:'change',type:'float'},{name:'pctChange',type:'float'},{name:'lastChange',type:'date'}])).toDictionary());$1.loadData($0);var
$2=new
Ext.grid.ColumnModel([{id:'company',header:'Company',width:160,sortable:true,locked:false,dataIndex:'company'},{header:'Price',width:75,sortable:true,renderer:Delegate.create(null,Ext.util.Format.usMoney),dataIndex:'price'},{header:'Change',width:75,sortable:true,renderer:Delegate.create(this,this.$1),dataIndex:'change'},{header:'%
Change',width:75,sortable:true,renderer:Delegate.create(this,this.$2),dataIndex:'pctChange'},{header:'Last
Updated',width:85,sortable:true,renderer:Ext.util.Format.dateRenderer('m/d/Y'),dataIndex:'lastChange'}]);var
$3=new Ext.grid.GridPanel(new
Ext.grid.GridPanelConfig().el('grid-example').ds($1).cm($2).autoExpandColumn('company').height(350).width(600).title('Array
Grid').toDictionary());$3.render();($3.getSelectionModel()).selectFirstRow();},$0:function($p0){return '<i>'+$p0+'</i>';},$1:function($p0){if($p0>0){return '<span
style=\"color:green;\">'+$p0+'</span>';}else if($p0<0){return '<span
style=\"color:red;\">'+$p0+'</span>';}return
$p0;},$2:function($p0){if($p0>0){return '<span
style=\"color:green;\">'+$p0+'%</span>';}else if($p0<0){return '<span
style=\"color:red;\">'+$p0+'%</span>';}return
$p0;},$3:function(){return [['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am']];}}
+SampleScripts.grid.ArrayGridScript.prototype={init:function(){var
$0=this.$3();var $1=new Ext.data.Store(new
Ext.data.StoreConfig().reader(new
Ext.data.ArrayReader({},[{name:'company'},{name:'price',type:'float'},{name:'change',type:'float'},{name:'pctChange',type:'float'},{name:'lastChange',type:'date',dateFormat:'n/j
h:ia'}])).toDictionary());$1.loadData($0);var $2=new
Ext.grid.ColumnModel([{id:'company',header:'Company',width:160,sortable:true,locked:false,dataIndex:'company'},{header:'Price',width:75,sortable:true,renderer:Delegate.create(null,Ext.util.Format.usMoney),dataIndex:'price'},{header:'Change',width:75,sortable:true,renderer:Delegate.create(this,this.$1),dataIndex:'change'},{header:'%
Change',width:75,sortable:true,renderer:Delegate.create(this,this.$2),dataIndex:'pctChange'},{header:'Last
Updated',width:85,sortable:true,renderer:Ext.util.Format.dateRenderer('m/d/Y'),dataIndex:'lastChange'}]);var
$3=new Ext.grid.GridPanel(new
Ext.grid.GridPanelConfig().el('grid-example').ds($1).cm($2).autoExpandColumn('company').height(350).width(600).title('Array
Grid').toDictionary());$3.render();($3.getSelectionModel()).selectFirstRow();},$0:function($p0){return '<i>'+$p0+'</i>';},$1:function($p0){if($p0>0){return '<span
style=\"color:green;\">'+$p0+'</span>';}else if($p0<0){return '<span
style=\"color:red;\">'+$p0+'</span>';}return
$p0;},$2:function($p0){if($p0>0){return '<span
style=\"color:green;\">'+$p0+'%</span>';}else if($p0<0){return '<span
style=\"color:red;\">'+$p0+'%</span>';}return
$p0;},$3:function(){return [['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am'],['Verizon
Communications',35.57,0.39,1.11,'9/1 12:00am'],['Wal-Mart Stores,
Inc.',45.45,0.73,1.63,'9/1 12:00am'],['3m Co',71.72,0.02,0.03,'9/1
12:00am'],['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],['Altria Group
Inc',83.81,0.28,0.34,'9/1 12:00am'],['American Express
Company',52.55,0.01,0.02,'9/1 12:00am'],['American International Group,
Inc.',64.13,0.31,0.49,'9/1 12:00am'],['AT&T
Inc.',31.61,-0.48,-1.54,'9/1 12:00am'],['Boeing
Co.',75.43,0.53,0.71,'9/1 12:00am'],['Caterpillar
Inc.',67.27,0.92,1.39,'9/1 12:00am'],['Citigroup,
Inc.',49.37,0.02,0.04,'9/1 12:00am'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'9/1 12:00am'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'9/1 12:00am'],['General Electric
Company',34.14,-0.08,-0.23,'9/1 12:00am'],['General Motors
Corporation',30.27,1.09,3.74,'9/1 12:00am'],['Hewlett-Packard
Co.',36.53,-0.03,-0.08,'9/1 12:00am'],['Honeywell Intl
Inc',38.77,0.05,0.13,'9/1 12:00am'],['Intel
Corporation',19.88,0.31,1.58,'9/1 12:00am'],['International Business
Machines',81.41,0.44,0.54,'9/1 12:00am'],['Johnson &
Johnson',64.72,0.06,0.09,'9/1 12:00am'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'9/1 12:00am'],['McDonald\"s
Corporation',36.76,0.86,2.4,'9/1 12:00am'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'9/1 12:00am'],['Microsoft
Corporation',25.84,0.14,0.54,'9/1 12:00am'],['Pfizer
Inc',27.96,0.4,1.45,'9/1 12:00am'],['The Coca-Cola
Company',45.07,0.26,0.58,'9/1 12:00am'],['The Home Depot,
Inc.',34.64,0.35,1.02,'9/1 12:00am'],['The Procter & Gamble
Company',61.91,0.01,0.02,'9/1 12:00am'],['United Technologies
Corporation',63.26,0.55,0.88,'9/1 12:00am']];}}
SampleScripts.grid.EditGridScript=function(){}
SampleScripts.grid.EditGridScript.main=function(args){ExtClass.onReady(Delegate.create(null,function(){
new SampleScripts.grid.EditGridScript().init();}));}
@@ -40,7 +40,7 @@
SampleScripts.grid.GroupingGridScript=function(){}
SampleScripts.grid.GroupingGridScript.main=function(args){ExtClass.onReady(Delegate.create(null,function(){
new SampleScripts.grid.GroupingGridScript().init();}));}
-SampleScripts.grid.GroupingGridScript.prototype={init:function(){var
$0=new Ext.data.ArrayReader(new
Ext.data.ArrayReaderConfig().toDictionary(),[{name:'company'},{name:'price',type:'float'},{name:'change',type:'float'},{name:'pctChange',type:'float'},{name:'lastChange',type:'date',dateFormat:'n/j
h:ia'},{name:'industry'},{name:'desc'}]);var $1=new
Ext.data.GroupingStore(new
Ext.data.GroupingStoreConfig().reader($0).data(this.$0()).sortInfo({field:'company',direction:'ASC'}).groupField('industry').toDictionary());var
$2=[{id:'company',header:'Company',width:60,sortable:true,dataIndex:'company'},{header:'Price',width:20,sortable:true,renderer:Delegate.create(null,Ext.util.Format.usMoney),dataIndex:'price'},{header:'Change',width:20,sortable:true,dataIndex:'change',renderer:Delegate.create(null,Ext.util.Format.usMoney)},{header:'Industry',width:20,sortable:true,dataIndex:'industry'},{header:'Last
Updated',width:20,sortable:true,renderer:Ext.util.Format.dateRenderer('m/d/Y'),dataIndex:'lastChange'}];var
$3=new Ext.grid.GroupingView(new
Ext.grid.GroupingViewConfig().forceFit(true).groupTextTpl('{text}
({[values.rs.length]} {[values.rs.length > 1 ? \"Items\" :
\"Item\"]})').toDictionary());var $4=new Ext.grid.GridPanel(new
Ext.grid.GridPanelConfig().ds($1).columns($2).view($3).frame(true).width(700).height(400).collapsible(true).animCollapse(false).title('Grouping
Example').iconCls('icon-grid').renderTo(document.body).toDictionary());},$0:function(){return
[['3m Co',71.72,0.02,0.03,'4/2 12:00am','Manufacturing'],['Alcoa
Inc',29.01,0.42,1.47,'4/1 12:00am','Manufacturing'],['Altria Group
Inc',83.81,0.28,0.34,'4/3 12:00am','Manufacturing'],['American Express
Company',52.55,0.01,0.02,'4/8 12:00am','Finance'],['American
International Group, Inc.',64.13,0.31,0.49,'4/1
12:00am','Services'],['AT&T Inc.',31.61,-0.48,-1.54,'4/8
12:00am','Services'],['Boeing Co.',75.43,0.53,0.71,'4/8
12:00am','Manufacturing'],['Caterpillar Inc.',67.27,0.92,1.39,'4/1
12:00am','Services'],['Citigroup, Inc.',49.37,0.02,0.04,'4/4
12:00am','Finance'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'4/1 12:00am','Manufacturing'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'4/3 12:00am','Manufacturing'],['General
Electric Company',34.14,-0.08,-0.23,'4/3
12:00am','Manufacturing'],['General Motors
Corporation',30.27,1.09,3.74,'4/3
12:00am','Automotive'],['Hewlett-Packard Co.',36.53,-0.03,-0.08,'4/3
12:00am','Computer'],['Honeywell Intl Inc',38.77,0.05,0.13,'4/3
12:00am','Manufacturing'],['Intel Corporation',19.88,0.31,1.58,'4/2
12:00am','Computer'],['International Business
Machines',81.41,0.44,0.54,'4/1 12:00am','Computer'],['Johnson &
Johnson',64.72,0.06,0.09,'4/2 12:00am','Medical'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'4/2 12:00am','Finance'],['McDonald\"s
Corporation',36.76,0.86,2.4,'4/2 12:00am','Food'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'4/2 12:00am','Medical'],['Microsoft
Corporation',25.84,0.14,0.54,'4/2 12:00am','Computer'],['Pfizer
Inc',27.96,0.4,1.45,'4/8 12:00am','Services','Medical'],['The Coca-Cola
Company',45.07,0.26,0.58,'4/1 12:00am','Food'],['The Home Depot,
Inc.',34.64,0.35,1.02,'4/8 12:00am','Retail'],['The Procter & Gamble
Company',61.91,0.01,0.02,'4/1 12:00am','Manufacturing'],['United
Technologies Corporation',63.26,0.55,0.88,'4/1
12:00am','Computer'],['Verizon Communications',35.57,0.39,1.11,'4/3
12:00am','Services'],['Wal-Mart Stores, Inc.',45.45,0.73,1.63,'4/3
12:00am','Retail'],['Walt Disney Company (The) (Holding
Company)',29.89,0.24,0.81,'4/1 12:00am','Services']];}}
+SampleScripts.grid.GroupingGridScript.prototype={init:function(){var
$0=new Ext.data.ArrayReader(new
Ext.data.ArrayReaderConfig().toDictionary(),[{name:'company'},{name:'price',type:'float'},{name:'change',type:'float'},{name:'pctChange',type:'float'},{name:'lastChange',type:'date',dateFormat:'n/j
h:ia'},{name:'industry'},{name:'desc'}]);var $1=new
Ext.data.GroupingStore(new
Ext.data.GroupingStoreConfig().reader($0).data(this.$0()).sortInfo({field:'company',direction:'ASC'}).groupField('industry').toDictionary());var
$2=[{id:'company',header:'Company',width:60,sortable:true,dataIndex:'company'},{header:'Price',width:20,sortable:true,renderer:Delegate.create(null,Ext.util.Format.usMoney),dataIndex:'price'},{header:'Change',width:20,sortable:true,dataIndex:'change',renderer:Delegate.create(null,Ext.util.Format.usMoney)},{header:'Industry',width:20,sortable:true,dataIndex:'industry'},{header:'Last
Updated',width:20,sortable:true,renderer:Ext.util.Format.dateRenderer('m/d/Y'),dataIndex:'lastChange'}];var
$3=new Ext.grid.GroupingView(new
Ext.grid.GroupingViewConfig().forceFit(true).groupTextTpl('{text}
({[values.rs.length]} {[values.rs.length > 1 ? \"Items\" :
\"Item\"]})').toDictionary());var $4=new Ext.grid.GridPanel(new
Ext.grid.GridPanelConfig().ds($1).columns($2).view($3).frame(true).width(700).height(400).collapsible(true).animCollapse(false).title('Grouping
Example').iconCls('icon-grid').toDictionary());$4.render(document.body);},$0:function(){return
[['3m Co',71.72,0.02,0.03,'4/2 12:00am','Manufacturing'],['Alcoa
Inc',29.01,0.42,1.47,'4/1 12:00am','Manufacturing'],['Altria Group
Inc',83.81,0.28,0.34,'4/3 12:00am','Manufacturing'],['American Express
Company',52.55,0.01,0.02,'4/8 12:00am','Finance'],['American
International Group, Inc.',64.13,0.31,0.49,'4/1
12:00am','Services'],['AT&T Inc.',31.61,-0.48,-1.54,'4/8
12:00am','Services'],['Boeing Co.',75.43,0.53,0.71,'4/8
12:00am','Manufacturing'],['Caterpillar Inc.',67.27,0.92,1.39,'4/1
12:00am','Services'],['Citigroup, Inc.',49.37,0.02,0.04,'4/4
12:00am','Finance'],['E.I. du Pont de Nemours and
Company',40.48,0.51,1.28,'4/1 12:00am','Manufacturing'],['Exxon Mobil
Corp',68.1,-0.43,-0.64,'4/3 12:00am','Manufacturing'],['General
Electric Company',34.14,-0.08,-0.23,'4/3
12:00am','Manufacturing'],['General Motors
Corporation',30.27,1.09,3.74,'4/3
12:00am','Automotive'],['Hewlett-Packard Co.',36.53,-0.03,-0.08,'4/3
12:00am','Computer'],['Honeywell Intl Inc',38.77,0.05,0.13,'4/3
12:00am','Manufacturing'],['Intel Corporation',19.88,0.31,1.58,'4/2
12:00am','Computer'],['International Business
Machines',81.41,0.44,0.54,'4/1 12:00am','Computer'],['Johnson &
Johnson',64.72,0.06,0.09,'4/2 12:00am','Medical'],['JP Morgan & Chase &
Co',45.73,0.07,0.15,'4/2 12:00am','Finance'],['McDonald\"s
Corporation',36.76,0.86,2.4,'4/2 12:00am','Food'],['Merck & Co.,
Inc.',40.96,0.41,1.01,'4/2 12:00am','Medical'],['Microsoft
Corporation',25.84,0.14,0.54,'4/2 12:00am','Computer'],['Pfizer
Inc',27.96,0.4,1.45,'4/8 12:00am','Services','Medical'],['The Coca-Cola
Company',45.07,0.26,0.58,'4/1 12:00am','Food'],['The Home Depot,
Inc.',34.64,0.35,1.02,'4/8 12:00am','Retail'],['The Procter & Gamble
Company',61.91,0.01,0.02,'4/1 12:00am','Manufacturing'],['United
Technologies Corporation',63.26,0.55,0.88,'4/1
12:00am','Computer'],['Verizon Communications',35.57,0.39,1.11,'4/3
12:00am','Services'],['Wal-Mart Stores, Inc.',45.45,0.73,1.63,'4/3
12:00am','Retail'],['Walt Disney Company (The) (Holding
Company)',29.89,0.24,0.81,'4/1 12:00am','Services']];}}
SampleScripts.grid.PagingGridScript=function(){}
SampleScripts.grid.PagingGridScript.main=function(args){ExtClass.onReady(Delegate.create(null,function(){
new SampleScripts.grid.PagingGridScript().init();}));}

Modified: trunk/ExtJS2Samples/Web/Bin/Script/SampleScripts.dll
==============================================================================
Binary files. No diff available.

Reply all
Reply to author
Forward
0 new messages