javax.swing.plaf.basic

Class BasicSplitPaneDivider.VerticalDragController

protected class BasicSplitPaneDivider.VerticalDragController extends BasicSplitPaneDivider.DragController

This is a helper class that controls dragging when the orientation is VERTICAL_SPLIT.
Constructor Summary
protected VerticalDragController(MouseEvent e)
Creates a new VerticalDragController object.
Method Summary
protected intgetNeededLocation(int x, int y)
This method returns one of the two parameters given the orientation.
protected intpositionForMouseEvent(MouseEvent e)
This method returns the new location of the divider given a MouseEvent.

Constructor Detail

VerticalDragController

protected VerticalDragController(MouseEvent e)
Creates a new VerticalDragController object.

Parameters: e The MouseEvent to initialize with.

Method Detail

getNeededLocation

protected int getNeededLocation(int x, int y)
This method returns one of the two parameters given the orientation. In this case, it returns y.

Parameters: x The x coordinate of the MouseEvent. y The y coordinate of the MouseEvent.

Returns: The y coordinate.

positionForMouseEvent

protected int positionForMouseEvent(MouseEvent e)
This method returns the new location of the divider given a MouseEvent.

Parameters: e The MouseEvent.

Returns: The new location of the divider.