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

Unified Diff: ios/web/web_state/ui/crw_web_controller.mm

Issue 2582373002: Call registerLoadRequest with URL instead of VirtualURL. (Closed)
Patch Set: only registerLoadRequest Created 4 years 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/web_state/ui/crw_web_controller.mm
diff --git a/ios/web/web_state/ui/crw_web_controller.mm b/ios/web/web_state/ui/crw_web_controller.mm
index da87296de68bf0eaeb586d5777504fa4c72c013c..d0e173d1e1f0105bc1c61c357e4b9666154568f9 100644
--- a/ios/web/web_state/ui/crw_web_controller.mm
+++ b/ios/web/web_state/ui/crw_web_controller.mm
@@ -1989,16 +1989,17 @@ const NSTimeInterval kSnapshotOverlayTransition = 0.5;
[self removeWebViewAllowingCachedReconstruction:NO];
web::NavigationItem* item = [self currentNavItem];
- const GURL targetURL = item ? item->GetVirtualURL() : GURL::EmptyGURL();
+ const GURL virtualURL = item ? item->GetVirtualURL() : GURL::EmptyGURL();
const web::Referrer referrer;
id<CRWNativeContent> nativeContent =
- [_nativeProvider controllerForURL:targetURL];
+ [_nativeProvider controllerForURL:virtualURL];
// Unlike the WebView case, always create a new controller and view.
// TODO(pinkerton): What to do if this does return nil?
[self setNativeController:nativeContent];
if ([nativeContent respondsToSelector:@selector(virtualURL)]) {
item->SetVirtualURL([nativeContent virtualURL]);
}
+ const GURL targetURL = item ? item->GetURL() : GURL::EmptyGURL();
[self registerLoadRequest:targetURL
referrer:referrer
transition:[self currentTransition]];
@@ -5629,7 +5630,7 @@ const NSTimeInterval kSnapshotOverlayTransition = 0.5;
[request setHTTPBody:POSTData];
[request setAllHTTPHeaderFields:[self currentHTTPHeaders]];
GURL navigationURL =
- currentItem ? currentItem->GetVirtualURL() : GURL::EmptyGURL();
+ currentItem ? currentItem->GetURL() : GURL::EmptyGURL();
[self registerLoadRequest:navigationURL
referrer:[self currentSessionEntryReferrer]
transition:[self currentTransition]];
@@ -5639,7 +5640,7 @@ const NSTimeInterval kSnapshotOverlayTransition = 0.5;
ProceduralBlock defaultNavigationBlock = ^{
web::NavigationItem* item = [self currentNavItem];
- GURL navigationURL = item ? item->GetVirtualURL() : GURL::EmptyGURL();
+ GURL navigationURL = item ? item->GetURL() : GURL::EmptyGURL();
[self registerLoadRequest:navigationURL
referrer:[self currentSessionEntryReferrer]
transition:[self currentTransition]];
@@ -5674,7 +5675,7 @@ const NSTimeInterval kSnapshotOverlayTransition = 0.5;
// will be a no-op when it is passed the current back forward list item,
// so |reload| must be explicitly called.
web::NavigationItem* item = [self currentNavItem];
- GURL navigationURL = item ? item->GetVirtualURL() : GURL::EmptyGURL();
+ GURL navigationURL = item ? item->GetURL() : GURL::EmptyGURL();
[self registerLoadRequest:navigationURL
referrer:[self currentSessionEntryReferrer]
transition:[self currentTransition]];
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698