mainwindow.h 1.12 KB
Newer Older
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
1 2 3 4 5
#ifndef KREVERSI_MAIN_WINDOW_H
#define KREVERSI_MAIN_WINDOW_H

#include <kmainwindow.h>

6
class KReversiScene;
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
7
class KReversiGame;
8
class KReversiView;
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
9
class KAction;
10
class KSelectAction;
11
class KToggleAction;
12 13
class QListWidget;
class QLabel;
14

Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
15 16
class KReversiMainWindow : public KMainWindow
{
17
    Q_OBJECT
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
18 19
public:
    KReversiMainWindow(QWidget* parent=0);
20
public slots:
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
21
    void slotNewGame();
22
    void slotBackgroundChanged(const QString& text);
23
    void slotSkillChanged(int);
24
    void slotAnimSpeedChanged(int);
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
25
    void slotUndo();
26
    void slotMoveFinished();
27
    void slotGameOver();
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
28
    void slotDemoMode(bool);
29
    void slotUseColoredChips(bool);
30
    void slotShowMovesHistory(bool);
31
    void slotComputerCantMove();
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
32 33
private:
    void setupActions();
34
    void loadSettings();
35

Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
36
    KReversiScene *m_scene;
37
    KReversiView  *m_view;
38 39
    KReversiGame  *m_game;
    QLabel        *m_historyLabel;
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
40
    QListWidget   *m_historyView;
41 42

    KAction* m_undoAct;
43
    KAction* m_hintAct;
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
44
    KAction* m_demoAct;
45
    KSelectAction* m_animSpeedAct;
46 47
    KSelectAction* m_bkgndAct;
    KSelectAction* m_skillAct;
48
    KToggleAction* m_coloredChipsAct;
Dmitry Suzdalev's avatar
Dmitry Suzdalev committed
49 50
};
#endif