2022-02-24 10:18:02 +01:00
|
|
|
|
2022-02-24 11:50:16 +01:00
|
|
|
#include "gamebase/GameBase.hpp"
|
|
|
|
#include "gamebase/PGNGameBase.hpp"
|
2022-02-24 15:22:56 +01:00
|
|
|
#include "ochess.hpp"
|
2022-02-24 10:18:02 +01:00
|
|
|
|
2022-02-24 16:45:28 +01:00
|
|
|
// Foreign events
|
|
|
|
wxDECLARE_EVENT(NEW_GAME_EVENT, wxCommandEvent);
|
2022-02-25 09:21:26 +01:00
|
|
|
wxDECLARE_EVENT(REFRESH_TAB_TITLE, wxCommandEvent);
|
2022-02-24 16:45:28 +01:00
|
|
|
|
2022-02-28 13:02:27 +01:00
|
|
|
class BaseTab : public TabBase, public TabInfos {
|
2022-02-24 11:50:16 +01:00
|
|
|
GameBase *base;
|
2022-02-25 11:13:35 +01:00
|
|
|
std::vector<std::uint32_t> deleted;
|
2022-02-28 20:16:57 +01:00
|
|
|
std::vector<std::shared_ptr<Game>> edited;
|
2022-02-25 11:42:46 +01:00
|
|
|
std::string base_file;
|
2022-02-24 15:22:56 +01:00
|
|
|
|
2022-02-24 10:18:02 +01:00
|
|
|
public:
|
2022-02-25 09:21:26 +01:00
|
|
|
BaseTab(wxFrame *parent, std::string base_file);
|
2022-02-28 18:51:47 +01:00
|
|
|
~BaseTab();
|
2022-02-24 11:50:16 +01:00
|
|
|
void ApplyPreferences();
|
2022-02-25 11:42:46 +01:00
|
|
|
void LoadFile();
|
2022-02-25 11:13:35 +01:00
|
|
|
void OnDelete(wxCommandEvent &event);
|
|
|
|
void OnSave(wxCommandEvent &event);
|
2022-02-25 14:57:09 +01:00
|
|
|
void OnExport(wxCommandEvent &event);
|
2022-02-24 15:22:56 +01:00
|
|
|
void OnOpenGame(wxListEvent &event);
|
2022-02-26 12:30:07 +01:00
|
|
|
void OnImport(wxCommandEvent &event);
|
2022-02-28 20:16:57 +01:00
|
|
|
std::shared_ptr<Game> GetGame() { return (std::shared_ptr<Game>(NULL)); }
|
2022-02-25 15:29:04 +01:00
|
|
|
void *GetBase() { return (base); };
|
2022-02-24 10:18:02 +01:00
|
|
|
};
|