1 Gilbert.lib.ui.DjangoForm = Ext.extend(Ext.FormPanel, {
2 initComponent: function () {
3 /*if (this.djangoFields) {
6 Gilbert.lib.ui.DjangoForm.superclass.initComponent.call(this);
8 /* initDjangoForm: function () {
9 this.items = this.items || [];
10 Ext.each(this.djangoFields, this.addDjangoField, this);
12 addDjangoField: function(field, index, all) {
13 this.items.push(Gilbert.lib.ui.DjangoFormHelper.get_field_converter(field.type)(field));
18 Gilbert.lib.ui.HTMLWindow = Ext.extend(Ext.Window, {
19 html_source: undefined,
20 onRender: function() {
21 if (this.html_source) {
26 Gilbert.lib.ui.HTMLWindow.superclass.onRender.apply(this, arguments);
27 var iframe = this.body.dom;
28 var doc = iframe.document;
29 if (iframe.contentDocument) {
30 doc = iframe.contentDocument;
31 } else if (iframe.contentWindow) {
32 doc = iframe.contentWindow.document;
35 doc.writeln(this.html_source);
38 Gilbert.lib.ui.HTMLWindow.superclass.onRender.apply(this, arguments);