public class WindowDecorationBehavior extends ComponentMoveBehavior
Modifier and Type | Field and Description |
---|---|
protected AbstractTransition<Float> |
fadeIn
Fade-in transition.
|
protected WebDialog |
glassDialog
Custom-styled glass dialog displaying side frame might be attached to.
|
protected Rectangle |
normalBounds
Window bounds in normal state.
|
protected WRootPaneUI |
rootPaneUI
WRootPaneUI containing title this behavior is attached to. |
protected Rectangle |
stickBounds
Window stick bounds.
|
protected CompassDirection |
stickDirection
Window stick direction.
|
dragged, dragging, enabled, gripper, initialBounds, initialPoint, target
Constructor and Description |
---|
WindowDecorationBehavior(WRootPaneUI rootPaneUI)
Constructs new behavior for windows with custom decoration.
|
Modifier and Type | Method and Description |
---|---|
protected void |
componentMoved(Point mouse,
Point location)
Informs about component being moved due to drag.
|
protected void |
componentMoveEnded(Point mouse,
Point location)
Informs about component move end.
|
protected void |
componentMoveStarted(Point mouse,
Point location)
Informs about component move start.
|
protected void |
displayGlassDialog(Rectangle screen,
CompassDirection direction)
Displays glass dialog.
|
protected void |
disposeGlassDialog()
Disposes glass dialog.
|
protected JFrame |
getFrame()
Returns frame this behavior is working with at this moment.
|
protected boolean |
isFrame()
Returns whether or not
rootPaneUI is used for JFrame root pane. |
protected boolean |
isGlassDialogVisible()
Returns whether or not glass dialog is visible.
|
protected boolean |
isMaximizable()
Returns whether or not maximize is available for this behavior.
|
protected boolean |
isResizable()
Returns whether or not resize is available for this behavior.
|
protected boolean |
isStickingAvailable()
Returns whether or not sticking to display sides is available for this behavior.
|
void |
mouseClicked(MouseEvent e) |
void |
mouseDragged(MouseEvent e) |
getDraggedComponent, getDragStartBounds, install, isEnabled, mousePressed, mouseReleased, setEnabled, uninstall
mouseEntered, mouseExited, mouseMoved, mouseWheelMoved
protected final WRootPaneUI rootPaneUI
WRootPaneUI
containing title this behavior is attached to.protected WebDialog glassDialog
protected Rectangle normalBounds
protected Rectangle stickBounds
protected CompassDirection stickDirection
protected final AbstractTransition<Float> fadeIn
public WindowDecorationBehavior(WRootPaneUI rootPaneUI)
rootPaneUI
- WRootPaneUI
public void mouseClicked(MouseEvent e)
mouseClicked
in interface MouseListener
mouseClicked
in class MouseAdapter
public void mouseDragged(MouseEvent e)
mouseDragged
in interface MouseMotionListener
mouseDragged
in class ComponentMoveBehavior
protected void componentMoveStarted(Point mouse, Point location)
ComponentMoveBehavior
componentMoveStarted
in class ComponentMoveBehavior
mouse
- mouse locationlocation
- component locationprotected void componentMoved(Point mouse, Point location)
ComponentMoveBehavior
componentMoved
in class ComponentMoveBehavior
mouse
- new mouse locationlocation
- new component locationprotected void componentMoveEnded(Point mouse, Point location)
ComponentMoveBehavior
componentMoveEnded
in class ComponentMoveBehavior
mouse
- mouse locationlocation
- component locationprotected void displayGlassDialog(Rectangle screen, CompassDirection direction)
screen
- glass dialog boundsdirection
- stick directionprotected void disposeGlassDialog()
protected boolean isGlassDialogVisible()
protected boolean isFrame()
rootPaneUI
is used for JFrame
root pane.true
if rootPaneUI
is used for JFrame
root pane, false
otherwiseprotected JFrame getFrame()
protected boolean isResizable()
true
if resize is available for this behavior, false
otherwiseprotected boolean isMaximizable()
true
if maximize is available for this behavior, false
otherwiseprotected boolean isStickingAvailable()
true
if sticking to display sides is available for this behavior, false
otherwiseCopyright © 2020. All rights reserved.