author | zecke <zecke> | 2004-10-16 00:01:01 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-10-16 00:01:01 (UTC) |
commit | df14f647ff1a60ca82e0fa9bd91458be146153b8 (patch) (unidiff) | |
tree | 4859961352851a4392e1442f2080c15bff8ad7bc /noncore/games | |
parent | 419f9710c488f56a7a117eb1529970d3371e0094 (diff) | |
download | opie-df14f647ff1a60ca82e0fa9bd91458be146153b8.zip opie-df14f647ff1a60ca82e0fa9bd91458be146153b8.tar.gz opie-df14f647ff1a60ca82e0fa9bd91458be146153b8.tar.bz2 |
Replace QPEApplication::qpeDir() + "/ with
QPEApplication::qpeDir() + "
as it is guranteed that qpeDir() will have '/' as the last
charachter
-rw-r--r-- | noncore/games/backgammon/backgammon.cpp | 14 | ||||
-rw-r--r-- | noncore/games/backgammon/filedialog.cpp | 2 | ||||
-rw-r--r-- | noncore/games/backgammon/themedialog.cpp | 2 |
3 files changed, 9 insertions, 9 deletions
diff --git a/noncore/games/backgammon/backgammon.cpp b/noncore/games/backgammon/backgammon.cpp index bdb1c78..c286a36 100644 --- a/noncore/games/backgammon/backgammon.cpp +++ b/noncore/games/backgammon/backgammon.cpp | |||
@@ -57,7 +57,7 @@ BackGammon::BackGammon(QWidget* parent, const char* name, WFlags fl) | |||
57 | } | 57 | } |
58 | conf.setGroup("general"); | 58 | conf.setGroup("general"); |
59 | theme_name=conf.readEntry("theme","default"); | 59 | theme_name=conf.readEntry("theme","default"); |
60 | QString theme_file=QPEApplication::qpeDir()+"/backgammon/"+theme_name+".theme"; | 60 | QString theme_file=QPEApplication::qpeDir()+"backgammon/"+theme_name+".theme"; |
61 | 61 | ||
62 | //the rules | 62 | //the rules |
63 | conf.setGroup("rules"); | 63 | conf.setGroup("rules"); |
@@ -328,7 +328,7 @@ void BackGammon::loadgame() | |||
328 | return; | 328 | return; |
329 | 329 | ||
330 | game_name=file->filename(); | 330 | game_name=file->filename(); |
331 | QString game_file=QPEApplication::qpeDir()+"/backgammon/"+game_name+".game"; | 331 | QString game_file=QPEApplication::qpeDir()+"backgammon/"+game_name+".game"; |
332 | 332 | ||
333 | Config game(game_file,Config::File); | 333 | Config game(game_file,Config::File); |
334 | game.setGroup("dice"); | 334 | game.setGroup("dice"); |
@@ -367,7 +367,7 @@ void BackGammon::loadgame() | |||
367 | 367 | ||
368 | void BackGammon::savegame() | 368 | void BackGammon::savegame() |
369 | { | 369 | { |
370 | QString game_file=QPEApplication::qpeDir()+"/backgammon/"+game_name+".game"; | 370 | QString game_file=QPEApplication::qpeDir()+"backgammon/"+game_name+".game"; |
371 | 371 | ||
372 | Config game(game_file,Config::File); | 372 | Config game(game_file,Config::File); |
373 | game.setGroup("dice"); | 373 | game.setGroup("dice"); |
@@ -406,7 +406,7 @@ void BackGammon::deletegame() | |||
406 | return; | 406 | return; |
407 | 407 | ||
408 | game_name=file->filename(); | 408 | game_name=file->filename(); |
409 | QString game_file=QPEApplication::qpeDir()+"/backgammon/"+game_name+".game"; | 409 | QString game_file=QPEApplication::qpeDir()+"backgammon/"+game_name+".game"; |
410 | 410 | ||
411 | if(!QMessageBox::warning(this,"Backgammon","deleted game\n"+game_name+" ?","OK","Cancel")) | 411 | if(!QMessageBox::warning(this,"Backgammon","deleted game\n"+game_name+" ?","OK","Cancel")) |
412 | { | 412 | { |
@@ -453,7 +453,7 @@ void BackGammon::loadtheme() | |||
453 | return; | 453 | return; |
454 | 454 | ||
455 | theme_name=file->filename(); | 455 | theme_name=file->filename(); |
456 | QString theme_file=QPEApplication::qpeDir()+"/backgammon/"+theme_name+".theme"; | 456 | QString theme_file=QPEApplication::qpeDir()+"backgammon/"+theme_name+".theme"; |
457 | 457 | ||
458 | Config theme(theme_file,Config::File); | 458 | Config theme(theme_file,Config::File); |
459 | theme.setGroup("theme"); | 459 | theme.setGroup("theme"); |
@@ -476,7 +476,7 @@ void BackGammon::savetheme() | |||
476 | QMessageBox::information(this,"Backgammon","Sorry\nCannot overwrite default.theme","OK"); | 476 | QMessageBox::information(this,"Backgammon","Sorry\nCannot overwrite default.theme","OK"); |
477 | return; | 477 | return; |
478 | } | 478 | } |
479 | QString theme_file=QPEApplication::qpeDir()+"/backgammon/"+theme_name+".theme"; | 479 | QString theme_file=QPEApplication::qpeDir()+"backgammon/"+theme_name+".theme"; |
480 | if(QMessageBox::information(this,"Backgammon","Save Theme\n"+theme_name,"Yes","No")) | 480 | if(QMessageBox::information(this,"Backgammon","Save Theme\n"+theme_name,"Yes","No")) |
481 | return; | 481 | return; |
482 | 482 | ||
@@ -509,7 +509,7 @@ void BackGammon::deletetheme() | |||
509 | return; | 509 | return; |
510 | 510 | ||
511 | theme_name=file->filename(); | 511 | theme_name=file->filename(); |
512 | QString theme_file=QPEApplication::qpeDir()+"/backgammon/"+theme_name+".theme"; | 512 | QString theme_file=QPEApplication::qpeDir()+"backgammon/"+theme_name+".theme"; |
513 | 513 | ||
514 | if(!QMessageBox::warning(this,tr( "Backgammon" ),tr( "deleted theme %1?").arg(theme_name),tr( "OK" ),tr( "Cancel" ))) | 514 | if(!QMessageBox::warning(this,tr( "Backgammon" ),tr( "deleted theme %1?").arg(theme_name),tr( "OK" ),tr( "Cancel" ))) |
515 | { | 515 | { |
diff --git a/noncore/games/backgammon/filedialog.cpp b/noncore/games/backgammon/filedialog.cpp index e0a2914..f185188 100644 --- a/noncore/games/backgammon/filedialog.cpp +++ b/noncore/games/backgammon/filedialog.cpp | |||
@@ -37,7 +37,7 @@ void FileDialog::selectorclicked(QListViewItem* entry) | |||
37 | void FileDialog::getCurrentDir() | 37 | void FileDialog::getCurrentDir() |
38 | { | 38 | { |
39 | dirselector->clear(); | 39 | dirselector->clear(); |
40 | QDir dir(QPEApplication::qpeDir()+"/backgammon"); | 40 | QDir dir(QPEApplication::qpeDir()+"backgammon"); |
41 | dir.setFilter(QDir::Files); | 41 | dir.setFilter(QDir::Files); |
42 | QFileInfoListIterator it(*(dir.entryInfoList())); | 42 | QFileInfoListIterator it(*(dir.entryInfoList())); |
43 | QFileInfo* fi; | 43 | QFileInfo* fi; |
diff --git a/noncore/games/backgammon/themedialog.cpp b/noncore/games/backgammon/themedialog.cpp index afd6a1b..9bdb6a9 100644 --- a/noncore/games/backgammon/themedialog.cpp +++ b/noncore/games/backgammon/themedialog.cpp | |||
@@ -143,7 +143,7 @@ void ThemeDialog::setCurrent(const ImageNames& current) | |||
143 | void ThemeDialog::fillBox(QString dirname,QComboBox* thebox) | 143 | void ThemeDialog::fillBox(QString dirname,QComboBox* thebox) |
144 | { | 144 | { |
145 | thebox->clear(); | 145 | thebox->clear(); |
146 | QDir dir(QPEApplication::qpeDir()+"/pics/backgammon/"+dirname); | 146 | QDir dir(QPEApplication::qpeDir()+"pics/backgammon/"+dirname); |
147 | dir.setFilter(QDir::Dirs | QDir::Files); | 147 | dir.setFilter(QDir::Dirs | QDir::Files); |
148 | QFileInfoListIterator it(*(dir.entryInfoList())); | 148 | QFileInfoListIterator it(*(dir.entryInfoList())); |
149 | QFileInfo* fi; | 149 | QFileInfo* fi; |