Diffstat (limited to 'noncore/games/minesweep/minesweep.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/games/minesweep/minesweep.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/noncore/games/minesweep/minesweep.cpp b/noncore/games/minesweep/minesweep.cpp index 48644b3..7214a73 100644 --- a/noncore/games/minesweep/minesweep.cpp +++ b/noncore/games/minesweep/minesweep.cpp | |||
@@ -12,24 +12,25 @@ | |||
12 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | 12 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
13 | ** | 13 | ** |
14 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. | 14 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. |
15 | ** | 15 | ** |
16 | ** Contact info@trolltech.com if any conditions of this licensing are | 16 | ** Contact info@trolltech.com if any conditions of this licensing are |
17 | ** not clear to you. | 17 | ** not clear to you. |
18 | ** | 18 | ** |
19 | **********************************************************************/ | 19 | **********************************************************************/ |
20 | 20 | ||
21 | #include "minesweep.h" | 21 | #include "minesweep.h" |
22 | #include "minefield.h" | 22 | #include "minefield.h" |
23 | 23 | ||
24 | #include <qpe/qpeapplication.h> | ||
24 | #include <qpe/resource.h> | 25 | #include <qpe/resource.h> |
25 | #include <qpe/config.h> | 26 | #include <qpe/config.h> |
26 | 27 | ||
27 | #include <qpe/qpetoolbar.h> | 28 | #include <qpe/qpetoolbar.h> |
28 | #include <qmenubar.h> | 29 | #include <qmenubar.h> |
29 | #include <qpopupmenu.h> | 30 | #include <qpopupmenu.h> |
30 | #include <qpushbutton.h> | 31 | #include <qpushbutton.h> |
31 | #include <qlcdnumber.h> | 32 | #include <qlcdnumber.h> |
32 | #include <qmessagebox.h> | 33 | #include <qmessagebox.h> |
33 | #include <qtimer.h> | 34 | #include <qtimer.h> |
34 | #include <qpalette.h> | 35 | #include <qpalette.h> |
35 | #include <qapplication.h> | 36 | #include <qapplication.h> |
@@ -230,24 +231,25 @@ protected: | |||
230 | field->setAvailableRect( contentsRect()); | 231 | field->setAvailableRect( contentsRect()); |
231 | QFrame::resizeEvent(e); | 232 | QFrame::resizeEvent(e); |
232 | } | 233 | } |
233 | private: | 234 | private: |
234 | MineField *field; | 235 | MineField *field; |
235 | }; | 236 | }; |
236 | 237 | ||
237 | 238 | ||
238 | 239 | ||
239 | MineSweep::MineSweep( QWidget* parent, const char* name, WFlags f ) | 240 | MineSweep::MineSweep( QWidget* parent, const char* name, WFlags f ) |
240 | : QMainWindow( parent, name, f ) | 241 | : QMainWindow( parent, name, f ) |
241 | { | 242 | { |
243 | QPEApplication::setInputMethodHint(this, QPEApplication::AlwaysOff ); | ||
242 | srand(::time(0)); | 244 | srand(::time(0)); |
243 | setCaption( tr("Mine Hunt") ); | 245 | setCaption( tr("Mine Hunt") ); |
244 | setIcon( Resource::loadPixmap( "minesweep_icon" ) ); | 246 | setIcon( Resource::loadPixmap( "minesweep_icon" ) ); |
245 | 247 | ||
246 | QToolBar *toolBar = new QToolBar( this ); | 248 | QToolBar *toolBar = new QToolBar( this ); |
247 | toolBar->setHorizontalStretchable( TRUE ); | 249 | toolBar->setHorizontalStretchable( TRUE ); |
248 | 250 | ||
249 | QMenuBar *menuBar = new QMenuBar( toolBar ); | 251 | QMenuBar *menuBar = new QMenuBar( toolBar ); |
250 | 252 | ||
251 | QPopupMenu *gameMenu = new QPopupMenu( this ); | 253 | QPopupMenu *gameMenu = new QPopupMenu( this ); |
252 | gameMenu->insertItem( tr("Beginner"), this, SLOT( beginner() ) ); | 254 | gameMenu->insertItem( tr("Beginner"), this, SLOT( beginner() ) ); |
253 | gameMenu->insertItem( tr("Advanced"), this, SLOT( advanced() ) ); | 255 | gameMenu->insertItem( tr("Advanced"), this, SLOT( advanced() ) ); |