author | zecke <zecke> | 2004-02-06 12:14:56 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-02-06 12:14:56 (UTC) |
commit | 0c74629e8f5c12a9b5a282b817f884fa10dee491 (patch) (side-by-side diff) | |
tree | 3294663b92023f8d24d68a01022e011a3c94002d /noncore/games/wordgame | |
parent | 46ce5afcfbe7be19f4d5ac0fed6886a0759f1a25 (diff) | |
download | opie-0c74629e8f5c12a9b5a282b817f884fa10dee491.zip opie-0c74629e8f5c12a9b5a282b817f884fa10dee491.tar.gz opie-0c74629e8f5c12a9b5a282b817f884fa10dee491.tar.bz2 |
Merge from the 1.0.x release
-rw-r--r-- | noncore/games/wordgame/main.cpp | 10 | ||||
-rw-r--r-- | noncore/games/wordgame/wordgame.h | 1 | ||||
-rw-r--r-- | noncore/games/wordgame/wordgame.pro | 5 |
3 files changed, 5 insertions, 11 deletions
diff --git a/noncore/games/wordgame/main.cpp b/noncore/games/wordgame/main.cpp index cd4600e..f32acff 100644 --- a/noncore/games/wordgame/main.cpp +++ b/noncore/games/wordgame/main.cpp @@ -1,34 +1,28 @@ /********************************************************************** ** Copyright (C) 2000 Trolltech AS. All rights reserved. ** ** This file is part of Qtopia Environment. ** ** This file may be distributed and/or modified under the terms of the ** GNU General Public License version 2 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. ** ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #include "wordgame.h" #include <qpe/qpeapplication.h> +#include <opie/oapplicationfactory.h> -int main( int argc, char ** argv ) -{ - QPEApplication a( argc, argv ); - WordGame mw; - //QPEApplication::setInputMethodHint( &mw, QPEApplication::AlwaysOff ); - a.showMainWidget(&mw); +OPIE_EXPORT_APP( OApplicationFactory<WordGame> ) - return a.exec(); -} diff --git a/noncore/games/wordgame/wordgame.h b/noncore/games/wordgame/wordgame.h index f73c85a..020a4b5 100644 --- a/noncore/games/wordgame/wordgame.h +++ b/noncore/games/wordgame/wordgame.h @@ -288,48 +288,49 @@ public: protected: QSize sizeHint() const; public slots: void showTemporaryScore(int amount); private slots: void showScores(); private: QStringList names; int *score; QTimer* msgtimer; bool showwinner; int boldone; }; class NewGame; class WordGame : public QMainWindow { Q_OBJECT public: WordGame( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 ); ~WordGame(); + static QString appName() { return QString::fromLatin1("wordgame"); } private slots: void endTurn(); void resetTurn(); void passTurn(); void think(); void endGame(); void startGame(); private: void writeConfig(); void readConfig(); void startGame(const QStringList& pnames); bool mayEndGame(); void openGameSelector(const QStringList& initnames); bool loadRules(const QString& filename); void addPlayer(const QString& name); void addPlayer(const QString& name, int cpu); void nextPlayer(); bool refillRack(int i); void readyRack(int i); Rack* rack(int i) const; diff --git a/noncore/games/wordgame/wordgame.pro b/noncore/games/wordgame/wordgame.pro index e997adc..7ef2bfd 100644 --- a/noncore/games/wordgame/wordgame.pro +++ b/noncore/games/wordgame/wordgame.pro @@ -1,13 +1,12 @@ -TEMPLATE = app -CONFIG = qt warn_on release -DESTDIR = $(OPIEDIR)/bin +CONFIG = qt warn_on release quick-app HEADERS = wordgame.h SOURCES = main.cpp \ wordgame.cpp INTERFACES = newgamebase.ui rulesbase.ui TARGET = wordgame INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe + include ( $(OPIEDIR)/include.pro ) |