Vegastrike 0.5.1 rc1  1.0
Original sources for Vegastrike Evolved
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
WindowController Class Referenceabstract

#include <windowcontroller.h>

Inheritance diagram for WindowController:
BaseComputer::LoadSaveQuitConfirm ModalDialog NavComputer NavComputer::RenameConfirm NetActionConfirm WctlBase< Subclass > WctlBase< BaseComputer > WctlBase< GameMenu >

Public Member Functions

virtual void init (void)=0
 
virtual void run (void)
 
virtual void draw (void)
 
virtual Windowwindow (void)
 
virtual void setWindow (Window *w)
 
virtual bool processWindowCommand (const EventCommandId &command, Control *control)
 
 WindowController ()
 
virtual ~WindowController (void)
 

Protected Attributes

Windowm_window
 
bool m_deleteOnWindowClose
 

Detailed Description

Definition at line 35 of file windowcontroller.h.

Constructor & Destructor Documentation

WindowController::WindowController ( )

Definition at line 62 of file windowcontroller.cpp.

62  : m_window( NULL )
63  , m_deleteOnWindowClose( true )
64 {}
WindowController::~WindowController ( void  )
virtual

Definition at line 67 of file windowcontroller.cpp.

67 {}

Member Function Documentation

void WindowController::draw ( void  )
virtual

Reimplemented in BaseComputer.

Definition at line 41 of file windowcontroller.cpp.

42 {
43  //Do nothing.
44 }
virtual void WindowController::init ( void  )
pure virtual
bool WindowController::processWindowCommand ( const EventCommandId command,
Control control 
)
virtual

Reimplemented in UpgradeOperationMountDialog, ListQuestionDialog, BaseComputer::LoadSaveQuitConfirm, WctlBase< Subclass >, WctlBase< GameMenu >, WctlBase< BaseComputer >, NavComputer::RenameConfirm, ModalDialog, NavComputer, and NetActionConfirm.

Definition at line 47 of file windowcontroller.cpp.

References m_deleteOnWindowClose.

Referenced by Window::processCommand(), NetActionConfirm::processWindowCommand(), NavComputer::processWindowCommand(), ModalDialog::processWindowCommand(), NavComputer::RenameConfirm::processWindowCommand(), WctlBase< BaseComputer >::processWindowCommand(), and BaseComputer::LoadSaveQuitConfirm::processWindowCommand().

48 {
49  if (command == "Window::Close") {
50  //Our window is closing.
52  delete this;
53  //We return false so that the window itself can see this command.
54  return false;
55  }
56  }
57  //Didn't find a handler.
58  return false;
59 }
void WindowController::run ( void  )
virtual
virtual void WindowController::setWindow ( Window w)
inlinevirtual
virtual Window* WindowController::window ( void  )
inlinevirtual

Definition at line 49 of file windowcontroller.h.

References m_window.

Referenced by NavComputer::actionAnd(), NavComputer::actionChain(), BaseComputer::actionConfirmedLoadGame(), BaseComputer::actionConfirmedSaveGame(), BaseComputer::actionDone(), BaseComputer::actionJoinGame(), BaseComputer::actionLoadGame(), BaseComputer::actionNetDie(), BaseComputer::actionNetSaveGame(), BaseComputer::actionNewGame(), NavComputer::actionNot(), NavComputer::actionOr(), NavComputer::actionRemoveCriteria(), BaseComputer::actionSaveGame(), BaseComputer::actionShowAccountMenu(), BaseComputer::actionShowServerMenu(), buyShip(), BaseComputer::changeToInfoMode(), BaseComputer::configureCargoCommitControls(), BaseComputer::configureUpgradeCommitControls(), NetActionConfirm::confirmedJoinGame(), NavComputer::constructControls(), BaseComputer::constructControls(), GameMenu::createControls(), NavComputer::createControls(), BaseComputer::createControls(), BaseComputer::createModeButtons(), NetActionConfirm::finalizeJoinGame(), ListQuestionDialog::getPicker(), BaseComputer::hideCommitControls(), GameMenu::init(), NetActionConfirm::init(), NavComputer::RenameConfirm::init(), QuestionDialog::init(), BaseComputer::LoadSaveQuitConfirm::init(), ListQuestionDialog::initControls(), NavComputer::loadAbsoluteButton(), BaseComputer::loadBuyUpgradeControls(), BaseComputer::loadCargoControls(), NavComputer::loadChainLister(), NavComputer::loadCriteriaLister(), BaseComputer::loadLoadSaveControls(), BaseComputer::loadMissionsControls(), BaseComputer::loadNewsControls(), NavComputer::loadPathLister(), BaseComputer::loadSavePickerChangedSelection(), BaseComputer::loadSellUpgradeControls(), BaseComputer::loadShipDealerControls(), ModalDialog::modalFinished(), BaseComputer::newsPickerChangedSelection(), GameMenu::processJoinGameButton(), GameMenu::processMainMenuButton(), GameMenu::processMultiPlayerAcctButton(), GameMenu::processMultiPlayerButton(), GameMenu::processMultiPlayerHostButton(), GameMenu::processSinglePlayerButton(), NetActionConfirm::processWindowCommand(), NavComputer::RenameConfirm::processWindowCommand(), BaseComputer::LoadSaveQuitConfirm::processWindowCommand(), ListQuestionDialog::processWindowCommand(), NavComputer::recalcTitle(), BaseComputer::recalcTitle(), ModalDialog::run(), BaseComputer::BuyUpgradeOperation::selectMount(), BaseComputer::SellUpgradeOperation::selectMount(), BaseComputer::showNetworkStatus(), BaseComputer::showPlayerInfo(), BaseComputer::showShipStats(), UniverseUtil::startMenuInterface(), BaseComputer::switchToControls(), NavComputer::switchToMajorControls(), NavComputer::switchToMinorControls(), NavComputer::updateDescription(), NavComputer::updateNodeDescription(), and BaseComputer::updateTransactionControlsForSelection().

50  {
51  return m_window;
52  }

Member Data Documentation

bool WindowController::m_deleteOnWindowClose
protected
Window* WindowController::m_window
protected

The documentation for this class was generated from the following files: