public class MonitorGui extends javax.swing.JFrame implements MonitorHandler
javax.swing.JFrame.AccessibleJFrame
java.awt.Window.AccessibleAWTWindow, java.awt.Window.Type
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
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
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Constructor and Description |
---|
MonitorGui(Screen screen,
inifile.IniFile inifile,
Warnings warnings,
int jversion,
boolean vibrantCols,
boolean isApplet,
int windowMode,
java.awt.GraphicsConfiguration gd,
java.awt.GraphicsDevice[] gds,
int currentMonitor)
Creates new form MonitorGui.
|
Modifier and Type | Method and Description |
---|---|
void |
deIconify()
Pops the window up if iconified or flashes the taskbar..
|
void |
dividerLocationChanged(int newLocation)
This is called whenever the divider location is changed, saves it to ini file.
|
javax.swing.JTextArea |
getDataLogger()
Gets the left monitor "wdw".
|
static java.awt.Image |
getFDImage(java.lang.String filename)
Returns an Image or null.
|
javax.swing.JTextField |
getInputWindow()
Gets the command line wdw.
|
Monitor |
getMonitor()
Gets the monitor.
|
boolean |
getMouseIsInScreen()
Returns whether the mouse is "in" the Screen object or not.
|
javax.swing.JTextArea |
getRegLogger()
Gets the right monitor wdw.
|
int |
menuBarIsVisible()
Checks whether menu bas is visible.
|
void |
menuBarVisible(boolean state)
Makes the menu bar visible/invisible.
|
void |
monitorCommand(java.lang.String command)
Sends a command to the monitor.
|
void |
setFocus()
Sets the focus to the screen object.
|
void |
setMonitor(Monitor monitor,
boolean getOpts)
Sets the monitor for this wdw.
|
boolean |
setMousePosition(int x,
int y)
Sets a new mouse position if that has changed from within SMSQ/E.
|
void |
setNewDeviceNames(int dType,
java.lang.String[] newNames)
Get some data for device, set new names for a device and save them to the inifile.
|
void |
setRomfile(java.lang.String s)
Sets the name of the romfile.
|
void |
setScreenUpdateInterval(int tim)
Sets the value shown as default value when the screen update interval menu item is actioned.
|
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setBackground, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setOpacity, setResizable, setShape, setState, setTitle, setUndecorated
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBackground, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOpacity, getOwnedWindows, getOwner, getOwnerlessWindows, getShape, getToolkit, getType, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isAutoRequestFocus, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isOpaque, isShowing, isValidateRoot, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setAutoRequestFocus, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocation, setLocation, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setType, setVisible, show, toBack, toFront
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusDownCycle, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
public MonitorGui(Screen screen, inifile.IniFile inifile, Warnings warnings, int jversion, boolean vibrantCols, boolean isApplet, int windowMode, java.awt.GraphicsConfiguration gd, java.awt.GraphicsDevice[] gds, int currentMonitor)
screen
- the Screen
object for displaying things.inifile
- the Inifile
object containing configured values.warnings
- object with warning flags.jversion
- the java version this is compiled for.vibrantCols
- true
if colours should be a little bit brighter.isApplet
- whether this is an applet (if yes, don't set exit_on_close).windowMode
- 0,1,or 2 : window, full screen, special full screen.gd
- the graphics configuration of the current monitor screen we're on.gds
- the info about all monitors that the user has connected.currentMonitor
- nbr of monitor the screen is displayed on in a multi-monitor environment.public void setMonitor(Monitor monitor, boolean getOpts)
monitor
- the monitor to use.getOpts
- true if options should be set.public javax.swing.JTextArea getDataLogger()
javax.swing.JTextArea
corresponds to the left wdw.public javax.swing.JTextArea getRegLogger()
javax.swing.JTextArea
corresponds to the right wdw.public javax.swing.JTextField getInputWindow()
javax.swing.JTextField
.public void setRomfile(java.lang.String s)
s
- the name of the romfile.public void setFocus()
public void monitorCommand(java.lang.String command)
monitorCommand
in interface MonitorHandler
command
- the command string to send.public void setNewDeviceNames(int dType, java.lang.String[] newNames)
dType
- the type of devicenewNames
- the 8-elements String array with the new namespublic void menuBarVisible(boolean state)
state
- = true if menu bar is to be visible, false if not.public int menuBarIsVisible()
public void deIconify()
public static java.awt.Image getFDImage(java.lang.String filename)
filename
- where to get the image from.public final Monitor getMonitor()
public void dividerLocationChanged(int newLocation)
dividerLocationChanged
in interface MonitorHandler
newLocation
- the new divider location.public boolean getMouseIsInScreen()
true
if the mouse pointer is "in" the Screen object, else false
.public boolean setMousePosition(int x, int y)
x
- the new x position, relative to the screen object.y
- same for y.public void setScreenUpdateInterval(int tim)
tim
- the value in milliseconds.