summaryrefslogtreecommitdiff
path: root/noncore/games/backgammon/backgammon.cpp
Unidiff
Diffstat (limited to 'noncore/games/backgammon/backgammon.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/games/backgammon/backgammon.cpp16
1 files changed, 10 insertions, 6 deletions
diff --git a/noncore/games/backgammon/backgammon.cpp b/noncore/games/backgammon/backgammon.cpp
index 51020a0..bdb1c78 100644
--- a/noncore/games/backgammon/backgammon.cpp
+++ b/noncore/games/backgammon/backgammon.cpp
@@ -1,22 +1,26 @@
1#include "backgammon.h" 1#include "backgammon.h"
2
3#include "aidialog.h" 2#include "aidialog.h"
4#include "filedialog.h" 3#include "filedialog.h"
5#include "playerdialog.h" 4#include "playerdialog.h"
6#include "rulesdialog.h" 5#include "rulesdialog.h"
7#include "themedialog.h" 6#include "themedialog.h"
8 7
8/* OPIE */
9#include <opie2/odebug.h>
10#include <qpe/qpeapplication.h>
11#include <qpe/config.h>
12#include <qpe/resource.h>
13using namespace Opie::Core;
14
15/* QT */
9#include <qfile.h> 16#include <qfile.h>
10#include <qlayout.h> 17#include <qlayout.h>
11#include <qmessagebox.h> 18#include <qmessagebox.h>
12#include <qtimer.h> 19#include <qtimer.h>
13#include <qpe/qpeapplication.h>
14#include <qpe/config.h>
15#include <qmenubar.h> 20#include <qmenubar.h>
16#include <qpe/resource.h>
17 21
18#include <stdlib.h> 22#include <stdlib.h>
19 23
20 24
21BackGammon::BackGammon(QWidget* parent, const char* name, WFlags fl) 25BackGammon::BackGammon(QWidget* parent, const char* name, WFlags fl)
22 : QMainWindow(parent, name, fl) 26 : QMainWindow(parent, name, fl)
@@ -30,13 +34,13 @@ BackGammon::BackGammon(QWidget* parent, const char* name, WFlags fl)
30 move=new MoveEngine(); 34 move=new MoveEngine();
31 35
32 //load the default theme 36 //load the default theme
33 Config conf("backgammon"); 37 Config conf("backgammon");
34 if(!conf.isValid()) 38 if(!conf.isValid())
35 { 39 {
36 qDebug("config file does not exist"); 40 odebug << "config file does not exist" << oendl;
37 conf.setGroup("general"); 41 conf.setGroup("general");
38 conf.writeEntry("theme","default"); 42 conf.writeEntry("theme","default");
39 conf.setGroup("rules"); 43 conf.setGroup("rules");
40 conf.writeEntry("move_with_pieces_out",false); 44 conf.writeEntry("move_with_pieces_out",false);
41 conf.writeEntry("nice_dice",false); 45 conf.writeEntry("nice_dice",false);
42 conf.setGroup("display"); 46 conf.setGroup("display");
@@ -75,13 +79,13 @@ BackGammon::BackGammon(QWidget* parent, const char* name, WFlags fl)
75 79
76 80
77 //get the theme component names 81 //get the theme component names
78 Config theme(theme_file,Config::File); 82 Config theme(theme_file,Config::File);
79 if(!theme.isValid()) 83 if(!theme.isValid())
80 { 84 {
81 qDebug("theme file does not exist"); 85 odebug << "theme file does not exist" << oendl;
82 theme.setGroup("theme"); 86 theme.setGroup("theme");
83 theme.writeEntry("board","casino_board_1"); 87 theme.writeEntry("board","casino_board_1");
84 theme.writeEntry("pieces1","casino_pieces_blue"); 88 theme.writeEntry("pieces1","casino_pieces_blue");
85 theme.writeEntry("pieces2","casino_pieces_white"); 89 theme.writeEntry("pieces2","casino_pieces_white");
86 theme.writeEntry("dice1","casino_dice"); 90 theme.writeEntry("dice1","casino_dice");
87 theme.writeEntry("dice2","casino_dice"); 91 theme.writeEntry("dice2","casino_dice");