aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authork-m_schindler <k-m_schindler@b956fd51-792f-4845-bead-9b4dfca2ff2c>2008-08-20 22:29:10 +0000
committerk-m_schindler <k-m_schindler@b956fd51-792f-4845-bead-9b4dfca2ff2c>2008-08-20 22:29:10 +0000
commit2488e27f943471e03ee41ffefd67afbafa6442d4 (patch)
tree1d45e3fd4f59077ebd0c57c5fc521ee4b67bdf62
parent03ab792ffd2935b2e7982ea7e20d87c9e1f35bbb (diff)
downloadusdx-2488e27f943471e03ee41ffefd67afbafa6442d4.tar.gz
usdx-2488e27f943471e03ee41ffefd67afbafa6442d4.tar.xz
usdx-2488e27f943471e03ee41ffefd67afbafa6442d4.zip
Creation of User Resource folder corrected + minor format adjustments.
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1279 b956fd51-792f-4845-bead-9b4dfca2ff2c
-rw-r--r--Game/Code/Classes/UPlatformMacOSX.pas16
1 files changed, 8 insertions, 8 deletions
diff --git a/Game/Code/Classes/UPlatformMacOSX.pas b/Game/Code/Classes/UPlatformMacOSX.pas
index a8af19fa..a774186f 100644
--- a/Game/Code/Classes/UPlatformMacOSX.pas
+++ b/Game/Code/Classes/UPlatformMacOSX.pas
@@ -159,12 +159,12 @@ const
begin
// Get the current folder and save it in OldBaseDir for returning to it, when
// finished.
- getdir (0, OldBaseDir);
+ getdir(0, OldBaseDir);
// UltraStarDeluxe.app/Contents/Resources contains all the default files and
// folders.
BaseDir := OldBaseDir + '/UltraStarDeluxe.app/Contents/Resources';
- chdir (BaseDir);
+ chdir(BaseDir);
// Right now, only $HOME/Library/Application Support/UltraStarDeluxe/Resources
// is used.
@@ -179,7 +179,7 @@ begin
repeat
RelativePath := DirectoryList[DirectoryIsFinished];
- chdir (BaseDir + '/' + RelativePath);
+ chdir(BaseDir + '/' + RelativePath);
if (FindFirst('*', faAnyFile, SearchInfo) = 0) then
begin
repeat
@@ -197,12 +197,12 @@ begin
until (DirectoryIsFinished = DirectoryList.Count);
// create missing folders
- if not DirectoryExists(UserPathName) then
- mkdir (UserPathName);
+ if not ForceDirectories(UserPathName) then
+ DebugWriteln('Error: Failed to create the folder: ', UserPathName);
for counter := 0 to DirectoryList.Count-1 do
- if not DirectoryExists(UserPathName + '/' + DirectoryList[counter]) then
- mkdir (UserPathName + '/' + DirectoryList[counter]);
+ if not ForceDirectories(UserPathName + '/' + DirectoryList[counter]) then
+ DebugWriteln('Error: Failed to create the folder: ', UserPathName + '/' + DirectoryList[counter]);
DirectoryList.Free();
// copy missing files
@@ -221,7 +221,7 @@ begin
FileList.Free();
// go back to the initial folder
- chdir (OldBaseDir);
+ chdir(OldBaseDir);
end;
function TPlatformMacOSX.GetBundlePath: WideString;