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

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

Issue 2900603003: Successful translation erroneously reported on page with too little text (Closed)
Patch Set: Fixed a nit Created 3 years, 6 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 | « chrome/browser/ui/browser_commands.cc ('k') | components/translate/core/browser/language_state.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/translate/core/browser/language_state.h
diff --git a/components/translate/core/browser/language_state.h b/components/translate/core/browser/language_state.h
index 08e670fec092c05e758176279a71a93f30567d41..10b07400606e3a272d5863d3c39ef854030ef746 100644
--- a/components/translate/core/browser/language_state.h
+++ b/components/translate/core/browser/language_state.h
@@ -59,6 +59,10 @@ class LanguageState {
bool translation_pending() const { return translation_pending_; }
void set_translation_pending(bool value) { translation_pending_ = value; }
+ // Whether an error occured during translation.
+ bool translation_error() const { return translation_error_; }
+ void set_translation_error(bool value) { translation_error_ = value; }
+
// Whether the user has already declined to translate the page.
bool translation_declined() const { return translation_declined_; }
void set_translation_declined(bool value) { translation_declined_ = value; }
@@ -109,6 +113,9 @@ class LanguageState {
// then we can get rid of that state.
bool translation_pending_;
+ // Whether an error occured during translation.
+ bool translation_error_;
+
// Whether the user has declined to translate the page (by closing the infobar
// for example). This is necessary as a new infobar could be shown if a new
// load happens in the page after the user closed the infobar.
« no previous file with comments | « chrome/browser/ui/browser_commands.cc ('k') | components/translate/core/browser/language_state.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698