},
response : function (self, id) {
// hide
- if (id < 1) {
+ if (id < 1) {
this.el.hide();
return;
}
- if (!this.get('bug').getValue().length) {
+ if (typeof(this.get('bug').getValue()) != 'object') {
print("ERROR");
- return;
- }
+ return;
+ }
- this.el.hide();
+ this.el.hide();
- var val = this.get('bug').getValue();
- Seed.print(val);
+ //var val = this.get('bug').getValue();
+ // Seed.print(val);
}
},
border_width : 3,
- default_height : 150,
+ default_height : 400,
default_width : 600,
- title : "Project Properties",
+ title : "Select Active Bug",
deletable : true,
modal : true,
show : function(c) {
});
// shouild set path..
*/
+
+
this.el.show_all();
+ this.get('/ok_button').el.set_sensitive(false);
+
+ // block until we return.
+ var run_ret = this.el.run();
+ if (run_ret < 1 ) {
+ return false;
+ }
+ print("RUN RETURN : " + run_ret);
+
+ //print(JSON.stringify(this.get('bug').getValue()));
+ return this.get('bug').getValue();
//this.success = c.success;
},
items : [
changed : function (self) {
var d = this.getValue();
this.get('/view').load(d.description);
+ this.get('/ok_button').el.set_sensitive(true);
}
},
id : "bug",
xtype: GtkSource.Buffer,
listeners : {
changed : function (self) {
+ /*
var s = new Gtk.TextIter();
var e = new Gtk.TextIter();
this.el.get_start_iter(s);
}));
this.get('/LeftPanel.model').changed( str , false);
+ */
}
},
pack : "set_buffer"
},
{
xtype: Gtk.Button,
- pack : "add_action_widget,1",
- label : "OK"
+ label : "Cancel",
+ pack : "add_action_widget,0"
},
{
xtype: Gtk.Button,
- pack : "add_action_widget,0",
- label : "Cancel"
+ id : "ok_button",
+ label : "OK",
+ pack : "add_action_widget,1"
}
]
});