summaryrefslogtreecommitdiff
path: root/noncore/games/minesweep/minesweep.h
Unidiff
Diffstat (limited to 'noncore/games/minesweep/minesweep.h') (more/less context) (show whitespace changes)
-rw-r--r--noncore/games/minesweep/minesweep.h67
1 files changed, 67 insertions, 0 deletions
diff --git a/noncore/games/minesweep/minesweep.h b/noncore/games/minesweep/minesweep.h
new file mode 100644
index 0000000..e860573
--- a/dev/null
+++ b/noncore/games/minesweep/minesweep.h
@@ -0,0 +1,67 @@
1/**********************************************************************
2** Copyright (C) 2000 Trolltech AS. All rights reserved.
3**
4** This file is part of Qtopia Environment.
5**
6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file.
10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13**
14** See http://www.trolltech.com/gpl/ for GPL licensing information.
15**
16** Contact info@trolltech.com if any conditions of this licensing are
17** not clear to you.
18**
19**********************************************************************/
20#ifndef MINESWEEP_H
21#define MINESWEEP_H
22
23#include <qmainwindow.h>
24#include <qdatetime.h>
25
26class MineField;
27class QLCDNumber;
28class QPushButton;
29
30class MineSweep : public QMainWindow
31{
32 Q_OBJECT
33public:
34 MineSweep( QWidget* parent = 0, const char* name = 0, WFlags f = 0 );
35 ~MineSweep();
36
37public slots:
38 void gameOver( bool won );
39 void newGame();
40
41protected slots:
42 void setCounter( int );
43 void updateTime();
44
45 void beginner();
46 void advanced();
47 void expert();
48
49private slots:
50 void startPlaying();
51
52private:
53 void readConfig();
54 void writeConfig() const;
55
56 void newGame(int);
57 MineField* field;
58 QLCDNumber* guessLCD;
59 QLCDNumber* timeLCD;
60 QPushButton* newGameButton;
61
62 QDateTime starttime;
63 QTimer* timer;
64};
65
66#endif // MINESWEEP_H
67