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

Unified Diff: components/sync/protocol/user_event_specifics.proto

Issue 2911603002: Initial translation event proto. (Closed)
Patch Set: update fields. Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/sync/protocol/proto_visitors.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/sync/protocol/user_event_specifics.proto
diff --git a/components/sync/protocol/user_event_specifics.proto b/components/sync/protocol/user_event_specifics.proto
index d36d7642c80aa0d8678d95212ac2409f46c3ad59..e2af33ac9cd9a393acff510e64c6b51d9888aacc 100644
--- a/components/sync/protocol/user_event_specifics.proto
+++ b/components/sync/protocol/user_event_specifics.proto
@@ -39,6 +39,35 @@ message LanguageDetection {
optional string adopted_language_code = 2;
}
+// User translated a page or interacted with translate suggestion.
+message Translation {
+ // Source language of the translation.
+ optional string from_language_code = 1;
+ // Target language of the translation.
+ optional string to_language_code = 2;
+ enum Interaction {
+ UNKNOWN = 0;
+ ACCEPT = 1;
+ DECLINE = 2;
+ // This happens when user scroll or click outside the UI without
+ // translation.
+ IGNORED = 3;
+ // This happens when user choose to close the translation window without
+ // translation.
+ DISMISSED = 4;
+ // User manually entered either language.
+ // In this case, from_language_code and to_language_code will be user chosen
+ // values.
+ MANUAL = 5;
+ // User choose to revert the translation, in this case, from_language_code
+ // and to_language_code will be previous chosen values.
+ TRANSLATION_REVERTED = 6;
+ // Automatically triggered translation.
+ AUTOMATIC_TRANSLATION = 7;
+ }
+ optional Interaction interaction = 3;
+}
+
message UserEventSpecifics {
// Time of event, as measured on the client (unix epoch).
optional int64 event_time_usec = 1;
@@ -53,5 +82,6 @@ message UserEventSpecifics {
oneof event {
FieldTrialEvent field_trial_event = 4;
LanguageDetection language_detection = 5;
+ Translation translation = 6;
}
}
« no previous file with comments | « components/sync/protocol/proto_visitors.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698