org.dashbuilder.renderer.chartjs.lib.event.AnimationCompleteEvent Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of dashbuilder-renderer-chartjs Show documentation
Show all versions of dashbuilder-renderer-chartjs Show documentation
Dashbuilder Renderer for the Chart JS API
package org.dashbuilder.renderer.chartjs.lib.event;
import org.dashbuilder.renderer.chartjs.lib.Chart;
import com.google.gwt.event.shared.GwtEvent;
/**
* Class represents event occurred when {@link Chart} animation has been finished
*/
public class AnimationCompleteEvent extends GwtEvent{
private static Type TYPE = new Type();
private Object sender;
protected AnimationCompleteEvent(Object sender){
this.sender = sender;
}
public Object getSender(){
return sender;
}
@Override
public com.google.gwt.event.shared.GwtEvent.Type getAssociatedType() {
return TYPE;
}
public static Type getType(){
return TYPE;
}
@Override
protected void dispatch(AnimationCompleteHandler handler) {
handler.onAnimationComplete(this);
}
public static void fire(HasAnimationCompleteHandlers source, Object sender) {
AnimationCompleteEvent event = new AnimationCompleteEvent(sender);
source.fireEvent(event);
}
}