diff --git a/ticketview/src/main/java/com/vipulasri/ticketview/TicketView.java b/ticketview/src/main/java/com/vipulasri/ticketview/TicketView.java index 79812c9..c43a5e6 100644 --- a/ticketview/src/main/java/com/vipulasri/ticketview/TicketView.java +++ b/ticketview/src/main/java/com/vipulasri/ticketview/TicketView.java @@ -115,18 +115,19 @@ protected void onDraw(Canvas canvas) { } canvas.drawPath(mPath, mBackgroundPaint); canvas.clipPath(mPath); - if (mShowBorder) { - canvas.drawPath(mPath, mBorderPaint); - } - if (mShowDivider) { - canvas.drawLine(mDividerStartX, mDividerStartY, mDividerStopX, mDividerStopY, mDividerPaint); - } + if (mBackgroundAfterDivider != null) { setTicketBackgroundAfterDivider(canvas); } if (mBackgroundBeforeDivider != null) { setTicketBackgroundBeforeDivider(canvas); } + if (mShowBorder) { + canvas.drawPath(mPath, mBorderPaint); + } + if (mShowDivider) { + canvas.drawLine(mDividerStartX, mDividerStartY, mDividerStopX, mDividerStopY, mDividerPaint); + } } private void doLayout() {