Example usage for com.google.gwt.user.client.ui AbstractImagePrototype getSafeHtml

List of usage examples for com.google.gwt.user.client.ui AbstractImagePrototype getSafeHtml

Introduction

In this page you can find the example usage for com.google.gwt.user.client.ui AbstractImagePrototype getSafeHtml.

Prototype

public SafeHtml getSafeHtml() 

Source Link

Document

Gets an HTML fragment that displays the image represented by this prototype.

Usage

From source file:com.gwtcx.client.resources.ImageCell.java

License:Open Source License

public static SafeHtml makeImage(ImageResource resource) {
    AbstractImagePrototype proto = AbstractImagePrototype.create(resource);
    return proto.getSafeHtml();
}

From source file:org.dataconservancy.dcs.access.client.model.DcpTree.java

License:Apache License

private static SafeHtml makeImage(ImageResource resource) {
    AbstractImagePrototype proto = AbstractImagePrototype.create(resource);
    return proto.getSafeHtml();
}

From source file:org.komodo.web.client.panels.vdb.property.panel.AbstractPropertiesPanel.java

License:Open Source License

/**
 * Make icons available as SafeHtml/*from ww  w.  j  ava  2  s .com*/
 * @param resource
 * @return
 */
protected static SafeHtml makeImage(ImageResource resource) {
    AbstractImagePrototype proto = AbstractImagePrototype.create(resource);

    // String html = proto.getHTML().replace("style='",
    // "style='left:0px;top:0px;"); // position:absolute;
    //
    // return SafeHtmlUtils.fromTrustedString(html);

    return proto.getSafeHtml();
}