com.realtime.crossfire.jxclient.window.GuiManager Class Reference

Collaboration diagram for com.realtime.crossfire.jxclient.window.GuiManager:
Collaboration graph
[legend]

List of all members.

Public Types

enum  EscAction { IGNORE, DISCONNECT, QUIT }

Public Member Functions

 GuiManager (@NotNull final GuiStateManager guiStateManager,@NotNull final TooltipManagerImpl tooltipManager,@NotNull final Settings settings,@NotNull final CrossfireServerConnection server,@NotNull final JXCWindowRenderer windowRenderer,@NotNull final GuiFactory guiFactory,@NotNull final KeybindingsManager keybindingsManager,@NotNull final JXCConnection connection)
void playerReceived ()
void manageAccount ()
void showCharacters ()
void hideAccountWindows ()
boolean openQuitDialog ()
EscAction escPressed (final boolean connected)
void openQueryDialog (@NotNull final String prompt, final int queryType)
boolean openDialog (@NotNull final Gui dialog, final boolean autoCloseOnDeactivate)
void toggleDialog (@NotNull final Gui dialog)
void closeQueryDialog ()
void closeKeybindDialog ()
boolean closeDialog (@NotNull final Gui dialog)
void updatePlayerName (@NotNull final String playerName)
void activateCommandInput (@Nullable final String newText)
void unsetSkin ()
void setSkin (@NotNull final JXCSkin skin)
void term ()
boolean createKeyBinding (final boolean perCharacter,@NotNull final CommandList cmdList)
boolean removeKeyBinding (final boolean perCharacter)
void updateWindowSize (final int width, final int height)
CommandList getCommandList (@NotNull final String args) throws NoSuchCommandException
void setAccountName (@NotNull final String accountName)
void selectCharacter (@NotNull final String accountName,@NotNull final String characterName)

Detailed Description

Maintains the application's main GUI state.

Author:
Andreas Kirschbaum

Definition at line 54 of file GuiManager.java.


Member Enumeration Documentation

Action after ESC has been pressed.

Enumerator:
IGNORE 

Ignore the key press.

DISCONNECT 

Disconnect from server.

QUIT 

Quit the application.

Definition at line 969 of file GuiManager.java.


Constructor & Destructor Documentation

com.realtime.crossfire.jxclient.window.GuiManager.GuiManager ( @NotNull final GuiStateManager  guiStateManager,
@NotNull final TooltipManagerImpl  tooltipManager,
@NotNull final Settings  settings,
@NotNull final CrossfireServerConnection  server,
@NotNull final JXCWindowRenderer  windowRenderer,
@NotNull final GuiFactory  guiFactory,
@NotNull final KeybindingsManager  keybindingsManager,
@NotNull final JXCConnection  connection 
)

Creates a new instance.

Parameters:
guiStateManager the gui state manager to watch
tooltipManager the tooltip manager to update
settings the settings to use
server the crossfire server connection to monitor
windowRenderer the window renderer to use
guiFactory the gui factory for creating gui instances
keybindingsManager the keybindings manager to use
connection the connection to use

Definition at line 344 of file GuiManager.java.


Member Function Documentation

void com.realtime.crossfire.jxclient.window.GuiManager.activateCommandInput ( @Nullable final String  newText  ) 

Activates the command input text field. If the skin defines more than one input field, the first matching one is selected.

If neither the main gui nor any visible dialog has an input text field, invisible GUIs are checked as well. If one is found, it is made visible.

Parameters:
newText the new command text if non-null

Definition at line 740 of file GuiManager.java.

Here is the call graph for this function:

boolean com.realtime.crossfire.jxclient.window.GuiManager.closeDialog ( @NotNull final Gui  dialog  ) 

Closes the given dialog. Does nothing if the dialog is not opened.

Parameters:
dialog the dialog to close
Returns:
whether the dialog has been closed; false if the dialog was not open

Definition at line 688 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.closeKeybindDialog (  ) 

Closes the keybinding dialog. Does nothing if the dialog is not opened.

Definition at line 674 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.closeQueryDialog (  ) 

Closes the "query" dialog. Does nothing if the dialog is not open.

Definition at line 576 of file GuiManager.java.

Here is the call graph for this function:

boolean com.realtime.crossfire.jxclient.window.GuiManager.createKeyBinding ( final boolean  perCharacter,
@NotNull final CommandList  cmdList 
)

Adds a key binding.

Parameters:
perCharacter whether a per-character key binding should be added
cmdList the command list to execute on key press
Returns:
whether the key bindings dialog should be opened

Definition at line 879 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

EscAction com.realtime.crossfire.jxclient.window.GuiManager.escPressed ( final boolean  connected  ) 

The ESC key has been pressed.

Parameters:
connected whether a connection to the server is active
Returns:
whether how the key has been consumed: 0=ignore key, 1=disconnect from server, quit=quit application

Definition at line 432 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

CommandList com.realtime.crossfire.jxclient.window.GuiManager.getCommandList ( @NotNull final String  args  )  throws NoSuchCommandException

Returns a named command list.

Parameters:
args the name of the command list
Returns:
the command list
Exceptions:
NoSuchCommandException if the command list does not exist

Definition at line 924 of file GuiManager.java.

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.hideAccountWindows (  ) 

Hides all account-related windows.

Definition at line 395 of file GuiManager.java.

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.manageAccount (  ) 

Displays the main account dialog, to let the player login or create a new account.

Definition at line 372 of file GuiManager.java.

Here is the call graph for this function:

boolean com.realtime.crossfire.jxclient.window.GuiManager.openDialog ( @NotNull final Gui  dialog,
final boolean  autoCloseOnDeactivate 
)

Opens a dialog. Raises the dialog if it is open.

Parameters:
dialog the dialog to show
autoCloseOnDeactivate whether the dialog should auto-close when it becomes inactive; ignored if the dialog is already open
Returns:
whether the dialog was opened or raised; false if the dialog already was opened as the topmost dialog

Definition at line 512 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.openQueryDialog ( @NotNull final String  prompt,
final int  queryType 
)

Opens the "query" dialog.

Parameters:
prompt the query prompt
queryType the query type

Definition at line 471 of file GuiManager.java.

Here is the call graph for this function:

boolean com.realtime.crossfire.jxclient.window.GuiManager.openQuitDialog (  ) 

Opens the "quit" dialog. Does nothing if the dialog is open.

Returns:
whether the dialog has been opened

Definition at line 409 of file GuiManager.java.

Here is the call graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.playerReceived (  ) 

A "player" protocol command has been received.

Definition at line 361 of file GuiManager.java.

Here is the call graph for this function:

boolean com.realtime.crossfire.jxclient.window.GuiManager.removeKeyBinding ( final boolean  perCharacter  ) 

Removes a key binding.

Parameters:
perCharacter whether a per-character key binding should be removed
Returns:
whether the key bindings dialog should be opened

Definition at line 893 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.selectCharacter ( @NotNull final String  accountName,
@NotNull final String  characterName 
)

Updates the selected character name in an account.

Parameters:
accountName the account name
characterName the character name

Definition at line 949 of file GuiManager.java.

Here is the call graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.setAccountName ( @NotNull final String  accountName  ) 

Updates the current account name.

Parameters:
accountName the current account name

Definition at line 940 of file GuiManager.java.

Here is the call graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.setSkin ( @NotNull final JXCSkin  skin  ) 

Sets a new skin.

Parameters:
skin the new skin

Definition at line 768 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.showCharacters (  ) 

Displays the window with the characters for an account.

Definition at line 384 of file GuiManager.java.

Here is the call graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.term (  ) 

Terminates the GUI. Stops display updates and saves the display state.

Definition at line 816 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.toggleDialog ( @NotNull final Gui  dialog  ) 

Toggles a dialog.

Parameters:
dialog the dialog to toggle

Definition at line 567 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.unsetSkin (  ) 

Unsets the current skin.

Definition at line 750 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.updatePlayerName ( @NotNull final String  playerName  ) 

Sets the current player name. Does nothing if not currently in the character name prompt.

Parameters:
playerName the player name

Definition at line 697 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:

void com.realtime.crossfire.jxclient.window.GuiManager.updateWindowSize ( final int  width,
final int  height 
)

Sets a new window size.

Parameters:
width the new window width
height the new window height

Definition at line 906 of file GuiManager.java.

Here is the call graph for this function:

Here is the caller graph for this function:


The documentation for this class was generated from the following file:
Generated on Sun Nov 6 15:57:01 2011 for Crossfire JXClient, Trunk by  doxygen 1.6.3