use of android.support.transition.Fade in project samourai-wallet-android by Samourai-Wallet.
the class SendTransactionDetailsView method showTransaction.
public void showTransaction() {
TransitionSet set = new TransitionSet();
set.setOrdering(TransitionSet.ORDERING_TOGETHER);
set.addTransition(new Fade()).addTarget(transactionReview).addTransition(new Slide(Gravity.START)).addTarget(transactionView);
TransitionManager.beginDelayedTransition(this, set);
addView(transactionView);
reviewActive = false;
removeView(transactionReview);
}
use of android.support.transition.Fade in project Memento-Calendar by alexstyl.
the class SearchTransitioner method onActivityResumed.
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
void onActivityResumed() {
if (supportsTransitions()) {
TransitionManager.beginDelayedTransition(toolbar, FadeInTransition.createTransition());
FrameLayout.LayoutParams layoutParams = (FrameLayout.LayoutParams) toolbar.getLayoutParams();
layoutParams.setMargins(toolbarMargin, toolbarMargin, toolbarMargin, toolbarMargin);
viewFader.showContent(toolbar);
toolbar.setLayoutParams(layoutParams);
TransitionManager.beginDelayedTransition(activityContent, new Fade(Fade.IN));
activityContent.setVisibility(VISIBLE);
ViewCompat.setElevation(toolbarHolder, 0);
}
}
use of android.support.transition.Fade in project Memento-Calendar by alexstyl.
the class SearchActivity method exitTransitionWithAction.
private void exitTransitionWithAction(final Runnable endingAction) {
Transition transition = FadeOutTransition.withAction(new SimpleTransitionListener() {
@Override
public void onTransitionEnd(Transition transition) {
endingAction.run();
}
});
TransitionManager.beginDelayedTransition(searchbar, transition);
fader.hideContentOf(searchbar);
TransitionManager.beginDelayedTransition(content, new Fade(Fade.OUT));
}
use of android.support.transition.Fade in project samourai-wallet-android by Samourai-Wallet.
the class SendTransactionDetailsView method showReview.
/**
* Shows review layout with transition
*
* @param ricochet will be used to show and hide ricochet hops slider
*/
public void showReview(boolean ricochet) {
TransitionSet set = new TransitionSet();
set.setOrdering(TransitionSet.ORDERING_TOGETHER);
set.addTransition(new Fade()).addTarget(transactionView).addTransition(new Slide(Gravity.END)).addTarget(transactionReview);
//
// if (ricochet) {
// // ricochetHopsReview.setVisibility(View.VISIBLE);
// stoneWallReview.setVisibility(View.GONE);
// } else {
// ricochetHopsReview.setVisibility(View.GONE);
// stoneWallReview.setVisibility(View.VISIBLE);
// }
TransitionManager.beginDelayedTransition(this, set);
addView(transactionReview);
reviewActive = true;
removeView(transactionView);
}
use of android.support.transition.Fade in project Memento-Calendar by alexstyl.
the class SearchTransitioner method transitionToSearch.
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
void transitionToSearch() {
if (transitioning) {
return;
}
if (supportsTransitions()) {
Transition transition = FadeOutTransition.withAction(navigateToSearchWhenDone());
TransitionManager.beginDelayedTransition(toolbar, transition);
ViewCompat.setElevation(toolbarHolder, activity.getResources().getDimensionPixelSize(R.dimen.toolbar_elevation));
expandToolbar();
viewFader.hideContentOf(toolbar);
TransitionManager.beginDelayedTransition(activityContent, new Fade(Fade.OUT));
activityContent.setVisibility(GONE);
} else {
navigator.toSearch(activity);
}
}
Aggregations