commit | bdffb53843235563a2c40a3f503234cb1c767a62 | [log] [tgz] |
---|---|---|
author | Steven Ng <stevenckng@google.com> | Wed Aug 11 22:40:06 2021 +0100 |
committer | Steven Ng <stevenckng@google.com> | Wed Aug 11 22:40:06 2021 +0100 |
tree | cb892696484af45d4c36a3bb8fdedaee9d3e8cb2 | |
parent | 8bc9c6355ad2d274f488396488bd0ad8ea8fb081 [diff] |
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
diff --git a/src/com/android/launcher3/widget/PendingAppWidgetHostView.java b/src/com/android/launcher3/widget/PendingAppWidgetHostView.java index d3a0190..57a6d3f 100644 --- a/src/com/android/launcher3/widget/PendingAppWidgetHostView.java +++ b/src/com/android/launcher3/widget/PendingAppWidgetHostView.java
@@ -85,7 +85,7 @@ setBackgroundResource(R.drawable.pending_widget_bg); setWillNotDraw(false); - updateAppWidget(null); + super.updateAppWidget(null); setOnClickListener(ItemClickHandler.INSTANCE); if (info.pendingItemInfo == null) {