summaryrefslogtreecommitdiff
path: root/noncore/games/snake/interface.cpp
Side-by-side diff
Diffstat (limited to 'noncore/games/snake/interface.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/games/snake/interface.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/noncore/games/snake/interface.cpp b/noncore/games/snake/interface.cpp
index 9d9550a..1eeb337 100644
--- a/noncore/games/snake/interface.cpp
+++ b/noncore/games/snake/interface.cpp
@@ -17,24 +17,24 @@
** not clear to you.
**
**********************************************************************/
#include "interface.h"
-#include <qpe/resource.h>
+#include <opie2/oresource.h>
#include <qtoolbar.h>
#include <qtoolbutton.h>
SnakeGame::SnakeGame(QWidget* parent, const char* name, WFlags f) :
QMainWindow(parent,name,f),
canvas(232, 258)
{
setCaption( tr("Snake") );
QPEApplication::setInputMethodHint(this, QPEApplication::AlwaysOff );
- QPixmap bg = Resource::loadPixmap("snake/grass");
+ QPixmap bg = Opie::Core::OResource::loadPixmap("snake/grass");
canvas.setBackgroundPixmap(bg);
canvas.setUpdatePeriod(100);
snake = 0;
cv = new QCanvasView(&canvas, this);
@@ -43,13 +43,13 @@ SnakeGame::SnakeGame(QWidget* parent, const char* name, WFlags f) :
setToolBarsMovable( FALSE );
QToolBar* toolbar = new QToolBar( this);
toolbar->setHorizontalStretchable( TRUE );
- QPixmap newicon = Resource::loadPixmap("ksnake");
+ QPixmap newicon = Opie::Core::OResource::loadPixmap("ksnake");
setIcon(newicon);
(void)new QToolButton(newicon, tr("New Game"), 0,
this, SLOT(newGame()), toolbar, "New Game");
scorelabel = new QLabel(toolbar);
showScore(0);
@@ -83,13 +83,13 @@ void SnakeGame::welcomescreen()
QCanvasText* title = new QCanvasText(tr("SNAKE!"), &canvas);
title->setColor(yellow);
title->setFont( QFont("times", 18, QFont::Bold) );
int w = title->boundingRect().width();
title->move(canvas.width()/2 -w/2, canvas.height()/2-110);
title->show();
- QCanvasPixmapArray* titlearray = new QCanvasPixmapArray(Resource::findPixmap("snake/title"));
+ QCanvasPixmapArray* titlearray = new QCanvasPixmapArray(Opie::Core::OResource::findPixmap("snake/title"));
QCanvasSprite* titlepic = new QCanvasSprite(titlearray, &canvas);
titlepic->move(canvas.width()/2 - 33, canvas.height()/2-85);
titlepic->show();
QCanvasText* instr = new QCanvasText(tr("Use the arrow keys to guide the\n"
"snake to eat the mouse. You must not\n"
"crash into the walls, edges or its tail."),