Example usage for com.google.gwt.dom.client Style setBackgroundColor

List of usage examples for com.google.gwt.dom.client Style setBackgroundColor

Introduction

In this page you can find the example usage for com.google.gwt.dom.client Style setBackgroundColor.

Prototype

public void setBackgroundColor(String value) 

Source Link

Usage

From source file:org.vaadin.sasha.portallayout.client.dnd.MouseDragHandler.java

License:Apache License

private void initCapturingWidget() {
    capturingWidget = new FocusPanel();
    capturingWidget.addMouseMoveHandler(this);
    capturingWidget.addMouseUpHandler(this);
    capturingWidget.addTouchMoveHandler(this);
    capturingWidget.addTouchEndHandler(this);
    capturingWidget.addTouchCancelHandler(this);
    Style style = capturingWidget.getElement().getStyle();
    // workaround for IE8 opacity
    // http://code.google.com/p/google-web-toolkit/issues/detail?id=5538
    style.setProperty("filter", "alpha(opacity=0)");
    style.setOpacity(0);//from   w  w w  .j av a2  s.c o m
    style.setZIndex(1000);
    style.setMargin(0, Style.Unit.PX);
    style.setBorderStyle(BorderStyle.NONE);
    style.setBackgroundColor("blue");
}