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

Unified Diff: ios/web_view/internal/cwv_web_view_configuration.mm

Issue 2983453002: Expose way to enable/disable translate. (Closed)
Patch Set: comment non obvious param Created 3 years, 5 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_view/internal/cwv_web_view_configuration.mm
diff --git a/ios/web_view/internal/cwv_web_view_configuration.mm b/ios/web_view/internal/cwv_web_view_configuration.mm
index 736dfbbd3fafcc0810b8aa849780bd4b3c28a064..36696713c8450143e8b95afe5818f9c3f4d719d1 100644
--- a/ios/web_view/internal/cwv_web_view_configuration.mm
+++ b/ios/web_view/internal/cwv_web_view_configuration.mm
@@ -8,6 +8,7 @@
#include "base/memory/ptr_util.h"
#include "base/threading/thread_restrictions.h"
#include "ios/web_view/internal/app/application_context.h"
+#import "ios/web_view/internal/cwv_preferences_internal.h"
#import "ios/web_view/internal/cwv_user_content_controller_internal.h"
#include "ios/web_view/internal/web_view_browser_state.h"
#include "ios/web_view/internal/web_view_global_state_util.h"
@@ -28,6 +29,7 @@
@implementation CWVWebViewConfiguration
+@synthesize preferences = _preferences;
@synthesize userContentController = _userContentController;
+ (instancetype)defaultConfiguration {
@@ -68,6 +70,9 @@
if (self) {
_browserState = std::move(browserState);
+ _preferences =
+ [[CWVPreferences alloc] initWithPrefService:_browserState->GetPrefs()];
+
_userContentController =
[[CWVUserContentController alloc] initWithConfiguration:self];
}

Powered by Google App Engine
This is Rietveld 408576698