nsresult nsSeamonkeyProfileMigrator::CopyBookmarks(PRBool aReplace) { if (aReplace) return CopyFile(FILE_NAME_BOOKMARKS, FILE_NAME_BOOKMARKS); return ImportNetscapeBookmarks(FILE_NAME_BOOKMARKS, NS_LITERAL_STRING("sourceNameSeamonkey").get()); }
nsresult nsNetscapeProfileMigratorBase::CopyBookmarks(bool aReplace) { if (aReplace) return CopyFile(FILE_NAME_BOOKMARKS, FILE_NAME_BOOKMARKS); return ImportNetscapeBookmarks(FILE_NAME_BOOKMARKS, "sourceNameSeamonkey"); }
nsresult nsDogbertProfileMigrator::CopyBookmarks(PRBool aReplace) { // If we're blowing away existing content, just copy the file, don't do fancy importing. if (aReplace) { nsresult rv = InitializeBookmarks(mTargetProfile); NS_ENSURE_SUCCESS(rv, rv); return MigrateDogbertBookmarks(); } return ImportNetscapeBookmarks(BOOKMARKS_FILE_NAME_IN_4x, NS_LITERAL_STRING("sourceNameDogbert").get()); }
nsresult nsSeamonkeyProfileMigrator::CopyBookmarks(PRBool aReplace) { nsresult rv; if (aReplace) { // Initialize the default bookmarks rv = InitializeBookmarks(mTargetProfile); NS_ENSURE_SUCCESS(rv, rv); // Merge in the bookmarks from the source profile nsCOMPtr<nsIFile> sourceFile; mSourceProfile->Clone(getter_AddRefs(sourceFile)); sourceFile->Append(FILE_NAME_BOOKMARKS); rv = ImportBookmarksHTML(sourceFile, PR_TRUE, PR_FALSE, EmptyString().get()); NS_ENSURE_SUCCESS(rv, rv); } else { rv = ImportNetscapeBookmarks(FILE_NAME_BOOKMARKS, NS_LITERAL_STRING("sourceNameSeamonkey").get()); NS_ENSURE_SUCCESS(rv, rv); } return NS_OK; }