diff --git a/cmds/statsd/src/atoms.proto b/cmds/statsd/src/atoms.proto index 5c53a3a585f8c..fa3be26a96f7e 100644 --- a/cmds/statsd/src/atoms.proto +++ b/cmds/statsd/src/atoms.proto @@ -173,6 +173,10 @@ message Atom { WifiRunningStateChanged wifi_running_state_changed = 114; AppCompacted app_compacted = 115; NetworkDnsEventReported network_dns_event_Reported = 116; + DocsUIPickerLaunchedFromReported docs_ui_picker_launched_from_reported = 117; + DocsUIPickResultReported docs_ui_pick_result_reported = 118; + DocsUISearchModeReported docs_ui_search_mode_reported = 119; + DocsUISearchTypeReported docs_ui_search_type_reported = 120; } // Pulled events will start at field 10000. @@ -3655,6 +3659,52 @@ message DocsUIInvalidScopedAccessRequestReported { optional android.stats.docsui.InvalidScopedAccess type = 1; } +/** + * Logs the package name that launches docsui picker mode. + * + * Logged from: + * package/app/DocumentsUI/src/com/android/documentsui/Metrics.java + */ +message DocsUIPickerLaunchedFromReported { + optional string package_name = 1; +} + +/** + * Logs the search type. + * + * Logged from: + * package/app/DocumentsUI/src/com/android/documentsui/Metrics.java + */ +message DocsUISearchTypeReported { + optional android.stats.docsui.SearchType search_type = 1; +} + +/** + * Logs the search mode. + * + * Logged from: + * package/app/DocumentsUI/src/com/android/documentsui/Metrics.java + */ +message DocsUISearchModeReported { + optional android.stats.docsui.SearchMode search_mode = 1; +} + +/** + * Logs the pick result information. + * + * Logged from: + * package/app/DocumentsUI/src/com/android/documentsui/Metrics.java + */ +message DocsUIPickResultReported { + optional int32 total_action_count = 1; + optional int64 duration_millis = 2; + optional int32 file_count= 3; + optional bool is_searching = 4; + optional android.stats.docsui.Root picked_from = 5; + optional android.stats.docsui.MimeType mime_type = 6; + optional int32 repeatedly_pick_times = 7; +} + /** * Logs when an app's memory is compacted. * diff --git a/core/proto/android/stats/docsui/docsui_enums.proto b/core/proto/android/stats/docsui/docsui_enums.proto index 6cb606ad1cabe..655b5e3260191 100644 --- a/core/proto/android/stats/docsui/docsui_enums.proto +++ b/core/proto/android/stats/docsui/docsui_enums.proto @@ -33,13 +33,14 @@ enum MimeType { MIME_UNKNOWN = 0; MIME_NONE = 1; MIME_ANY = 2; - MIME_AUDIO = 3; - MIME_IMAGE = 4; - MIME_MESSAGE = 5; - MIME_MULTIPART = 6; - MIME_TEXT = 7; - MIME_VIDEO = 8; - MIME_OTHER = 9; + MIME_APPLICATION = 3; + MIME_AUDIO = 4; + MIME_IMAGE = 5; + MIME_MESSAGE = 6; + MIME_MULTIPART = 7; + MIME_TEXT = 8; + MIME_VIDEO = 9; + MIME_OTHER = 10; } enum Root { @@ -163,6 +164,8 @@ enum UserAction { ACTION_EXTRACT_TO = 29; ACTION_VIEW_IN_APPLICATION = 30; ACTION_INSPECTOR = 31; + ACTION_SEARCH_CHIP = 32; + ACTION_SEARCH_HISTORY = 33; } enum InvalidScopedAccess { @@ -172,3 +175,20 @@ enum InvalidScopedAccess { SCOPED_DIR_ACCESS_ERROR = 3; SCOPED_DIR_ACCESS_DEPRECATED = 4; } + +enum SearchType { + TYPE_UNKNOWN = 0; + TYPE_CHIP_IMAGES = 1; + TYPE_CHIP_AUDIOS = 2; + TYPE_CHIP_VIDEOS = 3; + TYPE_CHIP_DOCS = 4; + TYPE_SEARCH_HISTORY = 5; + TYPE_SEARCH_STRING = 6; +} + +enum SearchMode { + SEARCH_UNKNOWN = 0; + SEARCH_KEYWORD = 1; + SEARCH_CHIPS = 2; + SEARCH_KEYWORD_N_CHIPS = 3; +}