use of org.thoughtcrime.securesms.animation.AnimationCompleteListener in project Signal-Android by WhisperSystems.
the class CameraXFragment method fadeInControls.
@Override
public void fadeInControls() {
controlsContainer.setEnabled(false);
controlsContainer.animate().setDuration(250).alpha(1f).setInterpolator(MediaAnimations.getInterpolator()).setListener(new AnimationCompleteListener() {
@Override
public void onAnimationEnd(Animator animation) {
controlsContainer.setEnabled(true);
}
});
}
use of org.thoughtcrime.securesms.animation.AnimationCompleteListener in project Signal-Android by WhisperSystems.
the class CameraXFragment method fadeOutControls.
@Override
public void fadeOutControls(@NonNull Runnable onEndAction) {
controlsContainer.setEnabled(false);
controlsContainer.animate().setDuration(250).alpha(0f).setInterpolator(MediaAnimations.getInterpolator()).setListener(new AnimationCompleteListener() {
@Override
public void onAnimationEnd(Animator animation) {
controlsContainer.setEnabled(true);
onEndAction.run();
}
});
}
use of org.thoughtcrime.securesms.animation.AnimationCompleteListener in project Signal-Android by WhisperSystems.
the class SearchToolbar method hide.
@MainThread
private void hide() {
if (getVisibility() == View.VISIBLE) {
if (listener != null)
listener.onSearchClosed();
if (Build.VERSION.SDK_INT >= 21) {
Animator animator = ViewAnimationUtils.createCircularReveal(this, (int) x, (int) y, getWidth(), 0);
animator.setDuration(400);
animator.addListener(new AnimationCompleteListener() {
@Override
public void onAnimationEnd(Animator animation) {
setVisibility(View.INVISIBLE);
}
});
animator.start();
} else {
setVisibility(View.INVISIBLE);
}
}
}
use of org.thoughtcrime.securesms.animation.AnimationCompleteListener in project Signal-Android by WhisperSystems.
the class ConversationItemFooter method showPlaybackSpeedToggle.
private void showPlaybackSpeedToggle() {
if (hasShrunkDate) {
return;
}
hasShrunkDate = true;
playbackSpeedToggleTextView.animate().alpha(1f).scaleX(1f).scaleY(1f).setDuration(150L).setListener(new AnimationCompleteListener() {
@Override
public void onAnimationEnd(Animator animation) {
playbackSpeedToggleTextView.setClickable(true);
}
});
if (isOutgoing) {
dateView.setMaxWidth(ViewUtil.dpToPx(28));
} else {
ConstraintSet constraintSet = new ConstraintSet();
constraintSet.clone(this);
constraintSet.constrainMaxWidth(R.id.date_and_expiry_wrapper, ViewUtil.dpToPx(40));
constraintSet.applyTo(this);
}
}
use of org.thoughtcrime.securesms.animation.AnimationCompleteListener in project Signal-Android by WhisperSystems.
the class Camera1Fragment method fadeInControls.
@Override
public void fadeInControls() {
controlsContainer.setEnabled(false);
controlsContainer.animate().setInterpolator(MediaAnimations.getInterpolator()).setDuration(250).alpha(1f).setListener(new AnimationCompleteListener() {
@Override
public void onAnimationEnd(Animator animation) {
controlsContainer.setEnabled(true);
}
});
}
Aggregations