Fix pending restore widget touch issue

After http://ag/14980850, we block updateAppWidget until app widget
is restored. However, PendingAppWidgetHostView constructor relies
on updateAppWidget(null) to trigger set listener in getDefaultView().
We should call super.updateAppWidget(null) in the constructor instead.

Test: manual
Bug: 14980850
Change-Id: I30af9778a636af2ad822e7abc152b6f0bfdea1bf
This commit is contained in:
Steven Ng
2021-08-11 22:40:06 +01:00
parent 8bc9c6355a
commit bdffb53843

View File

@@ -85,7 +85,7 @@ public class PendingAppWidgetHostView extends LauncherAppWidgetHostView
setBackgroundResource(R.drawable.pending_widget_bg);
setWillNotDraw(false);
updateAppWidget(null);
super.updateAppWidget(null);
setOnClickListener(ItemClickHandler.INSTANCE);
if (info.pendingItemInfo == null) {