OChess v0.0.2
Programmer's Manual
BaseTab Class Reference

Class that represents an opened chess games database in the MainWindow. More...

#include <BaseTab.hpp>

Inheritance diagram for BaseTab:
TabBase TabInfos

Public Member Functions

 BaseTab (wxFrame *parent, std::string base_file)
 
void Refresh ()
 
std::shared_ptr< GameGetGame ()
 
std::shared_ptr< GameBaseGetBase ()
 
- Public Member Functions inherited from TabBase
 TabBase (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(884, 624), long style=wxTAB_TRAVERSAL, const wxString &name=wxEmptyString)
 
- Public Member Functions inherited from TabInfos
 TabInfos (Type type_)
 
void Link (TabInfos *tab)
 
virtual void Refresh ()
 
virtual void OnLink ()
 Callback that is called when the current tab is linked to another one. More...
 
virtual void ApplyPreferences ()
 Can be called to load preferences that have been modify in the application settings. More...
 
virtual std::shared_ptr< GameGetGame ()=0
 
virtual std::shared_ptr< GameBaseGetBase ()=0
 
virtual std::uint32_t GetEngineId ()
 

Private Member Functions

void OnOpenGame (wxListEvent &event)
 Listen events from BaseImportTab.
 
void OnSave (wxCommandEvent &event)
 Listen events from BaseManageTab.
 

Private Attributes

std::shared_ptr< GameBasebase
 The opened database.
 
std::shared_ptr< Gamegame
 The last opened game.
 
BaseGameTabgames_tab
 All sub tabs from this main table.
 
BaseImportTabimport_tab
 
BaseManageTabmanage_tab
 
std::string base_file
   More...
 

Additional Inherited Members

- Public Types inherited from TabInfos
enum  Type { GAME , BASE , ENGINE , NONE }
 Which type of tab is it?
 
typedef enum TabInfos::Type Type
 Which type of tab is it?
 
- Public Attributes inherited from TabInfos
Type type
 
long id
 Each tab has an associated unique id.
 
long linked_id
 Specify to which tab id this tab is linked (e.g: database to linked to on of its opened game tab)
 
bool is_linked
 Set to true if this tab is attach to another one (c.f linked_id)
 
bool is_dirty
 True if current tab is dirty.
 
- Protected Attributes inherited from TabBase
wxNotebook * notebook
 

Detailed Description

Class that represents an opened chess games database in the MainWindow.

Member Function Documentation

◆ GetBase()

std::shared_ptr< GameBase > BaseTab::GetBase ( )
inlinevirtual

Implements TabInfos.

◆ GetGame()

std::shared_ptr< Game > BaseTab::GetGame ( )
inlinevirtual

Implements TabInfos.

◆ Refresh()

void BaseTab::Refresh ( )
virtual

Reimplemented from TabInfos.

Member Data Documentation

◆ base_file

std::string BaseTab::base_file
private

 

Database file path


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