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

Unified Diff: ios/web/public/web_state/web_state_observer.h

Issue 1079693002: Complete WebStateObserverBridge and follow Cocoa naming style. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
Index: ios/web/public/web_state/web_state_observer.h
diff --git a/ios/web/public/web_state/web_state_observer.h b/ios/web/public/web_state/web_state_observer.h
index da00148daed7a9c92dc124fee5754ba79ebc63b1..cd254f84c39a3d51a8556629c2aaa7a3b651639c 100644
--- a/ios/web/public/web_state/web_state_observer.h
+++ b/ios/web/public/web_state/web_state_observer.h
@@ -10,6 +10,8 @@
#include "base/macros.h"
+class GURL;
+
namespace web {
struct FaviconURL;
@@ -44,15 +46,15 @@ class WebStateObserver {
virtual void InsterstitialDismissed() {}
// Called on URL hash change events.
- virtual void URLHashChanged() {}
+ virtual void UrlHashChanged() {}
// Called on history state change events.
virtual void HistoryStateChanged() {}
- // Called on form submission. |user_interaction| is true if the user
+ // Called on form submission. |user_initiated| is true if the user
// interacted with the page.
virtual void DocumentSubmitted(const std::string& form_name,
- bool user_interaction) {}
+ bool user_initiated) {}
// Called when the user is typing on a form field, with |error| indicating if
// there is any error when parsing the form field information.
@@ -62,10 +64,18 @@ class WebStateObserver {
const std::string& type,
const std::string& value,
int key_code,
- bool error) {}
-
- // Invoked when new FaviconURL candidates are received.
- virtual void FaviconURLUpdated(const std::vector<FaviconURL>& candidates) {}
+ bool input_missing) {}
+
+ // Notifies the observer that the requestAutocomplete API was invoked from
+ // |source_url| for the form with the specified |form_name|.
+ // |user_initiated| indicates whether the API was invoked in response to a
+ // user interaction.
+ virtual void AutocompleteRequested(const GURL& source_url,
+ const std::string& form_name,
+ bool user_initiated) {}
+
+ // Invoked when new favicon URL candidates are received.
+ virtual void FaviconUrlUpdated(const std::vector<FaviconURL>& candidates) {}
// Invoked when the WebState is being destroyed. Gives subclasses a chance
// to cleanup.
« no previous file with comments | « ios/chrome/browser/autofill/form_suggestion_controller.mm ('k') | ios/web/public/web_state/web_state_observer_bridge.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698