/*************************************** * Returns the view title. * * @return The title string */ public String getTitle() { return Window.getTitle(); }
protected void pushToken(String token) { historian.pushState(token, Window.getTitle(), "#" + History.encodeHistoryToken(token)); }
protected void pushToken(String token) { historian.pushState(token, Window.getTitle(), "#" + History.encodeHistoryToken(token)); }
@Override public void run() { try { if (counter++ > 100 || "complete".equals(DOMUtil.windowReadyState(window))) { DOMUtil.windowSetTitle(window, "[log] " + Window.getTitle()); ready = true; cancel(); logPendingText(); } } catch (RuntimeException e) { window = null; cancel(); } } }.scheduleRepeating(100);
@Override public void onValueChange(ValueChangeEvent<String> event) { eventBus.fireEvent(new PopStateEvent(event.getValue(), Window.getTitle(), Window.Location.getHref())); }
@Override public void onValueChange(ValueChangeEvent<String> event) { eventBus.fireEvent(new PopStateEvent(event.getValue(), Window.getTitle(), Window.Location.getHref())); }
/** * Shows the uiObject content in a printable form in a new window * @param uiObject */ public static void print(UIObject uiObject){ String headTag = ""; String styleTags = ""; NodeList<com.google.gwt.dom.client.Element> head = Document.get().getElementsByTagName("head"); if(head.getItem(0) != null){ com.google.gwt.dom.client.Element e = head.getItem(0); NodeList<com.google.gwt.dom.client.Element> styles = e.getElementsByTagName("style"); for(int i = 0; i < styles.getLength(); i++){ styleTags = styleTags + styles.getItem(i).getString(); } } headTag = "<HEAD><TITLE>Print - " + Window.getTitle() + "</TITLE>" + styleTags + "</HEAD>"; openPrintWindow(uiObject.getElement().getString(), headTag, num); num++; }