summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/games/solitaire/canvascardwindow.cpp16
-rw-r--r--noncore/games/solitaire/opie-solitaire.control0
2 files changed, 13 insertions, 3 deletions
diff --git a/noncore/games/solitaire/canvascardwindow.cpp b/noncore/games/solitaire/canvascardwindow.cpp
index 450b4db..e836eb2 100644
--- a/noncore/games/solitaire/canvascardwindow.cpp
+++ b/noncore/games/solitaire/canvascardwindow.cpp
@@ -104,2 +104,3 @@ CanvasCardWindow::CanvasCardWindow(QWidget* parent, const char* name, WFlags f)
menu->insertItem(tr("Settings"),settings);
+ settings->setCheckable(TRUE);
@@ -113,4 +114,5 @@ CanvasCardWindow::CanvasCardWindow(QWidget* parent, const char* name, WFlags f)
settings->setItemChecked(snap_id, snapOn);
+
gameType = cfg.readNumEntry( "GameType", -1 );
- drawThree = cfg.readBoolEntry( "DrawThree", TRUE);
+ drawThree = cfg.readBoolEntry( "DrawThree", FALSE);
if ( gameType == 0 ) {
@@ -118,2 +120,3 @@ CanvasCardWindow::CanvasCardWindow(QWidget* parent, const char* name, WFlags f)
cardGame->setNumberToDraw(drawThree ? 3 : 1);
+
setCaption(tr("Patience"));
@@ -168,2 +171,3 @@ CanvasCardWindow::~CanvasCardWindow()
cfg.writeEntry( "DrawThree", drawThree);
+ cfg.write();
cardGame->writeConfig( cfg );
@@ -270,4 +274,9 @@ void CanvasCardWindow::drawnToggle()
{
+ drawThree=!drawThree;
+ Config cfg( "Patience" );
+ cfg.setGroup( "GlobalSettings" );
cardGame->toggleCardsDrawn();
updateDraw();
+ cfg.writeEntry( "DrawThree", drawThree);
+ cfg.write();
}
@@ -275,7 +284,8 @@ void CanvasCardWindow::drawnToggle()
void CanvasCardWindow::updateDraw() {
- if(cardGame->cardsDrawn() == 3)
+ if(cardGame->cardsDrawn() == 3){
settings->changeItem(drawId, tr("Turn One Card"));
- else
+ } else {
settings->changeItem(drawId, tr("Turn Three Cards"));
}
+}
diff --git a/noncore/games/solitaire/opie-solitaire.control b/noncore/games/solitaire/opie-solitaire.control
index f70fefa..4389360 100644
--- a/noncore/games/solitaire/opie-solitaire.control
+++ b/noncore/games/solitaire/opie-solitaire.control