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

Unified Diff: ios/web_view/public/cwv_web_view.h

Issue 2786033002: Expose way to set google api key through CWVWebView class method. (Closed)
Patch Set: Few lints Created 3 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_view/public/cwv_web_view.h
diff --git a/ios/web_view/public/cwv_web_view.h b/ios/web_view/public/cwv_web_view.h
index 86de8f52c87bbe10faf941d4d1f072f25e2db55a..d2d5a9c94a7768e86a5dbc4d93ffc31fce867cf7 100644
--- a/ios/web_view/public/cwv_web_view.h
+++ b/ios/web_view/public/cwv_web_view.h
@@ -61,6 +61,15 @@ CWV_EXPORT
// is reset to 0.0.
@property(nonatomic, readonly) double estimatedProgress;
+// Use this method to set the necessary credentials used to communicate with
+// the Google API for features such as translate. See this link for more info:
+// https://support.google.com/googleapi/answer/6158857
+// This method must be called before any |CWVWebViews| are instantiated for
+// the keys to be used.
++ (void)setGoogleAPIKey:(NSString*)googleAPIKey
+ clientID:(NSString*)clientID
+ clientSecret:(NSString*)clientSecret;
+
// |configuration| must not be null
- (instancetype)initWithFrame:(CGRect)frame
configuration:(CWVWebViewConfiguration*)configuration
« ios/web_view/internal/cwv_web_view.mm ('K') | « ios/web_view/internal/cwv_web_view.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698