3 Pango = imports.gi.Pango;
4 GLib = imports.gi.GLib;
6 GObject = imports.gi.GObject;
7 GtkSource = imports.gi.GtkSource;
8 WebKit = imports.gi.WebKit;
10 GtkClutter = imports.gi.GtkClutter;
12 console = imports.console;
13 XObject = imports.XObject.XObject;
17 destroy_event : function (self, event) {
21 response : function (self, id) {
27 if (!this.get('bug').getValue().length) {
34 var val = this.get('bug').getValue();
41 title : "Project Properties",
50 /*[ 'xtype' ].forEach(function(k) {
51 _this.get(k).setValue(typeof(c[k]) == 'undefined' ? '' : c[k]);
56 this.success = c.success;
61 pack : function(p,e) {
62 p.el.get_content_area().add(e.el)
67 pack : "pack_start,false,true,3",
71 label : "Select Active Bug:",
72 pack : "pack_start,false,true,3"
77 pack : "pack_end,true,true,3",
78 getValue : function() {
79 var ix = this.el.get_active();
83 return this.get('model').data[ix].xtype;
86 XObject.prototype.init.call(this);
87 this.el.add_attribute(this.items[0].el , 'markup', 1 );
89 setValue : function(v)
93 this.get('model').data.forEach(function(n, ix) {
102 xtype: Gtk.CellRendererText,
106 xtype: Gtk.ListStore,
110 XObject.prototype.init.call(this);
112 this.el.set_column_types ( 2, [
113 GObject.TYPE_STRING, // real key
114 GObject.TYPE_STRING // real type
118 var Ticket = imports.tests.tickets.Ticket;
120 var data = Tickets.fetchBugs("http://www.roojs.com/mtrack/index.php/Gitlive/web.hex");
122 { xtype: 'Roo', desc : "Roo Project" },
123 { xtype: 'Gtk', desc : "Gtk Project" },
124 //{ xtype: 'JS', desc : "Javascript Class" }
127 this.loadData(this.data);
130 loadData : function (data) {
132 var iter = new Gtk.TreeIter();
134 data.forEach(function(p) {
139 el.set_value(iter, 0, p.id);
140 el.set_value(iter, 1, '#' + p.id + p.name );
155 pack : "add_action_widget,1",
160 pack : "add_action_widget,0",
166 XObject.cache['/FixBug'] = FixBug;