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

Side by Side Diff: chrome/browser/ui/translate/translate_bubble_model_impl.h

Issue 1923143003: Implement the 2016Q2 Translate UI designe spec out in (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix namespace in .h and other minor review comments Created 4 years, 7 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 unified diff | Download patch
OLDNEW
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_IMPL_H_ 5 #ifndef CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_IMPL_H_
6 #define CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_IMPL_H_ 6 #define CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_IMPL_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 13 matching lines...) Expand all
24 std::unique_ptr<translate::TranslateUIDelegate> ui_delegate); 24 std::unique_ptr<translate::TranslateUIDelegate> ui_delegate);
25 ~TranslateBubbleModelImpl() override; 25 ~TranslateBubbleModelImpl() override;
26 26
27 // Converts a TranslateStep to a ViewState. 27 // Converts a TranslateStep to a ViewState.
28 // This function never returns VIEW_STATE_ADVANCED. 28 // This function never returns VIEW_STATE_ADVANCED.
29 static TranslateBubbleModel::ViewState TranslateStepToViewState( 29 static TranslateBubbleModel::ViewState TranslateStepToViewState(
30 translate::TranslateStep step); 30 translate::TranslateStep step);
31 31
32 // TranslateBubbleModel methods. 32 // TranslateBubbleModel methods.
33 TranslateBubbleModel::ViewState GetViewState() const override; 33 TranslateBubbleModel::ViewState GetViewState() const override;
34 bool GetAlwaysTranslateChecked() const override;
msw 2016/04/29 20:00:00 nit: reorder override to match reordering in base
ftang 2016/04/29 22:37:00 Done.
34 void SetViewState(TranslateBubbleModel::ViewState view_state) override; 35 void SetViewState(TranslateBubbleModel::ViewState view_state) override;
35 void ShowError(translate::TranslateErrors::Type error_type) override; 36 void ShowError(translate::TranslateErrors::Type error_type) override;
36 void GoBackFromAdvanced() override; 37 void GoBackFromAdvanced() override;
37 int GetNumberOfLanguages() const override; 38 int GetNumberOfLanguages() const override;
38 base::string16 GetLanguageNameAt(int index) const override; 39 base::string16 GetLanguageNameAt(int index) const override;
39 int GetOriginalLanguageIndex() const override; 40 int GetOriginalLanguageIndex() const override;
40 void UpdateOriginalLanguageIndex(int index) override; 41 void UpdateOriginalLanguageIndex(int index) override;
41 int GetTargetLanguageIndex() const override; 42 int GetTargetLanguageIndex() const override;
42 void UpdateTargetLanguageIndex(int index) override; 43 void UpdateTargetLanguageIndex(int index) override;
43 void DeclineTranslation() override; 44 void DeclineTranslation() override;
(...skipping 10 matching lines...) Expand all
54 std::unique_ptr<translate::TranslateUIDelegate> ui_delegate_; 55 std::unique_ptr<translate::TranslateUIDelegate> ui_delegate_;
55 TranslateBubbleViewStateTransition view_state_transition_; 56 TranslateBubbleViewStateTransition view_state_transition_;
56 57
57 bool translation_declined_; 58 bool translation_declined_;
58 bool translate_executed_; 59 bool translate_executed_;
59 60
60 DISALLOW_COPY_AND_ASSIGN(TranslateBubbleModelImpl); 61 DISALLOW_COPY_AND_ASSIGN(TranslateBubbleModelImpl);
61 }; 62 };
62 63
63 #endif // CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_IMPL_H_ 64 #endif // CHROME_BROWSER_UI_TRANSLATE_TRANSLATE_BUBBLE_MODEL_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698