M
- H
- public class NiftyScreen<M extends MenuDialog,H extends HelpDialog>
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
BaseApplication<?,?> |
app
The JME application used for the 3D visualization of the simulation.
|
static de.lessvoid.nifty.elements.Element |
helpPanelElement
The parent element (layer) for the nifty help menu.
|
static de.lessvoid.nifty.elements.Element |
menuLayerElement
The parent element (layer) for the nifty menu.
|
de.lessvoid.nifty.Nifty |
nifty
The Nifty GUI used to render this screen.
|
de.lessvoid.nifty.screen.Screen |
screen
The current and only Screen in the Nifty GUI.
|
static de.lessvoid.nifty.elements.Element |
windowLayerElement
The parent Element (layer) for the nifty windows.
|
Constructor and Description |
---|
NiftyScreen()
The
NiftyScreen constructor. |
Modifier and Type | Method and Description |
---|---|
void |
addContextWindow(java.lang.String id,
AbstractPropertyDialog<?,?> dialog)
Adds the dialog to the context window map.
|
boolean |
contains(java.lang.String dialogId) |
AbstractDialog<?> |
getHelpDialog()
Gets the help dialog.
|
static <M extends MenuDialog,H extends HelpDialog> |
getInstance()
This method returns the singleton instance of
NiftyScreen . |
AbstractDialog<?> |
getMenuDialog()
Gets the menu dialog.
|
void |
hideAllElements()
Hides all Nifty elements.
|
void |
hideContextWindows()
Hides all context windows.
|
void |
removeAllContextWindows()
Removes all context windows.
|
void |
removeAllElements()
Removes all Nifty elements.
|
void |
removeContextWindow(java.lang.String id)
Removes the Nifty element with the given id.
|
void |
showContextWindows()
Shows all context windows.
|
boolean |
showElement(java.lang.String id)
Shows the Nifty element for the given id.
|
void |
showHide(AbstractDialog<?> dialog)
If the given dialog is hidden this method shows it, otherwise hides it.
|
void |
updateContextWindows()
Updates the content of the context windows.
|
public BaseApplication<?,?> app
public de.lessvoid.nifty.Nifty nifty
public de.lessvoid.nifty.screen.Screen screen
public static de.lessvoid.nifty.elements.Element windowLayerElement
public static de.lessvoid.nifty.elements.Element menuLayerElement
public static de.lessvoid.nifty.elements.Element helpPanelElement
public NiftyScreen()
NiftyScreen
constructor.public static <M extends MenuDialog,H extends HelpDialog> NiftyScreen<?,?> getInstance()
NiftyScreen
. If the instance is null, then the singleton
instance is created.public boolean showElement(java.lang.String id)
id
- The id of the element to show.public void showContextWindows()
public void removeContextWindow(java.lang.String id)
id
- The id of the element to be removed.public void removeAllElements()
public void removeAllContextWindows()
public void hideAllElements()
public void hideContextWindows()
public void showHide(AbstractDialog<?> dialog)
dialog
- The dialog to be shown or hidden.public AbstractDialog<?> getHelpDialog()
public AbstractDialog<?> getMenuDialog()
public void updateContextWindows()
public void addContextWindow(java.lang.String id, AbstractPropertyDialog<?,?> dialog)
id
- The dialog iddialog
- The dialog instancepublic boolean contains(java.lang.String dialogId)
dialogId
- The dialog id.