Revert "Add UI updates for incremental app installs."

This reverts commit 84269d349d.

Reason for revert: causes b/176884453 and b/176992421

Change-Id: I3398674a0acbad8329df5d341ae074ac073a6bf9
(cherry picked from commit 229497d182)
This commit is contained in:
Schneider Victor-tulias authored and android-build-team Robot committed 2021-01-08 03:45:09 +00:00
1 parent eede21e7c3
commit a994593bde
24 files changed
+163 -400

No files matched your search

@@ -45,11 +45,10 @@ import android.widget.Toast;
import com.android.launcher3.PendingAddItemInfo;
import com.android.launcher3.R;
import com.android.launcher3.Utilities;
import com.android.launcher3.model.data.AppInfo;
import com.android.launcher3.model.data.ItemInfo;
import com.android.launcher3.model.data.ItemInfoWithIcon;
import com.android.launcher3.model.data.LauncherAppWidgetInfo;
import com.android.launcher3.model.data.PromiseAppInfo;
import com.android.launcher3.model.data.WorkspaceItemInfo;
import java.net.URISyntaxException;
@@ -201,12 +200,9 @@ public class PackageManagerHelper {
* Starts the details activity for {@code info}
*/
public void startDetailsActivityForInfo(ItemInfo info, Rect sourceBounds, Bundle opts) {
if (info instanceof ItemInfoWithIcon
&& (((ItemInfoWithIcon) info).runtimeStatusFlags
& ItemInfoWithIcon.FLAG_INSTALL_SESSION_ACTIVE) != 0) {
ItemInfoWithIcon appInfo = (ItemInfoWithIcon) info;
mContext.startActivity(new PackageManagerHelper(mContext)
.getMarketIntent(appInfo.getTargetComponent().getPackageName()));
if (info instanceof PromiseAppInfo) {
PromiseAppInfo promiseAppInfo = (PromiseAppInfo) info;
mContext.startActivity(promiseAppInfo.getMarketIntent(mContext));
return;
}
ComponentName componentName = null;
@@ -323,12 +319,4 @@ public class PackageManagerHelper {
}
return false;
}
/** Returns the incremental download progress for the given shortcut's app. */
public static int getLoadingProgress(LauncherActivityInfo info) {
if (Utilities.ATLEAST_S) {
return (int) (100 * info.getLoadingProgress());
}
return 100;
}
}