if (old.background == null) {
old.background = BACK_ON;
}
if (!RT.equals(old, pressed) && !selected.contains(old)) {
TimingTarget target = new BackgroundChangeTimingTarget(old, old.background, BACK_OFF);
old.animator = new Animator.Builder().addTarget(target)
.setDuration(160, TimeUnit.MILLISECONDS).build();
old.animator.start();
}
}
if (neo != null) {
if (neo.animator != null) {
neo.animator.cancel();
neo.animator = null;
}
if (neo.background == null) {
neo.background = BACK_OFF;
}
if (!RT.equals(neo, pressed) && !selected.contains(neo)) {
TimingTarget target = new BackgroundChangeTimingTarget(neo, neo.background, BACK_ON);
neo.animator = new Animator.Builder().addTarget(target)
.setDuration(160, TimeUnit.MILLISECONDS).build();
neo.animator.start();
}
}