diff options
author | Aura Linden <aura@lindenlab.com> | 2012-07-25 16:03:50 -0700 |
---|---|---|
committer | Aura Linden <aura@lindenlab.com> | 2012-07-25 16:03:50 -0700 |
commit | 3b560d4c4902eff361ac308f56d982b1147739c4 (patch) | |
tree | e3da8a91b0c0858e8ded3f8568c16bd3952a9a32 /indra | |
parent | a1d026889343b4745eeebffc85695bbcb2b93d64 (diff) |
Some cocoa that doesn't work
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llvfs/lldir_mac.cpp | 32 | ||||
-rw-r--r-- | indra/llvfs/lldir_mac.h | 5 |
2 files changed, 16 insertions, 21 deletions
diff --git a/indra/llvfs/lldir_mac.cpp b/indra/llvfs/lldir_mac.cpp index f0b46ade6d..de3347cf63 100644 --- a/indra/llvfs/lldir_mac.cpp +++ b/indra/llvfs/lldir_mac.cpp @@ -38,6 +38,21 @@ #include <boost/filesystem.hpp> #include <Carbon/Carbon.h> +//#include "lldir_mac.mm" +// +//std::string getApplicationSupportFolder () +//{ +// std::string support_folder_str; +// CFArrayRef a = appSupport(); +// if (CFArrayGetCount(a) > 0) { +// CFStringRef s = CFArrayGetValueAtIndex(a, 0); +// char path[PATH_MAX]; +// CFStringGetFileSystemRepresentation(s, path, sizeof(path)); +// support_folder_str = std::string(path); +// } +// CFRelease(a); +// return support_folder_str; +//} // -------------------------------------------------------------------------------- @@ -110,8 +125,6 @@ static void FSRefToLLString(FSRef *fsRef, std::string &llString) LLDir_Mac::LLDir_Mac() { mDirDelimiter = "/"; - mCurrentDirIndex = -1; - mCurrentDirCount = -1; CFBundleRef mainBundleRef = NULL; CFURLRef executableURLRef = NULL; @@ -236,8 +249,6 @@ void LLDir_Mac::initAppDirs(const std::string &app_name, mSkinBaseDir = mAppRODataDir + mDirDelimiter + "skins"; } mCAFile = getExpandedFilename(LL_PATH_APP_SETTINGS, "CA.pem"); - - //dumpCurrentDirectories(); } std::string LLDir_Mac::getCurPath() @@ -248,18 +259,7 @@ std::string LLDir_Mac::getCurPath() BOOL LLDir_Mac::fileExists(const std::string &filename) const { - struct stat stat_data; - // Check the age of the file - // Now, we see if the files we've gathered are recent... - int res = stat(filename.c_str(), &stat_data); - if (!res) - { - return TRUE; - } - else - { - return FALSE; - } + return boost::filesystem::exists(filename); } diff --git a/indra/llvfs/lldir_mac.h b/indra/llvfs/lldir_mac.h index 9f1938ae23..b8b9c6a9e7 100644 --- a/indra/llvfs/lldir_mac.h +++ b/indra/llvfs/lldir_mac.h @@ -49,11 +49,6 @@ public: /*virtual*/ std::string getLLPluginLauncher(); /*virtual*/ std::string getLLPluginFilename(std::string base_name); - -private: - int mCurrentDirIndex; - int mCurrentDirCount; - std::string mCurrentDir; }; #endif // LL_LLDIR_MAC_H |