Inherits nitro::ViewInterface.
Public Member Functions | |
TopWindow (void) | |
virtual bool | ExecuteCommand (const char *Command, const void *Param1=NULL, const void *Param2=NULL) |
virtual void * | GetGUI (const char *ViewName=NULL, void *Parent=NULL) |
Самое верхнее окно, которое никогда не будет показано, но будет родителем всех остальных окон приложения.
Definition at line 566 of file mvc_core.cpp.
nitro::TopWindow::TopWindow | ( | void | ) |
Definition at line 619 of file mvc_core.cpp.
: wxFrame( ( wxFrame * )NULL , -1 , "" , wxPoint( 0 , 0 ) , wxSize( 0 , 0 ) )
{
Centre();
Show( FALSE );
}
bool nitro::TopWindow::ExecuteCommand | ( | const char * | Command, | |
const void * | Param1 = NULL , |
|||
const void * | Param2 = NULL | |||
) | [virtual] |
Using this function a command to the class can be sent.
Command | - Command's name. | |
Param1 | - First parameter. | |
Param2 | - Second parameter. |
nitro::exception | - An exception of this type is thrown if the error occured. |
Reimplemented from nitro::ExecuteCommandInterface.
Definition at line 626 of file mvc_core.cpp.
References nitro::exception::code(), and nitro::exception::what().
{ try { if( std::string( "close_app" ) == Command ) { this->Close( TRUE ); return( false ); } return( true ); } catch( nitro::exception e ) { throw( nitro::exception( std::string( "TopWindow::ExecuteCommand( const char * Command , const void * Param1 /* = NULL */ , const void * Param2 /* = NULL */ )::" ) + e.what() , e.code() ) ); } catch( ... ) { throw( nitro::exception( "TopWindow::ExecuteCommand( const char * Command , const void * Param1 /* = NULL */ , const void * Param2 /* = NULL */ )::An error occured" , 1 ) ); } return( FALSE ); }
void * nitro::TopWindow::GetGUI | ( | const char * | ViewName = NULL , |
|
void * | Parent = NULL | |||
) | [virtual] |
Function provides access to the GUI.
ViewName | - View's name. | |
Parent | - Parent for the view. |
nitro::exception | - An exception of this type is thrown if the error occured. |
Reimplemented from nitro::ViewInterface.
Definition at line 651 of file mvc_core.cpp.
References nitro::exception::code(), and nitro::exception::what().
{ try { return( ( void * )( wxWindow * )this ); } catch( nitro::exception e ) { throw( nitro::exception( std::string( "TopWindow::GetGUI( const char * ViewName /* = NULL */ , void * Parent /* = NULL */ )::" ) + e.what() , e.code() ) ); } catch( ... ) { throw( nitro::exception( "TopWindow::GetGUI( const char * ViewName /* = NULL */ , void * Parent /* = NULL */ )::An error occured" , 1 ) ); } }