Merge "Add LAUNCHER_APP_LAUNCH_PENDING_INTENT where an app is launched through pending intent." into udc-dev am: f7d08912fa
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/23395239 Change-Id: Idbc12173e1ba985bd62bdbe84536982926e27913 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -642,6 +642,9 @@ public class StatsLogManager implements ResourceBasedOverride {
|
|||||||
|
|
||||||
@UiEvent(doc = "User has swiped upwards from the gesture handle to show transient taskbar.")
|
@UiEvent(doc = "User has swiped upwards from the gesture handle to show transient taskbar.")
|
||||||
LAUNCHER_TRANSIENT_TASKBAR_SHOW(1331),
|
LAUNCHER_TRANSIENT_TASKBAR_SHOW(1331),
|
||||||
|
|
||||||
|
@UiEvent(doc = "App launched through pending intent")
|
||||||
|
LAUNCHER_APP_LAUNCH_PENDING_INTENT(1394),
|
||||||
;
|
;
|
||||||
|
|
||||||
// ADD MORE
|
// ADD MORE
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ import static android.window.SplashScreen.SPLASH_SCREEN_STYLE_SOLID_COLOR;
|
|||||||
import static com.android.launcher3.LauncherSettings.Animation.DEFAULT_NO_ICON;
|
import static com.android.launcher3.LauncherSettings.Animation.DEFAULT_NO_ICON;
|
||||||
import static com.android.launcher3.logging.KeyboardStateManager.KeyboardState.HIDE;
|
import static com.android.launcher3.logging.KeyboardStateManager.KeyboardState.HIDE;
|
||||||
import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_ALLAPPS_KEYBOARD_CLOSED;
|
import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_ALLAPPS_KEYBOARD_CLOSED;
|
||||||
|
import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_APP_LAUNCH_PENDING_INTENT;
|
||||||
import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_APP_LAUNCH_TAP;
|
import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_APP_LAUNCH_TAP;
|
||||||
import static com.android.launcher3.model.WidgetsModel.GO_DISABLE_WIDGETS;
|
import static com.android.launcher3.model.WidgetsModel.GO_DISABLE_WIDGETS;
|
||||||
import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
|
import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
|
||||||
@@ -305,6 +306,11 @@ public interface ActivityContext {
|
|||||||
ActivityOptionsWrapper options = getActivityLaunchOptions(v, item);
|
ActivityOptionsWrapper options = getActivityLaunchOptions(v, item);
|
||||||
try {
|
try {
|
||||||
intent.send(null, 0, null, null, null, null, options.toBundle());
|
intent.send(null, 0, null, null, null, null, options.toBundle());
|
||||||
|
if (item != null) {
|
||||||
|
InstanceId instanceId = new InstanceIdSequence().newInstanceId();
|
||||||
|
getStatsLogManager().logger().withItemInfo(item).withInstanceId(instanceId)
|
||||||
|
.log(LAUNCHER_APP_LAUNCH_PENDING_INTENT);
|
||||||
|
}
|
||||||
return options.onEndCallback;
|
return options.onEndCallback;
|
||||||
} catch (PendingIntent.CanceledException e) {
|
} catch (PendingIntent.CanceledException e) {
|
||||||
Toast.makeText(v.getContext(),
|
Toast.makeText(v.getContext(),
|
||||||
|
|||||||
Reference in New Issue
Block a user