1.1 --- a/launcher/src/main/java/org/apidesign/bck2brwsr/launcher/Console.java Thu Dec 20 21:54:33 2012 +0100
1.2 +++ b/launcher/src/main/java/org/apidesign/bck2brwsr/launcher/Console.java Sat Dec 22 21:35:14 2012 +0100
1.3 @@ -44,6 +44,9 @@
1.4 @JavaScriptBody(args = {"id", "attr", "value"}, body =
1.5 "window.document.getElementById(id)[attr] = value;")
1.6 private static native void setAttr(String id, String attr, Object value);
1.7 +
1.8 + @JavaScriptBody(args = {}, body = "window.close();")
1.9 + private static native void closeWindow();
1.10
1.11 private static void log(String newText) {
1.12 String id = "result";
1.13 @@ -68,6 +71,7 @@
1.14 log("\nGot \"" + data + "\"");
1.15 if (data.isEmpty()) {
1.16 log("No data, exiting");
1.17 + closeWindow();
1.18 break;
1.19 }
1.20