Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2340)

Unified Diff: android_webview/browser/aw_autofill_external_delegate.h

Issue 15097004: Enable Autocomplete feature for chromium webview (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@setSaveFormData2
Patch Set: make personal_data_ optional Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: android_webview/browser/aw_autofill_external_delegate.h
diff --git a/android_webview/browser/aw_autofill_external_delegate.h b/android_webview/browser/aw_autofill_external_delegate.h
new file mode 100644
index 0000000000000000000000000000000000000000..0d62dd910bace349f55913e795396bf991b74c1d
--- /dev/null
+++ b/android_webview/browser/aw_autofill_external_delegate.h
@@ -0,0 +1,47 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef ANDROID_WEBVIEW_BROWSER_AW_AUTOFILL_EXTERNAL_DELEGATE_H_
+#define ANDROID_WEBVIEW_BROWSER_AW_AUTOFILL_EXTERNAL_DELEGATE_H_
+
+#include "components/autofill/browser/autofill_external_delegate.h"
+
+
+namespace content {
+class WebContents;
+}
+
+namespace autofill {
+class AutofillManager;
+}
+
+namespace android_webview {
+
+// External delegate for android webview autocomplete. Its main functionality
+// is to enable/disable the feature for a given webcontents.
+class AwAutofillExternalDelegate
+ : public autofill::AutofillExternalDelegate {
+
+ public:
+ // Creates an AwAutofillExternalDelegate and attaches it to the specified
+ // contents; the second argument is an AutofillManager managing Autofill for
+ // that WebContents.
+ static void CreateForWebContentsAndManager(
+ content::WebContents* web_contents,
+ autofill::AutofillManager* autofill_manager);
+
+ virtual bool ShouldIgnoreFormData() OVERRIDE;
+
+ protected:
+ AwAutofillExternalDelegate(content::WebContents* web_contents,
+ autofill::AutofillManager* autofill_manager);
+ virtual ~AwAutofillExternalDelegate();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(AwAutofillExternalDelegate);
+};
+
+} // namespace android_webview
+
+#endif // ANDROID_WEBVIEW_BROWSER_AW_AUTOFILL_EXTERNAL_DELEGATE_H_

Powered by Google App Engine
This is Rietveld 408576698