修改测试问题,shouye ytuijian

This commit is contained in:
18401019693 2022-08-11 00:01:04 +08:00
parent b1b5be9976
commit 01d0def52d
2 changed files with 2 additions and 1 deletions

View File

@ -23,7 +23,7 @@ public class ClipPathCircleImage extends ImageView {
protected void onDraw(Canvas canvas) {
canvas.save();
path.reset();
path.addCircle(width / 2, height / 2, width / 2, Path.Direction.CCW);//CCW:逆时针,这里是一个简单的园,无影响
path.addCircle(width / 2, height / 2, width / 2, Path.Direction.CW);//CCW:逆时针,这里是一个简单的园,无影响
canvas.clipPath(path);
super.onDraw(canvas);
canvas.restore();

View File

@ -13,6 +13,7 @@
<com.yunbao.common.views.weight.ClipPathCircleImage
android:id="@+id/avatar"
android:layout_width="55dp"
android:scaleType="centerCrop"
android:layout_height="55dp" />
<ImageView