From 69fd502d0f97fd27e6bcbc7e9c251b1c7d6605b2 Mon Sep 17 00:00:00 2001 From: Xuan Liu Date: Sun, 21 Jan 2018 17:17:16 +0800 Subject: [PATCH] call setNeedsDisplay() here to trigger render noDataText when chart view already rendered, if updating the chartData with nil, it will not rerender, and display the old content --- Source/Charts/Charts/ChartViewBase.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/Source/Charts/Charts/ChartViewBase.swift b/Source/Charts/Charts/ChartViewBase.swift index a45eaa2493..b1c6d503ca 100644 --- a/Source/Charts/Charts/ChartViewBase.swift +++ b/Source/Charts/Charts/ChartViewBase.swift @@ -198,6 +198,7 @@ open class ChartViewBase: NSUIView, ChartDataProvider, AnimatorDelegate guard let _data = _data else { + setNeedsDisplay() return }