rename the TreeGridCustomColumn to TreeGridRenderColumn and add the column object to the template so its accessible from the renderer

This commit is contained in:
Damien Churchill 2010-01-26 13:11:29 +00:00
parent 0a86a30c2a
commit 744f11e19b
4 changed files with 12 additions and 11 deletions

View file

@ -12,5 +12,5 @@ add_file "TreeGridColumnResizer.js"
add_file "TreeGridNodeUI.js"
add_file "TreeGridLoader.js"
add_file "TreeGridColumns.js"
add_file "TreeGridCustomColumn.js"
add_file "TreeGridRenderColumn.js"
add_file "TreeGrid.js"

View file

@ -1,9 +0,0 @@
Ext.tree.CustomColumn = Ext.extend(Ext.tree.Column, {
constructor: function(c) {
c.tpl = c.tpl || new Ext.XTemplate('{' + c.dataIndex + ':this.format}');
c.tpl.format = c.renderer;
Ext.tree.CustomColumn.superclass.constructor.call(this, c);
}
});
Ext.reg('tgcustomcolumn', Ext.tree.CustomColumn);

View file

@ -0,0 +1,10 @@
Ext.tree.RenderColumn = Ext.extend(Ext.tree.Column, {
constructor: function(c) {
c.tpl = c.tpl || new Ext.XTemplate('{' + c.dataIndex + ':this.format}');
c.tpl.format = c.renderer;
c.tpl.col = this;
Ext.tree.RenderColumn.superclass.constructor.call(this, c);
}
});
Ext.reg('tgrendercolumn', Ext.tree.RenderColumn);

View file

@ -331,7 +331,7 @@ class TopLevel(resource.Resource):
"/js/ext-extensions/TreeGridNodeUI.js",
"/js/ext-extensions/TreeGridLoader.js",
"/js/ext-extensions/TreeGridColumns.js",
"/js/ext-extensions/TreeGridCustomColumn.js",
"/js/ext-extensions/TreeGridRenderColumn.js",
"/js/ext-extensions/TreeGrid.js",
"/config.js",
"/gettext.js",