|
|||||||||
| Home >> All >> junk >> gui >> [ window overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
junk.gui.window
Class JXWindow

java.lang.Objectjava.awt.Component
java.awt.Container
java.awt.Window
javax.swing.JWindow
junk.gui.window.JXWindow
- All Implemented Interfaces:
- javax.accessibility.Accessible, java.util.EventListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, javax.swing.RootPaneContainer, java.io.Serializable
- public class JXWindow
- extends javax.swing.JWindow
- implements java.awt.event.MouseListener, java.awt.event.MouseMotionListener
- extends javax.swing.JWindow
JXWindow is a window with a custom drawn border and custom mouse handling
behaviour. All custom components using it must define an empty border that
do not overlap the custom drawn borders so that the custom border will
retain its design. The client defined empty border should be a width of 5
or more if the client has altered the design.
The design decision to include this custom heavy weight is so that some GUI
can be platform independent such that porting it is easy and its behaviour
can remain consistant in varying systems. One such example is the GUI of the
JXController, which needs to exist even if the JD4X windowing module fails or
has not yet been initialized.
This window should only be used if its designed advantage out weigths the
disadvantage of having a non-conforming GUI that must always be custom
crafted from the rest. In addition, the window might not be able to handle
focus and keyboard input well.
- Since:
- JD4X 1.0
- Version:
- 0.1, 15/04/2003
| Nested Class Summary |
| Nested classes inherited from class javax.swing.JWindow |
javax.swing.JWindow.AccessibleJWindow |
| Nested classes inherited from class java.awt.Window |
java.awt.Window.AccessibleAWTWindow |
| Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Field Summary | |
protected java.awt.Image |
jbar_h
Texture to be used for the box |
protected java.awt.Image |
jbar_v
Texture to be used for the box |
protected java.awt.Image |
jcorner_b_lt
Texture to be used for the box |
protected java.awt.Image |
jcorner_b_rt
Texture to be used for the box |
protected java.awt.Image |
jcorner_t_lt
Texture to be used for the box |
protected java.awt.Image |
jcorner_t_rt
Texture to be used for the box |
private boolean |
mouseCenterPressed
Mouse function bits for determining mouse action |
private boolean |
mouseDrag
Mouse function bits for determining mouse action |
private boolean |
mouseLeftPressed
Mouse function bits for determining mouse action |
private boolean |
mouseRightPressed
Mouse function bits for determining mouse action |
private int |
oldvalueX
Locations of the GUI on screen |
private int |
oldvalueY
Locations of the GUI on screen |
protected int |
POLL
Controller of the window movement speed |
private int |
polling
Calculations used for the mouse functions |
private int |
sumx
Calculations used for the mouse functions |
private int |
sumy
Calculations used for the mouse functions |
private int |
valueX
Locations of the GUI on screen |
private int |
valueY
Locations of the GUI on screen |
| Fields inherited from class javax.swing.JWindow |
accessibleContext, rootPane, rootPaneCheckingEnabled |
| Fields inherited from class java.awt.Window |
|
| Fields inherited from class java.awt.Container |
|
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
JXWindow()
|
|
| Method Summary | |
void |
mouseClicked(java.awt.event.MouseEvent clickEvent)
1 click = frame focus and move to front. |
void |
mouseDragged(java.awt.event.MouseEvent draggedEvent)
Move box following mouse position. |
void |
mouseEntered(java.awt.event.MouseEvent enterEvent)
Does nothing. |
void |
mouseExited(java.awt.event.MouseEvent exitEvent)
Does nothing. |
void |
mouseMoved(java.awt.event.MouseEvent movedEvent)
Update mouse position. |
void |
mousePressed(java.awt.event.MouseEvent pressEvent)
Update mouse button pressed. |
void |
mouseReleased(java.awt.event.MouseEvent releaseEvent)
Update mouse button released. |
void |
paint(java.awt.Graphics g)
Clients can extend this method to customize their box texture. |
void |
updateTheme()
Set the default icon and color theme of the window. |
| Methods inherited from class javax.swing.JWindow |
addImpl, createRootPane, getAccessibleContext, getContentPane, getGlassPane, getLayeredPane, getPreferredSize, getRootPane, isRootPaneCheckingEnabled, paramString, processKeyEvent, remove, setContentPane, setGlassPane, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update, windowInit |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
polling
private int polling
- Calculations used for the mouse functions
sumx
private int sumx
- Calculations used for the mouse functions
sumy
private int sumy
- Calculations used for the mouse functions
valueX
private int valueX
- Locations of the GUI on screen
valueY
private int valueY
- Locations of the GUI on screen
oldvalueX
private int oldvalueX
- Locations of the GUI on screen
oldvalueY
private int oldvalueY
- Locations of the GUI on screen
mouseDrag
private boolean mouseDrag
- Mouse function bits for determining mouse action
mouseLeftPressed
private boolean mouseLeftPressed
- Mouse function bits for determining mouse action
mouseRightPressed
private boolean mouseRightPressed
- Mouse function bits for determining mouse action
mouseCenterPressed
private boolean mouseCenterPressed
- Mouse function bits for determining mouse action
POLL
protected int POLL
- Controller of the window movement speed
jcorner_t_lt
protected java.awt.Image jcorner_t_lt
- Texture to be used for the box
jcorner_t_rt
protected java.awt.Image jcorner_t_rt
- Texture to be used for the box
jcorner_b_lt
protected java.awt.Image jcorner_b_lt
- Texture to be used for the box
jcorner_b_rt
protected java.awt.Image jcorner_b_rt
- Texture to be used for the box
jbar_h
protected java.awt.Image jbar_h
- Texture to be used for the box
jbar_v
protected java.awt.Image jbar_v
- Texture to be used for the box
| Constructor Detail |
JXWindow
public JXWindow()
| Method Detail |
mouseClicked
public void mouseClicked(java.awt.event.MouseEvent clickEvent)
- 1 click = frame focus and move to front.
- Specified by:
mouseClickedin interfacejava.awt.event.MouseListener
mouseEntered
public void mouseEntered(java.awt.event.MouseEvent enterEvent)
- Does nothing.
- Specified by:
mouseEnteredin interfacejava.awt.event.MouseListener
mouseExited
public void mouseExited(java.awt.event.MouseEvent exitEvent)
- Does nothing.
- Specified by:
mouseExitedin interfacejava.awt.event.MouseListener
mouseDragged
public void mouseDragged(java.awt.event.MouseEvent draggedEvent)
- Move box following mouse position. (solid move)
- Specified by:
mouseDraggedin interfacejava.awt.event.MouseMotionListener
mouseMoved
public void mouseMoved(java.awt.event.MouseEvent movedEvent)
- Update mouse position.
- Specified by:
mouseMovedin interfacejava.awt.event.MouseMotionListener
mousePressed
public void mousePressed(java.awt.event.MouseEvent pressEvent)
- Update mouse button pressed.
- Specified by:
mousePressedin interfacejava.awt.event.MouseListener
mouseReleased
public void mouseReleased(java.awt.event.MouseEvent releaseEvent)
- Update mouse button released.
- Specified by:
mouseReleasedin interfacejava.awt.event.MouseListener
paint
public void paint(java.awt.Graphics g)
- Clients can extend this method to customize their box texture.
updateTheme
public void updateTheme()
- Set the default icon and color theme of the window.
|
|||||||||
| Home >> All >> junk >> gui >> [ window overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC