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

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

Issue 2983453002: Expose way to enable/disable translate. (Closed)
Patch Set: 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
« no previous file with comments | « ios/web_view/internal/translate/cwv_translation_controller.mm ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web_view/public/cwv_translation_controller.h
diff --git a/ios/web_view/public/cwv_translation_controller.h b/ios/web_view/public/cwv_translation_controller.h
index 6e9476dece1f0a3c1cc285d61e2be1f9fc41a53c..f30113a3a9743f8de33b632e4f8f8051e8fd4c58 100644
--- a/ios/web_view/public/cwv_translation_controller.h
+++ b/ios/web_view/public/cwv_translation_controller.h
@@ -56,6 +56,10 @@ CWV_EXPORT
// Only resets non-incognito settings.
+ (void)resetTranslationPolicies;
+// Enables or disables the translate feature. Only applies to non-incognito.
Eugene But (OOO till 7-30) 2017/07/13 17:52:58 Why does it work only for non-incognito? If I disa
jzw1 2017/07/13 21:05:05 Refactored so that the user can configure for both
++ (BOOL)isTranslateEnabled;
Hiroshi Ichikawa 2017/07/13 07:28:59 Optional: Maybe it can be just "isEnabled" because
Eugene But (OOO till 7-30) 2017/07/13 17:52:58 Or isTranslationEnabled/setTranslationEnabled: to
jzw1 2017/07/13 21:05:05 I've renamed these in the new class CWVTranslation
++ (void)setTranslateEnabled:(BOOL)enabled;
+
// Begins translation on the current page from |sourceLanguage| to
// |targetLanguage|. These language parameters must be chosen from
// |supportedLanguages|. Set |userInitiated| to YES if translation
« no previous file with comments | « ios/web_view/internal/translate/cwv_translation_controller.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698