Add method to set start source info from launcher
Bug: 166614700
Test: Enable statsd log: "adb shell cmd stats print-logs"
Launch app from launcher check logcat ((48)0x10000).
Change-Id: Ifc944c5ae9f33147eb7e8768d3e6d1548d20a95a
This commit is contained in:
@@ -86,4 +86,12 @@ public abstract class ActivityOptionsCompat {
|
||||
opts.setFreezeRecentTasksReordering();
|
||||
return opts;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the launch event time from launcher.
|
||||
*/
|
||||
public static ActivityOptions setLauncherSourceInfo(ActivityOptions opts, long uptimeMillis) {
|
||||
opts.setSourceInfo(ActivityOptions.SourceInfo.TYPE_LAUNCHER, uptimeMillis);
|
||||
return opts;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user