Skip to content

Commit 5c37994

Browse files
committed
Cosmetic
1 parent d98f34d commit 5c37994

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

  • chartLib/src/main/kotlin/info/appdev/charting/charts

chartLib/src/main/kotlin/info/appdev/charting/charts/Chart.kt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -549,15 +549,14 @@ abstract class Chart<T : ChartData<out IDataSet<out Entry>>> : ViewGroup, IBaseP
549549

550550
setLastHighlighted(this.highlighted)
551551

552-
if (callListener && mSelectionListener != null) {
552+
mSelectionListener?.let { listener ->
553553
if (!valuesToHighlight()) {
554-
mSelectionListener!!.onNothingSelected()
554+
listener.onNothingSelected()
555555
} else {
556556
// notify the listener
557-
mSelectionListener!!.onValueSelected(entry!!, high!!)
557+
listener.onValueSelected(entry!!, high!!)
558558
}
559559
}
560-
561560
// redraw the chart
562561
invalidate()
563562
}

0 commit comments

Comments
 (0)