xoreos
0.0.5
|
#include <gui.h>
Public Member Functions | |
GUI (Console *console=0) | |
virtual | ~GUI () |
virtual void | show () |
Show the GUI. More... | |
virtual void | hide () |
Hide the GUI. More... | |
uint32 | run (uint32 startCode=kStartCodeNone) |
Run the GUI. More... | |
virtual void | abort () |
Abort the currently running GUI. More... | |
void | addEvent (const Events::Event &event) |
Add a single event for consideration into the GUI event queue. More... | |
uint32 | processEventQueue () |
Process the current event queue. More... | |
virtual Common::UString | getName () const |
Static Public Attributes | |
static const uint32 | kStartCodeNone = 0 |
static const uint32 | kReturnCodeNone = 0 |
static const uint32 | kReturnCodeAbort = 0xFFFFFFFF |
Protected Member Functions | |
void | addWidget (Widget *widget) |
Add a widget. More... | |
void | removeWidget (Widget *widget) |
Remove a widget. More... | |
void | clearWidgets () |
Clear all widgets. More... | |
bool | empty () |
Check if the gui is currently empty. More... | |
bool | hasWidget (const Common::UString &tag) const |
Does this specific widget exist within the GUI? More... | |
Widget * | getWidget (const Common::UString &tag, bool vital=false) |
Return a widget in the GUI. More... | |
const Widget * | getWidget (const Common::UString &tag, bool vital=false) const |
Return a widget in the GUI. More... | |
void | declareGroup (const std::list< Widget *> &group) |
Put these widgets together into a group. More... | |
void | removeFocus () |
Forcefully remove the focus from the current widget. More... | |
void | updateMouse () |
Force an update of the mouse position. More... | |
virtual void | mouseUp () |
The mouse state has changed. More... | |
virtual void | mouseDown () |
uint32 | sub (GUI &gui, uint32 startCode=kStartCodeNone, bool showSelf=true, bool hideSelf=true) |
Open up a sub GUI. More... | |
void | setPosition (float x, float y, float z) |
Set the GUI's position. More... | |
void | getPosition (float &x, float &y, float &z) const |
Get the GUI's position. More... | |
virtual void | callbackRun () |
Callback that's triggered periodically in the run() method. More... | |
virtual void | callbackActive (Widget &widget) |
Callback that's triggered when a widget was activated. More... | |
virtual void | callbackTextInput (const Common::UString &text) |
Callback that's triggered when a text input is received. More... | |
virtual void | callbackKeyInput (const Events::Key &key, const Events::EventType &type) |
Callback that's triggered when a key is pressed or released. More... | |
void | addChild (GUI *gui) |
Add a child GUI object to this GUI. More... | |
void | removeChild (GUI *gui) |
Remove a child GUI object from this GUI. More... | |
Protected Attributes | |
Console * | _console |
Widget * | _currentWidget |
The widget the mouse is currently on. More... | |
uint32 | _startCode |
The GUI's start code. More... | |
uint32 | _returnCode |
The GUI's return code. More... | |
GUI * | _sub |
The currently running sub GUI. More... | |
Private Types | |
typedef std::list< Widget * > | WidgetList |
typedef std::map< Common::UString, Widget * > | WidgetMap |
Private Member Functions | |
Widget * | getWidgetAt (float x, float y) |
Return the widget at that position. More... | |
void | changedWidget (Widget *widget) |
The current widget has changed. More... | |
void | checkWidgetActive (Widget *widget) |
Check if a widget was activated. More... | |
void | mouseMove (const Events::Event &event) |
Mouse move event triggered. More... | |
void | mouseDown (const Events::Event &event) |
Mouse down event triggered. More... | |
void | mouseUp (const Events::Event &event) |
Mouse up event triggered. More... | |
void | mouseWheel (const Events::Event &event) |
Mouse wheel event triggered. More... | |
void | textInput (const Events::Event &event) |
Text input event received. More... | |
void | keyDown (const Events::Event &event) |
Key down event triggered. More... | |
void | keyUp (const Events::Event &event) |
Key up event triggeered. More... | |
float | toGUIX (int x) |
float | toGUIY (int y) |
void | mouseMove (Widget *widget, const Events::Event &event) |
Send a mouse move event to the widget. More... | |
void | mouseDown (Widget *widget, const Events::Event &event) |
Send a mouse down event to the widget. More... | |
void | mouseUp (Widget *widget, const Events::Event &event) |
Send a mouse up event to the widget. More... | |
void | mouseWheel (Widget *widget, const Events::Event &event) |
Send a mouse wheel event to the widget. More... | |
Private Attributes | |
std::list< GUI * > | _childGUIs |
WidgetList | _widgets |
All widgets in the GUI. More... | |
WidgetMap | _widgetMap |
All widgets in the GUI, index by their tag. More... | |
float | _x |
The GUI X position. More... | |
float | _y |
The GUI Y position. More... | |
float | _z |
The GUI Z position. More... | |
std::list< Events::Event > | _eventQueue |
The GUI event queue. More... | |
Friends | |
class | Widget |
|
private |
|
private |
|
virtual |
Reimplemented in Engines::Jade::GUI, Engines::KotOR::GUI, and Engines::NWN::GUI.
Definition at line 52 of file gui.cpp.
References _widgets.
|
virtual |
Abort the currently running GUI.
Reimplemented in Engines::NWN::MainMenu.
Definition at line 156 of file gui.cpp.
References _returnCode, _sub, abort(), and kReturnCodeAbort.
Referenced by Engines::NWN::MainMenu::abort(), and abort().
|
protected |
Add a child GUI object to this GUI.
Ownership of the pointer is not transferred.
Definition at line 240 of file gui.cpp.
References _childGUIs, and show().
Referenced by Engines::KotOR::CharacterGenerationMenu::showCustom(), Engines::KotOR2::CharacterGeneration::showCustomChar(), Engines::KotOR::Menu::showMenu(), Engines::KotOR::CharacterGenerationMenu::showQuick(), Engines::KotOR2::CharacterGeneration::showQuickChar(), Engines::KotOR2::CharacterGeneration::showQuickOrCustom(), and Engines::KotOR::CharacterGenerationMenu::showQuickOrCustom().
void Engines::GUI::addEvent | ( | const Events::Event & | event | ) |
Add a single event for consideration into the GUI event queue.
Definition at line 163 of file gui.cpp.
References _eventQueue.
Referenced by run().
|
protected |
Add a widget.
Definition at line 250 of file gui.cpp.
References _widgetMap, _widgets, Common::UString::c_str(), Common::UString::empty(), Engines::Widget::getTag(), getWidget(), and hasWidget().
Referenced by Engines::Widget::addSub(), Engines::NWN::CharPortrait::CharPortrait(), Engines::NWN::Compass::Compass(), Engines::NWN::GUI::loadWidget(), Engines::KotOR::GUI::loadWidget(), Engines::Jade::GUI::loadWidget(), Engines::NWN::MainMenu::MainMenu(), Engines::NWN::OptionsControlsMenu::OptionsControlsMenu(), Engines::NWN::OptionsFeedbackMenu::OptionsFeedbackMenu(), Engines::NWN::OptionsGameMenu::OptionsGameMenu(), Engines::NWN::OptionsGorePasswordMenu::OptionsGorePasswordMenu(), Engines::NWN::OptionsMenu::OptionsMenu(), Engines::KotOR::OptionsMenu::OptionsMenu(), Engines::NWN::OptionsResolutionMenu::OptionsResolutionMenu(), Engines::NWN::OptionsSoundAdvancedMenu::OptionsSoundAdvancedMenu(), Engines::NWN::OptionsSoundMenu::OptionsSoundMenu(), Engines::NWN::OptionsVideoAdvancedMenu::OptionsVideoAdvancedMenu(), Engines::NWN::OptionsVideoMenu::OptionsVideoMenu(), Engines::NWN::PartyLeader::PartyLeader(), Engines::NWN::Quickbar::Quickbar(), and Engines::NWN::Quickchat::Quickchat().
|
protectedvirtual |
Callback that's triggered when a widget was activated.
Reimplemented in Engines::KotOR::Menu, Engines::NWN::NewPremiumMenu, Engines::NWN::NewModuleMenu, Engines::KotOR::HUD, Engines::Jade::OptionsMenu, Engines::NWN::CharSpells, Engines::NWN::CharPremadeMenu, Engines::NWN::CharFeats, Engines::NWN::CharSkills, Engines::NWN::Quickbar, Engines::NWN::Quickchat, Engines::NWN::CharDomain, Engines::NWN::CharInfoVoice, Engines::NWN::CharPortrait, Engines::NWN::PartyLeader, Engines::KotOR::SaveLoadMenu, Engines::KotOR::DialogGUIBase, Engines::NWN::CharAttributes, Engines::KotOR::ClassSelectionMenu, Engines::NWN::Compass, Engines::KotOR::CharacterGenerationBaseMenu, Engines::KotOR::MenuEquipment, Engines::KotOR::MenuOptions, Engines::NWN::OptionsResolutionMenu, Engines::KotOR::MainMenu, Engines::NWN::CharGenMenu, Engines::NWN::CharPackage, Engines::NWN::OKCancelDialog, Engines::NWN::YesNoCancelDialog, Engines::NWN::MainMenu, Engines::KotOR::OptionsMenu, Engines::NWN::CharAlignment, Engines::NWN::CharClass, Engines::NWN::OptionsGameMenu, Engines::NWN::OptionsSoundMenu, Engines::NWN::CharRace, Engines::NWN::CharSchool, Engines::NWN::CharSex, Engines::NWN::IngameMainMenu, Engines::Jade::MainMenu, Engines::KotOR::MenuMap, Engines::KotOR2::ClassSelection, Engines::NWN::CharAppearance, Engines::NWN::CharFeatsPopup, Engines::NWN::CharHelp, Engines::NWN::OptionsMenu, Engines::NWN::OptionsVideoMenu, Engines::NWN::OptionsVideoAdvancedMenu, Engines::KotOR::ContainerMenu, Engines::NWN::CharTypeMenu, Engines::NWN::NewMenu, Engines::NWN::NewCampMenu, Engines::NWN::OptionsFeedbackMenu, Engines::KotOR::ConfirmDialog, Engines::KotOR::OptionsGameplayMenu, Engines::KotOR::OptionsGraphicsMenu, Engines::KotOR2::CharacterGenerationNameMenu, Engines::KotOR2::MainMenu, Engines::NWN::NewXP1Menu, Engines::NWN::NewXP2Menu, Engines::KotOR::CharacterGenerationNameMenu, Engines::KotOR::CharacterGenerationPortraitMenu, Engines::KotOR::PartySelectionGUI, Engines::NWN::MoviesCampMenu, Engines::NWN::OptionsSoundAdvancedMenu, Engines::KotOR::QuickOrCustomPanel, Engines::KotOR::OptionsAutoPauseMenu, Engines::KotOR::OptionsGraphicsAdvancedMenu, Engines::KotOR::OptionsMouseSettingsMenu, Engines::KotOR::OptionsSoundMenu, Engines::KotOR::OptionsSoundAdvancedMenu, Engines::KotOR::CustomCharPanel, Engines::KotOR::QuickCharPanel, Engines::KotOR::MoviesMenu, Engines::KotOR::OptionsResolutionMenu, Engines::KotOR2::QuickCharPanel, Engines::NWN::MoviesBaseMenu, Engines::NWN::OptionsControlsMenu, Engines::NWN::OptionsGorePasswordMenu, Engines::KotOR::OptionsFeedbackMenu, Engines::KotOR::OptionsKeyboardConfigurationMenu, Engines::KotOR2::CustomCharPanel, Engines::KotOR2::QuickOrCustomPanel, Engines::Jade::AudioOptionsMenu, Engines::Jade::ControlOptionsMenu, Engines::Jade::DifficultyOptionsMenu, Engines::Jade::GameInfoOptionsMenu, Engines::Jade::VideoOptionsMenu, Engines::KotOR::MenuAbilities, Engines::KotOR::MenuCharacter, Engines::KotOR::MenuInventory, Engines::KotOR::MenuJournal, Engines::KotOR::MenuMessages, and Engines::KotOR2::CharacterGenerationPortraitMenu.
Definition at line 231 of file gui.cpp.
Referenced by checkWidgetActive(), and Engines::Widget::raiseCallbackActive().
|
protectedvirtual |
Callback that's triggered when a key is pressed or released.
Reimplemented in Engines::KotOR::SaveLoadMenu, Engines::KotOR::CharacterGenerationMenu, Engines::KotOR::DialogGUIBase, Engines::KotOR::ClassSelectionMenu, Engines::KotOR::MenuEquipment, Engines::KotOR::ContainerMenu, Engines::KotOR2::CharacterGenerationNameMenu, and Engines::KotOR::CharacterGenerationNameMenu.
Definition at line 237 of file gui.cpp.
Referenced by keyDown(), and keyUp().
|
protectedvirtual |
Callback that's triggered periodically in the run() method.
Reimplemented in Engines::KotOR::Menu, Engines::Jade::OptionsMenu, Engines::NWN::CharFeats, Engines::KotOR::ClassSelectionMenu, Engines::KotOR::MenuEquipment, and Engines::KotOR2::ClassSelection.
Definition at line 227 of file gui.cpp.
References _startCode, and kStartCodeNone.
Referenced by run().
|
protectedvirtual |
Callback that's triggered when a text input is received.
Reimplemented in Engines::KotOR2::CharacterGenerationNameMenu, and Engines::KotOR::CharacterGenerationNameMenu.
Definition at line 234 of file gui.cpp.
Referenced by textInput().
|
private |
The current widget has changed.
Definition at line 456 of file gui.cpp.
References _currentWidget, Engines::Widget::enter(), and Engines::Widget::leave().
Referenced by mouseDown(), mouseMove(), mouseUp(), mouseWheel(), and removeFocus().
|
private |
Check if a widget was activated.
Definition at line 469 of file gui.cpp.
References Engines::Widget::_owner, callbackActive(), Engines::Widget::isActive(), Engines::Widget::setActive(), and Engines::Widget::subActive().
Referenced by mouseMove(), and mouseUp().
|
protected |
Clear all widgets.
Definition at line 295 of file gui.cpp.
References _widgetMap, and _widgets.
Referenced by Engines::KotOR::GUI::load().
|
protected |
Put these widgets together into a group.
Definition at line 340 of file gui.cpp.
Referenced by Engines::NWN::OptionsControlsMenu::OptionsControlsMenu(), Engines::NWN::OptionsFeedbackMenu::OptionsFeedbackMenu(), Engines::NWN::OptionsGameMenu::OptionsGameMenu(), and Engines::NWN::OptionsSoundMenu::OptionsSoundMenu().
|
protected |
Check if the gui is currently empty.
Definition at line 306 of file gui.cpp.
References _widgets.
Referenced by Engines::KotOR::GUI::load(), and Engines::NWN::CharSpells::showSpellLevel().
|
virtual |
Reimplemented in Engines::Jade::GUI, and Engines::KotOR::GUI.
|
protected |
|
protected |
Return a widget in the GUI.
Definition at line 314 of file gui.cpp.
References _widgetMap, and Common::UString::c_str().
Referenced by addWidget(), Engines::NWN::CharAppearance::adjustButtons(), Engines::KotOR::ClassSelectionMenu::callbackKeyInput(), Engines::KotOR::CharacterGenerationMenu::callbackKeyInput(), Engines::KotOR::CharacterGenerationMenu::CharacterGenerationMenu(), Engines::NWN::CharGenMenu::CharGenMenu(), Engines::NWN::CharInfoVoice::CharInfoVoice(), Engines::NWN::CharPremadeMenu::CharPremadeMenu(), Engines::NWN::CharRace::CharRace(), Engines::NWN::GUI::getButton(), Engines::KotOR::GUI::getButton(), Engines::Jade::GUI::getButton(), Engines::NWN::GUI::getCheckBox(), Engines::KotOR::GUI::getCheckBox(), Engines::Jade::GUI::getCheckBox(), Engines::NWN::GUI::getClose(), Engines::NWN::GUI::getEditBox(), Engines::NWN::GUI::getFrame(), Engines::NWN::GUI::getLabel(), Engines::Jade::GUI::getLabel(), Engines::KotOR::GUI::getLabel(), Engines::NWN::GUI::getListBox(), Engines::KotOR::GUI::getListBox(), Engines::Jade::GUI::getListBox(), Engines::NWN::GUI::getPanel(), Engines::Jade::GUI::getPanel(), Engines::KotOR::GUI::getPanel(), Engines::KotOR::GUI::getProgressbar(), Engines::Jade::GUI::getProgressbar(), Engines::Jade::GUI::getProtoItem(), Engines::KotOR::GUI::getProtoItem(), Engines::NWN::GUI::getScrollbar(), Engines::KotOR::GUI::getScrollbar(), Engines::Jade::GUI::getScrollbar(), Engines::NWN::GUI::getSlider(), Engines::KotOR::GUI::getSlider(), Engines::Jade::GUI::getSlider(), getWidgetAt(), hasWidget(), Engines::NWN::IngameMainMenu::IngameMainMenu(), Engines::NWN::MainMenu::MainMenu(), Engines::NWN::MoviesCampMenu::MoviesCampMenu(), Engines::NWN::NewCampMenu::NewCampMenu(), Engines::NWN::NewMenu::NewMenu(), Engines::NWN::NewXP1Menu::NewXP1Menu(), Engines::NWN::NewXP2Menu::NewXP2Menu(), Engines::NWN::OptionsControlsMenu::OptionsControlsMenu(), Engines::NWN::OptionsFeedbackMenu::OptionsFeedbackMenu(), Engines::NWN::OptionsGameMenu::OptionsGameMenu(), Engines::NWN::OptionsGorePasswordMenu::OptionsGorePasswordMenu(), Engines::NWN::OptionsSoundAdvancedMenu::OptionsSoundAdvancedMenu(), Engines::NWN::OptionsSoundMenu::OptionsSoundMenu(), Engines::NWN::OptionsVideoAdvancedMenu::OptionsVideoAdvancedMenu(), Engines::NWN::OptionsVideoMenu::OptionsVideoMenu(), Engines::NWN::PartyLeader::PartyLeader(), Engines::NWN::OptionsVideoMenu::show(), Engines::NWN::MainMenu::show(), Engines::NWN::CharPremadeMenu::show(), Engines::KotOR2::QuickCharPanel::updateButtons(), and Engines::KotOR::QuickCharPanel::updateButtons().
|
protected |
Return a widget in the GUI.
Definition at line 327 of file gui.cpp.
References _widgetMap, and Common::UString::c_str().
|
private |
Return the widget at that position.
Definition at line 446 of file gui.cpp.
References Graphics::Renderable::getTag(), getWidget(), and GfxMan.
Referenced by mouseDown(), mouseMove(), mouseUp(), and mouseWheel().
|
protected |
Does this specific widget exist within the GUI?
Definition at line 310 of file gui.cpp.
References getWidget().
Referenced by Engines::Widget::addSub(), addWidget(), and Engines::NWN::CharHelp::CharHelp().
|
virtual |
Hide the GUI.
Reimplemented in Engines::NWN::CharSkills, Engines::Jade::GUI, Engines::KotOR::GUI, Engines::KotOR::DialogGUIBase, Engines::NWN::CharAttributes, Engines::KotOR::MenuEquipment, Engines::NWN::CharAlignment, Engines::NWN::CharRace, Engines::NWN::CharSchool, Engines::NWN::CharSex, Engines::Jade::MainMenu, and Engines::NWN::CharClass.
Definition at line 80 of file gui.cpp.
References _childGUIs, _widgets, and GfxMan.
Referenced by Engines::NWN::CharClass::hide(), Engines::NWN::CharRace::hide(), Engines::NWN::CharSchool::hide(), Engines::NWN::CharSex::hide(), Engines::NWN::CharAlignment::hide(), Engines::NWN::CharAttributes::hide(), Engines::KotOR::GUI::hide(), Engines::Jade::GUI::hide(), Engines::NWN::CharSkills::hide(), Engines::NWN::Game::mainMenu(), removeChild(), and sub().
|
private |
Key down event triggered.
Definition at line 559 of file gui.cpp.
References callbackKeyInput(), and Events::kEventKeyDown.
Referenced by processEventQueue().
|
private |
Key up event triggeered.
Definition at line 563 of file gui.cpp.
References callbackKeyInput(), and Events::kEventKeyUp.
Referenced by processEventQueue().
|
protectedvirtual |
Reimplemented in Engines::Jade::GUI, and Engines::KotOR::GUI.
Definition at line 440 of file gui.cpp.
Referenced by mouseDown(), and processEventQueue().
|
private |
Mouse down event triggered.
Definition at line 512 of file gui.cpp.
References _currentWidget, changedWidget(), getWidgetAt(), and mouseDown().
|
private |
Send a mouse down event to the widget.
Definition at line 584 of file gui.cpp.
References Engines::Widget::mouseDown(), toGUIX(), and toGUIY().
|
private |
Mouse move event triggered.
Definition at line 498 of file gui.cpp.
References _currentWidget, changedWidget(), checkWidgetActive(), and getWidgetAt().
Referenced by updateMouse().
|
private |
Send a mouse move event to the widget.
Definition at line 579 of file gui.cpp.
References Engines::Widget::mouseMove(), toGUIX(), and toGUIY().
|
protectedvirtual |
The mouse state has changed.
Reimplemented in Engines::Jade::GUI, and Engines::KotOR::GUI.
Definition at line 443 of file gui.cpp.
Referenced by mouseUp(), and processEventQueue().
|
private |
Mouse up event triggered.
Definition at line 525 of file gui.cpp.
References _currentWidget, changedWidget(), checkWidgetActive(), getWidgetAt(), mouseUp(), and updateMouse().
|
private |
Send a mouse up event to the widget.
Definition at line 589 of file gui.cpp.
References Engines::Widget::_lastClickButton, Engines::Widget::_lastClickTime, Engines::Widget::_lastClickX, Engines::Widget::_lastClickY, EventMan, kDoubleClickTime, Engines::Widget::mouseDblClick(), Engines::Widget::mouseUp(), toGUIX(), and toGUIY().
|
private |
Mouse wheel event triggered.
Definition at line 544 of file gui.cpp.
References _currentWidget, changedWidget(), and getWidgetAt().
Referenced by processEventQueue().
|
private |
Send a mouse wheel event to the widget.
Definition at line 612 of file gui.cpp.
References Engines::Widget::mouseWheel().
uint32 Engines::GUI::processEventQueue | ( | ) |
Process the current event queue.
Definition at line 167 of file gui.cpp.
References _console, _eventQueue, _returnCode, EventMan, Engines::Console::isVisible(), Events::kEventKeyDown, Events::kEventKeyUp, Events::kEventMouseDown, Events::kEventMouseMove, Events::kEventMouseUp, Events::kEventMouseWheel, Events::kEventTextInput, keyDown(), keyUp(), kReturnCodeNone, mouseDown(), mouseUp(), mouseWheel(), Engines::Console::processEvent(), removeFocus(), Engines::Console::show(), textInput(), and updateMouse().
Referenced by run().
|
protected |
Remove a child GUI object from this GUI.
Pointer will not be deallocated.
Definition at line 245 of file gui.cpp.
References _childGUIs, and hide().
Referenced by Engines::KotOR::CharacterGenerationMenu::showCustom(), Engines::KotOR2::CharacterGeneration::showCustomChar(), Engines::KotOR::Menu::showMenu(), Engines::KotOR::CharacterGenerationMenu::showQuick(), Engines::KotOR2::CharacterGeneration::showQuickChar(), Engines::KotOR2::CharacterGeneration::showQuickOrCustom(), and Engines::KotOR::CharacterGenerationMenu::showQuickOrCustom().
|
protected |
Forcefully remove the focus from the current widget.
Definition at line 422 of file gui.cpp.
References changedWidget().
Referenced by Engines::NWN::PartyLeader::callbackActive(), Engines::NWN::CharFeats::callbackRun(), Engines::NWN::CharFeats::moveFeat(), processEventQueue(), run(), and sub().
|
protected |
Remove a widget.
Definition at line 267 of file gui.cpp.
References Engines::Widget::_groupMembers, Engines::Widget::_owner, Engines::Widget::_parent, _widgetMap, _widgets, Engines::Widget::getTag(), Engines::Widget::hide(), Engines::Widget::removeChild(), and Engines::Widget::removeSub().
Referenced by Engines::Widget::remove().
uint32 Engines::GUI::run | ( | uint32 | startCode = kStartCodeNone | ) |
Run the GUI.
Definition at line 94 of file gui.cpp.
References _childGUIs, _returnCode, _startCode, addEvent(), callbackRun(), EventMan, kReturnCodeNone, processEventQueue(), removeFocus(), and updateMouse().
Referenced by Engines::KotOR2::Game::mainMenu(), Engines::Jade::Game::mainMenu(), Engines::KotOR::Game::mainMenu(), Engines::NWN::Game::mainMenu(), and sub().
|
protected |
Set the GUI's position.
Definition at line 394 of file gui.cpp.
References Engines::Widget::_parent, _widgets, _x, _y, _z, Engines::Widget::getPosition(), and Engines::Widget::setPosition().
Referenced by Engines::NWN::CharFeatsPopup::CharFeatsPopup(), Engines::NWN::CharHelp::CharHelp(), Engines::KotOR::CustomCharPanel::CustomCharPanel(), Engines::NWN::Compass::notifyResized(), Engines::NWN::Quickchat::notifyResized(), Engines::NWN::PartyLeader::notifyResized(), Engines::NWN::Quickbar::notifyResized(), Engines::KotOR::QuickCharPanel::QuickCharPanel(), Engines::KotOR::QuickOrCustomPanel::QuickOrCustomPanel(), and sub().
|
virtual |
Show the GUI.
Reimplemented in Engines::NWN::NewModuleMenu, Engines::NWN::NewPremiumMenu, Engines::NWN::CharPremadeMenu, Engines::NWN::CharInfoVoice, Engines::NWN::CharPortrait, Engines::Jade::GUI, Engines::KotOR::GUI, Engines::KotOR::DialogGUIBase, Engines::NWN::CharAttributes, Engines::NWN::CharPackage, Engines::KotOR::MenuEquipment, Engines::NWN::CharAlignment, Engines::NWN::OKCancelDialog, Engines::NWN::YesNoCancelDialog, Engines::NWN::MainMenu, Engines::NWN::OptionsResolutionMenu, Engines::NWN::OptionsSoundMenu, Engines::Jade::MainMenu, Engines::NWN::OptionsGameMenu, Engines::NWN::OptionsVideoMenu, Engines::KotOR::OptionsGameplayMenu, Engines::KotOR::OptionsGraphicsMenu, Engines::NWN::OptionsFeedbackMenu, Engines::NWN::OptionsVideoAdvancedMenu, Engines::KotOR::OptionsAutoPauseMenu, Engines::KotOR::OptionsGraphicsAdvancedMenu, Engines::KotOR::OptionsMouseSettingsMenu, and Engines::KotOR::OptionsSoundAdvancedMenu.
Definition at line 62 of file gui.cpp.
References _childGUIs, Engines::Widget::_owner, _widgets, GfxMan, and Engines::Widget::show().
Referenced by addChild(), Engines::NWN::CharTypeMenu::callbackActive(), Engines::NWN::NewMenu::callbackActive(), Engines::NWN::NewCampMenu::callbackActive(), Engines::NWN::IngameMainMenu::callbackActive(), Engines::NWN::NewXP1Menu::loadModule(), Engines::NWN::NewXP2Menu::loadModule(), Engines::NWN::NewMenu::loadModule(), Engines::NWN::OptionsFeedbackMenu::show(), Engines::NWN::OptionsVideoAdvancedMenu::show(), Engines::NWN::OptionsGameMenu::show(), Engines::NWN::OptionsVideoMenu::show(), Engines::NWN::OKCancelDialog::show(), Engines::NWN::YesNoCancelDialog::show(), Engines::NWN::OptionsSoundMenu::show(), Engines::NWN::OptionsResolutionMenu::show(), Engines::NWN::CharAlignment::show(), Engines::NWN::MainMenu::show(), Engines::NWN::CharAttributes::show(), Engines::NWN::CharPackage::show(), Engines::KotOR::GUI::show(), Engines::Jade::GUI::show(), Engines::NWN::CharPortrait::show(), Engines::NWN::CharInfoVoice::show(), Engines::NWN::CharPremadeMenu::show(), Engines::NWN::NewModuleMenu::show(), Engines::NWN::NewPremiumMenu::show(), and sub().
|
protected |
Open up a sub GUI.
Definition at line 349 of file gui.cpp.
References _sub, getPosition(), GfxMan, hide(), removeFocus(), run(), setPosition(), show(), and updateMouse().
Referenced by Engines::KotOR::OptionsSoundMenu::callbackActive(), Engines::NWN::MoviesCampMenu::callbackActive(), Engines::KotOR2::MainMenu::callbackActive(), Engines::KotOR::OptionsGameplayMenu::callbackActive(), Engines::KotOR::OptionsGraphicsMenu::callbackActive(), Engines::NWN::NewCampMenu::callbackActive(), Engines::NWN::CharTypeMenu::callbackActive(), Engines::NWN::NewMenu::callbackActive(), Engines::NWN::OptionsMenu::callbackActive(), Engines::KotOR2::ClassSelection::callbackActive(), Engines::KotOR::MenuMap::callbackActive(), Engines::Jade::MainMenu::callbackActive(), Engines::NWN::OptionsVideoMenu::callbackActive(), Engines::NWN::CharAppearance::callbackActive(), Engines::NWN::IngameMainMenu::callbackActive(), Engines::KotOR::OptionsMenu::callbackActive(), Engines::NWN::OptionsGameMenu::callbackActive(), Engines::NWN::OptionsSoundMenu::callbackActive(), Engines::NWN::CharGenMenu::callbackActive(), Engines::KotOR::MainMenu::callbackActive(), Engines::NWN::MainMenu::callbackActive(), Engines::NWN::CharPackage::callbackActive(), Engines::KotOR::ClassSelectionMenu::callbackActive(), Engines::NWN::CharPremadeMenu::callbackActive(), Engines::Jade::OptionsMenu::callbackActive(), Engines::KotOR::ClassSelectionMenu::callbackKeyInput(), Engines::KotOR::Menu::callbackRun(), Engines::NWN::NewXP1Menu::loadModule(), Engines::NWN::NewXP2Menu::loadModule(), Engines::NWN::NewMenu::loadModule(), Engines::NWN::NewModuleMenu::loadModule(), Engines::NWN::NewPremiumMenu::loadModule(), Engines::KotOR2::CharacterGeneration::showName(), Engines::KotOR::CharacterGenerationMenu::showName(), Engines::KotOR2::CharacterGeneration::showPortrait(), and Engines::KotOR::CharacterGenerationMenu::showPortrait().
|
private |
Text input event received.
Definition at line 555 of file gui.cpp.
References callbackTextInput().
Referenced by processEventQueue().
|
private |
Definition at line 567 of file gui.cpp.
References WindowMan.
Referenced by mouseDown(), mouseMove(), and mouseUp().
|
private |
Definition at line 573 of file gui.cpp.
References WindowMan.
Referenced by mouseDown(), mouseMove(), and mouseUp().
|
protected |
Force an update of the mouse position.
Definition at line 426 of file gui.cpp.
References CursorMan, and mouseMove().
Referenced by Engines::NWN::MoviesBaseMenu::callbackActive(), Engines::NWN::MoviesCampMenu::callbackActive(), mouseUp(), processEventQueue(), run(), and sub().
|
private |
Definition at line 138 of file gui.h.
Referenced by addChild(), hide(), removeChild(), run(), and show().
|
protected |
Definition at line 70 of file gui.h.
Referenced by Engines::KotOR::MenuMap::callbackActive(), Engines::NWN::CharAppearance::callbackActive(), Engines::NWN::CharPackage::callbackActive(), Engines::NWN::CharPremadeMenu::CharPremadeMenu(), Engines::NWN::CharTypeMenu::CharTypeMenu(), Engines::Jade::OptionsMenu::createAudioOptions(), Engines::KotOR::MainMenu::createClassSelection(), Engines::Jade::OptionsMenu::createControlOptions(), Engines::Jade::OptionsMenu::createDifficultyOptions(), Engines::Jade::OptionsMenu::createGameInfoOptions(), Engines::KotOR::MainMenu::createLoadGame(), Engines::NWN::MainMenu::createMovies(), Engines::KotOR::MainMenu::createMovies(), Engines::NWN::MainMenu::createNew(), Engines::NWN::MainMenu::createOptions(), Engines::KotOR::MainMenu::createOptions(), Engines::Jade::OptionsMenu::createVideoOptions(), Engines::NWN::IngameMainMenu::IngameMainMenu(), Engines::NWN::CharGenMenu::init(), Engines::NWN::MainMenu::MainMenu(), Engines::NWN::MoviesCampMenu::MoviesCampMenu(), Engines::NWN::NewCampMenu::NewCampMenu(), Engines::NWN::NewMenu::NewMenu(), Engines::NWN::OptionsGameMenu::OptionsGameMenu(), Engines::KotOR::OptionsGameplayMenu::OptionsGameplayMenu(), Engines::KotOR::OptionsGraphicsMenu::OptionsGraphicsMenu(), Engines::NWN::OptionsMenu::OptionsMenu(), Engines::KotOR::OptionsMenu::OptionsMenu(), Engines::KotOR::OptionsSoundMenu::OptionsSoundMenu(), Engines::NWN::OptionsSoundMenu::OptionsSoundMenu(), Engines::NWN::OptionsVideoMenu::OptionsVideoMenu(), and processEventQueue().
|
protected |
The widget the mouse is currently on.
Definition at line 72 of file gui.h.
Referenced by changedWidget(), mouseDown(), mouseMove(), mouseUp(), and mouseWheel().
|
private |
The GUI event queue.
Definition at line 147 of file gui.h.
Referenced by addEvent(), and processEventQueue().
|
protected |
The GUI's return code.
Definition at line 75 of file gui.h.
Referenced by abort(), Engines::Jade::DifficultyOptionsMenu::callbackActive(), Engines::Jade::GameInfoOptionsMenu::callbackActive(), Engines::KotOR::MenuCharacter::callbackActive(), Engines::Jade::VideoOptionsMenu::callbackActive(), Engines::KotOR::MenuInventory::callbackActive(), Engines::KotOR::MenuJournal::callbackActive(), Engines::KotOR::MenuMessages::callbackActive(), Engines::Jade::AudioOptionsMenu::callbackActive(), Engines::KotOR2::CharacterGenerationPortraitMenu::callbackActive(), Engines::Jade::ControlOptionsMenu::callbackActive(), Engines::KotOR2::QuickOrCustomPanel::callbackActive(), Engines::KotOR::OptionsFeedbackMenu::callbackActive(), Engines::KotOR::OptionsKeyboardConfigurationMenu::callbackActive(), Engines::KotOR::MoviesMenu::callbackActive(), Engines::NWN::MoviesBaseMenu::callbackActive(), Engines::NWN::OptionsControlsMenu::callbackActive(), Engines::NWN::OptionsGorePasswordMenu::callbackActive(), Engines::KotOR::QuickCharPanel::callbackActive(), Engines::KotOR2::QuickCharPanel::callbackActive(), Engines::KotOR::OptionsMouseSettingsMenu::callbackActive(), Engines::KotOR::OptionsAutoPauseMenu::callbackActive(), Engines::KotOR::OptionsGraphicsAdvancedMenu::callbackActive(), Engines::KotOR::OptionsSoundMenu::callbackActive(), Engines::KotOR::OptionsSoundAdvancedMenu::callbackActive(), Engines::KotOR::QuickOrCustomPanel::callbackActive(), Engines::KotOR::CharacterGenerationNameMenu::callbackActive(), Engines::KotOR::PartySelectionGUI::callbackActive(), Engines::NWN::MoviesCampMenu::callbackActive(), Engines::KotOR::CharacterGenerationPortraitMenu::callbackActive(), Engines::NWN::OptionsSoundAdvancedMenu::callbackActive(), Engines::NWN::NewXP2Menu::callbackActive(), Engines::KotOR2::MainMenu::callbackActive(), Engines::KotOR::ConfirmDialog::callbackActive(), Engines::KotOR2::CharacterGenerationNameMenu::callbackActive(), Engines::KotOR::OptionsGameplayMenu::callbackActive(), Engines::NWN::NewXP1Menu::callbackActive(), Engines::KotOR::OptionsGraphicsMenu::callbackActive(), Engines::KotOR::ContainerMenu::callbackActive(), Engines::NWN::CharTypeMenu::callbackActive(), Engines::NWN::NewMenu::callbackActive(), Engines::NWN::NewCampMenu::callbackActive(), Engines::NWN::OptionsFeedbackMenu::callbackActive(), Engines::NWN::CharFeatsPopup::callbackActive(), Engines::NWN::OptionsVideoAdvancedMenu::callbackActive(), Engines::NWN::CharHelp::callbackActive(), Engines::NWN::OptionsMenu::callbackActive(), Engines::NWN::OptionsVideoMenu::callbackActive(), Engines::KotOR::MenuMap::callbackActive(), Engines::KotOR2::ClassSelection::callbackActive(), Engines::Jade::MainMenu::callbackActive(), Engines::NWN::CharAppearance::callbackActive(), Engines::NWN::IngameMainMenu::callbackActive(), Engines::NWN::CharRace::callbackActive(), Engines::NWN::CharSchool::callbackActive(), Engines::NWN::CharSex::callbackActive(), Engines::NWN::CharClass::callbackActive(), Engines::NWN::OptionsGameMenu::callbackActive(), Engines::KotOR::OptionsMenu::callbackActive(), Engines::NWN::OptionsSoundMenu::callbackActive(), Engines::NWN::CharAlignment::callbackActive(), Engines::NWN::CharGenMenu::callbackActive(), Engines::NWN::CharPackage::callbackActive(), Engines::NWN::MainMenu::callbackActive(), Engines::NWN::OKCancelDialog::callbackActive(), Engines::NWN::YesNoCancelDialog::callbackActive(), Engines::KotOR::MainMenu::callbackActive(), Engines::KotOR::MenuEquipment::callbackActive(), Engines::KotOR::MenuOptions::callbackActive(), Engines::NWN::OptionsResolutionMenu::callbackActive(), Engines::KotOR::ClassSelectionMenu::callbackActive(), Engines::NWN::CharAttributes::callbackActive(), Engines::KotOR::SaveLoadMenu::callbackActive(), Engines::NWN::CharDomain::callbackActive(), Engines::NWN::CharPortrait::callbackActive(), Engines::NWN::CharInfoVoice::callbackActive(), Engines::NWN::CharFeats::callbackActive(), Engines::NWN::CharSkills::callbackActive(), Engines::NWN::CharSpells::callbackActive(), Engines::NWN::CharPremadeMenu::callbackActive(), Engines::Jade::OptionsMenu::callbackActive(), Engines::NWN::NewModuleMenu::callbackActive(), Engines::NWN::NewPremiumMenu::callbackActive(), Engines::KotOR::ClassSelectionMenu::callbackKeyInput(), Engines::KotOR::CharacterGenerationMenu::callbackKeyInput(), Engines::KotOR::Menu::callbackRun(), Engines::NWN::CharClass::hide(), Engines::NWN::CharSchool::hide(), Engines::NWN::CharRace::hide(), Engines::NWN::CharSex::hide(), Engines::NWN::CharAlignment::hide(), Engines::NWN::CharAttributes::hide(), Engines::NWN::CharSkills::hide(), Engines::NWN::NewXP2Menu::loadModule(), Engines::NWN::NewXP1Menu::loadModule(), Engines::NWN::NewMenu::loadModule(), Engines::NWN::NewModuleMenu::loadModule(), Engines::NWN::NewPremiumMenu::loadModule(), Engines::NWN::CharPremadeMenu::playCharacter(), processEventQueue(), run(), Engines::KotOR2::CharacterGeneration::start(), and Engines::KotOR::SaveLoadMenu::tryLoadGame().
|
protected |
|
protected |
|
private |
All widgets in the GUI, index by their tag.
Definition at line 141 of file gui.h.
Referenced by addWidget(), clearWidgets(), getWidget(), and removeWidget().
|
private |
All widgets in the GUI.
Definition at line 140 of file gui.h.
Referenced by addWidget(), clearWidgets(), empty(), hide(), removeWidget(), setPosition(), show(), and ~GUI().
|
private |
The GUI X position.
Definition at line 143 of file gui.h.
Referenced by getPosition(), and setPosition().
|
private |
The GUI Y position.
Definition at line 144 of file gui.h.
Referenced by getPosition(), and setPosition().
|
private |
The GUI Z position.
Definition at line 145 of file gui.h.
Referenced by getPosition(), and setPosition().
|
static |
Definition at line 47 of file gui.h.
Referenced by abort(), Engines::Jade::AudioOptionsMenu::callbackActive(), Engines::KotOR2::CharacterGenerationPortraitMenu::callbackActive(), Engines::Jade::VideoOptionsMenu::callbackActive(), Engines::Jade::ControlOptionsMenu::callbackActive(), Engines::Jade::GameInfoOptionsMenu::callbackActive(), Engines::Jade::DifficultyOptionsMenu::callbackActive(), Engines::KotOR2::CharacterGenerationNameMenu::callbackActive(), Engines::KotOR::ConfirmDialog::callbackActive(), Engines::KotOR::ContainerMenu::callbackActive(), and Engines::Jade::OptionsMenu::callbackActive().
|
static |
Definition at line 46 of file gui.h.
Referenced by processEventQueue(), and run().
|
static |
Definition at line 45 of file gui.h.
Referenced by Engines::KotOR::OptionsGraphicsMenu::callbackActive(), Engines::KotOR::MenuMap::callbackActive(), callbackRun(), and Engines::KotOR2::CharacterGeneration::showName().