summaryrefslogtreecommitdiff
path: root/quacker/macondo.h
blob: 18441b59254403f5996650df9de07808dc7474d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#ifndef MACONDO_H
#define MACONDO_H

#include <QWidget>

class QPushButton;
class QTimer;
namespace Quackle {
	class Game;
	class MoveList;
}
class MacondoBackend;
struct MacondoInitOptions;
class MoveBox;
class Macondo : public QWidget {
Q_OBJECT
public:
	Macondo(Quackle::Game *);
	~Macondo();
	void setGame(Quackle::Game *);
public slots:
	void simulate();
private slots:
	void gotSimMoves(const Quackle::MoveList &moves);
private:
	enum class Command {
		None,
		Simulate,
		Solve,
	};
	QPushButton *m_simulateButton;
	Quackle::Game *m_game;
	MacondoBackend *m_backend;
	int m_viewingPlyNumber = 0;
	Command m_command = Command::None;
	MoveBox *m_moveBox;
	std::unique_ptr<MacondoInitOptions> initOptions;
};

#endif