From fa6196303523461f1f68f23918415d31cc8aeda5 Mon Sep 17 00:00:00 2001 From: philackm Date: Thu, 6 Jul 2017 17:01:33 +1000 Subject: [PATCH] Move settings enums to appropriate files --- Classes/Plots/DotPlot.swift | 6 ++++ Classes/Plots/LinePlot.swift | 15 ++++++++++ Classes/Plots/Plot.swift | 6 +++- Classes/Reference/ReferenceLines.swift | 13 ++++++++- Classes/ScrollableGraphView.swift | 38 -------------------------- 5 files changed, 38 insertions(+), 40 deletions(-) diff --git a/Classes/Plots/DotPlot.swift b/Classes/Plots/DotPlot.swift index 9f2f8e5..45a0b38 100644 --- a/Classes/Plots/DotPlot.swift +++ b/Classes/Plots/DotPlot.swift @@ -41,3 +41,9 @@ open class DotPlot : Plot { dataPointLayer?.owner = self } } + +@objc public enum ScrollableGraphViewDataPointType : Int { + case circle + case square + case custom +} diff --git a/Classes/Plots/LinePlot.swift b/Classes/Plots/LinePlot.swift index 3427e6e..9aa4abd 100644 --- a/Classes/Plots/LinePlot.swift +++ b/Classes/Plots/LinePlot.swift @@ -116,3 +116,18 @@ open class LinePlot : Plot { gradientLayer?.owner = self } } + +@objc public enum ScrollableGraphViewLineStyle : Int { + case straight + case smooth +} + +@objc public enum ScrollableGraphViewFillType : Int { + case solid + case gradient +} + +@objc public enum ScrollableGraphViewGradientType : Int { + case linear + case radial +} diff --git a/Classes/Plots/Plot.swift b/Classes/Plots/Plot.swift index a1c5d46..22c19df 100644 --- a/Classes/Plots/Plot.swift +++ b/Classes/Plots/Plot.swift @@ -221,7 +221,11 @@ open class Plot { } } - +@objc public enum ScrollableGraphViewAnimationType : Int { + case easeOut + case elastic + case custom +} diff --git a/Classes/Reference/ReferenceLines.swift b/Classes/Reference/ReferenceLines.swift index 6dedcf5..f0e2cc8 100644 --- a/Classes/Reference/ReferenceLines.swift +++ b/Classes/Reference/ReferenceLines.swift @@ -69,7 +69,18 @@ open class ReferenceLines { @IBInspectable open var dataPointLabelsSparsity: Int = 1 } -public enum ReferenceLinePositioningType { + +@objc public enum ScrollableGraphViewReferenceLinePosition : Int { + case left + case right + case both +} + +@objc public enum ReferenceLinePositioningType : Int { case relative case absolute } + +@objc public enum ScrollableGraphViewReferenceLineType : Int { + case cover +} diff --git a/Classes/ScrollableGraphView.swift b/Classes/ScrollableGraphView.swift index 92dd463..09ba118 100644 --- a/Classes/ScrollableGraphView.swift +++ b/Classes/ScrollableGraphView.swift @@ -925,44 +925,6 @@ import UIKit // MARK: - ScrollableGraphView Settings Enums // ########################################## -@objc public enum ScrollableGraphViewLineStyle : Int { - case straight - case smooth -} - -@objc public enum ScrollableGraphViewFillType : Int { - case solid - case gradient -} - -@objc public enum ScrollableGraphViewGradientType : Int { - case linear - case radial -} - -@objc public enum ScrollableGraphViewDataPointType : Int { - case circle - case square - case custom -} - -@objc public enum ScrollableGraphViewReferenceLinePosition : Int { - case left - case right - case both -} - -@objc public enum ScrollableGraphViewReferenceLineType : Int { - case cover - //case Edge // FUTURE: Implement -} - -@objc public enum ScrollableGraphViewAnimationType : Int { - case easeOut - case elastic - case custom -} - @objc public enum ScrollableGraphViewDirection : Int { case leftToRight case rightToLeft