|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container java.awt.Window java.awt.Frame javax.swing.JFrame triptracker.client.gps.ui.GPSGui
public class GPSGui
The main GUI class for the GPS-client
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JFrame |
---|
JFrame.AccessibleJFrame |
Nested classes/interfaces inherited from class java.awt.Frame |
---|
Frame.AccessibleAWTFrame |
Nested classes/interfaces inherited from class java.awt.Window |
---|
Window.AccessibleAWTWindow |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected JMenuItem |
exitItem
|
protected JMenuItem |
generalItem
|
protected JMenuItem |
logOffItem
|
protected JMenuItem |
logOnItem
|
protected JMenuItem |
showRoutesItem
|
Fields inherited from class javax.swing.JFrame |
---|
accessibleContext, EXIT_ON_CLOSE, rootPaneCheckingEnabled |
Fields inherited from class java.awt.Frame |
---|
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface javax.swing.WindowConstants |
---|
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
GPSGui(GPSClientModel model)
Default constructor. |
Method Summary | |
---|---|
void |
addMenuListener(ActionListener listener)
Adds the menulisteners |
JMenuBar |
createMenu()
Creates a menubar. |
void |
deregister(Form form)
Deregisters a form |
void |
enableLogOffItem(boolean enable)
Enables/Disables the logOffItem in the menubar |
void |
enableLogOnItem(boolean enable)
Enables/Disables the logOnItem in the menubar |
void |
enableMenu(boolean b)
Enables the menu if true |
void |
enableRouteItem(boolean enable)
Enables/Disables the routeItem in the menubar |
Form |
getCurrentForm()
Gets the current form |
Form |
getLoginForm()
Gets the form registered as login form |
void |
register(Form form)
Registers a form |
void |
setStatusMsg(String msg)
Set the text of the status bar. |
void |
showErrorDialog(String heading,
String warning)
Shows a warning dialog |
void |
showErrorDialog(String heading,
String error,
ImageIcon icon)
Generates and shows an error dialog |
void |
showForm(Form form)
Shows the given form |
void |
showInfoDialog(String head,
String info)
Shows a info dialog |
void |
showLoginForm()
Shows the login form |
boolean |
showLogOffDialog()
Shows dialog to log off, user have to confirm |
void |
showMainForm()
Shows the main form |
void |
showRoutesForm()
Shows the route form |
void |
showSettingsForm()
Shows the settings form |
Methods inherited from class java.awt.Frame |
---|
addNotify, finalize, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.awt.MenuContainer |
---|
getFont, postEvent |
Field Detail |
---|
protected JMenuItem logOnItem
protected JMenuItem logOffItem
protected JMenuItem exitItem
protected JMenuItem generalItem
protected JMenuItem showRoutesItem
Constructor Detail |
---|
public GPSGui(GPSClientModel model)
Method Detail |
---|
public JMenuBar createMenu()
public void addMenuListener(ActionListener listener)
listener
- public void register(Form form)
register
in interface FormManager
form
- to registerpublic void deregister(Form form)
deregister
in interface FormManager
form
- to de-registerpublic void showForm(Form form)
showForm
in interface FormManager
form
- the form to be showedpublic boolean showLogOffDialog()
public void showErrorDialog(String heading, String warning)
heading
- the heading for the dialogwarning
- the warning to show in the dialogpublic void showInfoDialog(String head, String info)
head
- the headerinfo
- the info messagepublic void setStatusMsg(String msg)
msg
- status messagepublic void showLoginForm()
public void showSettingsForm()
public void showMainForm()
public void showRoutesForm()
public void enableRouteItem(boolean enable)
enable
- true for enable, false for disablepublic void enableLogOffItem(boolean enable)
enable
- true for enable, false for disablepublic void enableLogOnItem(boolean enable)
enable
- true for enable, false for disablepublic void enableMenu(boolean b)
b
- true for enable menupublic Form getCurrentForm()
public Form getLoginForm()
public void showErrorDialog(String heading, String error, ImageIcon icon)
heading
- heading for the errorerror
- the error itselficon
- icon for the error
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |