All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.ksyzt.gwt.client.common.DeleteButton Maven / Gradle / Ivy

There is a newer version: 2.3.0
Show newest version
package com.ksyzt.gwt.client.common;

import com.google.gwt.uibinder.client.UiConstructor;
import com.google.gwt.user.client.DOM;
import com.google.gwt.user.client.ui.Image;

// TODO: Auto-generated Javadoc

/**
 * The Class DeleteButton.
 */
public class DeleteButton extends Image {

    /**
     * Instantiates a new delete button.
     *
     * @param value the value
     */
    public DeleteButton(int value) {
        super(SysResource.INSTANCE.delete());
        DOM.setElementPropertyInt(this.getElement(), "v", value);
        DOM.setStyleAttribute(this.getElement(), "cursor", "hand");
    }

    /**
     * Instantiates a new delete button.
     */
    @UiConstructor
    public DeleteButton() {
        super(SysResource.INSTANCE.delete());
        DOM.setElementPropertyInt(this.getElement(), "v", 0);
        DOM.setStyleAttribute(this.getElement(), "cursor", "hand");
    }

    /**
     * Gets the value.
     *
     * @return the value
     */
    public int getValue() {
        return DOM.getElementPropertyInt(this.getElement(), "v");
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy