All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.sun.java.swing.basic.BasicSplitPaneDivider

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----com.sun.java.swing.basic.BasicSplitPaneDivider

public class BasicSplitPaneDivider
extends Container
implements PropertyChangeListener, Serializable
Divider used by BasicSplitPaneUI. Subclassers may wish to override paint to do something more interesting. The border effect is drawn in BasicSplitPaneUI, so if you don't like that border, reset it there. To conditionally drag from certain areas subclass mousePressed and call super when you wish the dragging to begin.


Variable Index

 o DIVIDER_SIZE
Width or height of the divider based on orientation BasicSplitPaneUI adds two to this.
 o dividerSize
Size of the divider.
 o dragger
Handles mouse dragging message to do the actual dragging.
 o hiddenDivider
Divider that is used for noncontinuous layout mode.
 o leftButton
Button for quickly toggling the left component.
 o mouseHandler
Handle of mouse events.
 o ONE_TOUCH_OFFSET
 o ONE_TOUCH_SIZE
 o orientation
Orientation of the JSplitPane.
 o rightButton
Button for quickly toggling the right component.
 o splitPane
JSplitPane the receiver is contained in.
 o splitPaneUI
UI this instance was created from.

Constructor Index

 o BasicSplitPaneDivider(BasicSplitPaneUI)
Creates an instance of BasicSplitPaneDivider.

Method Index

 o createLeftOneTouchButton()
Creates and return an instance of JButton that can be used to collapse the left component in the split pane.
 o createRightOneTouchButton()
Creates and return an instance of JButton that can be used to collapse the right component in the split pane.
 o dragDividerTo(int)
Messages the BasicSplitPaneUI with dragDividerTo that this instance is contained in.
 o finishDraggingTo(int)
Messages the BasicSplitPaneUI with finishDraggingTo that this instance is contained in.
 o getBasicSplitPaneUI()
Returns the SplitPaneUI the receiver is currently in.
 o getDividerSize()
Returns the size of the divider, that is the width if the splitpane is HORIZONTAL_SPLIT, or the height of VERTICAL_SPLIT.
 o getPreferredSize()
Returns dividerSize x dividerSize
 o oneTouchExpandableChanged()
Messaged when the oneTouchExpandable value of the JSplitPane the receiver is contained in changes.
 o paint(Graphics)
Paints the divider.
 o prepareForDragging()
Message to prepare for dragging.
 o propertyChange(PropertyChangeEvent)
Property change event, presumably from the JSplitPane, will message updateOrientation if necessary.
 o setBasicSplitPaneUI(BasicSplitPaneUI)
Sets the SplitPaneUI that is using the receiver.
 o setDividerSize(int)
Sets the size of the divider to newSize.

Variables

 o DIVIDER_SIZE
 public static final int DIVIDER_SIZE
Width or height of the divider based on orientation BasicSplitPaneUI adds two to this.

 o ONE_TOUCH_SIZE
 protected static final int ONE_TOUCH_SIZE
 o ONE_TOUCH_OFFSET
 protected static final int ONE_TOUCH_OFFSET
 o dragger
 protected BasicSplitPaneDivider. DragController dragger
Handles mouse dragging message to do the actual dragging.

 o splitPaneUI
 protected BasicSplitPaneUI splitPaneUI
UI this instance was created from.

 o dividerSize
 protected int dividerSize
Size of the divider.

 o hiddenDivider
 protected Component hiddenDivider
Divider that is used for noncontinuous layout mode.

 o splitPane
 protected JSplitPane splitPane
JSplitPane the receiver is contained in.

 o mouseHandler
 protected BasicSplitPaneDivider. MouseHandler mouseHandler
Handle of mouse events.

 o orientation
 protected int orientation
Orientation of the JSplitPane.

 o leftButton
 protected JButton leftButton
Button for quickly toggling the left component.

 o rightButton
 protected JButton rightButton
Button for quickly toggling the right component.

Constructors

 o BasicSplitPaneDivider
 public BasicSplitPaneDivider(BasicSplitPaneUI ui)
Creates an instance of BasicSplitPaneDivider. Registers this instance for mouse events and mouse dragged events.

Methods

 o setBasicSplitPaneUI
 public void setBasicSplitPaneUI(BasicSplitPaneUI newUI)
Sets the SplitPaneUI that is using the receiver.

 o getBasicSplitPaneUI
 public BasicSplitPaneUI getBasicSplitPaneUI()
Returns the SplitPaneUI the receiver is currently in.

 o setDividerSize
 public void setDividerSize(int newSize)
Sets the size of the divider to newSize. That is the width if the splitpane is HORIZONTAL_SPLIT, or the height of VERTICAL_SPLIT.

 o getDividerSize
 public int getDividerSize()
Returns the size of the divider, that is the width if the splitpane is HORIZONTAL_SPLIT, or the height of VERTICAL_SPLIT.

 o getPreferredSize
 public Dimension getPreferredSize()
Returns dividerSize x dividerSize

Overrides:
getPreferredSize in class Container
 o propertyChange
 public void propertyChange(PropertyChangeEvent e)
Property change event, presumably from the JSplitPane, will message updateOrientation if necessary.

 o paint
 public void paint(Graphics g)
Paints the divider.

Overrides:
paint in class Container
 o oneTouchExpandableChanged
 protected void oneTouchExpandableChanged()
Messaged when the oneTouchExpandable value of the JSplitPane the receiver is contained in changes. Will create the leftButton and rightButton if they are null. invalidates the receiver as well.

 o createLeftOneTouchButton
 protected JButton createLeftOneTouchButton()
Creates and return an instance of JButton that can be used to collapse the left component in the split pane.

 o createRightOneTouchButton
 protected JButton createRightOneTouchButton()
Creates and return an instance of JButton that can be used to collapse the right component in the split pane.

 o prepareForDragging
 protected void prepareForDragging()
Message to prepare for dragging. This messages the BasicSplitPaneUI with startDragging.

 o dragDividerTo
 protected void dragDividerTo(int location)
Messages the BasicSplitPaneUI with dragDividerTo that this instance is contained in.

 o finishDraggingTo
 protected void finishDraggingTo(int location)
Messages the BasicSplitPaneUI with finishDraggingTo that this instance is contained in.


All Packages  Class Hierarchy  This Package  Previous  Next  Index