summaryrefslogtreecommitdiff
path: root/noncore/games/kpacman/kpacman.cpp
Side-by-side diff
Diffstat (limited to 'noncore/games/kpacman/kpacman.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/games/kpacman/kpacman.cpp21
1 files changed, 8 insertions, 13 deletions
diff --git a/noncore/games/kpacman/kpacman.cpp b/noncore/games/kpacman/kpacman.cpp
index 7df6ef0..d9d2d69 100644
--- a/noncore/games/kpacman/kpacman.cpp
+++ b/noncore/games/kpacman/kpacman.cpp
@@ -26,13 +26,15 @@ Kpacman::Kpacman(QWidget *parent, const char *name)
menu();
+ m_view = new QWidget( this, "m_view" );
+ m_view->setBackgroundColor( black );
+ m_layout = new QGridLayout( m_view );
+ m_layout->setMargin( 7 );
+
view = new KpacmanWidget( this, QString(name)+"widget");
+ m_layout->addWidget( view, 0, 0 );
-#ifndef QWS
- setFixedSize(view->width(), view->height());
-#else
- setCaption( "Kpacman" );
-#endif
+ setCaption( "KPacman" );
view->referee->setFocus();
@@ -63,14 +65,7 @@ Kpacman::Kpacman(QWidget *parent, const char *name)
toggleFocusInContinue();
toggleHideMouseCursor();
-#ifndef QWS
- menuBar->show();
- view->show();
- setMenu(menuBar);
- setView(view);
-#else
- setCentralWidget( view );
-#endif
+ setCentralWidget( m_view );
}
Kpacman::~Kpacman()