зеркало из https://github.com/mozilla/pjs.git
Bug 335558 r=benjamin
Make storage form history use Mork if available
This commit is contained in:
Родитель
c372e44071
Коммит
479ce9f7f6
|
@ -67,6 +67,8 @@ REQUIRES = \
|
||||||
unicharutil \
|
unicharutil \
|
||||||
intl \
|
intl \
|
||||||
pref \
|
pref \
|
||||||
|
storage \
|
||||||
|
morkreader \
|
||||||
windowwatcher \
|
windowwatcher \
|
||||||
toolkitcomps \
|
toolkitcomps \
|
||||||
$(NULL)
|
$(NULL)
|
||||||
|
@ -74,18 +76,12 @@ REQUIRES = \
|
||||||
CPPSRCS = nsFormFillController.cpp \
|
CPPSRCS = nsFormFillController.cpp \
|
||||||
$(NULL)
|
$(NULL)
|
||||||
|
|
||||||
ifdef MOZ_STORAGE
|
ifdef MOZ_PLACES
|
||||||
REQUIRES += storage
|
|
||||||
CPPSRCS += nsStorageFormHistory.cpp
|
CPPSRCS += nsStorageFormHistory.cpp
|
||||||
ifdef MOZ_MORKREADER
|
else
|
||||||
REQUIRES += morkreader
|
|
||||||
endif
|
|
||||||
else # MOZ_STORAGE
|
|
||||||
ifdef MOZ_MORK
|
|
||||||
REQUIRES += mork
|
REQUIRES += mork
|
||||||
CPPSRCS += nsFormHistory.cpp
|
CPPSRCS += nsFormHistory.cpp
|
||||||
endif
|
endif
|
||||||
endif # MOZ_STORAGE
|
|
||||||
|
|
||||||
LOCAL_INCLUDES = \
|
LOCAL_INCLUDES = \
|
||||||
-I$(srcdir)/../../passwordmgr/base \
|
-I$(srcdir)/../../passwordmgr/base \
|
||||||
|
|
|
@ -39,10 +39,10 @@
|
||||||
|
|
||||||
#include "nsFormFillController.h"
|
#include "nsFormFillController.h"
|
||||||
|
|
||||||
#ifdef MOZ_STORAGE
|
#ifdef MOZ_PLACES
|
||||||
#include "nsStorageFormHistory.h"
|
#include "nsStorageFormHistory.h"
|
||||||
#include "nsIAutoCompleteSimpleResult.h"
|
#include "nsIAutoCompleteSimpleResult.h"
|
||||||
#elif defined(MOZ_MORK)
|
#else
|
||||||
#include "nsFormHistory.h"
|
#include "nsFormHistory.h"
|
||||||
#include "nsIAutoCompleteResultTypes.h"
|
#include "nsIAutoCompleteResultTypes.h"
|
||||||
#endif
|
#endif
|
||||||
|
@ -466,14 +466,12 @@ nsFormFillController::StartSearch(const nsAString &aSearchString, const nsAStrin
|
||||||
{
|
{
|
||||||
nsCOMPtr<nsIAutoCompleteResult> result;
|
nsCOMPtr<nsIAutoCompleteResult> result;
|
||||||
|
|
||||||
#ifdef MOZ_STORAGE
|
#ifdef MOZ_PLACES
|
||||||
// This assumes that FormHistory uses nsIAutoCompleteSimpleResult,
|
// This assumes that FormHistory uses nsIAutoCompleteSimpleResult,
|
||||||
// while PasswordManager does not.
|
// while PasswordManager does not.
|
||||||
nsCOMPtr<nsIAutoCompleteSimpleResult> historyResult;
|
nsCOMPtr<nsIAutoCompleteSimpleResult> historyResult;
|
||||||
#elif defined(MOZ_MORK)
|
|
||||||
nsCOMPtr<nsIAutoCompleteMdbResult2> historyResult;
|
|
||||||
#else
|
#else
|
||||||
#error either mozstorage or mork must be compiled
|
nsCOMPtr<nsIAutoCompleteMdbResult2> historyResult;
|
||||||
#endif
|
#endif
|
||||||
historyResult = do_QueryInterface(aPreviousResult);
|
historyResult = do_QueryInterface(aPreviousResult);
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче