Remove popup container drag listener on close complete.

Bug: 217162588
Test: Verified removal once drag is finished. Verified working on secondary display launcher.
Change-Id: I16515518c6d488b74450456306abbfff646ac11b
Merged-In: I16515518c6d488b74450456306abbfff646ac11b
This commit is contained in:
Brian Isganitis
2022-02-18 11:11:25 -08:00
parent 0fb7fa4e30
commit 8aa4b05d22

View File

@@ -486,6 +486,9 @@ public class PopupContainerWithArrow<T extends Context & ActivityContext>
@Override
protected void closeComplete() {
super.closeComplete();
if (mActivityContext.getDragController() != null) {
mActivityContext.getDragController().removeDragListener(this);
}
PopupContainerWithArrow openPopup = getOpen(mActivityContext);
if (openPopup == null || openPopup.mOriginalIcon != mOriginalIcon) {
mOriginalIcon.setTextVisibility(mOriginalIcon.shouldTextBeVisible());