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

Unified Diff: ios/web/shell/view_controller.mm

Issue 1901343002: [ios] Do not use private web// API in ios_web_shell. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added missing include Created 4 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/shell/view_controller.mm
diff --git a/ios/web/shell/view_controller.mm b/ios/web/shell/view_controller.mm
index 1d541061cbf792a066a0c78679b78381d1fd3306..748c739d57f8eeffb8ee23756f8128ceba1f6249 100644
--- a/ios/web/shell/view_controller.mm
+++ b/ios/web/shell/view_controller.mm
@@ -15,12 +15,12 @@
#include "ios/net/cookies/cookie_store_ios.h"
#import "ios/net/crn_http_protocol_handler.h"
#import "ios/net/empty_nsurlcache.h"
+#import "ios/net/request_tracker.h"
+#import "ios/web/public/navigation_manager.h"
#include "ios/web/public/referrer.h"
#include "ios/web/public/web_state/web_state.h"
#import "ios/web/public/web_state/web_state_delegate_bridge.h"
#import "ios/web/public/web_state/web_state_observer_bridge.h"
-#include "ios/web/shell/shell_browser_state.h"
-#include "ios/web/web_state/web_state_impl.h"
#include "ui/base/page_transition_types.h"
NSString* const kWebShellBackButtonAccessibilityLabel = @"Back";
@@ -33,7 +33,7 @@ using web::NavigationManager;
CRWWebStateObserver,
UITextFieldDelegate> {
web::BrowserState* _browserState;
- std::unique_ptr<web::WebStateImpl> _webState;
+ std::unique_ptr<web::WebState> _webState;
std::unique_ptr<web::WebStateObserverBridge> _webStateObserver;
std::unique_ptr<web::WebStateDelegateBridge> _webStateDelegate;
@@ -111,8 +111,8 @@ using web::NavigationManager;
// Set up the network stack before creating the WebState.
[self setUpNetworkStack];
- _webState.reset(new web::WebStateImpl(_browserState));
- _webState->GetNavigationManagerImpl().InitializeSession(nil, nil, NO, 0);
+ web::WebState::CreateParams web_state_create_params(_browserState);
rohitrao (ping after 24h) 2016/04/21 00:17:18 webStateCreateParams?
Eugene But (OOO till 7-30) 2016/04/21 00:48:16 Done.
+ _webState = web::WebState::Create(web_state_create_params);
_webState->SetWebUsageEnabled(true);
_webStateObserver.reset(

Powered by Google App Engine
This is Rietveld 408576698