aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/MainWindow.cpp16
-rw-r--r--src/game_tab/Game.cpp2
-rw-r--r--src/game_tab/Game.hpp5
-rw-r--r--src/game_tab/HalfMove.hpp6
4 files changed, 13 insertions, 16 deletions
diff --git a/src/MainWindow.cpp b/src/MainWindow.cpp
index afca91e..f9d5905 100644
--- a/src/MainWindow.cpp
+++ b/src/MainWindow.cpp
@@ -58,22 +58,6 @@ MainWindow::MainWindow()
Bind(wxEVT_CLOSE_WINDOW, &MainWindow::OnClose, this);
}
-class AdvancePage : public wxPreferencesPage {
-public:
- virtual wxString GetName() const { return "Topics"; }
- virtual wxBitmap GetLargeIcon() {
- return wxArtProvider::GetBitmap(wxART_HELP, wxART_TOOLBAR);
- }
- virtual wxWindow *CreateWindow(wxWindow *parent) {
- wxPanel *p =
- new wxPanel(parent, wxID_ANY, wxDefaultPosition, wxSize(800, 800));
- wxBoxSizer *s = new wxBoxSizer(wxVERTICAL);
- s->Add(new wxButton(p, COPY_FEN_BTN, L"Copy FEN"), 1, wxEXPAND);
- p->SetSizer(s);
- return p;
- }
-};
-
void MainWindow::OnSettings(wxCommandEvent &event) {
if (prefsEditor != NULL) {
delete prefsEditor;
diff --git a/src/game_tab/Game.cpp b/src/game_tab/Game.cpp
index dab67b8..48e48bf 100644
--- a/src/game_tab/Game.cpp
+++ b/src/game_tab/Game.cpp
@@ -29,6 +29,7 @@ std::string Game::GetTag(std::string tagname) { return (tags[tagname]); }
void Game::SetTag(std::string tagname, std::string value) {
tags[tagname] = value;
}
+
bool Game::IsBlackToPlay() {
if (current == NULL) {
return (false);
@@ -55,6 +56,7 @@ void Game::DeleteMove(HalfMove *m) {
}
HalfMove *Game::GetCurrentMove() { return (current); }
+
HalfMove *Game::GetMoves() { return (moves); }
void Game::PromoteMove(HalfMove *m) {
diff --git a/src/game_tab/Game.hpp b/src/game_tab/Game.hpp
index 37b6f77..53249fb 100644
--- a/src/game_tab/Game.hpp
+++ b/src/game_tab/Game.hpp
@@ -37,5 +37,10 @@ public:
std::vector<std::string> ListTags();
std::string GetPGN();
void SetResult(std::string result);
+ /**
+ * @brief Build current game
+ * Verify and play all the moves in the game
+ * while building the fen for each move
+ */
void BuildAndVerify();
}; \ No newline at end of file
diff --git a/src/game_tab/HalfMove.hpp b/src/game_tab/HalfMove.hpp
index 07be4d0..51b38a0 100644
--- a/src/game_tab/HalfMove.hpp
+++ b/src/game_tab/HalfMove.hpp
@@ -55,5 +55,11 @@ public:
void SetFen(std::string fen);
void SetCapture(char c);
std::string GetPGN();
+
+ /**
+ * @brief Build current move
+ * Verify and play all the moves in the game
+ * while building the fen for each move
+ */
void BuildAndVerify(std::string initial_fen);
};