Clear animator target

pull/207/head
M66B 3 years ago
parent 440759066d
commit da27db5988

@ -814,6 +814,10 @@ abstract class ActivityBase extends AppCompatActivity implements SharedPreferenc
RecyclerView.Adapter.class.isAssignableFrom(type)) {
Log.i("Clearing " + f.getClass().getSimpleName() + ":" + field.getName());
field.setAccessible(true);
if (Animator.class.isAssignableFrom(type))
((Animator) field.get(f)).setTarget(null);
field.set(f, null);
}
}

@ -661,7 +661,6 @@ public class Helper {
public void onDestroyed() {
try {
animator.removeUpdateListener(listener);
fab.setAlpha(1.0f);
owner.getLifecycle().removeObserver(this);
} catch (Throwable ex) {
Log.e(ex);

Loading…
Cancel
Save