private static class HubServiceMode.SysTrayWindowConfig extends HubServiceMode.BasicWindowConfig
| Modifier and Type | Field and Description |
|---|---|
private java.awt.MenuItem |
exitItem_ |
private javax.swing.Action |
hideAct_ |
private java.awt.MenuItem |
hideItem_ |
private java.awt.event.ActionListener |
iconListener_ |
private javax.swing.Action |
showAct_ |
private java.awt.MenuItem |
showItem_ |
private SysTray |
sysTray_ |
private java.lang.Object |
trayIcon_ |
configProfiles_, exitAct_, frame_, hubService_, profileTogglers_, runners_| Constructor and Description |
|---|
SysTrayWindowConfig(javax.swing.JFrame frame,
HubProfile[] profiles,
Hub[] runners,
GuiHubService hubService,
SysTray sysTray)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
configureMenus()
Configures menus on the window.
|
void |
configureSysTray()
Performs configuration.
|
void |
configureWindow()
Perform configuration of window.
|
private void |
setWindowVisible(boolean isVis)
Sets visibility for the hub control window, adjusting actions
as appropriate.
|
void |
tidyGui()
Performs any required tidying operations.
|
private java.awt.MenuItem |
toMenuItem(javax.swing.Action act)
Turns an action into an AWT menu item.
|
private final SysTray sysTray_
private final javax.swing.Action showAct_
private final javax.swing.Action hideAct_
private final java.awt.MenuItem showItem_
private final java.awt.MenuItem hideItem_
private final java.awt.MenuItem exitItem_
private final java.awt.event.ActionListener iconListener_
private java.lang.Object trayIcon_
SysTrayWindowConfig(javax.swing.JFrame frame,
HubProfile[] profiles,
Hub[] runners,
GuiHubService hubService,
SysTray sysTray)
frame - hub windowprofiles - hub profiles to runrunners - 1-element array which will contain an associated
hub runner object if one existshubService - object providing hub servicessysTray - system tray facade objectprotected void configureMenus()
HubServiceMode.BasicWindowConfigconfigureMenus in class HubServiceMode.BasicWindowConfigpublic void configureWindow()
HubServiceMode.BasicWindowConfigconfigureWindow in class HubServiceMode.BasicWindowConfigpublic void configureSysTray()
throws java.awt.AWTException
java.awt.AWTExceptionpublic void tidyGui()
HubServiceMode.TidiertidyGui in interface HubServiceMode.TidiertidyGui in class HubServiceMode.BasicWindowConfigprivate void setWindowVisible(boolean isVis)
isVis - true for visible, false for invisibleprivate java.awt.MenuItem toMenuItem(javax.swing.Action act)
act - action