Package com.google.gwt.dom.client

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


 
  public RadioButton() {
    super(null);
    if (Utils.isAndroid() && Utils.isWVGA()) {
      setStyleName("RadioButton");
      DivElement div = Document.get().createDivElement();
      this.getElement().insertFirst(div);
    }
  }
View Full Code Here


    public void detach() {
      logContainer.removeFromParent();
    }

    private void appendLogLine(String line) {
      DivElement element = Document.get().createDivElement();
      element.setInnerHTML(line);
      element.getStyle().setProperty("borderBottomStyle", "dotted");
      element.getStyle().setBorderWidth(1, Unit.PX);
      element.getStyle().setBorderColor("#c0c0c0");
      logContainer.appendChild(element);
      lastElement = element;
    }
View Full Code Here

      StyleInjector.inject(RESOURCES.css().getText());
    }

    /** Helper function to create a DivElement with a given style name */
    private Element createDiv(String style) {
      DivElement x = Document.get().createDivElement();
      x.setClassName(style);
      return (Element) Element.as(x);
    }
View Full Code Here

    this.cajoleService = service;
    this.cajaFrame = cajaFrame;
  }

  private void appendToDocument(HTML target, PluginContext pluginContext, CajolerResponse response) {
    DivElement domitaVdocElement = Document.get().createDivElement();
    domitaVdocElement.setClassName("innerHull");

    target.getElement().setInnerHTML("");
    target.getElement().setClassName("outerHull");
    target.getElement().appendChild(domitaVdocElement);

    initializeDoodadEnvironment(
        cajaFrame, domitaVdocElement, pluginContext.getJSOInterface());

    // Render HTML
    domitaVdocElement.setInnerHTML(response.getHtml());

    // Inject JS
    Document cajaFrameDoc = cajaFrame.getContentDocument();
    cajaFrameDoc.getBody().appendChild(cajaFrameDoc.createScriptElement(response.getJs()));
  }
View Full Code Here

   * this is such a common task
   * @param styleName
   * @return The created div element
   */
  public static DivElement createDivWithStyle(String styleName) {
    DivElement d = Document.get().createDivElement();
    d.setClassName(styleName);
    return d;
  }
View Full Code Here

    sinkEvents(Event.ONCHANGE | Event.ONCLICK | Event.MOUSEEVENTS);

    createFileInput();

    button = new TextButton(getMessages().browserText());
    DivElement wrapper = Document.get().createDivElement();
    wrapper.addClassName(appearance.buttonClass());
    XElement buttonElement = button.getElement();
    if (GXT.isIE6() || GXT.isIE7() || GXT.isIE8() || GXT.isOpera()) {
      buttonElement.removeClassName(CommonStyles.get().inlineBlock());
    }
    wrapper.appendChild(buttonElement);
    getElement().appendChild(wrapper);

    ensureVisibilityOnSizing = true;
    setWidth(150);
  }
View Full Code Here

      public void onLoaded()
      {
        String content = getDocWrittenContent();
        restoreDocWriteFunction();
        processNextScript(callback);
        final DivElement wrapperElement = Document.get().createDivElement();
        wrapperElement.setInnerHTML(content);
        cloneScript.getParentElement().insertAfter(wrapperElement, cloneScript);
        Scheduler.get().scheduleDeferred(new ScheduledCommand()
        {
          @Override
          public void execute()
View Full Code Here

     return false;
   }-*/;

  private static Element createStyleRuler(Element parent) {
    DivElement styleRuler = Document.get().createDivElement();
    DivElement styleInner = Document.get().createDivElement();

    styleRuler.getStyle().setPosition(Position.ABSOLUTE);
    styleRuler.getStyle().setLeft(-10000, PX);

    parent.appendChild(styleRuler);
View Full Code Here

  public Element attachChild(Element parent, Element child, Element before) {
    if (!isIE6) {
      return super.attachChild(parent, child, before);
    }

    DivElement container = Document.get().createDivElement();
    container.insertBefore(child, before);

    container.getStyle().setPosition(Position.ABSOLUTE);
    container.getStyle().setOverflow(Overflow.HIDDEN);
    child.getStyle().setPosition(Position.ABSOLUTE);

    // Hang the style ruler from the container element, but associate it with
    // the child element, so that measureDecoration(child) will work.
    setPropertyElement(child, "__styleRuler", createStyleRuler(container));
View Full Code Here

    fixedRuler = createRuler(IN, IN);
    doc.getBody().appendChild(fixedRuler);
  }

  protected static DivElement createRuler(Unit widthUnit, Unit heightUnit) {
    DivElement ruler = Document.get().createDivElement();
    ruler.setInnerHTML(" ");
    Style style = ruler.getStyle();
    style.setPosition(Position.ABSOLUTE);
    style.setZIndex(-32767);
    style.setLeft(-10000, PX);

    // Note that we are making the ruler element 10x10, because some browsers
View Full Code Here

TOP

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

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.