Skip to content

Commit

Permalink
Modify:fix RoundImageView 描边相关 bug
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaofeidev committed Jul 8, 2020
1 parent a7c77fe commit cc5eb4b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,6 @@ dependencies {
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'

// implementation project(":lib_round")
implementation 'com.github.xiaofeidev:round:1.0.0'
implementation project(":lib_round")
// implementation 'com.github.xiaofeidev:round:1.0.0'
}
2 changes: 1 addition & 1 deletion app/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@
app:layout_constraintDimensionRatio="1"
android:layout_marginStart="10dp"
android:layout_marginEnd="5dp"
app:rd_radius="10dp"
app:rd_radius="20dp"
app:rd_stroke_width="4dp"
app:rd_stroke_color="@android:color/black"
android:scaleType="fitXY"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -258,35 +258,35 @@ public void fillRadius() {
@Override
public void setRadius(float radius) {
mRoundStatus.setRadius(radius);
mRoundStatusStroke.setRadius(radius);
initStroke();
update();
}

@Override
public void setTopLeftRadius(float topLeftRadius) {
mRoundStatus.setTopLeftRadius(topLeftRadius);
mRoundStatusStroke.setTopLeftRadius(topLeftRadius);
initStroke();
update();
}

@Override
public void setTopRightRadius(float topRightRadius) {
mRoundStatus.setTopRightRadius(topRightRadius);
mRoundStatusStroke.setTopRightRadius(topRightRadius);
initStroke();
update();
}

@Override
public void setBottomRightRadius(float bottomRightRadius) {
mRoundStatus.setBottomRightRadius(bottomRightRadius);
mRoundStatusStroke.setBottomRightRadius(bottomRightRadius);
initStroke();
update();
}

@Override
public void setBottomLeftRadius(float bottomLeftRadius) {
mRoundStatus.setBottomLeftRadius(bottomLeftRadius);
mRoundStatusStroke.setBottomLeftRadius(bottomLeftRadius);
initStroke();
update();
}

Expand Down

0 comments on commit cc5eb4b

Please sign in to comment.