diff options
author | Denys Dmytriyenko <denis@denix.org> | 2009-03-17 14:32:59 -0400 |
---|---|---|
committer | Denys Dmytriyenko <denis@denix.org> | 2009-03-17 14:32:59 -0400 |
commit | 709c4d66e0b107ca606941b988bad717c0b45d9b (patch) | |
tree | 37ee08b1eb308f3b2b6426d5793545c38396b838 /recipes/pocketcellar/pocketcellar-1.1/winedb.patch | |
parent | fa6cd5a3b993f16c27de4ff82b42684516d433ba (diff) |
rename packages/ to recipes/ per earlier agreement
See links below for more details:
http://thread.gmane.org/gmane.comp.handhelds.openembedded/21326
http://thread.gmane.org/gmane.comp.handhelds.openembedded/21816
Signed-off-by: Denys Dmytriyenko <denis@denix.org>
Acked-by: Mike Westerhof <mwester@dls.net>
Acked-by: Philip Balister <philip@balister.org>
Acked-by: Khem Raj <raj.khem@gmail.com>
Acked-by: Marcin Juszkiewicz <hrw@openembedded.org>
Acked-by: Koen Kooi <koen@openembedded.org>
Acked-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com>
Diffstat (limited to 'recipes/pocketcellar/pocketcellar-1.1/winedb.patch')
-rw-r--r-- | recipes/pocketcellar/pocketcellar-1.1/winedb.patch | 92 |
1 files changed, 92 insertions, 0 deletions
diff --git a/recipes/pocketcellar/pocketcellar-1.1/winedb.patch b/recipes/pocketcellar/pocketcellar-1.1/winedb.patch new file mode 100644 index 0000000000..885a23a5ce --- /dev/null +++ b/recipes/pocketcellar/pocketcellar-1.1/winedb.patch @@ -0,0 +1,92 @@ +# +# Try to remove hardcoded /home path +# +--- pocketcellar-1.1/winedb.cpp.old 2005-02-28 13:43:30.000000000 +0000 ++++ pocketcellar-1.1/winedb.cpp 2005-02-28 13:40:55.000000000 +0000 +@@ -141,6 +141,7 @@ + #include <qdatastream.h> + #include <qtextstream.h> + #include <qfile.h> ++#include <qdir.h> + + + QDataStream& operator>>(QDataStream& s, Wine& w) { +@@ -209,15 +210,15 @@ + + + bool WineDB::load(QListView *parent, int loc) { +- QString path("/home"); ++ QString path(QDir::homeDirPath()); + + if (loc == 1) +- path = "/usr/mnt.rom/cf"; ++ path = "/media/cf"; + else if (loc == 2) +- path = "/usr/mnt.rom/card"; ++ path = "/media/card"; + +- mkdir(QString(path + "/QtPalmtop/data/PocketCellar").ascii(), 755); +- QFile f(path + "/QtPalmtop/data/PocketCellar/PCWineDB"); ++ mkdir(QString(path + "/Documents/application/PocketCellar").ascii(), 755); ++ QFile f(path + "/Documents/application/PocketCellar/PCWineDB"); + + if (!f.open(IO_ReadOnly)) + return false; +@@ -240,26 +241,26 @@ + + f.close(); + +- if (loc != 0) ++/* if (loc != 0) + unlink("/home/QtPalmtop/data/PocketCellar/PCWineDB"); + if (loc != 1) + unlink("/usr/mnt.rom/cf/QtPalmtop/data/PocketCellar/PCWineDB"); + if (loc != 2) +- unlink("/usr/mnt.rom/card/QtPalmtop/data/PocketCellar/PCWineDB"); ++ unlink("/usr/mnt.rom/card/QtPalmtop/data/PocketCellar/PCWineDB");*/ + return true; + } + + + bool WineDB::save(QListView *parent, int loc) { +- QString path("/home"); ++ QString path(QDir::homeDirPath()); + + if (loc == 1) +- path = "/usr/mnt.rom/cf"; ++ path = "/media/cf"; + else if (loc == 2) +- path = "/usr/mnt.rom/card"; ++ path = "/media/card"; + +- mkdir(QString(path + "/QtPalmtop/data/PocketCellar").ascii(), 755); +- QFile f(path + "/QtPalmtop/data/PocketCellar/PCWineDB"); ++ mkdir(QString(path + "/Documents/application/PocketCellar").ascii(), 755); ++ QFile f(path + "/Documents/application/PocketCellar/PCWineDB"); + + if (!f.open(IO_WriteOnly)) + return false; +@@ -277,12 +278,12 @@ + + f.close(); + +- if (loc != 0) ++/* if (loc != 0) + unlink("/home/QtPalmtop/data/PocketCellar/PCWineDB"); + if (loc != 1) + unlink("/usr/mnt.rom/cf/QtPalmtop/data/PocketCellar/PCWineDB"); + if (loc != 2) +- unlink("/usr/mnt.rom/card/QtPalmtop/data/PocketCellar/PCWineDB"); ++ unlink("/usr/mnt.rom/card/QtPalmtop/data/PocketCellar/PCWineDB");*/ + return true; + } + +@@ -290,7 +291,7 @@ + QStringList WineDB::grapeList; + + bool WineDB::loadGrapeList() { +- QFile f("/home/QtPalmtop/data/PocketCellar/grapelist.txt"); ++ QFile f("/opt/QtPalmtop/data/PocketCellar/grapelist.txt"); + + if (!f.open(IO_ReadOnly)) + return false; |