Upgrade to ExtJS 4.0.7 - Released 10/19/2011
[extjs.git] / examples / dd / dragdropzones.js
index 7d481ce..912598c 100644 (file)
@@ -1,3 +1,17 @@
+/*
+
+This file is part of Ext JS 4
+
+Copyright (c) 2011 Sencha Inc
+
+Contact:  http://www.sencha.com/contact
+
+GNU General Public License Usage
+This file may be used under the terms of the GNU General Public License version 3.0 as published by the Free Software Foundation and appearing in the file LICENSE included in the packaging of this file.  Please review the following information to ensure the GNU General Public License version 3.0 requirements will be met: http://www.gnu.org/copyleft/gpl.html.
+
+If you are unsure which license is appropriate for your use, please contact the sales department at http://www.sencha.com/contact.
+
+*/
 Ext.require(['*']);
 
 Ext.onReady(function() {
@@ -9,8 +23,8 @@ Ext.onReady(function() {
         telephone: '555 1234 123'
     }, {
         insuranceCode: '22222',
-        name: 'Fred West',
-        address: 'Cromwell Street',
+        name: 'Fred Bansod',
+        address: 'Van Ness',
         telephone: '666 666 666'
     }, {
         insuranceCode: '33333',
@@ -109,15 +123,19 @@ Ext.onReady(function() {
         width: 920,
         height: 500,
         closeAction: 'hide',
-        renderTpl: [
-            '<textarea readonly class="{baseCls}-body<tpl if="bodyCls"> {bodyCls}</tpl><tpl if="frame"> {baseCls}-body-framed</tpl><tpl if="ui"> {baseCls}-body-{ui}</tpl>"<tpl if="bodyStyle"> style="{bodyStyle}"</tpl>></div>'
+        layout: 'fit',
+        items: [
+            {
+                xtype: 'textarea',
+                itemId: 'srcTextArea'
+            }
         ],
         listeners: {
             render: function(w) {
                 Ext.Ajax.request({
                     url: 'dragdropzones.js',
                     success: function(r) {
-                        w.body.dom.value = r.responseText;
+                        w.down('#srcTextArea').setValue(r.responseText);
                     }
                 });
             }
@@ -290,3 +308,4 @@ function initializeHospitalDropZone(v) {
         }
     });
 }
+