Skip to content

Commit

Permalink
Fix #93; set minimum size of slider bitmap
Browse files Browse the repository at this point in the history
  • Loading branch information
QuadFlask committed Nov 7, 2019
1 parent 8b90d0f commit 2f51275
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ protected void createBitmaps() {
height = getHeight();
}

bar = Bitmap.createBitmap(width - barOffsetX * 2, barHeight, Bitmap.Config.ARGB_8888);
bar = Bitmap.createBitmap(Math.max(width - barOffsetX * 2, 1), barHeight, Bitmap.Config.ARGB_8888);
barCanvas = new Canvas(bar);

if (bitmap == null || bitmap.getWidth() != width || bitmap.getHeight() != height) {
Expand Down

0 comments on commit 2f51275

Please sign in to comment.