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

Unified Diff: chrome/browser/ui/translate/translate_bubble_view_state_transition.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: change according to msw review comments Created 4 years, 8 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: chrome/browser/ui/translate/translate_bubble_view_state_transition.h
diff --git a/chrome/browser/ui/translate/translate_bubble_view_state_transition.h b/chrome/browser/ui/translate/translate_bubble_view_state_transition.h
index 383bc24cb7ad754f3125c320470585ac12c2cd5d..3c16d2c5260a52d00e69e4d0e8af4df5f0289a87 100644
--- a/chrome/browser/ui/translate/translate_bubble_view_state_transition.h
+++ b/chrome/browser/ui/translate/translate_bubble_view_state_transition.h
@@ -8,6 +8,65 @@
#include "base/macros.h"
#include "chrome/browser/ui/translate/translate_bubble_model.h"
+namespace translate {
+
+enum TranslateBubbleUiEvent {
+ // The user clicked the advanced option.
+ SET_STATE_OPTIONS,
+
+ // The user clicked down and went back from the advanced option.
msw 2016/04/29 23:43:40 nit: I'm not sure what 'clicked down' means, do yo
ftang 2016/04/30 01:24:50 Done.
+ LEAVE_STATE_OPTIONS,
+
+ // The user clicked the advanced link.
+ ADVANCED_LINK_CLICKED,
+
+ // The user checked the "always translate" checkbox.
+ ALWAYS_TRANSLATE_CHECKED,
+
+ // The user unchecked the "always translate" checkbox.
+ ALWAYS_TRANSLATE_UNCHECKED,
+
+ // The user selected the "Nope" in option menu.
msw 2016/04/29 23:43:40 nit: grammar here and elsewhere, but whatever...
ftang 2016/04/30 01:24:50 Done.
+ NOPE_MENU_CLICKED,
+
+ // The user selected the "Never translate language" in option menu.
+ NEVER_TRANSLATE_LANGUAGE_MENU_CLICKED,
+
+ // The user selected the "Never translate this site" in option menu.
+ NEVER_TRANSLATE_SITE_MENU_CLICKED,
+
+ // The user clicked "Translate" button.
msw 2016/04/29 23:43:40 nit: 'clicked the'
ftang 2016/04/30 01:24:50 Done.
+ TRANSLATE_BUTTON_CLICKED,
+
+ // The user clicked the "Done" button.
+ DONE_BUTTON_CLICKED,
+
+ // The user clicked the "Cancel" button.
+ CANCEL_BUTTON_CLICKED,
+
+ // The user clicked the "Closed" [X] button.
+ CLOSE_BUTTON_CLICKED,
+
+ // The user clicked the "Try Again" button.
+ TRY_AGAIN_BUTTON_CLICKED,
+
+ // The user clicked the "Show Original" button.
+ SHOW_ORIGINAL_BUTTON_CLICKED,
+
+ // The user clicked the "Setting" link.
msw 2016/04/29 23:43:40 nit: Settings
ftang 2016/04/30 01:24:50 Done.
+ SETTING_LINK_CLICKED,
msw 2016/04/29 23:43:40 nit: SETTINGS
ftang 2016/04/30 01:24:50 Done.
+
+ // The user changed the "Source language".
+ SOURCE_LANGUAGE_MENU_CLICKED,
+
+ // The user changed the "Target language".
+ TARGET_LANGUAGE_MENU_CLICKED,
+
+ TRANSLATE_BUBBLE_UI_EVENT_MAX
+};
+
+} // namespace translate
+
// The class which manages the transition of the view state of the Translate
// bubble.
class TranslateBubbleViewStateTransition {

Powered by Google App Engine
This is Rietveld 408576698