Added Current Working Directory

This commit is contained in:
dp%netscape.com 1999-04-03 17:17:49 +00:00
parent c0fe7290ed
commit e6a86ec777
4 changed files with 28 additions and 0 deletions

View File

@ -44,6 +44,7 @@ class NS_BASE nsSpecialSystemDirectory : public nsFileSpec
OS_DriveDirectory = 1
, OS_TemporaryDirectory = 2
, OS_CurrentProcessDirectory= 3
, OS_CurrentWorkingDirectory= 4
, Mac_SystemDirectory = 101
, Mac_DesktopDirectory = 102

View File

@ -58,6 +58,15 @@ static char* MakeUpperCase(char* aPath)
}
#endif
//----------------------------------------------------------------------------------------
static void GetCurrentWorkingDirectory(nsFileSpec& aFileSpec)
//----------------------------------------------------------------------------------------
{
aFileSpec = ".";
return;
}
//----------------------------------------------------------------------------------------
static void GetCurrentProcessDirectory(nsFileSpec& aFileSpec)
//----------------------------------------------------------------------------------------
@ -226,6 +235,10 @@ void nsSpecialSystemDirectory::operator = (SystemDirectories aSystemSystemDirect
GetCurrentProcessDirectory(*this);
break;
case OS_CurrentWorkingDirectory:
GetCurrentWorkingDirectory(*this);
break;
#ifdef XP_MAC
case Mac_SystemDirectory:
*this = kSystemFolderType;

View File

@ -58,6 +58,15 @@ static char* MakeUpperCase(char* aPath)
}
#endif
//----------------------------------------------------------------------------------------
static void GetCurrentWorkingDirectory(nsFileSpec& aFileSpec)
//----------------------------------------------------------------------------------------
{
aFileSpec = ".";
return;
}
//----------------------------------------------------------------------------------------
static void GetCurrentProcessDirectory(nsFileSpec& aFileSpec)
//----------------------------------------------------------------------------------------
@ -226,6 +235,10 @@ void nsSpecialSystemDirectory::operator = (SystemDirectories aSystemSystemDirect
GetCurrentProcessDirectory(*this);
break;
case OS_CurrentWorkingDirectory:
GetCurrentWorkingDirectory(*this);
break;
#ifdef XP_MAC
case Mac_SystemDirectory:
*this = kSystemFolderType;

View File

@ -44,6 +44,7 @@ class NS_BASE nsSpecialSystemDirectory : public nsFileSpec
OS_DriveDirectory = 1
, OS_TemporaryDirectory = 2
, OS_CurrentProcessDirectory= 3
, OS_CurrentWorkingDirectory= 4
, Mac_SystemDirectory = 101
, Mac_DesktopDirectory = 102