Merge "Made usages of animate().setListener() call safer" into sc-v2-dev
This commit is contained in:
@@ -2371,7 +2371,8 @@ public class GlobalActionsDialogLite implements DialogInterface.OnDismissListene
|
|||||||
message.animate()
|
message.animate()
|
||||||
.alpha(0f)
|
.alpha(0f)
|
||||||
.setDuration(TOAST_FADE_TIME)
|
.setDuration(TOAST_FADE_TIME)
|
||||||
.setStartDelay(visibleTime);
|
.setStartDelay(visibleTime)
|
||||||
|
.setListener(null);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -289,6 +289,9 @@ public abstract class MediaOutputBaseAdapter extends
|
|||||||
public void onAnimationEnd(Animator animation) {
|
public void onAnimationEnd(Animator animation) {
|
||||||
to.requireViewById(R.id.volume_indeterminate_progress).setVisibility(
|
to.requireViewById(R.id.volume_indeterminate_progress).setVisibility(
|
||||||
View.VISIBLE);
|
View.VISIBLE);
|
||||||
|
// Unset the listener, otherwise this may persist for another view
|
||||||
|
// property animation
|
||||||
|
toTitleText.animate().setListener(null);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// Animation for seek bar
|
// Animation for seek bar
|
||||||
@@ -312,8 +315,14 @@ public abstract class MediaOutputBaseAdapter extends
|
|||||||
public void onAnimationEnd(Animator animation) {
|
public void onAnimationEnd(Animator animation) {
|
||||||
mIsAnimating = false;
|
mIsAnimating = false;
|
||||||
notifyDataSetChanged();
|
notifyDataSetChanged();
|
||||||
|
// Unset the listener, otherwise this may persist for
|
||||||
|
// another view property animation
|
||||||
|
fromTitleText.animate().setListener(null);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
// Unset the listener, otherwise this may persist for another view
|
||||||
|
// property animation
|
||||||
|
fromSeekBar.animate().setListener(null);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -770,6 +770,8 @@ public class QSFragment extends LifecycleFragment implements QS, CommandQueue.Ca
|
|||||||
public void onAnimationEnd(Animator animation) {
|
public void onAnimationEnd(Animator animation) {
|
||||||
mHeaderAnimating = false;
|
mHeaderAnimating = false;
|
||||||
updateQsState();
|
updateQsState();
|
||||||
|
// Unset the listener, otherwise this may persist for another view property animation
|
||||||
|
getView().animate().setListener(null);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -717,6 +717,9 @@ public class KeyguardIndicationController {
|
|||||||
textView.setTranslationY(BOUNCE_ANIMATION_FINAL_Y);
|
textView.setTranslationY(BOUNCE_ANIMATION_FINAL_Y);
|
||||||
ViewClippingUtil.setClippingDeactivated(textView, false,
|
ViewClippingUtil.setClippingDeactivated(textView, false,
|
||||||
mClippingParams);
|
mClippingParams);
|
||||||
|
// Unset the listener, otherwise this may persist for
|
||||||
|
// another view property animation
|
||||||
|
textView.animate().setListener(null);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -124,6 +124,9 @@ public class LightsOutNotifController {
|
|||||||
public void onAnimationEnd(Animator a) {
|
public void onAnimationEnd(Animator a) {
|
||||||
mLightsOutNotifView.setAlpha(showDot ? 1 : 0);
|
mLightsOutNotifView.setAlpha(showDot ? 1 : 0);
|
||||||
mLightsOutNotifView.setVisibility(showDot ? View.VISIBLE : View.GONE);
|
mLightsOutNotifView.setVisibility(showDot ? View.VISIBLE : View.GONE);
|
||||||
|
// Unset the listener, otherwise this may persist for
|
||||||
|
// another view property animation
|
||||||
|
mLightsOutNotifView.animate().setListener(null);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.start();
|
.start();
|
||||||
|
|||||||
@@ -120,6 +120,9 @@ public class SettingsButton extends AlphaOptimizedImageButton {
|
|||||||
setAlpha(1f);
|
setAlpha(1f);
|
||||||
setTranslationX(0);
|
setTranslationX(0);
|
||||||
cancelLongClick();
|
cancelLongClick();
|
||||||
|
// Unset the listener, otherwise this may persist for
|
||||||
|
// another view property animation
|
||||||
|
animate().setListener(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in New Issue
Block a user