Index: ios/web/web_state/ui/crw_web_controller.h |
diff --git a/ios/web/web_state/ui/crw_web_controller.h b/ios/web/web_state/ui/crw_web_controller.h |
index b7d5225fa6d3728f876f26636b18f51bc9b46ef2..27aef98e074f19576334e59df4b4cf346a3ee3bb 100644 |
--- a/ios/web/web_state/ui/crw_web_controller.h |
+++ b/ios/web/web_state/ui/crw_web_controller.h |
@@ -185,12 +185,14 @@ class WebStateImpl; |
// Loads the URL indicated by current session state. |
- (void)loadCurrentURL; |
-// Updates UIWebView's URL and urlOnStartLoading_ during back/forward navigation |
-// over pushed URLs. Needed so that sites that depend on URL params/fragment |
-// continue to work correctly and checks for the URL don't incorrectly trigger |
-// -pageChanged calls. |
-- (void)finishPushStateNavigationToURL:(const GURL&)url |
- withStateObject:(NSString*)stateObject; |
+// Injects JavaScript into the web view to update the URL to |url|, to set |
+// window.history.state to |stateObject|, and to trigger a popstate() event. |
+// Upon the scripts completion, resets |urlOnStartLoading_| and |
+// |_lastRegisteredRequestURL| to |url|. This is necessary so that sites that |
+// depend on URL params/fragments continue to work correctly and that checks for |
+// the URL don't incorrectly trigger |-pageChanged| calls. |
+- (void)setPushedOrReplacedURL:(const GURL&)url |
Eugene But (OOO till 7-30)
2015/09/18 02:02:35
Since this method is not called anywhere, lets tak
Eugene But (OOO till 7-30)
2015/09/18 02:02:36
NIT: s/url/URL (including changes in the comments)
kkhorimoto
2015/09/21 22:55:13
Done.
|
+ stateObject:(NSString*)stateObject; |
// Loads the HTML into the page. |
- (void)loadHTML:(NSString*)html; |
// Loads HTML in the page and presents it as if it was originating from an |
@@ -301,7 +303,7 @@ class WebStateImpl; |
// Helper method called at the end of history navigation methods goBack, |
// goForward, and goDelta. Determines whether to load a new URL or call |
-// |finishPushStateNavigationToURL:withStateObject:|. |fromEntry| is the |
+// |setPushedOrReplacedURL:stateObject:|. |fromEntry| is the |
Eugene But (OOO till 7-30)
2015/09/18 02:02:36
NIT: I think mentioning setPushedOrReplacedURL:sta
kkhorimoto
2015/09/21 22:55:13
Done.
|
// CRWSessionEntry that was the current entry prior to the navigation. |
// TODO(rohitrao): This is only exposed so Tab can call it temporarily. Remove |
// as soon as all the Tab calls have moved into CRWWebController. |