OChess v0.0.2
Programmer's Manual
TabInfos Class Referenceabstract

Used by each tab of the GUI to attach additional informations and features. More...

#include <ochess.hpp>

Inheritance diagram for TabInfos:
BaseTab EngineTab GameTab

Public Types

enum  Type { GAME , BASE , ENGINE , NONE }
 Which type of tab is it?
 
typedef enum TabInfos::Type Type
 Which type of tab is it?
 

Public Member Functions

 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 ()
 

Public Attributes

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.
 

Static Private Attributes

static long tab_count = 0
 Keep track of the number of opened tabs.
 

Detailed Description

Used by each tab of the GUI to attach additional informations and features.

Member Function Documentation

◆ ApplyPreferences()

virtual void TabInfos::ApplyPreferences ( )
inlinevirtual

Can be called to load preferences that have been modify in the application settings.

Reimplemented in EngineTab, and GameTab.

◆ OnLink()

virtual void TabInfos::OnLink ( )
inlinevirtual

Callback that is called when the current tab is linked to another one.

Reimplemented in GameTab.


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