fix for bug 77604 and bug 78243, r=hewitt, sr=sspitzer - load the history db when the url bar kicks off an autocomplete, and make sure that we answer to the sorted name property for non-find URLs

This commit is contained in:
alecf%netscape.com 2001-05-01 23:02:40 +00:00
Родитель 1fbb28457a
Коммит de6cfe3ff7
1 изменённых файлов: 3 добавлений и 1 удалений

Просмотреть файл

@ -1477,7 +1477,8 @@ nsGlobalHistory::GetTarget(nsIRDFResource* aSource,
NS_ADDREF(*aTarget);
return NS_OK;
}
else if (aProperty == kNC_Name) {
else if (aProperty == kNC_Name ||
aProperty == kNC_NameSort) {
// Site name (i.e., page title)
nsAutoString title;
rv = GetRowValue(row, kToken_NameColumn, title);
@ -3463,6 +3464,7 @@ nsGlobalHistory::OnStartLookup(const PRUnichar *searchString,
nsIAutoCompleteListener *listener)
{
NS_ASSERTION(searchString, "searchString can't be null, fix your caller");
NS_ENSURE_SUCCESS(OpenDB(), NS_ERROR_FAILURE);
if (!listener)
return NS_ERROR_NULL_POINTER;