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

Unified Diff: components/autofill/renderer/autofill_agent.h

Issue 13264002: Requery the autofill server when forms and input fields are dynamically added. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fun with merging Created 7 years, 8 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
« no previous file with comments | « components/autofill/common/forms_seen_state.h ('k') | components/autofill/renderer/autofill_agent.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/autofill/renderer/autofill_agent.h
diff --git a/components/autofill/renderer/autofill_agent.h b/components/autofill/renderer/autofill_agent.h
index d47ab77ee00cb6e3d74a4ec193d5e70700ad3121..7d882b14ca38ca72d43eb5849e384c847ee27619 100644
--- a/components/autofill/renderer/autofill_agent.h
+++ b/components/autofill/renderer/autofill_agent.h
@@ -13,6 +13,7 @@
#include "base/memory/weak_ptr.h"
#include "base/time.h"
#include "base/timer.h"
+#include "components/autofill/common/forms_seen_state.h"
#include "components/autofill/renderer/form_cache.h"
#include "components/autofill/renderer/page_click_listener.h"
#include "content/public/renderer/render_view_observer.h"
@@ -103,6 +104,8 @@ class AutofillAgent : public content::RenderViewObserver,
WebKit::WebFrame* frame,
const WebKit::WebFormElement& form) OVERRIDE;
virtual void setIgnoreTextChanges(bool ignore) OVERRIDE;
+ virtual void didAssociateFormControls(
+ const WebKit::WebVector<WebKit::WebNode>& nodes) OVERRIDE;
void OnSuggestionsReturned(int query_id,
const std::vector<base::string16>& values,
@@ -206,6 +209,8 @@ class AutofillAgent : public content::RenderViewObserver,
// Hides any currently showing Autofill UI in the browser only.
void HideHostAutofillUi();
+ void MaybeSendDynamicFormsSeen();
+
// Send |AutofillHostMsg_MaybeShowAutocheckoutBubble| to browser if needed.
void MaybeShowAutocheckoutBubble();
@@ -256,6 +261,13 @@ class AutofillAgent : public content::RenderViewObserver,
// Autocheckout flow.
bool autocheckout_click_in_progress_;
+ // Whether or not |topmost_frame_| is whitelisted for Autocheckout.
+ bool is_autocheckout_supported_;
+
+ // Whether or not new forms/fields have been dynamically added
+ // since the last loaded forms were sent to the browser process.
+ bool has_new_forms_for_browser_;
+
// Whether or not we should try to offer the user Autocheckout functionality
// by sending |AutofillHostMsg_MaybeShowAutocheckoutBubble| to the browser.
bool try_to_show_autocheckout_bubble_;
@@ -273,6 +285,7 @@ class AutofillAgent : public content::RenderViewObserver,
friend class PasswordAutofillAgentTest;
FRIEND_TEST_ALL_PREFIXES(ChromeRenderViewTest, FillFormElement);
FRIEND_TEST_ALL_PREFIXES(ChromeRenderViewTest, SendForms);
+ FRIEND_TEST_ALL_PREFIXES(ChromeRenderViewTest, SendDynamicForms);
FRIEND_TEST_ALL_PREFIXES(ChromeRenderViewTest, ShowAutofillWarning);
FRIEND_TEST_ALL_PREFIXES(PasswordAutofillAgentTest, WaitUsername);
FRIEND_TEST_ALL_PREFIXES(PasswordAutofillAgentTest, SuggestionAccept);
« no previous file with comments | « components/autofill/common/forms_seen_state.h ('k') | components/autofill/renderer/autofill_agent.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698