From 2ef8651bd5d8c1782abebf2576cb8903af33044a Mon Sep 17 00:00:00 2001 From: Alan Knowles Date: Thu, 2 Dec 2010 07:56:01 +0800 Subject: [PATCH] XObjectBase/GtkTreeStore.js --- XObjectBase/GtkTreeStore.js | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/XObjectBase/GtkTreeStore.js b/XObjectBase/GtkTreeStore.js index ebb828a4d..5003bec46 100644 --- a/XObjectBase/GtkTreeStore.js +++ b/XObjectBase/GtkTreeStore.js @@ -16,20 +16,18 @@ GtkListStore = XObject.define( }, XObject, { - pack : false, + pack : 'set_model', init : function() { - // this is done before pack? - this.el = new Gtk.TreeViewColumn(); - this.parent.el.append_column(this.el); - XObject.prototype.init.call(this); - - if (this.items.length) { - this.el.add_attribute(this.items[0].el , 'markup', 4 ); - } - - + this.el.set_column_types ( 6, [ + GObject.TYPE_STRING, + GObject.TYPE_STRING, + GObject.TYPE_STRING, + GObject.TYPE_STRING, + GObject.TYPE_STRING, + GObject.TYPE_STRING + ] ); } } -- 2.39.2