本文整理了Java中android.support.v7.widget.CardView.getHeight()
方法的一些代码示例,展示了CardView.getHeight()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。CardView.getHeight()
方法的具体详情如下:
包路径:android.support.v7.widget.CardView
类名称:CardView
方法名:getHeight
暂无
代码示例来源:origin: fanrunqi/MaterialLogin
public void animateRevealShow() {
Animator mAnimator = ViewAnimationUtils.createCircularReveal(cvAdd, cvAdd.getWidth()/2,0, fab.getWidth() / 2, cvAdd.getHeight());
mAnimator.setDuration(500);
mAnimator.setInterpolator(new AccelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
super.onAnimationEnd(animation);
}
@Override
public void onAnimationStart(Animator animation) {
cvAdd.setVisibility(View.VISIBLE);
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
代码示例来源:origin: fanrunqi/MaterialLogin
public void animateRevealClose() {
Animator mAnimator = ViewAnimationUtils.createCircularReveal(cvAdd,cvAdd.getWidth()/2,0, cvAdd.getHeight(), fab.getWidth() / 2);
mAnimator.setDuration(500);
mAnimator.setInterpolator(new AccelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
cvAdd.setVisibility(View.INVISIBLE);
super.onAnimationEnd(animation);
fab.setImageResource(R.drawable.plus);
AActivityTwo.super.onBackPressed();
}
@Override
public void onAnimationStart(Animator animation) {
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
@Override
代码示例来源:origin: qs-lll/ExpandingPager
public void open() {
ViewGroup.LayoutParams layoutParams = layout3.getLayoutParams();
layoutParams.height = (int) (front.getHeight() * SCALE_OPENED / 4 * SCALE_OPENED);
layout3.setLayoutParams(layoutParams);
ViewCompat.setPivotY(back, 0);
PropertyValuesHolder front1 = PropertyValuesHolder.ofFloat(View.TRANSLATION_Y, 0, -front.getHeight() / 4);
PropertyValuesHolder front2 = PropertyValuesHolder.ofFloat(View.SCALE_X, 1, 1);
frontAnimator = ObjectAnimator.ofPropertyValuesHolder(front, front1, front2);
PropertyValuesHolder backX = PropertyValuesHolder.ofFloat(View.SCALE_X, 1f, 1.2f);
PropertyValuesHolder backY = PropertyValuesHolder.ofFloat(View.SCALE_Y, 1f, 1.2f);
backAnimator = ObjectAnimator.ofPropertyValuesHolder(back, backX, backY);
back.setPivotY(0);
frontAnimator.start();
backAnimator.start();
front.setCardElevation(ELEVATION_OPENED);
}
代码示例来源:origin: NightscoutFoundation/xDrip
private synchronized void hideSnoozeFloater() {
if (!floaterHidden) {
animateSnoozeFloater(0, floatingsnooze.getHeight(), new AccelerateInterpolator(1.5f));
floaterHidden = true;
}
}
代码示例来源:origin: jamorham/xDrip-plus
private synchronized void hideSnoozeFloater() {
if (!floaterHidden) {
animateSnoozeFloater(0, floatingsnooze.getHeight(), new AccelerateInterpolator(1.5f));
floaterHidden = true;
}
}
代码示例来源:origin: hieuapp/android-firebase-chat
public void animateRevealShow() {
Animator mAnimator = ViewAnimationUtils.createCircularReveal(cvAdd, cvAdd.getWidth()/2,0, fab.getWidth() / 2, cvAdd.getHeight());
mAnimator.setDuration(500);
mAnimator.setInterpolator(new AccelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
super.onAnimationEnd(animation);
}
@Override
public void onAnimationStart(Animator animation) {
cvAdd.setVisibility(View.VISIBLE);
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
代码示例来源:origin: zhangke3016/TranslationCompat
public void animateRevealShow() {
Animator mAnimator = ViewAnimationCompatUtils.createCircularReveal(cvAdd, cvAdd.getWidth()/2,0, fab.getWidth() / 2, cvAdd.getHeight());
mAnimator.setDuration(300);
mAnimator.setInterpolator(new AccelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
super.onAnimationEnd(animation);
}
@Override
public void onAnimationStart(Animator animation) {
cvAdd.setVisibility(View.VISIBLE);
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
代码示例来源:origin: hieuapp/android-firebase-chat
public void animateRevealClose() {
Animator mAnimator = ViewAnimationUtils.createCircularReveal(cvAdd,cvAdd.getWidth()/2,0, cvAdd.getHeight(), fab.getWidth() / 2);
mAnimator.setDuration(500);
mAnimator.setInterpolator(new AccelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
cvAdd.setVisibility(View.INVISIBLE);
super.onAnimationEnd(animation);
fab.setImageResource(R.drawable.ic_signup);
RegisterActivity.super.onBackPressed();
}
@Override
public void onAnimationStart(Animator animation) {
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
@Override
代码示例来源:origin: lv910929/RxDemo
public void animateRevealShow() {
Animator mAnimator = null;
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.LOLLIPOP) {
mAnimator = ViewAnimationUtils.createCircularReveal(cardViewRegister, cardViewRegister.getWidth() / 2, 0, floatButtonExit.getWidth() / 2, cardViewRegister.getHeight());
}
mAnimator.setDuration(500);
mAnimator.setInterpolator(new AccelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
super.onAnimationEnd(animation);
}
@Override
public void onAnimationStart(Animator animation) {
cardViewRegister.setVisibility(View.VISIBLE);
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
代码示例来源:origin: zhangke3016/TranslationCompat
public void animateRevealClose() {
Animator mAnimator = ViewAnimationCompatUtils.createCircularReveal(cvAdd,cvAdd.getWidth()/2,0, cvAdd.getHeight(), fab.getWidth() / 2);
mAnimator.setDuration(300);
mAnimator.setInterpolator(new AccelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
cvAdd.setVisibility(View.INVISIBLE);
super.onAnimationEnd(animation);
fab.setImageResource(R.drawable.plus);
// RegisterActivity.super.onBackPressed();
TransitionController.getInstance().exitActivity(RegisterActivity.this);
}
@Override
public void onAnimationStart(Animator animation) {
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
@Override
代码示例来源:origin: lv910929/RxDemo
public void animateRevealClose() {
Animator mAnimator = null;
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.LOLLIPOP) {
mAnimator = ViewAnimationUtils.createCircularReveal(cardViewRegister, cardViewRegister.getWidth() / 2, 0, cardViewRegister.getHeight(), floatButtonExit.getWidth() / 2);
mAnimator.setDuration(500);
mAnimator.setInterpolator(new AccelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
cardViewRegister.setVisibility(View.INVISIBLE);
super.onAnimationEnd(animation);
floatButtonExit.setImageResource(R.drawable.plus);
RegisterActivity.super.onBackPressed();
}
@Override
public void onAnimationStart(Animator animation) {
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
}
代码示例来源:origin: freedom10086/Ruisi
searchCard.getWidth(),
0,
(float) Math.hypot(searchCard.getWidth(), searchCard.getHeight()),
0);
代码示例来源:origin: freedom10086/Ruisi
private void hideSearchView() {
animator = ViewAnimationUtils.createCircularReveal(
searchCard,
searchCard.getWidth(),
0,
(float) Math.hypot(searchCard.getWidth(), searchCard.getHeight()),
0);
animator.setInterpolator(new DecelerateInterpolator());
animator.setDuration(260);
animator.addListener(new Animator.AnimatorListener() {
@Override
public void onAnimationStart(Animator animator) {
}
@Override
public void onAnimationEnd(Animator animator) {
searchCard.setVisibility(View.GONE);
}
@Override
public void onAnimationCancel(Animator animator) {
}
@Override
public void onAnimationRepeat(Animator animator) {
}
});
animator.start();
}
代码示例来源:origin: NightscoutFoundation/xDrip
private synchronized void showSnoozeFloater() {
if (floaterHidden) {
animateSnoozeFloater(floatingsnooze.getHeight(), 0, new DecelerateInterpolator(1.5f));
floaterHidden = false;
floatingsnooze.setVisibility(View.VISIBLE);
showcase(this, SHOWCASE_REMINDER3);
}
hideKeyboard(recyclerView);
}
代码示例来源:origin: jamorham/xDrip-plus
private synchronized void showSnoozeFloater() {
if (floaterHidden) {
animateSnoozeFloater(floatingsnooze.getHeight(), 0, new DecelerateInterpolator(1.5f));
floaterHidden = false;
floatingsnooze.setVisibility(View.VISIBLE);
showcase(this, SHOWCASE_REMINDER3);
}
hideKeyboard(recyclerView);
}
代码示例来源:origin: freedom10086/Ruisi
private void showSearchView() {
searchCard.setVisibility(View.VISIBLE);
animator = ViewAnimationUtils.createCircularReveal(
searchCard,
searchCard.getWidth(),
0,
0,
(float) Math.hypot(searchCard.getWidth(), searchCard.getHeight()));
animator.setInterpolator(new AccelerateInterpolator());
animator.setDuration(260);
animator.addListener(new Animator.AnimatorListener() {
@Override
public void onAnimationStart(Animator animator) {
}
@Override
public void onAnimationEnd(Animator animator) {
KeyboardUtil.showKeyboard(searchInput);
}
@Override
public void onAnimationCancel(Animator animator) {
}
@Override
public void onAnimationRepeat(Animator animator) {
}
});
animator.start();
}
代码示例来源:origin: freedom10086/Ruisi
private void show_search_view() {
searchCard.setVisibility(View.VISIBLE);
animator = ViewAnimationUtils.createCircularReveal(
searchCard,
searchCard.getWidth(),
0,
0,
(float) Math.hypot(searchCard.getWidth(), searchCard.getHeight()));
animator.setInterpolator(new AccelerateInterpolator());
animator.setDuration(260);
animator.start();
animator.addListener(new Animator.AnimatorListener() {
@Override
public void onAnimationStart(Animator animator) {
}
@Override
public void onAnimationEnd(Animator animator) {
KeyboardUtil.showKeyboard(searchInput);
}
@Override
public void onAnimationCancel(Animator animator) {
}
@Override
public void onAnimationRepeat(Animator animator) {
}
});
}
代码示例来源:origin: zhangke3016/TranslationCompat
@Override
public void onTransitionEnd(Animator animator) {
getSupportActionBar().show();
mFloatingActionButton.animate().setDuration(300).scaleX(1).scaleY(1);
Animator mAnimator = ViewAnimationCompatUtils.createRectReveal( cardview, 0, cardview.getHeight(),ViewAnimationCompatUtils.RECT_TOP);
mAnimator.setDuration(500);
mAnimator.setInterpolator(new AccelerateDecelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
super.onAnimationEnd(animation);
}
@Override
public void onAnimationStart(Animator animation) {
nsv.setVisibility(View.VISIBLE);
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
代码示例来源:origin: zhangke3016/TranslationCompat
@Override
public void onTransitionEnd(Animator animator) {
getSupportActionBar().show();
mFloatingActionButton.animate().setDuration(300).scaleX(1).scaleY(1);
//ObjectAnimator mAnimator = ObjectAnimator.ofFloat(nsv,"translationY",nsv.getHeight(),0);
Animator mAnimator = ViewAnimationCompatUtils.createCircularReveal( cardview, 0, 0, cardview.getWidth() / 2, cardview.getHeight());
mAnimator.setDuration(500);
mAnimator.setInterpolator(new AccelerateDecelerateInterpolator());
mAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
super.onAnimationEnd(animation);
}
@Override
public void onAnimationStart(Animator animation) {
nsv.setVisibility(View.VISIBLE);
super.onAnimationStart(animation);
}
});
mAnimator.start();
}
代码示例来源:origin: Jerey-Jobs/KeepGank
dip2px(context, 23),
(float) Math.hypot(search.getWidth(), search.getHeight()),
0);
animatorHide.addListener(new Animator.AnimatorListener() {
内容来源于网络,如有侵权,请联系作者删除!