2004/01/07 20:37:32
[org.ibex.core.git] / src / org / xwt / XWT.java
index d599f0e..0572b66 100644 (file)
@@ -113,7 +113,11 @@ public final class XWT extends JS {
         //#switch(name)
         case "thread": Scheduler.add((JSFunction)value); return;
         case "ui.clipboard": Platform.setClipBoard((String)value); return;
-        case "ui.frame": Platform.createSurface((Box)value, true, true); return;
+        case "ui.frame":
+            Box b = (Box)value;
+            Surface s = Platform.createSurface(b,true, true);
+            if(b.get("titlebar") != null) s.setTitleBarText(JS.toString(b.get("titlebar")));
+            return;
         case "ui.window": Platform.createSurface((Box)value, false, true); return;
         case "undocumented.internal.proxyAuthorization":
             HTTP.Proxy.Authorization.authorization = value.toString();
@@ -180,12 +184,13 @@ public final class XWT extends JS {
                             }
                         }
                         return a;
+                    case "regexp": return new JSRegexp(a, b);
                     //#end
                     break;
             }
         } catch (RuntimeException e) {
             // FIXME: maybe JSExn should take a second argument, Exception
-            Log.info(this, "xwt."+name+"() threw: "+e);
+            Log.info(this, "xwt."+name+"() threw: " + e);
             throw new JSExn("invalid argument for xwt object method "+name+"()");
         }