From 80219ed2bbfebc1a227f7b75f6d62cc37d670f38 Mon Sep 17 00:00:00 2001 From: Alan Knowles Date: Thu, 4 Nov 2010 11:20:28 +0800 Subject: [PATCH] Sample/Editor.js --- Sample/Editor.js | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/Sample/Editor.js b/Sample/Editor.js index 3be3ec7a5..9c3864b7e 100644 --- a/Sample/Editor.js +++ b/Sample/Editor.js @@ -12,15 +12,6 @@ console = imports.console; XObject = imports.XObject.XObject; Editor=new XObject({ xtype: Gtk.Window, - save : function (self, event) { - if (!this.get('/Editor.RightEditor').save()) { - // no hiding with errors. - return true; - } - this.get('/Editor').activePath = false; - this.el.hide(); - return true; - }, listeners : { delete_event : function (self, event) { if (!this.get('/Editor.RightEditor').save()) { @@ -47,8 +38,14 @@ Editor=new XObject({ id : "EditorWindow", title : "Application Builder - Editor", width_request : 500, - : function() { - return this.get('/Editor.RightEditor').save(); + save : function (self, event) { + if (!this.get('/Editor.RightEditor').save()) { + // no hiding with errors. + return true; + } + this.get('/Editor').activePath = false; + this.el.hide(); + return true; }, init : function() { XObject.prototype.init.call(this); -- 2.39.2