git.ithinksw.org
/
extjs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Upgrade to ExtJS 4.0.0 - Released 04/26/2011
[extjs.git]
/
examples
/
form
/
anchoring.js
diff --git
a/examples/form/anchoring.js
b/examples/form/anchoring.js
index
dcad675
..
9a9a1b1
100644
(file)
--- a/
examples/form/anchoring.js
+++ b/
examples/form/anchoring.js
@@
-1,15
+1,17
@@
-/*!
- * Ext JS Library 3.3.1
- * Copyright(c) 2006-2010 Sencha Inc.
- * licensing@sencha.com
- * http://www.sencha.com/license
- */
+Ext.require([
+ 'Ext.form.*',
+ 'Ext.window.Window'
+]);
+
Ext.onReady(function() {
Ext.onReady(function() {
- var form = new Ext.form.FormPanel({
- baseCls: 'x-plain',
- labelWidth: 55,
- url:'save-form.php',
+ var form = Ext.create('Ext.form.Panel', {
+ border: false,
+ fieldDefaults: {
+ labelWidth: 55
+ },
+ url: 'save-form.php',
defaultType: 'textfield',
defaultType: 'textfield',
+ bodyPadding: 5,
items: [{
fieldLabel: 'Send To',
items: [{
fieldLabel: 'Send To',
@@
-23,20
+25,18
@@
Ext.onReady(function() {
xtype: 'textarea',
hideLabel: true,
name: 'msg',
xtype: 'textarea',
hideLabel: true,
name: 'msg',
- anchor: '100% -
53
' // anchor width by percentage and height by raw adjustment
+ anchor: '100% -
47
' // anchor width by percentage and height by raw adjustment
}]
});
}]
});
- var win
dow = new Ext.Window(
{
+ var win
= Ext.create('Ext.window.Window',
{
title: 'Resize Me',
width: 500,
height:300,
minWidth: 300,
minHeight: 200,
layout: 'fit',
title: 'Resize Me',
width: 500,
height:300,
minWidth: 300,
minHeight: 200,
layout: 'fit',
- plain:true,
- bodyStyle:'padding:5px;',
- buttonAlign:'center',
+ plain: true,
items: form,
buttons: [{
items: form,
buttons: [{
@@
-46,5
+46,5
@@
Ext.onReady(function() {
}]
});
}]
});
- win
dow
.show();
+ win.show();
});
\ No newline at end of file
});
\ No newline at end of file