org.cruxframework.crux.widgets.client.util.draganddrop
Class ResizeCapability.DragResizeAction

java.lang.Object
  extended by org.cruxframework.crux.widgets.client.util.draganddrop.GenericDragEventHandler.DragAction<ResizeCapability.Resizable<?>>
      extended by org.cruxframework.crux.widgets.client.util.draganddrop.ResizeCapability.DragResizeAction
Enclosing class:
ResizeCapability

public static class ResizeCapability.DragResizeAction
extends GenericDragEventHandler.DragAction<ResizeCapability.Resizable<?>>

The logic needed to resize a widget when user drags a part of it

Author:
Gesse Dafe

Constructor Summary
ResizeCapability.DragResizeAction(ResizeCapability.Resizable<?> resizable, int minWidth, int minHeight)
           
 
Method Summary
 GenericDragEventHandler.DragAndDropFeature getFeature()
          Gets the feature associated to this action
 void onDrag(int x, int y, int dragStartX, int dragStartY)
          Action to me taken when drag happens
 void onStartDrag()
          Action to me taken when drag starts
 
Methods inherited from class org.cruxframework.crux.widgets.client.util.draganddrop.GenericDragEventHandler.DragAction
getDraggable
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResizeCapability.DragResizeAction

public ResizeCapability.DragResizeAction(ResizeCapability.Resizable<?> resizable,
                                         int minWidth,
                                         int minHeight)
Parameters:
movable -
minWidth -
minHeight -
Method Detail

onStartDrag

public void onStartDrag()
Description copied from class: GenericDragEventHandler.DragAction
Action to me taken when drag starts

Specified by:
onStartDrag in class GenericDragEventHandler.DragAction<ResizeCapability.Resizable<?>>

onDrag

public void onDrag(int x,
                   int y,
                   int dragStartX,
                   int dragStartY)
Description copied from class: GenericDragEventHandler.DragAction
Action to me taken when drag happens

Specified by:
onDrag in class GenericDragEventHandler.DragAction<ResizeCapability.Resizable<?>>

getFeature

public GenericDragEventHandler.DragAndDropFeature getFeature()
Description copied from class: GenericDragEventHandler.DragAction
Gets the feature associated to this action

Specified by:
getFeature in class GenericDragEventHandler.DragAction<ResizeCapability.Resizable<?>>
Returns:


Copyright © 2015. All rights reserved.