-rw-r--r-- | noncore/games/fifteen/fifteen.cpp | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/noncore/games/fifteen/fifteen.cpp b/noncore/games/fifteen/fifteen.cpp index bb57ee1..c41c0a4 100644 --- a/noncore/games/fifteen/fifteen.cpp +++ b/noncore/games/fifteen/fifteen.cpp | |||
@@ -20,14 +20,14 @@ | |||
20 | 20 | ||
21 | #include "fifteen.h" | 21 | #include "fifteen.h" |
22 | 22 | ||
23 | #include "fifteenconfigdialog.h" | 23 | #include "fifteenconfigdialog.h" |
24 | 24 | ||
25 | #include <opie2/ofileselector.h> | 25 | #include <opie2/ofileselector.h> |
26 | #include <opie2/oresource.h> | ||
26 | 27 | ||
27 | #include <qtopia/resource.h> | ||
28 | #include <qtopia/config.h> | 28 | #include <qtopia/config.h> |
29 | #include <qtopia/qpeapplication.h> | 29 | #include <qtopia/qpeapplication.h> |
30 | 30 | ||
31 | #include <qvbox.h> | 31 | #include <qvbox.h> |
32 | #include <qaction.h> | 32 | #include <qaction.h> |
33 | #include <qpainter.h> | 33 | #include <qpainter.h> |
@@ -49,12 +49,13 @@ FifteenMainWindow::FifteenMainWindow(QWidget *parent, const char* name, WFlags f | |||
49 | 49 | ||
50 | QToolBar *toolbar = new QToolBar(this); | 50 | QToolBar *toolbar = new QToolBar(this); |
51 | toolbar->setHorizontalStretchable( FALSE ); | 51 | toolbar->setHorizontalStretchable( FALSE ); |
52 | QMenuBar *menubar = new QMenuBar( toolbar ); | 52 | QMenuBar *menubar = new QMenuBar( toolbar ); |
53 | menubar->setMargin(0); | 53 | menubar->setMargin(0); |
54 | QPopupMenu *game = new QPopupMenu( this ); | 54 | QPopupMenu *game = new QPopupMenu( this ); |
55 | menubar->insertItem( tr( "Game" ), game ); | ||
55 | 56 | ||
56 | QWidget *spacer = new QWidget( toolbar ); | 57 | QWidget *spacer = new QWidget( toolbar ); |
57 | spacer->setBackgroundMode( PaletteButton ); | 58 | spacer->setBackgroundMode( PaletteButton ); |
58 | toolbar->setStretchableWidget( spacer ); | 59 | toolbar->setStretchableWidget( spacer ); |
59 | 60 | ||
60 | 61 | ||
@@ -62,32 +63,23 @@ FifteenMainWindow::FifteenMainWindow(QWidget *parent, const char* name, WFlags f | |||
62 | QVBox *vbox = new QVBox( this ); | 63 | QVBox *vbox = new QVBox( this ); |
63 | PiecesTable *table = new PiecesTable( vbox ); | 64 | PiecesTable *table = new PiecesTable( vbox ); |
64 | setCentralWidget(vbox); | 65 | setCentralWidget(vbox); |
65 | 66 | ||
66 | 67 | ||
67 | 68 | ||
68 | QAction *a = new QAction( tr( "Randomize" ), Resource::loadPixmap( "new" ), | 69 | QAction *a = new QAction( tr( "Randomize" ), Opie::Core::OResource::loadPixmap( "new", Opie::Core::OResource::SmallIcon ), |
69 | QString::null, 0, this, 0 ); | 70 | QString::null, 0, this, 0 ); |
70 | connect( a, SIGNAL( activated() ), table, SLOT( slotRandomize() ) ); | 71 | connect( a, SIGNAL( activated() ), table, SLOT( slotRandomize() ) ); |
71 | a->addTo( game ); | 72 | a->addTo( game ); |
72 | a->addTo( toolbar ); | 73 | a->addTo( toolbar ); |
73 | 74 | ||
74 | 75 | ||
75 | a = new QAction( tr("Configure"), Resource::loadPixmap( "SettingsIcon" ), | 76 | a = new QAction( tr("Configure"), Opie::Core::OResource::loadPixmap( "SettingsIcon", Opie::Core::OResource::SmallIcon ), |
76 | QString::null, 0, this, 0 ); | 77 | QString::null, 0, this, 0 ); |
77 | connect( a, SIGNAL( activated()), table, SLOT( slotConfigure()) ); | 78 | connect( a, SIGNAL( activated()), table, SLOT( slotConfigure()) ); |
78 | a->addTo( game ); | 79 | a->addTo( game ); |
79 | |||
80 | /* This is pointless and confusing. | ||
81 | a = new QAction( tr( "Solve" ), Resource::loadIconSet( "repeat" ), | ||
82 | QString::null, 0, this, 0 ); | ||
83 | connect( a, SIGNAL( activated() ), table, SLOT( slotReset() ) ); | ||
84 | a->addTo( game ); | ||
85 | a->addTo( toolbar ); | ||
86 | */ | ||
87 | menubar->insertItem( tr( "Game" ), game ); | ||
88 | } | 80 | } |
89 | 81 | ||
90 | 82 | ||
91 | 83 | ||
92 | 84 | ||
93 | /////////////// | 85 | /////////////// |