本文整理了Java中android.widget.ImageView.setClipToOutline()
方法的一些代码示例,展示了ImageView.setClipToOutline()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ImageView.setClipToOutline()
方法的具体详情如下:
包路径:android.widget.ImageView
类名称:ImageView
方法名:setClipToOutline
暂无
代码示例来源:origin: rockon999/LeanbackLauncher
public void clearBannerState() {
super.clearBannerState();
if (this.mBannerView != null) {
this.mBannerView.setClipToOutline(true);
}
}
}
代码示例来源:origin: MoMoWait/LeanbackLauncher
public void clearBannerState() {
super.clearBannerState();
if (this.mBannerView != null) {
this.mBannerView.setClipToOutline(true);
}
}
}
代码示例来源:origin: tyhjh/JinyunEffect
private void initView() {
jinyunView = findViewById(R.id.sv_bg);
iv_bg = findViewById(R.id.iv_bg);
ivShowPic = findViewById(R.id.ivShowPic);
Glide.with(MainActivity.this).asBitmap().addListener(new RequestListener<Bitmap>() {
@Override
public boolean onLoadFailed(@Nullable GlideException e, Object model, Target<Bitmap> target, boolean isFirstResource) {
return false;
}
@Override
public boolean onResourceReady(Bitmap resource, Object model, Target<Bitmap> target, DataSource dataSource, boolean isFirstResource) {
jinyunView.setmPaintColor(ImageUtil.getColor(resource, 3).getRgb());
return false;
}
}).load(R.mipmap.ic_show).into(ivShowPic);
ivShowPic.setClipToOutline(true);
ivShowPic.setOutlineProvider(ImageUtil.getOutline(true, 20, 1));
objectAnimator = ObjectAnimator.ofFloat(ivShowPic, "rotation", 0f, 360f);
objectAnimator.setDuration(20 * 1000);
objectAnimator.setRepeatMode(ValueAnimator.RESTART);
objectAnimator.setInterpolator(new LinearInterpolator());
objectAnimator.setRepeatCount(-1);
objectAnimator.start();
}
代码示例来源:origin: MoMoWait/LeanbackLauncher
protected void onFinishInflate() {
super.onFinishInflate();
this.mUninstallCircle = (ImageView) findViewById(R.id.uninstall_area_circle);
this.mUninstallIconCircle = (ImageView) findViewById(R.id.uninstall_icon_circle);
this.mUninstallIcon = (ImageView) findViewById(R.id.uninstall_icon);
this.mUninstallText = (TextView) findViewById(R.id.uninstall_text);
this.mFinishButton = (Button) findViewById(R.id.finish_button);
this.mUninstallApp = (ImageView) findViewById(R.id.uninstall_app_banner);
this.mFocusAnimator = new ViewFocusAnimator(this.mUninstallApp);
this.mFocusAnimator.setFocusImmediate(true);
float zDeltaIcon = (float) getResources().getDimensionPixelOffset(R.dimen.edit_uninstall_icon_z);
this.mUninstallApp.setZ((float) getResources().getDimensionPixelOffset(R.dimen.edit_app_banner_z));
this.mUninstallIconCircle.setZ(zDeltaIcon);
this.mUninstallIcon.setZ(zDeltaIcon);
this.mUninstallApp.setClipToOutline(true);
this.mFinishButton.setOnClickListener(this);
this.mUninstallText.setImportantForAccessibility(2);
setUninstallCircleLayout();
setUninstallIconCircleLayout();
setUninstallTextLayout();
this.mUninstallAnimation = new EditModeUninstallAnimationHolder(this);
}
代码示例来源:origin: rockon999/LeanbackLauncher
protected void onFinishInflate() {
super.onFinishInflate();
this.mUninstallCircle = (ImageView) findViewById(R.id.uninstall_area_circle);
this.mUninstallIconCircle = (ImageView) findViewById(R.id.uninstall_icon_circle);
this.mUninstallIcon = (ImageView) findViewById(R.id.uninstall_icon);
this.mUninstallText = (TextView) findViewById(R.id.uninstall_text);
this.mFinishButton = (Button) findViewById(R.id.finish_button);
this.mUninstallApp = (ImageView) findViewById(R.id.uninstall_app_banner);
this.mFocusAnimator = new ViewFocusAnimator(this.mUninstallApp);
this.mFocusAnimator.setFocusImmediate(true);
float zDeltaIcon = (float) getResources().getDimensionPixelOffset(R.dimen.edit_uninstall_icon_z);
this.mUninstallApp.setZ((float) getResources().getDimensionPixelOffset(R.dimen.edit_app_banner_z));
this.mUninstallIconCircle.setZ(zDeltaIcon);
this.mUninstallIcon.setZ(zDeltaIcon);
this.mUninstallApp.setClipToOutline(true);
this.mFinishButton.setOnClickListener(this);
this.mUninstallText.setImportantForAccessibility(2);
setUninstallCircleLayout();
setUninstallIconCircleLayout();
setUninstallTextLayout();
this.mUninstallAnimation = new EditModeUninstallAnimationHolder(this);
}
内容来源于网络,如有侵权,请联系作者删除!