Upgrade to ExtJS 3.0.3 - Released 10/11/2009
[extjs.git] / examples / spinner / spinner.js
1 /*!
2  * Ext JS Library 3.0.3
3  * Copyright(c) 2006-2009 Ext JS, LLC
4  * licensing@extjs.com
5  * http://www.extjs.com/license
6  */
7 Ext.onReady(function(){\r
8     var simple = new Ext.FormPanel({\r
9         labelWidth: 40, // label settings here cascade unless overridden\r
10         frame: true,\r
11         title: 'Simple Form',\r
12         bodyStyle: 'padding:5px 5px 0',\r
13         width: 210,\r
14         defaults: {width: 135},\r
15         defaultType: 'textfield',\r
16 \r
17         items: [\r
18             new Ext.ux.form.SpinnerField({\r
19                 fieldLabel: 'Age',\r
20                 name: 'age'\r
21             }),\r
22             {\r
23                 xtype: 'spinnerfield',\r
24                 fieldLabel: 'Test',\r
25                 name: 'test',\r
26                 minValue: 0,\r
27                 maxValue: 100,\r
28                 allowDecimals: true,\r
29                 decimalPrecision: 1,\r
30                 incrementValue: 0.4,\r
31                 alternateIncrementValue: 2.1,\r
32                 accelerate: true\r
33             }\r
34         ]\r
35     });\r
36 \r
37     simple.render('form-ct');\r
38 });\r