private static String syncRestNativeCall(final String purl) { final XMLHttpRequest xmlHttp = Browser.getWindow().newXMLHttpRequest(); xmlHttp.open("GET", purl, false); // false for synchronous request xmlHttp.send(); return xmlHttp.getResponseText(); } }
public void f() { Browser.getWindow().getConsole().info("loading angularjs succeeded."); injectModules(); } });
/** Turn off Super DevMode for the current IDE GWT app. */ void off() { Window window = Browser.getWindow(); Storage sessionStorage = window.getSessionStorage(); for (int i = 0; i < sessionStorage.getLength(); i++) { String key = sessionStorage.key(i); if (key.equals("__gwtDevModeHook:" + IDE_GWT_APP_SHORT_NAME)) { sessionStorage.removeItem(key); break; } } window.getLocation().reload(); }
final int winX = window.getInnerWidth(); final int winY = window.getInnerHeight(); ClientRect widgetRect = this.popupElement.getBoundingClientRect(); if (widgetRect.getBottom() > winY) {
private void addHandlers() { cleanUpHandlers(); partStackStateEventRemover = eventBus.addHandler(PartStackStateChangedEvent.TYPE, this); blurEventRemover = getWindow().addEventListener(BLUR, evt -> appStateManager.persistState()); windowEventsRemover = eventBus.addHandler(WindowActionEvent.TYPE, this); workspaceStoppingEventRemover = eventBus.addHandler(WorkspaceStoppingEvent.TYPE, this); }
private static String syncRestNativeCall(final String purl) { final XMLHttpRequest xmlHttp = Browser.getWindow().newXMLHttpRequest(); xmlHttp.open("GET", purl, false); // false for synchronous request xmlHttp.send(); return xmlHttp.getResponseText(); } }
public void f() { Browser.getWindow().getConsole().warn("loading angularjs failed."); } });
private static String syncRestNativeCall(final String purl) { final XMLHttpRequest xmlHttp = Browser.getWindow().newXMLHttpRequest(); xmlHttp.open("GET", purl, false); // false for synchronous request xmlHttp.send(); return xmlHttp.getResponseText(); } }
private void loadAngular() { if(!isInjected()) { Promise loadAngular = new ScriptLoader(); loadAngular.done(new Function() { public void f() { Browser.getWindow().getConsole().info("loading angularjs succeeded."); injectModules(); } }); loadAngular.fail(new Function() { public void f() { Browser.getWindow().getConsole().warn("loading angularjs failed."); } }); } else { Browser.getWindow().getConsole().info("angularjs already loaded."); injectModules(); } }
XMLHttpRequest xhr = Browser.getWindow().newXMLHttpRequest();