org.eesgmbh.gimv.client.event
Class ViewportDragFinishedEvent

java.lang.Object
  extended by com.google.gwt.event.shared.GwtEvent<H>
      extended by org.eesgmbh.gimv.client.event.FilteredDispatchGwtEvent<ViewportDragFinishedEventHandler>
          extended by org.eesgmbh.gimv.client.event.ViewportDragFinishedEvent

public class ViewportDragFinishedEvent
extends FilteredDispatchGwtEvent<ViewportDragFinishedEventHandler>

Fired after a drag is finished (i.e. the user performs a mouse up).

Contains information how much was dragged both in absolute pixels and as proportional values relative to the viewport dimensions. The pixel bounds are also relative to the parent Viewport.

The two bounds use left and top for the starting position of the drag and right and bottom for the end position.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.google.gwt.event.shared.GwtEvent
GwtEvent.Type<H>
 
Field Summary
static GwtEvent.Type<ViewportDragFinishedEventHandler> TYPE
           
 
Constructor Summary
ViewportDragFinishedEvent(Bounds proportionalBounds, Bounds relativePixelBounds, ViewportDragFinishedEventHandler... blockedHandlers)
          Instantiates the event.
 
Method Summary
 GwtEvent.Type<ViewportDragFinishedEventHandler> getAssociatedType()
           
 Bounds getProportionalBounds()
          Returns the bounds of the complete drag as proportional values (0 to 1 based) related to the viewport dimensions.
 Bounds getRelativePixelBounds()
          Returns the bounds of the complete drag as pixel values related to the viewport as the parent element.
protected  void onDispatch(ViewportDragFinishedEventHandler handler)
          Invoked when a handler is contained in the blockedHandlers list
 
Methods inherited from class org.eesgmbh.gimv.client.event.FilteredDispatchGwtEvent
dispatch, getBlockedHandlers, isBlockedHandler
 
Methods inherited from class com.google.gwt.event.shared.GwtEvent
assertLive, getSource, isLive, kill, revive, toDebugString, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE

public static GwtEvent.Type<ViewportDragFinishedEventHandler> TYPE
Constructor Detail

ViewportDragFinishedEvent

public ViewportDragFinishedEvent(Bounds proportionalBounds,
                                 Bounds relativePixelBounds,
                                 ViewportDragFinishedEventHandler... blockedHandlers)
Instantiates the event.

Parameters:
proportionalBounds - Bounds in relation to the size of the Viewport
relativePixelBounds - Bounds as pixels
blockedHandlers - optional handlers that must not be informed (see FilteredDispatchGwtEvent )
Method Detail

getProportionalBounds

public Bounds getProportionalBounds()
Returns the bounds of the complete drag as proportional values (0 to 1 based) related to the viewport dimensions.

Returns:
proportional Bounds

getRelativePixelBounds

public Bounds getRelativePixelBounds()
Returns the bounds of the complete drag as pixel values related to the viewport as the parent element.

Returns:
pixel Bounds

getAssociatedType

public GwtEvent.Type<ViewportDragFinishedEventHandler> getAssociatedType()
Specified by:
getAssociatedType in class GwtEvent<ViewportDragFinishedEventHandler>

onDispatch

protected void onDispatch(ViewportDragFinishedEventHandler handler)
Description copied from class: FilteredDispatchGwtEvent
Invoked when a handler is contained in the blockedHandlers list

Specified by:
onDispatch in class FilteredDispatchGwtEvent<ViewportDragFinishedEventHandler>


Copyright © 2010 - EES GmbH