+ "* init" : [
+ "{",
+ "\tvar ev = new Gtk.EventControllerKey();",
+ "\tev.propagation_phase = Gtk.PropagationPhase.CAPTURE;",
+ "\t// my vars (dec)",
+ "",
+ "\t// set gobject values",
+ "",
+ "\t//listeners",
+ "\tev.key_released.connect( (keyval, keycode, state) => {",
+ "\t",
+ "\t\t// GLib.debug(\"key pressed %d\", (int)keycode);",
+ "\t\tif (keycode != 9) {",
+ "\t\t\treturn ;",
+ "\t\t}",
+ "\t\tif (BuilderApplication.windows.size < 2 && ",
+ "\t\t\t_this.win.windowstate.file == null",
+ "\t\t) { ",
+ "\t\t\tBuilderApplication.singleton(null).quit();",
+ "\t\t\treturn ;",
+ "\t\t}",
+ "\t",
+ "\t\t_this.el.hide();",
+ "\t\t",
+ "\t\t if (_this.win.windowstate.file == null) {\t\t ",
+ "\t\t\tBuilderApplication.removeWindow(_this.win);",
+ "\t\t\t ",
+ "\t\t}",
+ "\t",
+ "\t\treturn ;",
+ "\t});",
+ "\tev.ref(); //?? needed?",
+ "\t(this.el as Gtk.Widget).add_controller(ev);",
+ "}",
+ ""
+ ],