summaryrefslogtreecommitdiff
path: root/noncore/games/kpacman/kpacmanwidget.cpp
Side-by-side diff
Diffstat (limited to 'noncore/games/kpacman/kpacmanwidget.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/games/kpacman/kpacmanwidget.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/noncore/games/kpacman/kpacmanwidget.cpp b/noncore/games/kpacman/kpacmanwidget.cpp
index feb782c..cf2aed9 100644
--- a/noncore/games/kpacman/kpacmanwidget.cpp
+++ b/noncore/games/kpacman/kpacmanwidget.cpp
@@ -20,12 +20,15 @@
#include "referee.h"
#include "status.h"
KpacmanWidget::KpacmanWidget( QWidget *parent, const char *name)
: QWidget( parent, name )
{
+ score = 0l;
+ referee = 0l;
+ status = 0l;
bitfont = NULL;
fontName = "";
scheme = mode = -1;
confScheme();
@@ -138,15 +141,17 @@ void KpacmanWidget::setScheme(int Scheme, int Mode)
referee->repaint(FALSE);
status->repaint(FALSE);
}
void KpacmanWidget::resizeEvent( QResizeEvent * )
{
+ qWarning("Resize");
referee->setGeometry(0, bitfont->height()*3, referee->width(), referee->height());
referee->setBackgroundColor(BLACK);
+ if(!status ) return;
status->setGeometry(0, bitfont->height()*3+referee->height(), referee->width(),
status->height());
status->setBackgroundColor(BLACK);
score->setGeometry(0, 0, referee->width(), bitfont->height()*3+referee->height()+status->height());
score->setBackgroundColor(BLACK);