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

Unified Diff: ios/chrome/app/main_controller.mm

Issue 2600963002: [ios] Do not use CRWWebController in MainController. (Closed)
Patch Set: 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 | « ios/chrome/app/DEPS ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/app/main_controller.mm
diff --git a/ios/chrome/app/main_controller.mm b/ios/chrome/app/main_controller.mm
index ea0326e908dd6968842ea47deb5f90fee5b607fe..b88d59bcc4b3e6a97fbb4127ac9bf9910cc227d5 100644
--- a/ios/chrome/app/main_controller.mm
+++ b/ios/chrome/app/main_controller.mm
@@ -137,11 +137,11 @@
#include "ios/web/net/request_tracker_factory_impl.h"
#include "ios/web/net/request_tracker_impl.h"
#include "ios/web/net/web_http_protocol_handler_delegate.h"
+#import "ios/web/public/navigation_manager.h"
#include "ios/web/public/web_capabilities.h"
#include "ios/web/public/web_state/web_state.h"
#import "ios/web/public/web_view_creation_util.h"
#include "ios/web/public/webui/web_ui_ios_controller_factory.h"
-#import "ios/web/web_state/ui/crw_web_controller.h"
#include "mojo/edk/embedder/embedder.h"
#import "net/base/mac/url_conversions.h"
#include "net/url_request/url_request_context.h"
@@ -2317,7 +2317,7 @@ enum class StackViewDismissalMode { NONE, NORMAL, INCOGNITO };
#pragma mark - Tab opening utility methods.
- (Tab*)openOrReuseTabInMode:(ApplicationMode)targetMode
- withURL:(const GURL&)url
+ withURL:(const GURL&)URL
transition:(ui::PageTransition)transition {
BrowserViewController* targetBVC =
targetMode == ApplicationMode::NORMAL ? self.mainBVC : self.otrBVC;
@@ -2328,16 +2328,16 @@ enum class StackViewDismissalMode { NONE, NORMAL, INCOGNITO };
currentURL = [currentTabInTargetBVC url];
if (!(currentTabInTargetBVC && IsURLNtp(currentURL))) {
- return [targetBVC addSelectedTabWithURL:url
+ return [targetBVC addSelectedTabWithURL:URL
atIndex:NSNotFound
transition:transition];
}
Tab* newTab = currentTabInTargetBVC;
// Don't call loadWithParams for chrome://newtab, it's already loaded.
- if (!(IsURLNtp(url))) {
- web::NavigationManager::WebLoadParams params(url);
- [[newTab webController] loadWithParams:params];
+ if (!(IsURLNtp(URL))) {
+ web::NavigationManager::WebLoadParams params(URL);
+ [newTab webState]->GetNavigationManager()->LoadURLWithParams(params);
}
return newTab;
}
« no previous file with comments | « ios/chrome/app/DEPS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698