blob: 2bc06a0f7c5865cf2b8848914df17bceda144d65 [file] [log] [blame]
/**
*
* Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany)
*
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Florian Pirchner <florian.pirchner@gmail.com> - Initial implementation
*/
package org.eclipse.osbp.vaadin.addons.designer.overlay.client.widgets;
import com.google.gwt.event.shared.GwtEvent;
// TODO: Auto-generated Javadoc
/**
* The Class OButtonClickEvent.
*/
public class OButtonClickEvent extends GwtEvent<OButtonClickHandler> {
/**
* Event type for resize end events.
*/
private static final Type<OButtonClickHandler> TYPE = new Type<OButtonClickHandler>();
/** The widget. */
private final OButtonWidget widget;
/** The custom event type. */
private final String customEventType;
/**
* Instantiates a new o button click event.
*
* @param widget the widget
* @param customEventType the custom event type
*/
public OButtonClickEvent(OButtonWidget widget, String customEventType) {
this.widget = widget;
this.customEventType = customEventType;
}
/**
* Gets the widget.
*
* @return the widget
*/
public OButtonWidget getWidget() {
return widget;
}
/**
* Gets the custom event type.
*
* @return the custom event type
*/
public String getCustomEventType() {
return customEventType;
}
/**
* Gets the event type associated with resize end events.
*
* @return the handler type
*/
public static Type<OButtonClickHandler> getType() {
return TYPE;
}
/* (non-Javadoc)
* @see com.google.gwt.event.shared.GwtEvent#getAssociatedType()
*/
@Override
public final Type<OButtonClickHandler> getAssociatedType() {
return TYPE;
}
/* (non-Javadoc)
* @see com.google.gwt.event.shared.GwtEvent#dispatch(com.google.gwt.event.shared.EventHandler)
*/
@Override
protected void dispatch(OButtonClickHandler handler) {
handler.clicked(this);
}
}