author | chicken <chicken> | 2004-03-01 20:30:56 (UTC) |
---|---|---|
committer | chicken <chicken> | 2004-03-01 20:30:56 (UTC) |
commit | 7b0bdb05e4ae29b2643d73e3b8f20a86a86dcccc (patch) (unidiff) | |
tree | 0ec283bce345770910a2630e868afcde3d7c3dc9 /noncore/games/kpacman | |
parent | 054b3c3e032bdb0a6061a3345487b4ff877eebfd (diff) | |
download | opie-7b0bdb05e4ae29b2643d73e3b8f20a86a86dcccc.zip opie-7b0bdb05e4ae29b2643d73e3b8f20a86a86dcccc.tar.gz opie-7b0bdb05e4ae29b2643d73e3b8f20a86a86dcccc.tar.bz2 |
fix includes
-rw-r--r-- | noncore/games/kpacman/board.cpp | 3 | ||||
-rw-r--r-- | noncore/games/kpacman/keys.cpp | 5 | ||||
-rw-r--r-- | noncore/games/kpacman/kpacman.cpp | 5 | ||||
-rw-r--r-- | noncore/games/kpacman/kpacmanwidget.cpp | 5 | ||||
-rw-r--r-- | noncore/games/kpacman/monster.cpp | 1 | ||||
-rw-r--r-- | noncore/games/kpacman/pacman.cpp | 1 | ||||
-rw-r--r-- | noncore/games/kpacman/painter.cpp | 10 | ||||
-rw-r--r-- | noncore/games/kpacman/referee.cpp | 9 | ||||
-rw-r--r-- | noncore/games/kpacman/score.cpp | 6 | ||||
-rw-r--r-- | noncore/games/kpacman/status.cpp | 2 |
10 files changed, 1 insertions, 46 deletions
diff --git a/noncore/games/kpacman/board.cpp b/noncore/games/kpacman/board.cpp index f95f699..f82b5f9 100644 --- a/noncore/games/kpacman/board.cpp +++ b/noncore/games/kpacman/board.cpp | |||
@@ -1,22 +1,19 @@ | |||
1 | 1 | ||
2 | #include "portable.h" | ||
3 | 2 | ||
4 | #if defined( KDE2_PORT ) | 3 | #if defined( KDE2_PORT ) |
5 | #include <kapp.h> | 4 | #include <kapp.h> |
6 | #include <klocale.h> | 5 | #include <klocale.h> |
7 | #endif | 6 | #endif |
8 | 7 | ||
9 | #include <qrect.h> | ||
10 | #include <qregexp.h> | ||
11 | #include <qmessagebox.h> | 8 | #include <qmessagebox.h> |
12 | #include <qfile.h> | 9 | #include <qfile.h> |
13 | #include <qtextstream.h> | 10 | #include <qtextstream.h> |
14 | 11 | ||
15 | #include "board.h" | 12 | #include "board.h" |
16 | #include "bitmaps.h" | 13 | #include "bitmaps.h" |
17 | 14 | ||
18 | Board::Board(int size) : QArray<int> (size) | 15 | Board::Board(int size) : QArray<int> (size) |
19 | { | 16 | { |
20 | sz = size; // set size of board | 17 | sz = size; // set size of board |
21 | 18 | ||
22 | map = ""; | 19 | map = ""; |
diff --git a/noncore/games/kpacman/keys.cpp b/noncore/games/kpacman/keys.cpp index 07ce135..5200bc2 100644 --- a/noncore/games/kpacman/keys.cpp +++ b/noncore/games/kpacman/keys.cpp | |||
@@ -9,29 +9,24 @@ | |||
9 | #include <kaccel.h> | 9 | #include <kaccel.h> |
10 | 10 | ||
11 | #include <keys.h> | 11 | #include <keys.h> |
12 | #include <keys.moc> | 12 | #include <keys.moc> |
13 | #elif defined( QPE_PORT ) | 13 | #elif defined( QPE_PORT ) |
14 | #include <qaccel.h> | 14 | #include <qaccel.h> |
15 | #include <qpe/qpeapplication.h> | 15 | #include <qpe/qpeapplication.h> |
16 | #include <qpe/config.h> | 16 | #include <qpe/config.h> |
17 | #include "keys.h" | 17 | #include "keys.h" |
18 | #endif | 18 | #endif |
19 | 19 | ||
20 | #include <qpushbt.h> | 20 | #include <qpushbt.h> |
21 | #include <qlabel.h> | ||
22 | #include <qframe.h> | ||
23 | #include <qkeycode.h> | ||
24 | #include <qpixmap.h> | ||
25 | #include <qstring.h> | ||
26 | 21 | ||
27 | Keys::Keys( QWidget *parent, const char *name) | 22 | Keys::Keys( QWidget *parent, const char *name) |
28 | : QDialog( parent, name, TRUE ) | 23 | : QDialog( parent, name, TRUE ) |
29 | { | 24 | { |
30 | //KStandardDirs *dirs = KGlobal::dirs(); | 25 | //KStandardDirs *dirs = KGlobal::dirs(); |
31 | 26 | ||
32 | QPushButton *okButton = new QPushButton(this); | 27 | QPushButton *okButton = new QPushButton(this); |
33 | okButton->setText(tr("Ok")); | 28 | okButton->setText(tr("Ok")); |
34 | okButton->setFixedSize(okButton->size()); | 29 | okButton->setFixedSize(okButton->size()); |
35 | connect( okButton, SIGNAL(clicked()),this, SLOT(ok()) ); | 30 | connect( okButton, SIGNAL(clicked()),this, SLOT(ok()) ); |
36 | okButton->move(20,210); | 31 | okButton->move(20,210); |
37 | 32 | ||
diff --git a/noncore/games/kpacman/kpacman.cpp b/noncore/games/kpacman/kpacman.cpp index df27c76..be2e46d 100644 --- a/noncore/games/kpacman/kpacman.cpp +++ b/noncore/games/kpacman/kpacman.cpp | |||
@@ -3,29 +3,24 @@ | |||
3 | 3 | ||
4 | #if defined( KDE2_PORT ) | 4 | #if defined( KDE2_PORT ) |
5 | #include <kpacman.h> | 5 | #include <kpacman.h> |
6 | #include <kpacman.moc> | 6 | #include <kpacman.moc> |
7 | #include <kcolordlg.h> | 7 | #include <kcolordlg.h> |
8 | #elif defined( QPE_PORT ) | 8 | #elif defined( QPE_PORT ) |
9 | #include <qmenubar.h> | 9 | #include <qmenubar.h> |
10 | #include <qpe/config.h> | 10 | #include <qpe/config.h> |
11 | #include <qapplication.h> | 11 | #include <qapplication.h> |
12 | #include "kpacman.h" | 12 | #include "kpacman.h" |
13 | #endif | 13 | #endif |
14 | 14 | ||
15 | #include <qkeycode.h> | ||
16 | #include <qcolor.h> | ||
17 | #include <qstring.h> | ||
18 | #include <qpopmenu.h> | ||
19 | #include <qmsgbox.h> | ||
20 | 15 | ||
21 | Kpacman::Kpacman(QWidget *parent, const char *name) | 16 | Kpacman::Kpacman(QWidget *parent, const char *name) |
22 | : KTMainWindow(parent, name) | 17 | : KTMainWindow(parent, name) |
23 | { | 18 | { |
24 | schemesPopup = new QList<QPopupMenu>; | 19 | schemesPopup = new QList<QPopupMenu>; |
25 | schemesPopup->setAutoDelete(TRUE); | 20 | schemesPopup->setAutoDelete(TRUE); |
26 | 21 | ||
27 | menu(); | 22 | menu(); |
28 | 23 | ||
29 | m_view = new QWidget( this, "m_view" ); | 24 | m_view = new QWidget( this, "m_view" ); |
30 | m_view->setBackgroundColor( black ); | 25 | m_view->setBackgroundColor( black ); |
31 | m_layout = new QGridLayout( m_view ); | 26 | m_layout = new QGridLayout( m_view ); |
diff --git a/noncore/games/kpacman/kpacmanwidget.cpp b/noncore/games/kpacman/kpacmanwidget.cpp index 823d2bf..9631495 100644 --- a/noncore/games/kpacman/kpacmanwidget.cpp +++ b/noncore/games/kpacman/kpacmanwidget.cpp | |||
@@ -4,30 +4,25 @@ | |||
4 | #if defined( KDE2_PORT ) | 4 | #if defined( KDE2_PORT ) |
5 | #include <kapp.h> | 5 | #include <kapp.h> |
6 | #include <kconfig.h> | 6 | #include <kconfig.h> |
7 | #include <kstddirs.h> | 7 | #include <kstddirs.h> |
8 | #include <kpacmanwidget.h> | 8 | #include <kpacmanwidget.h> |
9 | #include <kpacmanwidget.moc> | 9 | #include <kpacmanwidget.moc> |
10 | #elif defined( QPE_PORT ) | 10 | #elif defined( QPE_PORT ) |
11 | #include <qpe/qpeapplication.h> | 11 | #include <qpe/qpeapplication.h> |
12 | #include <qpe/config.h> | 12 | #include <qpe/config.h> |
13 | #include "kpacmanwidget.h" | 13 | #include "kpacmanwidget.h" |
14 | #endif | 14 | #endif |
15 | 15 | ||
16 | #include <qmessagebox.h> | ||
17 | 16 | ||
18 | #include "bitfont.h" | ||
19 | #include "score.h" | ||
20 | #include "referee.h" | ||
21 | #include "status.h" | ||
22 | 17 | ||
23 | KpacmanWidget::KpacmanWidget( QWidget *parent, const char *name) | 18 | KpacmanWidget::KpacmanWidget( QWidget *parent, const char *name) |
24 | : QWidget( parent, name ) | 19 | : QWidget( parent, name ) |
25 | { | 20 | { |
26 | score = 0l; | 21 | score = 0l; |
27 | referee = 0l; | 22 | referee = 0l; |
28 | status = 0l; | 23 | status = 0l; |
29 | bitfont = NULL; | 24 | bitfont = NULL; |
30 | fontName = ""; | 25 | fontName = ""; |
31 | 26 | ||
32 | scheme = mode = -1; | 27 | scheme = mode = -1; |
33 | confScheme(); | 28 | confScheme(); |
diff --git a/noncore/games/kpacman/monster.cpp b/noncore/games/kpacman/monster.cpp index 2f402b4..80b4655 100644 --- a/noncore/games/kpacman/monster.cpp +++ b/noncore/games/kpacman/monster.cpp | |||
@@ -1,14 +1,13 @@ | |||
1 | #include "monster.h" | 1 | #include "monster.h" |
2 | #include "board.h" | ||
3 | 2 | ||
4 | Monster::Monster(Board *b, int mid) | 3 | Monster::Monster(Board *b, int mid) |
5 | { | 4 | { |
6 | board = b; | 5 | board = b; |
7 | ID = mid; | 6 | ID = mid; |
8 | 7 | ||
9 | setREM(0); | 8 | setREM(0); |
10 | setHarmless(0, 0, 0); | 9 | setHarmless(0, 0, 0); |
11 | setArrested(0, 0); | 10 | setArrested(0, 0); |
12 | setFreedom(board->position(prisonexit)); | 11 | setFreedom(board->position(prisonexit)); |
13 | if (mid == 0) | 12 | if (mid == 0) |
14 | setPrison(board->position(prisonentry)); | 13 | setPrison(board->position(prisonentry)); |
diff --git a/noncore/games/kpacman/pacman.cpp b/noncore/games/kpacman/pacman.cpp index 40f60a8..82524b4 100644 --- a/noncore/games/kpacman/pacman.cpp +++ b/noncore/games/kpacman/pacman.cpp | |||
@@ -1,14 +1,13 @@ | |||
1 | #include "pacman.h" | 1 | #include "pacman.h" |
2 | #include "board.h" | ||
3 | 2 | ||
4 | Pacman::Pacman(Board *b) | 3 | Pacman::Pacman(Board *b) |
5 | { | 4 | { |
6 | board = b; | 5 | board = b; |
7 | setDemo(FALSE); | 6 | setDemo(FALSE); |
8 | setAlive(0); | 7 | setAlive(0); |
9 | actualPosition = lastPosition = OUT; | 8 | actualPosition = lastPosition = OUT; |
10 | mouthPosition = 0; | 9 | mouthPosition = 0; |
11 | lastPix = 0; | 10 | lastPix = 0; |
12 | maxPixmaps = 0; | 11 | maxPixmaps = 0; |
13 | } | 12 | } |
14 | 13 | ||
diff --git a/noncore/games/kpacman/painter.cpp b/noncore/games/kpacman/painter.cpp index d8c7460..410d3f5 100644 --- a/noncore/games/kpacman/painter.cpp +++ b/noncore/games/kpacman/painter.cpp | |||
@@ -1,36 +1,28 @@ | |||
1 | 1 | ||
2 | #include "portable.h" | 2 | #include "portable.h" |
3 | 3 | ||
4 | #if defined( KDE2_PORT ) | 4 | #if defined( KDE2_PORT ) |
5 | #include <kapp.h> | 5 | #include <kapp.h> |
6 | #include <kconfig.h> | 6 | #include <kconfig.h> |
7 | #include <kstddirs.h> | 7 | #include <kstddirs.h> |
8 | #elif defined( QPE_PORT ) | 8 | #elif defined( QPE_PORT ) |
9 | #include <qpe/qpeapplication.h> | 9 | #include <qpe/qpeapplication.h> |
10 | #include <qpe/config.h> | 10 | #include <qpe/config.h> |
11 | #endif | 11 | #endif |
12 | 12 | ||
13 | #include <qcolor.h> | 13 | |
14 | #include <qpainter.h> | ||
15 | #include <qpixmap.h> | ||
16 | #include <qbitmap.h> | ||
17 | #include <qrect.h> | ||
18 | #include <qstring.h> | ||
19 | |||
20 | #include <qmessagebox.h> | ||
21 | #include <qfileinfo.h> | 14 | #include <qfileinfo.h> |
22 | 15 | ||
23 | #include "painter.h" | 16 | #include "painter.h" |
24 | #include "board.h" | ||
25 | 17 | ||
26 | Painter::Painter( Board *b, QWidget *parent, int Scheme, int Mode, Bitfont *font) | 18 | Painter::Painter( Board *b, QWidget *parent, int Scheme, int Mode, Bitfont *font) |
27 | { | 19 | { |
28 | w = parent; | 20 | w = parent; |
29 | board = b; | 21 | board = b; |
30 | 22 | ||
31 | pointPix = NULL; | 23 | pointPix = NULL; |
32 | wallPix = NULL; | 24 | wallPix = NULL; |
33 | prisonPix = NULL; | 25 | prisonPix = NULL; |
34 | energizerPix = NULL; | 26 | energizerPix = NULL; |
35 | fruitPix = NULL; | 27 | fruitPix = NULL; |
36 | pacmanPix = NULL; | 28 | pacmanPix = NULL; |
diff --git a/noncore/games/kpacman/referee.cpp b/noncore/games/kpacman/referee.cpp index 1b810d8..2d0f3be 100644 --- a/noncore/games/kpacman/referee.cpp +++ b/noncore/games/kpacman/referee.cpp | |||
@@ -6,37 +6,28 @@ | |||
6 | #include <kconfig.h> | 6 | #include <kconfig.h> |
7 | #include <kstddirs.h> | 7 | #include <kstddirs.h> |
8 | #include <kaccel.h> | 8 | #include <kaccel.h> |
9 | #include <referee.h> | 9 | #include <referee.h> |
10 | #include <referee.moc> | 10 | #include <referee.moc> |
11 | #elif defined( QPE_PORT ) | 11 | #elif defined( QPE_PORT ) |
12 | #include <qaccel.h> | 12 | #include <qaccel.h> |
13 | #include <qpe/qpeapplication.h> | 13 | #include <qpe/qpeapplication.h> |
14 | #include <qpe/config.h> | 14 | #include <qpe/config.h> |
15 | #include "referee.h" | 15 | #include "referee.h" |
16 | #endif | 16 | #endif |
17 | 17 | ||
18 | #include <qdatetm.h> | ||
19 | #include <stdlib.h> | 18 | #include <stdlib.h> |
20 | #include <qtimer.h> | 19 | #include <qtimer.h> |
21 | #include <qevent.h> | ||
22 | #include <qcolor.h> | ||
23 | #include <qkeycode.h> | ||
24 | #include <qfileinfo.h> | 20 | #include <qfileinfo.h> |
25 | 21 | ||
26 | #include "board.h" | ||
27 | #include "pacman.h" | ||
28 | #include "monster.h" | ||
29 | #include "fruit.h" | ||
30 | #include "painter.h" | ||
31 | 22 | ||
32 | Referee::Referee( QWidget *parent, const char *name, int Scheme, int Mode, Bitfont *font) | 23 | Referee::Referee( QWidget *parent, const char *name, int Scheme, int Mode, Bitfont *font) |
33 | : QWidget( parent, name ) | 24 | : QWidget( parent, name ) |
34 | { | 25 | { |
35 | gameState.resize(12); | 26 | gameState.resize(12); |
36 | gameTimer = 0; | 27 | gameTimer = 0; |
37 | energizerTimer = 0; | 28 | energizerTimer = 0; |
38 | 29 | ||
39 | focusedPause = FALSE; | 30 | focusedPause = FALSE; |
40 | setFocusPolicy(QWidget::StrongFocus); | 31 | setFocusPolicy(QWidget::StrongFocus); |
41 | 32 | ||
42 | initKeys(); | 33 | initKeys(); |
diff --git a/noncore/games/kpacman/score.cpp b/noncore/games/kpacman/score.cpp index e91771b..6878b81 100644 --- a/noncore/games/kpacman/score.cpp +++ b/noncore/games/kpacman/score.cpp | |||
@@ -10,32 +10,26 @@ | |||
10 | #include <kconfig.h> | 10 | #include <kconfig.h> |
11 | #include <kstddirs.h> | 11 | #include <kstddirs.h> |
12 | #include <kmessagebox.h> | 12 | #include <kmessagebox.h> |
13 | #elif defined( QPE_PORT ) | 13 | #elif defined( QPE_PORT ) |
14 | #include <qaccel.h> | 14 | #include <qaccel.h> |
15 | #include <qpe/config.h> | 15 | #include <qpe/config.h> |
16 | #include "score.h" | 16 | #include "score.h" |
17 | #endif | 17 | #endif |
18 | 18 | ||
19 | #include <stdlib.h> | 19 | #include <stdlib.h> |
20 | #include <ctype.h> | 20 | #include <ctype.h> |
21 | 21 | ||
22 | #include <qpixmap.h> | ||
23 | #include <qstring.h> | ||
24 | #include <qdstream.h> | ||
25 | #include <qkeycode.h> | ||
26 | #include <qtimer.h> | 22 | #include <qtimer.h> |
27 | #include <qfileinfo.h> | ||
28 | 23 | ||
29 | #include "bitfont.h" | ||
30 | 24 | ||
31 | Score::Score(QWidget *parent, const char *name, int Scheme, int Mode, Bitfont *font) : QWidget(parent, name) | 25 | Score::Score(QWidget *parent, const char *name, int Scheme, int Mode, Bitfont *font) : QWidget(parent, name) |
32 | { | 26 | { |
33 | setFocusPolicy(QWidget::StrongFocus); | 27 | setFocusPolicy(QWidget::StrongFocus); |
34 | 28 | ||
35 | paused = FALSE; | 29 | paused = FALSE; |
36 | 30 | ||
37 | lastScore = -1; | 31 | lastScore = -1; |
38 | lastPlayer = -1; | 32 | lastPlayer = -1; |
39 | 33 | ||
40 | cursorBlinkTimer = 0; | 34 | cursorBlinkTimer = 0; |
41 | cursorBlinkMS = -1; | 35 | cursorBlinkMS = -1; |
diff --git a/noncore/games/kpacman/status.cpp b/noncore/games/kpacman/status.cpp index 2a17c21..02ff63d 100644 --- a/noncore/games/kpacman/status.cpp +++ b/noncore/games/kpacman/status.cpp | |||
@@ -4,27 +4,25 @@ | |||
4 | #if defined( KDE2_PORT ) | 4 | #if defined( KDE2_PORT ) |
5 | #include <kapp.h> | 5 | #include <kapp.h> |
6 | #include <klocale.h> | 6 | #include <klocale.h> |
7 | #include <kstddirs.h> | 7 | #include <kstddirs.h> |
8 | #include <status.h> | 8 | #include <status.h> |
9 | #include <status.moc> | 9 | #include <status.moc> |
10 | #elif defined( QPE_PORT ) | 10 | #elif defined( QPE_PORT ) |
11 | #include <qpe/qpeapplication.h> | 11 | #include <qpe/qpeapplication.h> |
12 | #include <qpe/config.h> | 12 | #include <qpe/config.h> |
13 | #include "status.h" | 13 | #include "status.h" |
14 | #endif | 14 | #endif |
15 | 15 | ||
16 | #include <qpixmap.h> | ||
17 | #include <qbitmap.h> | 16 | #include <qbitmap.h> |
18 | #include <qstring.h> | ||
19 | #include <qmsgbox.h> | 17 | #include <qmsgbox.h> |
20 | #include <qfileinfo.h> | 18 | #include <qfileinfo.h> |
21 | 19 | ||
22 | Status::Status( QWidget *parent, const char *name, int Scheme, int Mode ) : | 20 | Status::Status( QWidget *parent, const char *name, int Scheme, int Mode ) : |
23 | QWidget( parent, name ) | 21 | QWidget( parent, name ) |
24 | { | 22 | { |
25 | qWarning("Status::Status"); | 23 | qWarning("Status::Status"); |
26 | actualLifes = 0; | 24 | actualLifes = 0; |
27 | actualLevel = 0; | 25 | actualLevel = 0; |
28 | 26 | ||
29 | lifesPix = NULL; | 27 | lifesPix = NULL; |
30 | levelPix = NULL; | 28 | levelPix = NULL; |