OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_H_ | 5 #ifndef CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_H_ |
6 #define CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_H_ | 6 #define CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
11 #include "chrome/common/translate/translate_errors.h" | 11 #include "components/translate/core/common/translate_errors.h" |
12 | 12 |
13 // The model for the Translate bubble UX. This manages the user's manipulation | 13 // The model for the Translate bubble UX. This manages the user's manipulation |
14 // of the bubble and offers the data to show on the bubble. | 14 // of the bubble and offers the data to show on the bubble. |
15 class TranslateBubbleModel { | 15 class TranslateBubbleModel { |
16 public: | 16 public: |
17 enum ViewState { | 17 enum ViewState { |
18 // The view state before translating. | 18 // The view state before translating. |
19 VIEW_STATE_BEFORE_TRANSLATE, | 19 VIEW_STATE_BEFORE_TRANSLATE, |
20 | 20 |
21 // The view state during translating. | 21 // The view state during translating. |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 // |explicitly_closed| is true if the user explicitly closed the UI, for | 90 // |explicitly_closed| is true if the user explicitly closed the UI, for |
91 // example, clicking 'Nope' button. | 91 // example, clicking 'Nope' button. |
92 virtual void TranslationDeclined(bool explicitly_closed) = 0; | 92 virtual void TranslationDeclined(bool explicitly_closed) = 0; |
93 | 93 |
94 // Returns true if the page is translated in the currently selected source | 94 // Returns true if the page is translated in the currently selected source |
95 // and target language. | 95 // and target language. |
96 virtual bool IsPageTranslatedInCurrentLanguages() const = 0; | 96 virtual bool IsPageTranslatedInCurrentLanguages() const = 0; |
97 }; | 97 }; |
98 | 98 |
99 #endif // CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_H_ | 99 #endif // CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_H_ |
OLD | NEW |