X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=src%2Forg%2Fibex%2Fcore%2FMain.java;h=d35def121e242446b6cf2afe411eef46af6a30d4;hb=0db31fc0dc88749cd8022790fd475df8b7b06c27;hp=ceb7efa65b813184d9936cbbb0998fbdc0cbcdf7;hpb=439e58899c718846994d6389ece66ee73a9045ed;p=org.ibex.core.git diff --git a/src/org/ibex/core/Main.java b/src/org/ibex/core/Main.java index ceb7efa..d35def1 100644 --- a/src/org/ibex/core/Main.java +++ b/src/org/ibex/core/Main.java @@ -1,4 +1,7 @@ -// Copyright 2004 Adam Megacz, see the COPYING file for licensing [GPL] +// Copyright 2000-2005 the Contributors, as shown in the revision logs. +// Licensed under the GNU General Public License version 2 ("the License"). +// You may not use this file except in compliance with the License. + package org.ibex.core; import java.net.*; @@ -83,8 +86,10 @@ public class Main { originHost = originHost.substring(0, originHost.indexOf('/') == -1 ? originHost.length() : originHost.indexOf('/')); if (originHost.indexOf('@') != -1) originHost = originHost.substring(originHost.indexOf('@') + 1); originAddr = InetAddress.getByName(originHost); - rr = builtin; - startupTemplate = "org.ibex.builtin.splash"; + //rr = builtin; + //startupTemplate = "org.ibex.builtin.splash"; + rr = new Stream.HTTP(origin); + startupTemplate = initialTemplate; } else { rr = new Stream.File(origin); if (!new File(origin).isDirectory()) rr = new Stream.Zip(rr); @@ -96,9 +101,15 @@ public class Main { org.ibex.graphics.Surface.scarImage = Picture.load(new Stream.FromInputStream(Encode.JavaSourceCode.decode(Scar.data)), - new Task() { public void perform() throws JSExn, UnknownHostException { - if (Log.on) Log.info(Main.class, "invoking initial template"); - ibex.resolveString(startupTemplate, false).call(new Box(), null, null, null, 1); + new Callable() { + private JS[] callargs = new JS[1]; + public Object run(Object o) throws JSExn,UnknownHostException { + if (Log.on) Log.info(Main.class, "invoking initial template"); + try { + callargs[0] = new Box(); + ibex.resolveString(startupTemplate, false).call(callargs); + } finally { callargs[0] = null; } + return null; } }); Scheduler.init();