diff options
author | Shawn O. Pearce <sop@google.com> | 2009-03-01 14:24:31 -0800 |
---|---|---|
committer | Shawn O. Pearce <sop@google.com> | 2009-03-01 14:24:31 -0800 |
commit | 37f4c2e6e09c3c7187986b5f397210471e6324a5 (patch) | |
tree | bca82fc0becdb8164708a9b376900519370b7dfb | |
parent | aa8b3d4e2d2db8da124488d889b066f1350b4f33 (diff) |
Switch to gwtexpui's iframe busting code
Signed-off-by: Shawn O. Pearce <sop@google.com>
-rw-r--r-- | src/main/java/com/google/gerrit/client/Gerrit.java | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/src/main/java/com/google/gerrit/client/Gerrit.java b/src/main/java/com/google/gerrit/client/Gerrit.java index 8ebadcb02b..890da52216 100644 --- a/src/main/java/com/google/gerrit/client/Gerrit.java +++ b/src/main/java/com/google/gerrit/client/Gerrit.java @@ -36,6 +36,7 @@ import com.google.gwt.user.client.ui.HTML; import com.google.gwt.user.client.ui.MenuBar; import com.google.gwt.user.client.ui.MenuItem; import com.google.gwt.user.client.ui.RootPanel; +import com.google.gwtexpui.user.client.UserAgent; import com.google.gwtjsonrpc.client.JsonUtil; import java.util.ArrayList; @@ -173,11 +174,7 @@ public class Gerrit implements EntryPoint { } public void onModuleLoad() { - if (GWT.isScript() && amInsideIFrame()) { - bustOutOfIFrame(Window.Location.getHref()); - return; - } - + UserAgent.assertNotInIFrame(); initHistoryHooks(); populateBottomMenu(); @@ -198,12 +195,6 @@ public class Gerrit implements EntryPoint { }); } - private static native boolean amInsideIFrame() - /*-{ return top.location != $wnd.location; }-*/; - - private static native void bustOutOfIFrame(String newloc) - /*-{ top.location.href = newloc }-*/; - private static ArrayList<JavaScriptObject> historyHooks; private static native void initHistoryHooks() |