| Index: components/autofill/browser/webdata/autofill_webdata_service.h
|
| diff --git a/components/autofill/browser/webdata/autofill_webdata_service.h b/components/autofill/browser/webdata/autofill_webdata_service.h
|
| index fd5c6cea20c6f5622a6860078de95e703a21145c..ae76613f69b02d07e66a5dacc87d7eda90f524cf 100644
|
| --- a/components/autofill/browser/webdata/autofill_webdata_service.h
|
| +++ b/components/autofill/browser/webdata/autofill_webdata_service.h
|
| @@ -31,11 +31,14 @@ class AutofillWebDataBackend;
|
| class AutofillWebDataServiceObserverOnDBThread;
|
| class AutofillWebDataServiceObserverOnUIThread;
|
| class CreditCard;
|
| +class AutofillBackendDelegate;
|
|
|
| // API for Autofill web data.
|
| class AutofillWebDataService : public AutofillWebData,
|
| public WebDataServiceBase {
|
| public:
|
| + typedef base::Callback<void(AutofillBackendDelegate*)> DelegateOnDBCallback;
|
| +
|
| AutofillWebDataService();
|
|
|
| AutofillWebDataService(scoped_refptr<WebDatabaseService> wdbs,
|
| @@ -46,14 +49,6 @@ class AutofillWebDataService : public AutofillWebData,
|
| static scoped_refptr<AutofillWebDataService> FromBrowserContext(
|
| content::BrowserContext* context);
|
|
|
| - // Notifies listeners on the UI thread that multiple changes have been made to
|
| - // to Autofill records of the database.
|
| - // NOTE: This method is intended to be called from the DB thread. It
|
| - // it asynchronously notifies listeners on the UI thread.
|
| - // |web_data_service| may be NULL for testing purposes.
|
| - static void NotifyOfMultipleAutofillChanges(
|
| - AutofillWebDataService* web_data_service);
|
| -
|
| // WebDataServiceBase implementation.
|
| virtual void ShutdownOnUIThread() OVERRIDE;
|
|
|
| @@ -84,9 +79,6 @@ class AutofillWebDataService : public AutofillWebData,
|
| virtual void RemoveAutofillDataModifiedBetween(
|
| const base::Time& delete_begin, const base::Time& delete_end) OVERRIDE;
|
|
|
| - void AddObserver(AutofillWebDataServiceObserverOnDBThread* observer);
|
| - void RemoveObserver(AutofillWebDataServiceObserverOnDBThread* observer);
|
| -
|
| void AddObserver(AutofillWebDataServiceObserverOnUIThread* observer);
|
| void RemoveObserver(AutofillWebDataServiceObserverOnUIThread* observer);
|
|
|
| @@ -100,6 +92,13 @@ class AutofillWebDataService : public AutofillWebData,
|
|
|
| virtual void ShutdownOnDBThread();
|
|
|
| + // Asynchronously gets an instance of |AutofillBackendDelegate|, which can be
|
| + // used to do work on the DB thread. This method is meant to be called from
|
| + // the UI thread, but the callback will be called on the DB thread.
|
| + // The delegate instance is owned by |AutofillWebDataBackend|, and so has the
|
| + // same lifetime as |AutofillWebDataService|.
|
| + void GetDelegateOnDB(const DelegateOnDBCallback& del_callback);
|
| +
|
| protected:
|
| virtual ~AutofillWebDataService();
|
|
|
|
|