From aa39627b2517f35ec465d28dbf1f79aae2cf7c93 Mon Sep 17 00:00:00 2001 From: Xiaobin Chen Date: Wed, 14 Oct 2015 22:00:02 +0800 Subject: [PATCH] styling update --- Charts/Classes/Charts/BarLineChartViewBase.swift | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Charts/Classes/Charts/BarLineChartViewBase.swift b/Charts/Classes/Charts/BarLineChartViewBase.swift index 1147abf6dc..d73aed340f 100644 --- a/Charts/Classes/Charts/BarLineChartViewBase.swift +++ b/Charts/Classes/Charts/BarLineChartViewBase.swift @@ -982,11 +982,12 @@ public class BarLineChartViewBase: ChartViewBase, UIGestureRecognizerDelegate scrollView = scrollView?.superview } - //address UITableViewWrepperView bug, - //if there is two scrollview together, we pick the outer one - let scrollViewSuper = scrollView?.superview - if scrollViewSuper!.isKindOfClass(UIScrollView) { - scrollView = scrollViewSuper + // If there is two scrollview together, we pick the superview of the inner scrollview. + // In the case of UITableViewWrepperView, the superview will be UITableView + let superViewOfScrollView = scrollView?.superview + if (superViewOfScrollView!.isKindOfClass(UIScrollView)) + { + scrollView = superViewOfScrollView } var foundScrollView = scrollView as? UIScrollView