1/* 2 * Copyright (C) 2019 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17syntax = "proto2"; 18package android.stats.textclassifier; 19option java_multiple_files = true; 20 21enum EventType { 22 TYPE_UNKNOWN = 0; 23 // User started a new selection. 24 SELECTION_STARTED = 1; 25 // User modified an existing selection. 26 SELECTION_MODIFIED = 2; 27 // Smart selection triggered for a single token (word). 28 SMART_SELECTION_SINGLE = 3; 29 // Smart selection triggered spanning multiple tokens (words). 30 SMART_SELECTION_MULTI = 4; 31 // Something else other than user or the default TextClassifier triggered a selection. 32 AUTO_SELECTION = 5; 33 // Smart actions shown to the user. 34 ACTIONS_SHOWN = 6; 35 // User clicked a link. 36 LINK_CLICKED = 7; 37 // User typed over the selection. 38 OVERTYPE = 8; 39 // User clicked on Copy action. 40 COPY_ACTION = 9; 41 // User clicked on Paste action. 42 PASTE_ACTION = 10; 43 // User clicked on Cut action. 44 CUT_ACTION = 11; 45 // User clicked on Share action. 46 SHARE_ACTION = 12; 47 // User clicked on a Smart action. 48 SMART_ACTION = 13; 49 // User dragged+dropped the selection. 50 SELECTION_DRAG = 14; 51 // Selection is destroyed. 52 SELECTION_DESTROYED = 15; 53 // User clicked on a custom action. 54 OTHER_ACTION = 16; 55 // User clicked on Select All action 56 SELECT_ALL = 17; 57 // User reset the smart selection. 58 SELECTION_RESET = 18; 59 // User composed a reply. 60 MANUAL_REPLY = 19; 61 // TextClassifier generated some actions 62 ACTIONS_GENERATED = 20; 63 // Some text links were generated 64 LINKS_GENERATED = 21; 65} 66 67enum WidgetType { 68 WIDGET_TYPE_UNKNOWN = 0; 69 // Standard TextView 70 WIDGET_TYPE_TEXTVIEW = 1; 71 // EditText 72 WIDGET_TYPE_EDITTEXT = 2; 73 // Not selectable textview 74 WIDGET_TYPE_UNSELECTABLE_TEXTVIEW = 3; 75 // Standard Webview 76 WIDGET_TYPE_WEBVIEW = 4; 77 // Editable TextView 78 WIDGET_TYPE_EDIT_WEBVIEW = 5; 79 // Custom text widget 80 WIDGET_TYPE_CUSTOM_TEXTVIEW = 6; 81 // Custom editable text widget. 82 WIDGET_TYPE_CUSTOM_EDITTEXT = 7; 83 // Non-selectable text widget. 84 WIDGET_TYPE_CUSTOM_UNSELECTABLE_TEXTVIEW = 8; 85 // Notification 86 WIDGET_TYPE_NOTIFICATION = 9; 87} 88