summaryrefslogtreecommitdiffstats
path: root/protos
diff options
context:
space:
mode:
authorHyunyoung Song <hyunyoungs@google.com>2016-03-04 10:27:09 -0800
committerHyunyoung Song <hyunyoungs@google.com>2016-03-04 10:27:09 -0800
commitc619edbc72e7ad2a77ab25d7a42258bc988c0b4b (patch)
tree335d7b168a8d0930de883d64f1cffd9f457a61d3 /protos
parent2494c3f1681e71af06556ef47de16f018811f7e3 (diff)
downloadandroid_packages_apps_Trebuchet-c619edbc72e7ad2a77ab25d7a42258bc988c0b4b.tar.gz
android_packages_apps_Trebuchet-c619edbc72e7ad2a77ab25d7a42258bc988c0b4b.tar.bz2
android_packages_apps_Trebuchet-c619edbc72e7ad2a77ab25d7a42258bc988c0b4b.zip
[DO NOT MERGE] Upload proto file to burnaby-polish
b/26494415 - needed for ag/879262 getLogger function parameter - prediction to start parsing proto instead of the bundle Change-Id: I002ceb5faad0f2272ae5676b891f20826dbfcf3f
Diffstat (limited to 'protos')
-rw-r--r--protos/launcher_log.proto122
1 files changed, 122 insertions, 0 deletions
diff --git a/protos/launcher_log.proto b/protos/launcher_log.proto
new file mode 100644
index 000000000..a7b6429e4
--- /dev/null
+++ b/protos/launcher_log.proto
@@ -0,0 +1,122 @@
+/*
+ * Copyright (C) 2016 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+syntax = "proto2";
+
+option java_package = "com.android.launcher3.userevent.nano";
+option java_outer_classname = "LauncherLogProto";
+
+package userevent;
+
+message Target {
+ enum Type {
+ NONE = 0;
+ ITEM = 1;
+ CONTROL = 2;
+ CONTAINER = 3;
+ }
+
+ optional Type type = 1;
+
+ // For container type and item type
+ // Used mainly for ContainerType.FOLDER, ItemType.*
+ optional Target parent = 2;
+ optional int32 page_index = 3;
+ optional int32 rank = 4;
+ optional int32 grid_x = 5;
+ optional int32 grid_y = 6;
+
+ // For container types only
+ optional ContainerType container_type = 7;
+ optional int32 cardinality = 8;
+
+ // For control types only
+ optional ControlType control_type = 9;
+
+ // For item types only
+ optional ItemType item_type = 10;
+ optional int32 package_name_hash = 11;
+ optional int32 component_hash = 12; // Used for ItemType.WIDGET
+ optional int32 intent_hash = 13; // Used for ItemType.SHORTCUT
+ optional int32 span_x = 14 [default = 1];// Used for ItemType.WIDGET
+ optional int32 span_y = 15 [default = 1];// Used for ItemType.WIDGET
+}
+
+enum ItemType {
+ APP_ICON = 0;
+ SHORTCUT = 1;
+ WIDGET = 2;
+ FOLDER_ICON = 3;
+}
+
+enum ContainerType {
+ WORKSPACE = 0;
+ HOTSEAT = 1;
+ FOLDER = 2;
+ ALLAPPS = 3;
+ WIDGETS = 4;
+ OVERVIEW = 5;
+ PREDICTION = 6;
+ SEARCHRESULT = 7;
+}
+
+enum ControlType {
+ ALL_APPS_BUTTON = 0;
+ WIDGETS_BUTTON = 1;
+ WALLPAPER_BUTTON = 2;
+ SETTINGS_BUTTON = 3;
+ REMOVE_TARGET = 4;
+ UNINSTALL_TARGET = 5;
+ APPINFO_TARGET = 6;
+ RESIZE_HANDLE = 7;
+ FAST_SCROLL_HANDLE = 8;
+ // HOME, BACK, GO_TO_PLAYSTORE
+}
+
+message Action {
+ enum Type {
+ TOUCH = 0;
+ AUTOMATED = 1;
+ // SOFT_KEYBOARD, HARD_KEYBOARD, ASSIST
+ }
+ enum Touch {
+ TAP = 0;
+ LONGPRESS = 1;
+ DRAGDROP = 2;
+ SWIPE = 3;
+ FLING = 4;
+ PINCH = 5;
+ }
+ optional Type type = 1;
+ optional Touch touch = 2;
+}
+
+//
+// Context free grammar of typical user interaction:
+// Action (Touch) + Target
+// Action (Touch) + Target + Target
+//
+message LauncherEvent {
+
+ required Action action = 1;
+
+ // List of targets that touch actions can be operated on.
+ optional Target src_target = 2;
+ optional Target dest_target = 3;
+
+ optional int64 action_duration_millis = 4;
+ optional int64 elapsed_container_millis = 5;
+ optional int64 elapsed_session_millis = 6;
+}