5 "path" : "/home/alan/gitlive/app.Builder.js/src/Builder4/MainWindow.bjs",
8 "build_module" : "builder",
12 "delete_event" : " ( event) => {\n return false;\n}",
13 "destroy" : "() => {\n Xcls_MainWindow.singleton().no_windows--;\n \n Resources.singleton().disconnect(_this.statusbar.handler_id);\n \n \n if (Xcls_MainWindow.singleton().no_windows < 1) {\n\n Gtk.main_quit();\n }\n}",
14 "show" : " ( ) => {\n // hide the file editing..\n \n //this.hideViewEditing();\n _this.statusbar.el.hide();\n _this.statusbar_errors.el.hide();\n _this.statusbar_warnings.el.hide();\n _this.statusbar_depricated.el.hide();\n \n \n Resources.singleton().checkResources();\n\n}"
17 "default_width" : 800,
18 "* init" : " \n\t \n //this.el.show_all();\n \n ",
19 "# Project.Project project" : "null",
20 "# string title" : "\"Application Builder\"",
22 "# int no_windows" : 1,
23 "default_height" : 500,
24 "| void initChildren" : " () {\n // this needs putting in a better place..\n this.windowstate = new WindowState(this);\n \n\n //w.el.show_all();\n var tl = new Clutter.Timeline(6000);\n tl.set_repeat_count(-1);\n tl.start();\n tl.ref();\n\n \n\n\n\n}\n",
26 "| void show" : "() {\n \n this.el.show_all();\n\n}",
27 "# WindowState windowstate" : "null",
29 "$ type" : "Gtk.WindowType.TOPLEVEL",
30 "| void setTitle" : " (string str) {\n this.headerbar.el.set_title(this.title + \" - \" + str);\n} \n",
34 "xtype" : "HeaderBar",
35 "* pack" : "set_titlebar",
36 "bool show_close_button" : true,
38 "string title" : "Application Builder",
41 "* pack" : "pack_start",
46 "bool use_popover" : false,
47 "xtype" : "MenuButton",
53 "* init" : "{\n this.el.show_all();\n}\n",
55 "* pack" : "set_popup",
60 "activate" : " ( ) => {\n Xcls_MainWindow.singleton().no_windows++;\n var w = new Xcls_MainWindow();\n w.ref();\n\n w.el.show_all();\n w.initChildren();\n w.windowstate.switchState(WindowState.State.FILES);\n}"
62 "string label" : "Open a new Window",
69 "xtype" : "SeparatorMenuItem",
74 "activate" : " ( ) => {\n Resources.singleton().fetchStart();\n}"
77 "string label" : "Download updated Resources",
83 "activate" : "() => {\n About.singleton().el.show();\n }"
87 "string label" : "About the Builder",
93 "utf8 icon_name" : "help-about",
94 "* pack" : "set_image",
109 "$ homogeneous" : false,
114 "* pack" : "pack_start,true,true,0",
115 "# int lastWidth" : 0,
128 "* pack" : "pack_start,false,true,0",
154 "size_allocate" : " ( alloc) => {\n if (_this.windowstate == null) {\n return;\n }\n _this.windowstate.resizeCanvas(); \n \n}"
156 "id" : "clutterembed",
157 "* init" : " var stage = this.el.get_stage();\n stage.set_background_color( Clutter.Color.from_string(\"#000\"));\n \n \n",
159 "* pack" : "pack_start,true,true,0",
160 "$ xns" : "GtkClutter",
164 "* init" : "{\n \n \n this.el.add_constraint(\n new Clutter.AlignConstraint(\n _this.clutterembed.el.get_stage(), \n Clutter.AlignAxis.X_AXIS,\n 1.0f\n )\n );\n \n //this.el.set_position(100,100);\n this.el.set_pivot_point(1.0f,1.0f);\n \n this.el.set_size(_this.clutterembed.el.get_stage().width-50,\n _this.clutterembed.el.get_stage().height);\n \n}",
166 "* pack" : "get_stage().add_child",
167 "$ xns" : "GtkClutter"
171 "* init" : "{\n \n /*\n this.el.add_constraint(\n new Clutter.AlignConstraint(\n _this.clutterembed.el.get_stage(), \n Clutter.AlignAxis.X_AXIS,\n 0.0f\n )\n );\n */\n this.el.fixed_x = 50.0f;\n this.el.fixed_y = 0.0f;\n //this.el.set_position(100,100);\n this.el.set_pivot_point(0.0f,0.0f);\n this.el.set_scale(0.0f,1.0f);\n this.el.set_size((_this.clutterembed.el.get_stage().width-50)/2,\n _this.clutterembed.el.get_stage().height);\n \n}",
173 "* pack" : "get_stage().add_child",
174 "$ xns" : "GtkClutter"
177 "id" : "codeeditview",
178 "* init" : "{\n \n /*\n this.el.add_constraint(\n new Clutter.AlignConstraint(\n _this.clutterembed.el.get_stage(), \n Clutter.AlignAxis.X_AXIS,\n 0.0f\n )\n );\n */\n this.el.fixed_x = 50.0f;\n this.el.fixed_y = 0.0f;\n //this.el.set_position(100,100);\n this.el.set_pivot_point(0.0f,0.0f);\n this.el.set_scale(0.0f,1.0f);\n this.el.set_size((_this.clutterembed.el.get_stage().width-50)/2,\n _this.clutterembed.el.get_stage().height);\n \n}",
180 "* pack" : "get_stage().add_child",
181 "$ xns" : "GtkClutter"
184 "id" : "addpropsview",
185 "* init" : "{\n \n /*\n this.el.add_constraint(\n new Clutter.AlignConstraint(\n _this.clutterembed.el.get_stage(), \n Clutter.AlignAxis.X_AXIS,\n 0.0f\n )\n );\n */\n this.el.fixed_x = 50.0f;\n this.el.fixed_y = 0.0f;\n //this.el.set_position(100,100);\n this.el.set_pivot_point(0.0f,0.0f);\n this.el.set_scale(0.0f,1.0f);\n this.el.set_size((_this.clutterembed.el.get_stage().width-50)/2,\n _this.clutterembed.el.get_stage().height);\n \n}",
187 "* pack" : "get_stage().add_child",
188 "$ xns" : "GtkClutter"
191 "id" : "projecteditview",
192 "* init" : "{\n \n \n this.el.add_constraint(\n new Clutter.AlignConstraint(\n _this.clutterembed.el.get_stage(), \n Clutter.AlignAxis.X_AXIS,\n 1.0f\n )\n );\n \n //this.el.set_position(100,100);\n this.el.set_pivot_point(0.0f,0.0f);\n this.el.set_scale(1.0f,0.0f);\n this.el.set_size(_this.clutterembed.el.get_stage().width-50,\n _this.clutterembed.el.get_stage().height /2);\n \n}",
194 "* pack" : "get_stage().add_child",
195 "$ xns" : "GtkClutter"
198 "id" : "buttonlayout",
199 "* init" : "{\n \n this.el.add_constraint(\n new Clutter.AlignConstraint(\n _this.clutterembed.el.get_stage(), \n Clutter.AlignAxis.X_AXIS,\n 0.0f\n )\n );\n \n \n //this.el.set_position(100,100);\n this.el.set_pivot_point(0.5f,0.5f);\n this.el.set_size(50,\n _this.clutterembed.el.get_stage().height);\n \n}",
201 "* pack" : "get_stage().add_child",
205 "$ orientation" : "Clutter.Orientation.VERTICAL",
206 "xtype" : "BoxLayout",
208 "* prop" : "layout_manager"
212 "* init" : "this.el.set_size(50,50);",
214 "* pack" : "add_child",
218 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
220 "* pack" : "add_child",
221 "$ xns" : "GtkClutter",
225 "clicked" : " ( ) => {\n \n _this.windowstate.switchState(WindowState.State.PREVIEW);\n \n\n}"
227 "utf8 tooltip_text" : "Back",
230 "width_request" : 50,
232 "height_request" : 50,
236 "utf8 icon_name" : "go-previous",
237 "* pack" : "set_image",
247 "id" : "projectbutton",
248 "* init" : "this.el.set_size(50,50);",
250 "* pack" : "add_child",
254 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
255 "* pack" : "add_child",
257 "$ xns" : "GtkClutter",
261 "clicked" : " ( ) => {\n _this.windowstate.switchState(WindowState.State.FILES);\n \n\n}"
265 "width_request" : 50,
267 "height_request" : 50,
268 "$ tooltop_text" : "\"Open File\"",
271 "* pack" : "set_image",
273 "utf8 icon_name" : "document-open",
283 "id" : "editfilebutton",
284 "* init" : "this.el.set_size(50.0f,50.0f);",
286 "* pack" : "add_child",
290 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
291 "* pack" : "add_child",
293 "$ xns" : "GtkClutter",
297 "clicked" : " ( ) => {\n \n // create a new file in project..\n if (_this.project == null || _this.windowstate.left_tree.model.file == null) {\n return ;\n }\n _this.windowstate.file_details.show(\n _this.windowstate.left_tree.model.file, this.el\n );\n \n return ; \n\n\n}"
301 "width_request" : 50,
303 "$ tooltip_text" : "\"File Details\"",
304 "height_request" : 50,
307 "utf8 icon_name" : "document-properties",
308 "* pack" : "set_image",
319 "id" : "projecteditbutton",
320 "* init" : "this.el.set_size(50,50);",
322 "* pack" : "add_child",
326 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
327 "* pack" : "add_child",
329 "$ xns" : "GtkClutter",
333 "clicked" : " ( ) => {\n _this.windowstate.switchState(WindowState.State.PROJECT);\n \n\n\n}"
337 "width_request" : 50,
339 "$ tooltip_text" : "\"Project Details\"",
340 "height_request" : 50,
344 "utf8 icon_name" : "emblem-system",
345 "* pack" : "set_image",
356 "enter_event" : "( event) => {\n this.el.background_color = new Clutter.Color.from_string(\"#333\");\n return false;\n}",
357 "leave_event" : "( event) => {\n this.el.background_color = new Clutter.Color.from_string(\"#000\");\n return false;\n}"
359 "id" : "objectshowbutton",
360 "* init" : "this.el.set_size(50,50);",
362 "* pack" : "add_child",
366 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
367 "* pack" : "add_child",
369 "$ xns" : "GtkClutter",
373 "clicked" : " ( ) => {\n \n _this.windowstate.switchState(WindowState.State.OBJECT);\n \n \n}"
377 "width_request" : 50,
379 "$ tooltip_text" : "\"Add Child Element\"",
380 "height_request" : 50,
383 "* pack" : "set_image",
385 "utf8 icon_name" : "list-add",
395 "id" : "addpropbutton",
396 "* init" : "this.el.set_size(50,50);",
398 "* pack" : "add_child",
402 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
403 "* pack" : "add_child",
405 "$ xns" : "GtkClutter",
409 "clicked" : " ( ) => {\n \n _this.windowstate.switchState(WindowState.State.PROP);\n \n\n}"
413 "width_request" : 50,
415 "$ tooltip_text" : "\"Add Property\"",
416 "height_request" : 50,
419 "utf8 icon_name" : "format-justify-left",
420 "* pack" : "set_image",
431 "id" : "addlistenerbutton",
432 "* init" : "this.el.set_size(50,50);",
434 "* pack" : "add_child",
438 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
439 "* pack" : "add_child",
441 "$ xns" : "GtkClutter",
445 "clicked" : " ( ) => {\n \n _this.windowstate.switchState(WindowState.State.LISTENER);\n \n\n\n}"
449 "width_request" : 50,
451 "$ tooltip_text" : "\"Add Event Code\"",
452 "height_request" : 50,
456 "utf8 icon_name" : "appointment-new",
457 "* pack" : "set_image",
467 "id" : "addprojectbutton",
468 "* init" : "this.el.set_size(50.0f,50.0f);",
470 "* pack" : "add_child",
474 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
475 "* pack" : "add_child",
477 "$ xns" : "GtkClutter",
481 "clicked" : " ( ) => {\n \n // create a new file in project..\n //Xcls_DialogNewComponent.singleton().show(\n var pe = Xcls_EditProject.singleton();\n pe.el.set_transient_for(_this.el);\n pe.el.set_modal(true); \n \n var p = pe.show();\n\n if (p == null) {\n return;\n }\n \n \n _this.windowstate.left_projects.is_loaded = false; \n _this.windowstate.left_projects.load();\n _this.windowstate.left_projects.selectProject(p);\n return ; \n\n\n}"
485 "width_request" : 50,
487 "$ tooltip_text" : "\"New\\nProj.\"",
488 "height_request" : 50,
491 "utf8 icon_name" : "folder-new",
492 "* pack" : "set_image",
503 "id" : "addfilebutton",
504 "* init" : "this.el.set_size(50.0f,50.0f);",
506 "* pack" : "add_child",
510 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
511 "* pack" : "add_child",
513 "$ xns" : "GtkClutter",
517 "clicked" : " () => {\n // create a new file in project..\n \n // what's the currently selected project...\n var proj = _this.windowstate.left_projects.getSelectedProject();\n \n if (proj == null) {\n return ;\n }\n \n \n \n var f = JsRender.JsRender.factory(proj.xtype, proj, \"\");\n _this.project = proj;\n \n _this.windowstate.file_details.show(\n f, this.el\n );\n \n \n return ; \n}"
521 "width_request" : 50,
523 "$ tooltip_text" : "\"Add File\"",
524 "height_request" : 50,
527 "* pack" : "set_image",
529 "utf8 icon_name" : "document-new",
539 "id" : "delprojectbutton",
540 "* init" : "this.el.set_size(50,50);",
542 "* pack" : "add_child",
546 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
547 "* pack" : "add_child",
549 "$ xns" : "GtkClutter",
553 "clicked" : " ( ) => {\n \n var cd = DialogConfirm.singleton();\n cd.el.set_transient_for(_this.el);\n cd.el.set_modal(true);\n\n var project = _this.windowstate.left_projects.getSelectedProject();\n if (project == null) {\n print(\"SKIP - no project\\n\");\n return;\n }\n \n \n if (Gtk.ResponseType.YES != cd.show(\"Confirm\", \n \"Are you sure you want to delete project %s\".printf(project.name))) {\n return;\n }\n \n\n // confirm?\n Project.Project.remove(project);\n _this.project = null;\n \n _this.windowstate.left_projects.is_loaded = false;\n _this.windowstate.left_projects.load();\n _this.windowstate.clutterfiles.clearFiles();\n\n}"
557 "width_request" : 50,
559 "$ tooltip_text" : "\"Delete Project\"",
560 "height_request" : 50,
563 "utf8 icon_name" : "user-trash",
564 "* pack" : "set_image",
583 "bool homogeneous" : false,
585 "* pack" : "pack_end,false,true,0",
589 "* pack" : "pack_start,true,true,0",
591 "string label" : " ",
595 "bool show_text" : true,
597 "ulong handler_id" : "-1",
598 "* init" : "{\n this.handler_id = Resources.singleton().updateProgress.connect((pos,total) => {\n if (pos < 1) {\n this.el.hide();\n _this.mainpane.el.set_sensitive(true);\n \n return;\n }\n _this.mainpane.el.set_sensitive(false);\n this.el.show();\n this.el.set_fraction ((1.0f * pos) / (1.0f * total));\n this.el.set_text(\"Fetching Resource : %s/%s\".printf(pos.to_string(), total.to_string()));\n \n });\n}\n",
599 "xtype" : "ProgressBar",
600 "* pack" : "pack_start,true,true,0",
604 "* pack" : "pack_end,false,true,0",
610 "button_press_event" : "() => {\n if (this.popup == null) {\n this.popup = new Xcls_ValaCompileErrors();\n this.popup.window = _this;\n }\n this.popup.show(this.notices, this.el);\n}"
612 "bool always_show_image" : true,
613 "id" : "statusbar_errors",
614 "Xcls_ValaCompileErrors popup" : "",
615 "string label" : "Errors",
617 "xtype" : "ImageMenuItem",
618 "# Json.Object notices" : "new Json.Object() ",
623 "utf8 icon_name" : "dialog-error",
624 "* pack" : "set_image",
631 "button_press_event" : "() => {\n if (this.popup == null) {\n this.popup = new Xcls_ValaCompileErrors();\n this.popup.window = _this;\n }\n this.popup.show(this.notices, this.el);\n}"
633 "bool always_show_image" : true,
634 "id" : "statusbar_warnings",
635 "Xcls_ValaCompileErrors popup" : "",
637 "string label" : "Warnings",
638 "xtype" : "ImageMenuItem",
639 "# Json.Object notices" : "new Json.Object()",
643 "* pack" : "set_image",
645 "utf8 icon_name" : "dialog-warning",
652 "button_press_event" : "() => {\n if (this.popup == null) {\n this.popup = new Xcls_ValaCompileErrors();\n this.popup.window = _this;\n }\n this.popup.show(this.notices, this.el);\n}"
654 "bool always_show_image" : true,
655 "id" : "statusbar_depricated",
656 "string label" : "Depricated",
658 "xtype" : "ImageMenuItem",
659 "# Json.Object notices" : "new Json.Object()",
664 "utf8 icon_name" : "dialog-information",
665 "* pack" : "set_image",