本文整理汇总了Java中android.app.ActivityOptions.makeThumbnailScaleUpAnimation方法的典型用法代码示例。如果您正苦于以下问题:Java ActivityOptions.makeThumbnailScaleUpAnimation方法的具体用法?Java ActivityOptions.makeThumbnailScaleUpAnimation怎么用?Java ActivityOptions.makeThumbnailScaleUpAnimation使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类android.app.ActivityOptions
的用法示例。
在下文中一共展示了ActivityOptions.makeThumbnailScaleUpAnimation方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: imgSharedElementTransition
import android.app.ActivityOptions; //导入方法依赖的package包/类
public void imgSharedElementTransition(View view) {
Intent intent = new Intent(this, ImageSharedTransitionActivity.class);
ActivityOptions options = ActivityOptions.makeSceneTransitionAnimation(this, findViewById(R.id.img_shared), "img");
ActivityOptions options2 = ActivityOptions.makeScaleUpAnimation(view, view.getWidth() / 2, view.getHeight() / 2, 0, 0);
ActivityOptions options3 = ActivityOptions.makeSceneTransitionAnimation(this);
ActivityOptions options4 = ActivityOptions.makeThumbnailScaleUpAnimation(view, BitmapFactory.decodeResource(getResources(), R.mipmap.pic), view.getWidth() / 2, view.getHeight() / 2);
startActivity(intent, options.toBundle());
// overridePendingTransition(0, 0);
}
示例2: makeThumbnailScaleUpAnimation
import android.app.ActivityOptions; //导入方法依赖的package包/类
public static ActivityOptionsCompatJB makeThumbnailScaleUpAnimation(View source, Bitmap thumbnail, int startX, int startY) {
return new ActivityOptionsCompatJB(ActivityOptions.makeThumbnailScaleUpAnimation(source, thumbnail, startX, startY));
}