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