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",
44 "Gtk.Orientation orientation" : "Gtk.Orientation.HORIZONTAL",
47 "bool use_popover" : false,
48 "xtype" : "MenuButton",
54 "* init" : "{\n this.el.show_all();\n}\n",
56 "* pack" : "set_popup",
61 "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}"
63 "string label" : "Open a new Window",
70 "xtype" : "SeparatorMenuItem",
75 "activate" : " ( ) => {\n Resources.singleton().fetchStart();\n}"
78 "string label" : "Download updated Resources",
84 "activate" : "() => {\n About.singleton().el.show();\n }"
88 "string label" : "About the Builder",
94 "utf8 icon_name" : "help-about",
95 "* pack" : "set_image",
110 "Gtk.Orientation orientation" : "Gtk.Orientation.VERTICAL",
111 "$ homogeneous" : false,
116 "* pack" : "pack_start,true,true,0",
117 "# int lastWidth" : 0,
120 "Gtk.Orientation orientation" : "Gtk.Orientation.HORIZONTAL",
127 "Gtk.Orientation orientation" : "Gtk.Orientation.VERTICAL",
132 "* pack" : "pack_start,false,true,0",
134 "Gtk.Orientation orientation" : "Gtk.Orientation.VERTICAL",
159 "size_allocate" : " ( alloc) => {\n if (_this.windowstate == null) {\n return;\n }\n _this.windowstate.resizeCanvas(); \n \n}"
161 "id" : "clutterembed",
162 "* init" : " var stage = this.el.get_stage();\n stage.set_background_color( Clutter.Color.from_string(\"#000\"));\n \n \n",
164 "* pack" : "pack_start,true,true,0",
165 "$ xns" : "GtkClutter",
169 "* 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}",
171 "* pack" : "get_stage().add_child",
172 "$ xns" : "GtkClutter"
176 "* 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}",
178 "* pack" : "get_stage().add_child",
179 "$ xns" : "GtkClutter"
182 "id" : "codeeditview",
183 "* 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}",
185 "* pack" : "get_stage().add_child",
186 "$ xns" : "GtkClutter"
189 "id" : "addpropsview",
190 "* 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}",
192 "* pack" : "get_stage().add_child",
193 "$ xns" : "GtkClutter"
196 "id" : "projecteditview",
197 "* 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}",
199 "* pack" : "get_stage().add_child",
200 "$ xns" : "GtkClutter"
203 "id" : "buttonlayout",
204 "* 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}",
206 "* pack" : "get_stage().add_child",
210 "$ orientation" : "Clutter.Orientation.VERTICAL",
211 "xtype" : "BoxLayout",
213 "* prop" : "layout_manager"
217 "* init" : "this.el.set_size(50,50);",
219 "* pack" : "add_child",
223 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
225 "* pack" : "add_child",
226 "$ xns" : "GtkClutter",
230 "clicked" : " ( ) => {\n \n _this.windowstate.switchState(WindowState.State.PREVIEW);\n \n\n}"
232 "utf8 tooltip_text" : "Back",
235 "width_request" : 50,
237 "height_request" : 50,
241 "utf8 icon_name" : "go-previous",
242 "* pack" : "set_image",
252 "id" : "projectbutton",
253 "* init" : "this.el.set_size(50,50);",
255 "* pack" : "add_child",
259 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
260 "* pack" : "add_child",
262 "$ xns" : "GtkClutter",
266 "clicked" : " ( ) => {\n _this.windowstate.switchState(WindowState.State.FILES);\n \n\n}"
270 "width_request" : 50,
272 "height_request" : 50,
273 "$ tooltop_text" : "\"Open File\"",
276 "* pack" : "set_image",
278 "utf8 icon_name" : "document-open",
288 "id" : "editfilebutton",
289 "* init" : "this.el.set_size(50.0f,50.0f);",
291 "* pack" : "add_child",
295 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
296 "* pack" : "add_child",
298 "$ xns" : "GtkClutter",
302 "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}"
306 "width_request" : 50,
308 "$ tooltip_text" : "\"File Details\"",
309 "height_request" : 50,
312 "utf8 icon_name" : "document-properties",
313 "* pack" : "set_image",
324 "id" : "projecteditbutton",
325 "* init" : "this.el.set_size(50,50);",
327 "* pack" : "add_child",
331 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
332 "* pack" : "add_child",
334 "$ xns" : "GtkClutter",
338 "clicked" : " ( ) => {\n _this.windowstate.switchState(WindowState.State.PROJECT);\n \n\n\n}"
342 "width_request" : 50,
344 "$ tooltip_text" : "\"Project Details\"",
345 "height_request" : 50,
349 "utf8 icon_name" : "emblem-system",
350 "* pack" : "set_image",
361 "enter_event" : "( event) => {\n this.el.background_color = new Clutter.Color.from_string(\"#333\");\n return false;\n}",
362 "leave_event" : "( event) => {\n this.el.background_color = new Clutter.Color.from_string(\"#000\");\n return false;\n}"
364 "id" : "objectshowbutton",
365 "* init" : "this.el.set_size(50,50);",
367 "* pack" : "add_child",
371 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
372 "* pack" : "add_child",
374 "$ xns" : "GtkClutter",
378 "clicked" : " ( ) => {\n \n _this.windowstate.switchState(WindowState.State.OBJECT);\n \n \n}"
382 "width_request" : 50,
384 "$ tooltip_text" : "\"Add Child Element\"",
385 "height_request" : 50,
388 "* pack" : "set_image",
390 "utf8 icon_name" : "list-add",
400 "id" : "addpropbutton",
401 "* init" : "this.el.set_size(50,50);",
403 "* pack" : "add_child",
407 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
408 "* pack" : "add_child",
410 "$ xns" : "GtkClutter",
414 "clicked" : " ( ) => {\n \n _this.windowstate.switchState(WindowState.State.PROP);\n \n\n}"
418 "width_request" : 50,
420 "$ tooltip_text" : "\"Add Property\"",
421 "height_request" : 50,
424 "utf8 icon_name" : "format-justify-left",
425 "* pack" : "set_image",
436 "id" : "addlistenerbutton",
437 "* init" : "this.el.set_size(50,50);",
439 "* pack" : "add_child",
443 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
444 "* pack" : "add_child",
446 "$ xns" : "GtkClutter",
450 "clicked" : " ( ) => {\n \n _this.windowstate.switchState(WindowState.State.LISTENER);\n \n\n\n}"
454 "width_request" : 50,
456 "$ tooltip_text" : "\"Add Event Code\"",
457 "height_request" : 50,
461 "utf8 icon_name" : "appointment-new",
462 "* pack" : "set_image",
472 "id" : "addprojectbutton",
473 "* init" : "this.el.set_size(50.0f,50.0f);",
475 "* pack" : "add_child",
479 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
480 "* pack" : "add_child",
482 "$ xns" : "GtkClutter",
486 "clicked" : " ( ) => {\n \n // create a new file in project..\n //Xcls_DialogNewComponent.singleton().show(\n var pe = 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}"
490 "width_request" : 50,
492 "$ tooltip_text" : "\"New\\nProj.\"",
493 "height_request" : 50,
496 "utf8 icon_name" : "folder-new",
497 "* pack" : "set_image",
508 "id" : "addfilebutton",
509 "* init" : "this.el.set_size(50.0f,50.0f);",
511 "* pack" : "add_child",
515 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
516 "* pack" : "add_child",
518 "$ xns" : "GtkClutter",
522 "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}"
526 "width_request" : 50,
528 "$ tooltip_text" : "\"Add File\"",
529 "height_request" : 50,
532 "* pack" : "set_image",
534 "utf8 icon_name" : "document-new",
544 "id" : "delprojectbutton",
545 "* init" : "this.el.set_size(50,50);",
547 "* pack" : "add_child",
551 "* init" : "((Gtk.Container)(this.el.get_widget())).add ( child_0.el);",
552 "* pack" : "add_child",
554 "$ xns" : "GtkClutter",
558 "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}"
562 "width_request" : 50,
564 "$ tooltip_text" : "\"Delete Project\"",
565 "height_request" : 50,
568 "utf8 icon_name" : "user-trash",
569 "* pack" : "set_image",
588 "bool homogeneous" : false,
590 "* pack" : "pack_end,false,true,0",
594 "* pack" : "pack_start,true,true,0",
596 "string label" : " ",
600 "bool show_text" : true,
602 "ulong handler_id" : "-1",
603 "* 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",
604 "xtype" : "ProgressBar",
605 "* pack" : "pack_start,true,true,0",
609 "* pack" : "pack_end,false,true,0",
614 "xtype" : "MenuItem",
615 "string label" : "Compile Status:",
621 "button_press_event" : "() => {\n if (this.popup == null) {\n this.popup = new Xcls_ValaCompileErrors();\n this.popup.window = _this;\n }\n \n \n this.popup.show(this.notices, this.el);\n return true;\n}"
623 "bool always_show_image" : true,
624 "id" : "statusbar_errors",
625 "| void setNotices" : "(Json.Object nots, int qty) {\n this.el.show();\n this.el.label = qty.to_string() + \" Errors\";\n this.notices = nots;\n\n}\n",
626 "Xcls_ValaCompileErrors popup" : "",
627 "string label" : "Errors",
629 "xtype" : "ImageMenuItem",
630 "# Json.Object notices" : "new Json.Object() ",
635 "utf8 icon_name" : "dialog-error",
636 "* pack" : "set_image",
643 "button_press_event" : "() => {\n if (this.popup == null) {\n this.popup = new Xcls_ValaCompileErrors();\n this.popup.window = _this;\n }\n \n this.popup.show(this.notices, this.el);\n return true;\n}"
645 "bool always_show_image" : true,
646 "id" : "statusbar_warnings",
647 "| void setNotices" : "(Json.Object nots, int qty) {\n this.el.show();\n this.el.label = qty.to_string() + \" Warnings\";\n this.notices = nots;\n\n}\n",
648 "Xcls_ValaCompileErrors popup" : "",
650 "string label" : "Warnings",
651 "xtype" : "ImageMenuItem",
652 "# Json.Object notices" : "new Json.Object()",
656 "* pack" : "set_image",
658 "utf8 icon_name" : "dialog-warning",
665 "button_press_event" : "() => {\n if (this.popup == null) {\n this.popup = new Xcls_ValaCompileErrors();\n this.popup.window = _this;\n }\n \n \n this.popup.show(this.notices, this.el);\n return true;\n}"
667 "bool always_show_image" : true,
668 "id" : "statusbar_depricated",
669 "| void setNotices" : "(Json.Object nots, int qty) {\n this.el.show();\n this.el.label = qty.to_string() + \" Depricated\";\n this.notices = nots;\n\n}\n",
670 "Xcls_ValaCompileErrors popup" : "",
671 "string label" : "Depricated",
673 "xtype" : "ImageMenuItem",
674 "# Json.Object notices" : "new Json.Object()",
678 "utf8 icon_name" : "dialog-information",
679 "* pack" : "set_image",