X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=src%2Forg%2Fxwt%2FTemplate.java;h=bd57bf9878fbc07605e28b0e9b28ff42fd95981f;hb=8c1756ef3fd42cc2f324baf47e13a83f51045efe;hp=9a324d2b6af071b66ea8413e91242f1a7260aecd;hpb=a76646eb76b01b5f1b5f0507b1c4bcd4202f1f11;p=org.ibex.core.git diff --git a/src/org/xwt/Template.java b/src/org/xwt/Template.java index 9a324d2..bd57bf9 100644 --- a/src/org/xwt/Template.java +++ b/src/org/xwt/Template.java @@ -62,7 +62,7 @@ public class Template { new TemplateHelper().parseit(r.getInputStream(), r.t); return r.t; } catch (Exception e) { - if (Log.on) Log.log(r.t.fileName, e); + if (Log.on) Log.log(r.t == null ? "null" : r.t.fileName, e); return null; } } @@ -70,7 +70,8 @@ public class Template { public static Res resolveStringToResource(String str, XWT xwt, boolean permitAbsolute) { // URL if (str.indexOf("://") != -1) { - if (permitAbsolute) return Res.fromString(str); + // FIXME + //if (permitAbsolute) return Res.fromString(str); Log.log(Template.class, "absolute URL " + str + " not permitted here"); return null; } @@ -97,7 +98,7 @@ public class Template { if (staticscript == null) return staticJSScope; JSFunction temp = staticscript; staticscript = null; - temp.cloneWithNewParentJSScope(staticJSScope).call(new JSArray()); + temp.cloneWithNewParentJSScope(staticJSScope).call(null, null, null, null, 0); return staticJSScope; } @@ -121,10 +122,10 @@ public class Template { for (int i=0; children != null && i 0) + thisscript = JS.parse(t.fileName + (isstatic ? "._" : ""), t.content_start, new StringReader(contentString)); } catch (IOException ioe) { if (Log.on) Log.log(this, " ERROR: " + ioe.getMessage()); thisscript = null;