2 Mancala - A Historical Board Game
3 Copyright (C) 2009-2010 A.H.M.Mahfuzur Rahman 65mahfuz90@gmail.com
4 Copyright (c) 2010 Reto Zingg g.d0b3rm4n@gmail.com
6 This program is free software; you can redistribute it and/or
7 modify it under the terms of the GNU General Public License as
8 published by the Free Software Foundation; either version 2 of
9 the License, or (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program. If not, see <http://www.gnu.org/licenses/>.
26 #include <QResizeEvent>
27 #include <QMainWindow>
30 #include <QStackedWidget>
32 //#include <kxmlguiwindow.h>
33 //#include <kgamedifficulty.h>
35 #include "GameController.h"
36 #include "settingswidget.h"
43 //class KSelectAction;
44 class QXmlStreamReader;
47 class MainWindow : public QMainWindow{
51 MainWindow(QWidget *parent = 0);
54 QString gameName(){ return m_gameName;}
56 QRectF windowRect(){ return this->rect();}
58 void setGameName(QString gameName);
62 void newGame(int gameId);
63 void slotShowScore(int score,bool human);
64 void slotShowTurn(bool);
65 void slotShowGameOver();
66 void slotMessage(QString);
68 // void slotChangeDifficulty(KGameDifficulty::standardLevel);
69 void slotChangeDifficulty(int level);
71 void slotShowSettings();
72 void slotChangeGameName(int game);
76 void signalLoadTheme();
77 void signalGameDifficulty(GameController::Difficulty);
80 void resizeEvent(QResizeEvent *event);
90 void parseXml(QIODevice *device);
93 GraphicsScene *m_scene;
95 ThemeManager* m_gameTheme;
96 GameController *m_gameController;
97 // KGameClock* m_gameClock;
99 QStringList m_gameNameList;
102 QGraphicsView *m_view;
103 // GraphicsView* m_view;
105 // KSelectAction* newGameAct;
106 QXmlStreamReader *reader;
121 QAction *newGameAction;
122 QAction *restartGameAction;
125 SettingsWidget *settings;
126 QStackedWidget *m_StackedWidget;
129 void resized(QSizeF size);
132 #endif // MAINWINDOW_H