resources/RooUsage.txt
[app.Builder.js] / old-javascript / XObjectBase / GtkTreeStore.js
1
2 //<Script type="Text/javascript">
3
4 XObject = imports.XObject.XObject
5  
6 GObject = imports.gi.GObject;
7  
8 GtkTreeStore = XObject.define(
9     function(cfg) {
10         this.columns = cfg.columns = cfg.columns || false;
11         delete cfg.columns;
12         XObject.call(this, cfg);
13        
14        
15     }, 
16     XObject,
17     {
18         pack : 'set_model',
19         init : function() 
20         {
21             XObject.prototype.init.call(this);
22             
23             if (!this.columns) { 
24                 
25                 this.el.set_column_types ( 6, [
26                     GObject.TYPE_STRING, 
27                     GObject.TYPE_STRING, 
28                     GObject.TYPE_STRING, 
29                     GObject.TYPE_STRING, 
30                     GObject.TYPE_STRING, 
31                     GObject.TYPE_STRING 
32                 ] );
33             } else {
34                  this.el.set_column_types ( this.columns.length, this.columns);
35                   
36                 
37             }
38             
39             
40         }
41     }
42 );