X-Git-Url: http://git.roojs.org/?a=blobdiff_plain;f=jhbuild.js;h=7f235760506bda4d72adc00f7a0b404e3bb3d854;hb=54fb81afef4dd47e2ee106911cb11199647cb3f8;hp=5ae4d60c897e8d70ae3a0275cd2ef079d9b0f46e;hpb=a08358414206432175d30ea8d5e41ca642e630bf;p=gnome.introspection-doc-generator diff --git a/jhbuild.js b/jhbuild.js index 5ae4d60..7f23576 100755 --- a/jhbuild.js +++ b/jhbuild.js @@ -7,12 +7,14 @@ GLib= imports.gi.GLib; Gio = imports.gi.Gio; -//Roo = imports['Roo.js'].Roo; -File = imports.file.File; -console = imports.console; +File = imports.File.File; +console = imports.console.console; + +Seed.include('Date.js'); -Date = imports.Date.Date; +//DateExtra = imports.DateExtra.DateExtra; + // these should come from args @@ -231,7 +233,7 @@ function spawnlog (cwd, s, outfile, errfile) { GLib.SpawnFlags.DO_NOT_REAP_CHILD + GLib.SpawnFlags.SEARCH_PATH , null, null, ret); - var ctx = GLib.main_loop_new (null, false); + var ctx = new GLib.MainLoop.c_new (null, false); var started = false; GLib.child_watch_add(GLib.PRIORITY_DEFAULT, ret.child_pid, function(pid, status) { @@ -240,7 +242,7 @@ function spawnlog (cwd, s, outfile, errfile) { retval.done = true; if (started) { console.log("Ending LOOP"); - GLib.main_loop_quit(ctx); + ctx.quit(); } }); @@ -257,15 +259,15 @@ function spawnlog (cwd, s, outfile, errfile) { var x = new GLib.String(); - var cstatus = GLib.io_channel_get_buffer_condition(ch); - cstatus = GLib.io_channel_get_flags (ch) + var cstatus = ch.get_buffer_condition(); + cstatus = ch.get_flags (ch) //Seed.print("WAITING INPUT?" + prop+':'+cstatus); //var status = GLib.io_channel_read_line_string (ch, x, null); - var status = GLib.io_channel_read_line_string (ch, x); + var status = ch.read_line_string (x); //Seed.print(prop + ":INPUT:" + status); @@ -315,7 +317,7 @@ function spawnlog (cwd, s, outfile, errfile) { if (!retval.done) { started = true; console.log("STARTING LOOP"); - GLib.main_loop_run(ctx, false); // wait fore exit? + ctx.run(); // wait fore exit? } readstr(out_ch, outfile, 'output'); readstr(err_ch, errfile, 'error');