mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-13 10:25:01 +00:00
part of Messenger Mac Landing, modifications affect only Mac build.
This commit is contained in:
parent
91118ec325
commit
8876e69d85
Binary file not shown.
@ -250,8 +250,12 @@ nsMsgLocalMailFolder::AddDirectorySeparator(nsFileSpec &path)
|
||||
// unfortunately we can't just say:
|
||||
// path += sep;
|
||||
// here because of the way nsFileSpec concatenates
|
||||
#if defined(XP_MAC)
|
||||
nsAutoString str((nsFilePath)path); //ducarroz: please don't cast a nsFilePath to char* on Mac
|
||||
#else
|
||||
const char *chpath = path;
|
||||
nsAutoString str(chpath);
|
||||
#endif
|
||||
str += sep;
|
||||
path = str;
|
||||
}
|
||||
@ -376,8 +380,15 @@ NS_IMETHODIMP nsMsgLocalMailFolder::BuildFolderURL(char **url)
|
||||
nsFileSpec path;
|
||||
nsresult rv = GetPath(path);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
#if defined(XP_MAC)
|
||||
nsAutoString tmpPath((nsFilePath)path); //ducarroz: please don't cast a nsFilePath to char* on Mac
|
||||
const char *pathName = tmpPath.ToNewCString();
|
||||
*url = PR_smprintf("%s%s", urlScheme, pathName);
|
||||
delete [] pathName;
|
||||
#else
|
||||
const char *pathName = path;
|
||||
*url = PR_smprintf("%s%s", urlScheme, pathName);
|
||||
#endif
|
||||
return NS_OK;
|
||||
|
||||
}
|
||||
|
@ -39,6 +39,11 @@
|
||||
#define MESSAGE_PATH_URL "/C|/temp/tempMessage.eml"
|
||||
#endif
|
||||
|
||||
#ifdef XP_MAC
|
||||
#define MESSAGE_PATH "tempMessage.eml"
|
||||
#define MESSAGE_PATH_URL "tempMessage.eml"
|
||||
#endif
|
||||
|
||||
// State Flags (Note, I use the word state in terms of storing
|
||||
// state information about the connection (authentication, have we sent
|
||||
// commands, etc. I do not intend it to refer to protocol state)
|
||||
|
@ -26,6 +26,9 @@
|
||||
#include "nsParseMailbox.h"
|
||||
|
||||
#ifdef XP_MAC
|
||||
/* ducarroz: we should solve this redefinition problem! */
|
||||
# undef LINEBREAK
|
||||
# undef LINEBREAK_LEN
|
||||
# define LINEBREAK "\015"
|
||||
# define LINEBREAK_LEN 1
|
||||
#else
|
||||
|
Loading…
Reference in New Issue
Block a user