From c6b206ab5601108dbc917f78077612d6d935c7be Mon Sep 17 00:00:00 2001 From: Yohann Ferreira Date: Sat, 16 Jul 2005 00:30:14 +0000 Subject: Now we don't use the char *homeDir anymore. --- src/engine.cpp | 2 +- src/main.h | 1 - src/resources/buddylist.cpp | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/engine.cpp b/src/engine.cpp index f0902bb0..7181ac80 100644 --- a/src/engine.cpp +++ b/src/engine.cpp @@ -159,7 +159,7 @@ Engine::Engine(): // Create dialogs chatWindow = new ChatWindow( - std::string(homeDir) + std::string("chatlog.txt")); + config.getValue("homeDir", "") + std::string("chatlog.txt")); statusWindow = new StatusWindow(); buyDialog = new BuyDialog(); sellDialog = new SellDialog(); diff --git a/src/main.h b/src/main.h index dcee297a..a6af43fe 100644 --- a/src/main.h +++ b/src/main.h @@ -71,7 +71,6 @@ extern unsigned char state; extern Sound sound; extern int screenW, screenH, bitDepth, displayFlags; extern bool useOpenGL; -extern char *homeDir; extern Configuration config; #endif diff --git a/src/resources/buddylist.cpp b/src/resources/buddylist.cpp index 9f11b5f7..a227ec71 100644 --- a/src/resources/buddylist.cpp +++ b/src/resources/buddylist.cpp @@ -29,7 +29,7 @@ BuddyList::BuddyList() { // Find saved buddy list file - filename = new std::string(std::string(homeDir) + "buddy.txt"); + filename = new std::string(std::string(config.getValue("homeDir", "") + "buddy.txt")); // Load buddy from file loadFile(); -- cgit v1.2.3-70-g09d2