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

Unified Diff: components/translate/core/browser/translate_ui_delegate.h

Issue 1632953002: Change the TranslateDeclined() to only count decline if the explicit_closed is set to true (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix mac unit test breakage Created 4 years, 10 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: components/translate/core/browser/translate_ui_delegate.h
diff --git a/components/translate/core/browser/translate_ui_delegate.h b/components/translate/core/browser/translate_ui_delegate.h
index 82a4bc9bef20c5362ca2bf75e28f7ac227afb670..33ee3293374351ac5d12cbb14664bd16dc352362 100644
--- a/components/translate/core/browser/translate_ui_delegate.h
+++ b/components/translate/core/browser/translate_ui_delegate.h
@@ -88,6 +88,15 @@ class TranslateUIDelegate {
void RevertTranslation();
// Processes when the user declines translation.
+ // The function name is not accurate. It only means the user did not take
+ // affirmative action after the translation ui show up. The user either
+ // actively decline the translation or ignore the prompt of translation.
+ // Pass |explicitly_closed| as true if user explicityly decline the
+ // translation.
+ // Pass |explicitly_closed| as false if the translation UI is dismissed
+ // implicit by some user actions which ignore the translation UI,
+ // such as switch to a new tab/window or navigate to another page by
+ // click a link.
void TranslationDeclined(bool explicitly_closed);
// Returns true if the current language is blocked.

Powered by Google App Engine
This is Rietveld 408576698