#include <GLWPanel.h>

Public Types | |
| enum | LayoutFlags { SpaceRight = 1, SpaceLeft = 2, SpaceTop = 4, SpaceBottom = 8, SpaceAll = 16, AlignLeft = 32, AlignRight = 64, AlignCenterLeftRight = 128, AlignTop = 256, AlignBottom = 512, AlignCenterTopBottom = 1024 } |
| enum | LayoutType { LayoutNone, LayoutHorizontal, LayoutVerticle, LayoutGrid } |
Public Member Functions | |
| GLWPanel (float x=0.0f, float y=0.0f, float w=0.0f, float h=0.0f, bool depressed=false, bool visible=true, bool ridge=false) | |
| virtual | ~GLWPanel () |
| virtual void | simulate (float frameTime) |
| virtual void | draw () |
| virtual void | mouseDown (int button, float x, float y, bool &skipRest) |
| virtual void | mouseUp (int button, float x, float y, bool &skipRest) |
| virtual void | mouseDrag (int button, float mx, float my, float x, float y, bool &skipRest) |
| virtual void | keyDown (char *buffer, unsigned int keyState, KeyboardHistory::HistoryElement *history, int hisCount, bool &skipRest) |
| virtual void | mouseWheel (float x, float y, float z, bool &skipRest) |
| virtual void | display () |
| virtual void | hide () |
| virtual bool | initFromXML (XMLNode *node) |
| virtual void | clear () |
| virtual void | layout () |
| virtual void | setLayout (unsigned int layout) |
| virtual unsigned int | getLayout () |
| virtual void | setGridWidth (unsigned int grid) |
| virtual unsigned int | getGridWidth () |
| GLWidget * | addWidget (GLWidget *widget, GLWCondition *condition=0, unsigned int flags=0, float width=0.0f) |
| std::list < GLWPanelEntry > & | getWidgets () |
| GLWidget * | getWidgetByName (const char *name) |
| REGISTER_CLASS_HEADER (GLWPanel) | |
| bool & | getDrawPanel () |
Protected Attributes | |
| std::list < GLWPanelEntry > | widgets_ |
| bool | depressed_ |
| bool | drawPanel_ |
| bool | ridge_ |
| unsigned int | layout_ |
| unsigned int | gridWidth_ |
Classes | |
| struct | GLWPanelEntry |
Definition at line 31 of file GLWPanel.h.
| SpaceRight | |
| SpaceLeft | |
| SpaceTop | |
| SpaceBottom | |
| SpaceAll | |
| AlignLeft | |
| AlignRight | |
| AlignCenterLeftRight | |
| AlignTop | |
| AlignBottom | |
| AlignCenterTopBottom |
Definition at line 34 of file GLWPanel.h.
| enum GLWPanel::LayoutType |
Definition at line 48 of file GLWPanel.h.
| GLWPanel::GLWPanel | ( | float | x = 0.0f, |
|
| float | y = 0.0f, |
|||
| float | w = 0.0f, |
|||
| float | h = 0.0f, |
|||
| bool | depressed = false, |
|||
| bool | visible = true, |
|||
| bool | ridge = false | |||
| ) |
Definition at line 50 of file GLWPanel.cpp.
Referenced by AdminDialog::AdminDialog(), AutoDefenseDialog::AutoDefenseDialog(), BuyAccessoryDialog::BuyAccessoryDialog(), PlayerDialog::display(), AuthDialog::display(), AdminAuthDialog::display(), GiftMoneyDialog::GiftMoneyDialog(), HUDDialog::HUDDialog(), InventoryDialog::InventoryDialog(), MsgBoxDialog::MsgBoxDialog(), PlayerDialog::PlayerDialog(), SaveDialog::SaveDialog(), SettingsSelectDialog::SettingsSelectDialog(), SettingsSubSelectDialog::SettingsSubSelectDialog(), SoundDialog::SoundDialog(), and TipDialog::TipDialog().
| GLWPanel::~GLWPanel | ( | ) | [virtual] |
| void GLWPanel::simulate | ( | float | frameTime | ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in AnimatedBackdropDialog, CameraDialog, ConnectDialog, MessageDialog, NetworkSelectDialog, SkipAllDialog, TutorialDialog, and GLWScrollPanel.
Definition at line 122 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, GLWCondition::getResult(), GLWidget::simulate(), GLWPanel::GLWPanelEntry::widget, and widgets_.
Referenced by GLWWindowManager::simulate(), TutorialDialog::simulate(), SkipAllDialog::simulate(), and NetworkSelectDialog::simulate().
| void GLWPanel::draw | ( | ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in AnimatedBackdropDialog, BackdropDialog, BuyAccessoryDialog, CameraDialog, LogDialog, MessageDialog, PlayerDialog, ProgressDialog, RulesDialog, ScoreDialog, StartDialog, TutorialDialog, GLMenu, GLWProgress, GLWScrollPanel, GLWSelector, GLWTab, and GLWWindow.
Definition at line 139 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, depressed_, GLState::DEPTH_OFF, GLWidget::draw(), drawPanel_, GLWidget::drawShadedRoundBox(), GLWCondition::getResult(), GL_LINE_LOOP, GL_QUADS, glBegin(), glColor3f(), glEnd(), glPopMatrix(), glPushMatrix(), glTranslatef(), glVertex2f(), GLWidget::h_, ridge_, GLState::TEXTURE_OFF, GLWidget::w_, GLWPanel::GLWPanelEntry::widget, widgets_, GLWidget::x_, and GLWidget::y_.
Referenced by GLWTankViewer::draw(), GLWProgress::draw(), and GLWWindow::drawMaximizedWindow().
| void GLWPanel::mouseDown | ( | int | button, | |
| float | x, | |||
| float | y, | |||
| bool & | skipRest | |||
| ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in CameraDialog, MsgBoxDialog, StartDialog, GLMenu, GLWScrollPanel, GLWSelector, GLWTab, and GLWWindow.
Definition at line 216 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, GLWCondition::getResult(), GLWPanel::GLWPanelEntry::widget, widgets_, GLWidget::x_, and GLWidget::y_.
Referenced by GLWWindow::mouseDown().
| void GLWPanel::mouseUp | ( | int | button, | |
| float | x, | |||
| float | y, | |||
| bool & | skipRest | |||
| ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in MsgBoxDialog, GLMenu, GLWScrollPanel, GLWSelector, and GLWWindow.
Definition at line 239 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, GLWCondition::getResult(), GLWPanel::GLWPanelEntry::widget, widgets_, GLWidget::x_, and GLWidget::y_.
Referenced by GLWWindow::mouseUp().
| void GLWPanel::mouseDrag | ( | int | button, | |
| float | mx, | |||
| float | my, | |||
| float | x, | |||
| float | y, | |||
| bool & | skipRest | |||
| ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in GLMenu, GLWScrollPanel, GLWSelector, and GLWWindow.
Definition at line 260 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, GLWCondition::getResult(), GLWidget::h_, GLWidget::w_, GLWPanel::GLWPanelEntry::widget, widgets_, GLWidget::x_, and GLWidget::y_.
Referenced by GLWWindow::mouseDrag().
| void GLWPanel::keyDown | ( | char * | buffer, | |
| unsigned int | keyState, | |||
| KeyboardHistory::HistoryElement * | history, | |||
| int | hisCount, | |||
| bool & | skipRest | |||
| ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in MsgBoxDialog, PlayerDialog, GLMenu, GLWSelector, and GLWWindow.
Definition at line 288 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, GLWCondition::getResult(), GLWPanel::GLWPanelEntry::widget, and widgets_.
Referenced by GLWWindow::keyDown().
| void GLWPanel::mouseWheel | ( | float | x, | |
| float | y, | |||
| float | z, | |||
| bool & | skipRest | |||
| ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in MsgBoxDialog, GLWScrollPanel, GLWTab, and GLWWindow.
Definition at line 191 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, GLWCondition::getResult(), GLWidget::h_, GLWidget::inBox(), GLWidget::w_, GLWPanel::GLWPanelEntry::widget, widgets_, GLWidget::x_, and GLWidget::y_.
Referenced by GLWWindow::mouseWheel(), and GLWScrollPanel::mouseWheel().
| void GLWPanel::display | ( | ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in AdminAuthDialog, AdminCheckDialog, AdminDialog, AuthDialog, BuyAccessoryDialog, GiftMoneyDialog, HUDDialog, InventoryDialog, ModSelectDialog, ModSubSelectDialog, NetworkSelectDialog, PlayerDialog, QuitDialog, RulesDialog, SaveDialog, SaveSelectDialog, ScoreDialog, SettingsSelectDialog, SettingsSubSelectDialog, SkipAllDialog, SoundDialog, TipDialog, and TutorialDialog.
Definition at line 308 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, GLWCondition::getResult(), GLWPanel::GLWPanelEntry::widget, and widgets_.
Referenced by TutorialDialog::display(), TipDialog::display(), SoundDialog::display(), ScoreDialog::display(), SaveDialog::display(), RulesDialog::display(), QuitDialog::display(), PlayerDialog::display(), HUDDialog::display(), GiftMoneyDialog::display(), AuthDialog::display(), AdminCheckDialog::display(), AdminAuthDialog::display(), GLWWindowManager::setCurrentEntry(), and GLWWindowManager::showWindow().
| void GLWPanel::hide | ( | ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in NetworkSelectDialog, and RulesDialog.
Definition at line 325 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, GLWCondition::getResult(), GLWPanel::GLWPanelEntry::widget, and widgets_.
Referenced by RulesDialog::hide(), GLWWindowManager::hideWindow(), and GLWWindowManager::setCurrentEntry().
| bool GLWPanel::initFromXML | ( | XMLNode * | node | ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in GLWWindow, and GLWWindowSkin.
Definition at line 342 of file GLWPanel.cpp.
References addWidget(), S3D::dialogMessage(), drawPanel_, XMLNode::failChildren(), S3D::formatStringBuffer(), XMLNode::getChildren(), XMLNode::getContent(), XMLNode::getNamedChild(), XMLNode::getNamedParameter(), MetaClassRegistration::getNewClass(), GLWCondition::initFromXML(), and GLWidget::initFromXML().
Referenced by GLWWindow::initFromXML().
| void GLWPanel::clear | ( | ) | [virtual] |
Reimplemented in MessageDialog, and GLWScrollPanel.
Definition at line 109 of file GLWPanel.cpp.
References widgets_.
Referenced by InventoryDialog::addPlayerName(), BuyAccessoryDialog::addPlayerName(), GLWScrollPanel::clear(), AuthDialog::display(), AdminAuthDialog::display(), AutoDefenseDialog::displayCurrent(), and ~GLWPanel().
| void GLWPanel::layout | ( | ) | [virtual] |
Reimplemented from GLWidget.
Reimplemented in GLWTabContainer.
Definition at line 418 of file GLWPanel.cpp.
References AlignBottom, AlignCenterLeftRight, AlignCenterTopBottom, AlignLeft, AlignRight, AlignTop, GLWPanel::GLWPanelEntry::bottomSpace, DIALOG_ASSERT, GLWPanel::GLWPanelEntry::flags, GLWidget::getH(), GLWidget::getW(), gridWidth_, GLWidget::layout(), layout_, LayoutGrid, LayoutHorizontal, LayoutNone, LayoutVerticle, GLWPanel::GLWPanelEntry::leftSpace, MAX, GLWPanel::GLWPanelEntry::rightSpace, GLWidget::setH(), GLWidget::setW(), GLWidget::setX(), GLWidget::setY(), GLWPanel::GLWPanelEntry::topSpace, GLWPanel::GLWPanelEntry::widget, and widgets_.
Referenced by AdminDialog::AdminDialog(), AutoDefenseDialog::AutoDefenseDialog(), AuthDialog::display(), AdminAuthDialog::display(), GiftMoneyDialog::GiftMoneyDialog(), HUDDialog::HUDDialog(), MsgBoxDialog::MsgBoxDialog(), SaveDialog::SaveDialog(), SettingsSelectDialog::SettingsSelectDialog(), SettingsSubSelectDialog::SettingsSubSelectDialog(), MsgBoxDialog::show(), SoundDialog::SoundDialog(), TipDialog::TipDialog(), and TutorialDialog::TutorialDialog().
| void GLWPanel::setLayout | ( | unsigned int | layout | ) | [virtual] |
Definition at line 605 of file GLWPanel.cpp.
References layout_.
Referenced by AdminDialog::AdminDialog(), AutoDefenseDialog::AutoDefenseDialog(), AuthDialog::display(), AdminAuthDialog::display(), GiftMoneyDialog::GiftMoneyDialog(), HUDDialog::HUDDialog(), MsgBoxDialog::MsgBoxDialog(), SaveDialog::SaveDialog(), SettingsSelectDialog::SettingsSelectDialog(), SettingsSubSelectDialog::SettingsSubSelectDialog(), SoundDialog::SoundDialog(), TipDialog::TipDialog(), and TutorialDialog::TutorialDialog().
| unsigned int GLWPanel::getLayout | ( | ) | [virtual] |
| void GLWPanel::setGridWidth | ( | unsigned int | grid | ) | [virtual] |
Definition at line 615 of file GLWPanel.cpp.
References gridWidth_.
Referenced by AuthDialog::display(), AdminAuthDialog::display(), SettingsSelectDialog::SettingsSelectDialog(), and SettingsSubSelectDialog::SettingsSubSelectDialog().
| unsigned int GLWPanel::getGridWidth | ( | ) | [virtual] |
| GLWidget * GLWPanel::addWidget | ( | GLWidget * | widget, | |
| GLWCondition * | condition = 0, |
|||
| unsigned int | flags = 0, |
|||
| float | width = 0.0f | |||
| ) |
Definition at line 64 of file GLWPanel.cpp.
References DIALOG_ASSERT, GLWidget::setParent(), GLWPanel::GLWPanelEntry::widget, and widgets_.
Referenced by BuyAccessoryDialog::addAccessory(), InventoryDialog::addPlayerName(), BuyAccessoryDialog::addPlayerName(), InventoryDialog::addPlayerWeapons(), BuyAccessoryDialog::addTabs(), AdminDialog::AdminDialog(), AutoDefenseDialog::AutoDefenseDialog(), BuyAccessoryDialog::BuyAccessoryDialog(), GLWOptionEntry::createEntry(), PlayerDialog::display(), AuthDialog::display(), AdminAuthDialog::display(), AutoDefenseDialog::displayCurrent(), GiftMoneyDialog::GiftMoneyDialog(), HUDDialog::HUDDialog(), initFromXML(), InventoryDialog::InventoryDialog(), KibitzingDialog::KibitzingDialog(), LogDialog::LogDialog(), ModSelectDialog::ModSelectDialog(), ModSubSelectDialog::ModSubSelectDialog(), MsgBoxDialog::MsgBoxDialog(), NetworkSelectDialog::NetworkSelectDialog(), PlayerDialog::PlayerDialog(), QuitDialog::QuitDialog(), ResignDialog::ResignDialog(), RulesDialog::RulesDialog(), SaveDialog::SaveDialog(), SaveSelectDialog::SaveSelectDialog(), SettingsSelectDialog::SettingsSelectDialog(), SettingsSubSelectDialog::SettingsSubSelectDialog(), SkipAllDialog::SkipAllDialog(), SkipDialog::SkipDialog(), SoundDialog::SoundDialog(), TipDialog::TipDialog(), and TutorialDialog::TutorialDialog().
| std::list<GLWPanelEntry>& GLWPanel::getWidgets | ( | ) | [inline] |
Definition at line 101 of file GLWPanel.h.
References widgets_.
Referenced by BuyAccessoryDialog::addPlayerWeapons(), GLWScrollPanel::calculateVisible(), BuyAccessoryDialog::display(), GLWTab::draw(), GLWScrollPanel::draw(), BuyAccessoryDialog::draw(), GLWTextBox::keyDown(), GLWScrollPanel::mouseDown(), GLWScrollPanel::mouseDrag(), GLWScrollPanel::mouseUp(), BuyAccessoryDialog::playerRefreshKeepPos(), GLWScrollPanel::positionChange(), GLWTextBox::setCurrent(), GLWTab::setDepressed(), BuyAccessoryDialog::stateChange(), and BuyAccessoryDialog::tabDown().
| GLWidget * GLWPanel::getWidgetByName | ( | const char * | name | ) |
Definition at line 82 of file GLWPanel.cpp.
References GLWPanel::GLWPanelEntry::condition, MetaClass::getClassName(), GLWidget::getName(), GLWCondition::getResult(), getWidgetByName(), LangStringUtil::strcmp(), GLWPanel::GLWPanelEntry::widget, and widgets_.
Referenced by getWidgetByName(), and TutorialDialog::processHighlight().
| GLWPanel::REGISTER_CLASS_HEADER | ( | GLWPanel | ) |
| bool& GLWPanel::getDrawPanel | ( | ) | [inline] |
Definition at line 107 of file GLWPanel.h.
References drawPanel_.
Referenced by GLWWindow::GLWWindow().
std::list<GLWPanelEntry> GLWPanel::widgets_ [protected] |
Definition at line 110 of file GLWPanel.h.
Referenced by addWidget(), clear(), display(), draw(), getWidgetByName(), getWidgets(), hide(), keyDown(), GLWTabContainer::layout(), layout(), mouseDown(), mouseDrag(), mouseUp(), mouseWheel(), and simulate().
bool GLWPanel::depressed_ [protected] |
bool GLWPanel::drawPanel_ [protected] |
bool GLWPanel::ridge_ [protected] |
unsigned int GLWPanel::layout_ [protected] |
unsigned int GLWPanel::gridWidth_ [protected] |
Definition at line 115 of file GLWPanel.h.
Referenced by getGridWidth(), layout(), and setGridWidth().
1.5.3