resolve merge conflicts of 82eb1f0ea to ub-launcher3-dorval-polish

Test: I solemnly swear I tested this conflict resolution.
Change-Id: Ic1f6ace04ec2c11206276df76ef7a20df545d604
This commit is contained in:
Tony Wickham
2017-05-03 12:59:09 -07:00
5 changed files with 24 additions and 8 deletions

View File

@@ -19,6 +19,8 @@ package com.android.launcher3;
import android.content.ActivityNotFoundException;
import android.content.ComponentName;
import android.content.Context;
import android.graphics.Rect;
import android.os.Bundle;
import android.provider.Settings;
import android.util.AttributeSet;
import android.util.Log;
@@ -58,12 +60,16 @@ public class InfoDropTarget extends UninstallDropTarget {
*/
public static boolean startDetailsActivityForInfo(
ItemInfo info, Launcher launcher, DropTargetResultCallback callback) {
return startDetailsActivityForInfo(info, launcher, callback, null, null);
}
public static boolean startDetailsActivityForInfo(ItemInfo info, Launcher launcher,
DropTargetResultCallback callback, Rect sourceBounds, Bundle opts) {
if (info instanceof PromiseAppInfo) {
PromiseAppInfo promiseAppInfo = (PromiseAppInfo) info;
launcher.startActivity(promiseAppInfo.getMarketIntent());
return true;
}
boolean result = false;
ComponentName componentName = null;
if (info instanceof AppInfo) {
@@ -78,7 +84,7 @@ public class InfoDropTarget extends UninstallDropTarget {
if (componentName != null) {
try {
LauncherAppsCompat.getInstance(launcher)
.showAppDetailsForProfile(componentName, info.user);
.showAppDetailsForProfile(componentName, info.user, sourceBounds, opts);
result = true;
} catch (SecurityException | ActivityNotFoundException e) {
Toast.makeText(launcher, R.string.activity_not_found, Toast.LENGTH_SHORT).show();