Package com.google.gwt.dom.client

Examples of com.google.gwt.dom.client.LinkElement


      cssName = cssName.substring(cssName.lastIndexOf(".") + 1);
    } else {
      cssName = "Default";
    }

    LinkElement issueLinkElement = Document.get().createLinkElement();
    issueLinkElement.setRel("stylesheet");
    issueLinkElement.setType("text/css");
    issueLinkElement.setHref("issues/" + cssName + ".css");
    return issueLinkElement;
  }
View Full Code Here


     *
     * @param url
     *            , url of the file to load
     */
    public void loadCss(String url) {
        LinkElement link = Document.get().createLinkElement();
        link.setRel("stylesheet");
        link.setHref(url);
        attachToHead(link);
    }
View Full Code Here

    } else {
      cssName = "Default";
    }

    String baseUrl = GWT.getModuleBaseURL();
    LinkElement issueLinkElement = Document.get().createLinkElement();
    issueLinkElement.setRel("stylesheet");
    issueLinkElement.setType("text/css");
    issueLinkElement.setHref(baseUrl + "issues/" + cssName + ".css");
    return issueLinkElement;
  }
View Full Code Here

   * Load a style sheet onto the page.
   *
   * @param href the url of the style sheet
   */
  public static void loadStyleSheet(String href) {
    LinkElement linkElem = Document.get().createLinkElement();
    linkElem.setRel("stylesheet");
    linkElem.setType("text/css");
    linkElem.setHref(href);
    getHeadElement().appendChild(linkElem);
  }
View Full Code Here

    /**
     * Inject public resource css file as a file.
     * @param filename inject file name
     */
    public static void injectResourceCssAsFile(String filename) {
        LinkElement link = Document.get().createLinkElement();
        link.setType("text/css");
        link.setRel("stylesheet");
        link.setHref(GWT.getModuleBaseURL() + "css/" + filename);
        getHead().appendChild(link);
    }
View Full Code Here

    // by putting this in your gwt.xml
    // <set-property name="mgwt.mainresource.inject" value="no" />
    MainResourceHolder.inject();

    if (settings.getIconUrl() != null) {
      LinkElement iconUrlLinkElement = Document.get().createLinkElement();
      iconUrlLinkElement.setRel("apple-touch-icon");
      iconUrlLinkElement.setHref(settings.getIconUrl());
      head.appendChild(iconUrlLinkElement);
    }

    if (settings.getStartUrl() != null) {
      LinkElement startUrlLinkElement = Document.get().createLinkElement();
      startUrlLinkElement.setRel("apple-touch-startup-image");
      startUrlLinkElement.setHref(settings.getStartUrl());
      head.appendChild(startUrlLinkElement);
    }

    ViewPort viewPort = settings.getViewPort();
View Full Code Here

    /**
     * Inject public resource css file as a file.
     * @param filename inject file name
     */
    public static void injectResourceCssAsFile(String filename) {
        LinkElement link = Document.get().createLinkElement();
        link.setType("text/css");
        link.setRel("stylesheet");
        link.setHref(GWT.getModuleName() + "/css/" + filename);
        getHead().appendChild(link);
    }
View Full Code Here

    /**
     * Inject public resource css file as a file.
     * @param filename inject file name
     */
    public static void injectResourceCssAsFile(String filename) {
        LinkElement link = Document.get().createLinkElement();
        link.setType("text/css");
        link.setRel("stylesheet");
        link.setHref(GWT.getModuleName() + "/css/" + filename);
        getHead().appendChild(link);
    }
View Full Code Here

TOP

Related Classes of com.google.gwt.dom.client.LinkElement

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.