From d26c3c709a71c1d9dbc61ae95139bcb7c9cceac1 Mon Sep 17 00:00:00 2001 From: Alan Knowles Date: Wed, 10 Sep 2014 19:48:34 +0800 Subject: [PATCH] tests/GtkView.vala --- tests/GtkView.vala | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/tests/GtkView.vala b/tests/GtkView.vala index dbf396fce..583491bad 100644 --- a/tests/GtkView.vala +++ b/tests/GtkView.vala @@ -3,20 +3,33 @@ */ - + +public Project proj; + int main (string[] args) { Gtk.init (ref args); //GtkClutter.init (ref args); new JsRender.Lang_Class(); GLib.Log.set_always_fatal(LogLevelFlags.LEVEL_ERROR | LogLevelFlags.LEVEL_CRITICAL); Project.Project.loadAll(); - var proj = Project.Project.getProject("Builder4"); + proj = Project.Project.getProject("Builder4"); proj.scanDirs(); print("load %s\n", proj.firstPath() + "/WindowLeftProps.bjs"); + + loadit("EditProject"); + + + Gtk.main(); + + + return 0; +} + +void loadit(string name ) { //var tf = proj.files.get(proj.firstPath() + "/WindowLeftProps.bjs"); - var tf = proj.files.get(proj.firstPath() + "/EditProject.bjs"); + var tf = proj.files.get(proj.firstPath() + "/" + name +".bjs"); tf.loadItems(); @@ -29,9 +42,4 @@ int main (string[] args) { left_props.addNode(tf); left_props.container.el.show_all(); - - Gtk.main(); - - - return 0; } \ No newline at end of file -- 2.39.2