зеркало из https://github.com/mozilla/pjs.git
fixing XP_WIN bookmarks bustage
This commit is contained in:
Родитель
a59ce831a1
Коммит
c6027def9e
|
@ -3161,7 +3161,7 @@ nsBookmarksService::ResolveKeyword(const PRUnichar *aUserInput, char **aShortcut
|
|||
#ifdef XP_WIN
|
||||
// *** code copied from widget/src/windows/nsClipboard.cpp
|
||||
// Determines the URL for a shortcut file
|
||||
static void ResolveShortcut(const nsACString &aFileName, char** aOutURL)
|
||||
static void ResolveShortcut(const nsAFlatString &aFileName, char** aOutURL)
|
||||
{
|
||||
// IUniformResourceLocator isn't supported by VC5 (bless its little heart)
|
||||
#if _MSC_VER >= 1200
|
||||
|
@ -3174,9 +3174,8 @@ static void ResolveShortcut(const nsACString &aFileName, char** aOutURL)
|
|||
IPersistFile* urlFile = nsnull;
|
||||
result = urlLink->QueryInterface(IID_IPersistFile, (void**)&urlFile);
|
||||
if (SUCCEEDED(result) && urlFile) {
|
||||
NS_ConvertUTF8toUCS2 wideFileName(aFileName);
|
||||
|
||||
result = urlFile->Load(wideFileName.get(), STGM_READ);
|
||||
result = urlFile->Load(aFileName.get(), STGM_READ);
|
||||
if (SUCCEEDED(result) ) {
|
||||
LPSTR lpTemp = nsnull;
|
||||
|
||||
|
@ -3231,9 +3230,8 @@ nsBookmarksService::ParseFavoritesFolder(nsIFile* aDirectory, nsIRDFResource* aP
|
|||
nsCOMPtr<nsIFileURL> fileURL(do_QueryInterface(uri));
|
||||
fileURL->SetFile(currFile);
|
||||
|
||||
nsCAutoString leafName;
|
||||
currFile->GetLeafName(leafName);
|
||||
NS_ConvertUTF8toUCS2 bookmarkName(leafName);
|
||||
nsAutoString bookmarkName;
|
||||
currFile->GetLeafName(bookmarkName);
|
||||
|
||||
PRBool isDir = PR_FALSE;
|
||||
currFile->IsDirectory(&isDir);
|
||||
|
@ -3257,7 +3255,7 @@ nsBookmarksService::ParseFavoritesFolder(nsIFile* aDirectory, nsIRDFResource* aP
|
|||
nsAutoString name(Substring(bookmarkName, 0,
|
||||
bookmarkName.Length() - extension.Length() - 1));
|
||||
|
||||
nsCAutoString path;
|
||||
nsAutoString path;
|
||||
currFile->GetPath(path);
|
||||
|
||||
nsXPIDLCString url;
|
||||
|
|
Загрузка…
Ссылка в новой задаче