Commit abd72e41 by Daniel Dahan

development: added prefix for PulseAnimation to MotionPulseAnimation

parent 542797fb
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
import UIKit import UIKit
open class Button: UIButton, Pulseable { open class Button: UIButton, MotionPulseable {
/** /**
A CAShapeLayer used to manage elements that would be affected by A CAShapeLayer used to manage elements that would be affected by
the clipToBounds property of the backing layer. For example, this the clipToBounds property of the backing layer. For example, this
...@@ -42,8 +42,8 @@ open class Button: UIButton, Pulseable { ...@@ -42,8 +42,8 @@ open class Button: UIButton, Pulseable {
/// A Pulse reference. /// A Pulse reference.
fileprivate var pulse: MotionPulse! fileprivate var pulse: MotionPulse!
/// PulseAnimation value. /// MotionPulseAnimation value.
open var pulseAnimation: PulseAnimation { open var pulseAnimation: MotionPulseAnimation {
get { get {
return pulse.animation return pulse.animation
} }
...@@ -52,7 +52,7 @@ open class Button: UIButton, Pulseable { ...@@ -52,7 +52,7 @@ open class Button: UIButton, Pulseable {
} }
} }
/// PulseAnimation color. /// MotionPulseAnimation color.
@IBInspectable @IBInspectable
open var pulseColor: UIColor { open var pulseColor: UIColor {
get { get {
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
import UIKit import UIKit
@objc(CollectionReusableView) @objc(CollectionReusableView)
open class CollectionReusableView: UICollectionReusableView, Pulseable { open class CollectionReusableView: UICollectionReusableView, MotionPulseable {
/** /**
A CAShapeLayer used to manage elements that would be affected by A CAShapeLayer used to manage elements that would be affected by
the clipToBounds property of the backing layer. For example, this the clipToBounds property of the backing layer. For example, this
...@@ -43,8 +43,8 @@ open class CollectionReusableView: UICollectionReusableView, Pulseable { ...@@ -43,8 +43,8 @@ open class CollectionReusableView: UICollectionReusableView, Pulseable {
/// A Pulse reference. /// A Pulse reference.
fileprivate var pulse: MotionPulse! fileprivate var pulse: MotionPulse!
/// PulseAnimation value. /// MotionPulseAnimation value.
open var pulseAnimation: PulseAnimation { open var pulseAnimation: MotionPulseAnimation {
get { get {
return pulse.animation return pulse.animation
} }
...@@ -53,7 +53,7 @@ open class CollectionReusableView: UICollectionReusableView, Pulseable { ...@@ -53,7 +53,7 @@ open class CollectionReusableView: UICollectionReusableView, Pulseable {
} }
} }
/// PulseAnimation color. /// MotionPulseAnimation color.
@IBInspectable @IBInspectable
open var pulseColor: UIColor { open var pulseColor: UIColor {
get { get {
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
import UIKit import UIKit
@objc(CollectionViewCell) @objc(CollectionViewCell)
open class CollectionViewCell: UICollectionViewCell, Pulseable { open class CollectionViewCell: UICollectionViewCell, MotionPulseable {
/** /**
A CAShapeLayer used to manage elements that would be affected by A CAShapeLayer used to manage elements that would be affected by
the clipToBounds property of the backing layer. For example, this the clipToBounds property of the backing layer. For example, this
...@@ -43,8 +43,8 @@ open class CollectionViewCell: UICollectionViewCell, Pulseable { ...@@ -43,8 +43,8 @@ open class CollectionViewCell: UICollectionViewCell, Pulseable {
/// A Pulse reference. /// A Pulse reference.
fileprivate var pulse: MotionPulse! fileprivate var pulse: MotionPulse!
/// PulseAnimation value. /// MotionPulseAnimation value.
open var pulseAnimation: PulseAnimation { open var pulseAnimation: MotionPulseAnimation {
get { get {
return pulse.animation return pulse.animation
} }
...@@ -53,7 +53,7 @@ open class CollectionViewCell: UICollectionViewCell, Pulseable { ...@@ -53,7 +53,7 @@ open class CollectionViewCell: UICollectionViewCell, Pulseable {
} }
} }
/// PulseAnimation color. /// MotionPulseAnimation color.
@IBInspectable @IBInspectable
open var pulseColor: UIColor { open var pulseColor: UIColor {
get { get {
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
import UIKit import UIKit
@objc(menu) @objc(menu)
open class Menu: View, Springable { open class Menu: View, MotionSpringable {
internal let spring = Spring() internal let spring = Spring()
open var views: [UIView] { open var views: [UIView] {
......
...@@ -30,8 +30,8 @@ ...@@ -30,8 +30,8 @@
import UIKit import UIKit
@objc(PulseAnimation) @objc(MotionPulseAnimation)
public enum PulseAnimation: Int { public enum MotionPulseAnimation: Int {
case none case none
case center case center
case centerWithBacking case centerWithBacking
...@@ -42,9 +42,9 @@ public enum PulseAnimation: Int { ...@@ -42,9 +42,9 @@ public enum PulseAnimation: Int {
case pointWithBacking case pointWithBacking
} }
public protocol Pulseable { public protocol MotionPulseable {
/// A reference to the PulseAnimation. /// A reference to the MotionPulseAnimation.
var pulseAnimation: PulseAnimation { get set } var pulseAnimation: MotionPulseAnimation { get set }
/// A UIColor. /// A UIColor.
var pulseColor: UIColor { get set } var pulseColor: UIColor { get set }
...@@ -54,7 +54,7 @@ public protocol Pulseable { ...@@ -54,7 +54,7 @@ public protocol Pulseable {
} }
public struct MotionPulse { public struct MotionPulse {
/// A UIView that is Pulseable. /// A UIView that is MotionPulseable.
fileprivate weak var pulseView: UIView? fileprivate weak var pulseView: UIView?
/// The layer the pulse layers are added to. /// The layer the pulse layers are added to.
...@@ -63,8 +63,8 @@ public struct MotionPulse { ...@@ -63,8 +63,8 @@ public struct MotionPulse {
/// Pulse layers. /// Pulse layers.
fileprivate var layers = [CAShapeLayer]() fileprivate var layers = [CAShapeLayer]()
/// A reference to the PulseAnimation. /// A reference to the MotionPulseAnimation.
public var animation = MotionPulseAnimation.pointWithBacking public var animation = MotionMotionPulseAnimation.pointWithBacking
/// A UIColor. /// A UIColor.
public var color = Color.grey.base public var color = Color.grey.base
......
...@@ -30,22 +30,22 @@ ...@@ -30,22 +30,22 @@
import UIKit import UIKit
@objc(SpringDirection) @objc(MotionSpringDirection)
public enum SpringDirection: Int { public enum MotionSpringDirection: Int {
case up case up
case down case down
case left case left
case right case right
} }
public protocol Springable { public protocol MotionSpringable {
/// A SpringDirection value. /// A MotionSpringDirection value.
var springDirection: SpringDirection { get set } var springDirection: MotionSpringDirection { get set }
} }
open class MotionSpring { open class MotionSpring {
/// A SpringDirection value. /// A MotionSpringDirection value.
open var direction = SpringDirection.up open var direction = MotionSpringDirection.up
/// A Boolean that indicates if the menu is open or not. /// A Boolean that indicates if the menu is open or not.
open internal(set) var isOpened = false open internal(set) var isOpened = false
......
...@@ -30,12 +30,12 @@ ...@@ -30,12 +30,12 @@
import UIKit import UIKit
open class PulseView: View, Pulseable { open class PulseView: View, MotionPulseable {
/// A Pulse reference. /// A Pulse reference.
fileprivate var pulse: MotionPulse! fileprivate var pulse: MotionPulse!
/// PulseAnimation value. /// MotionPulseAnimation value.
open var pulseAnimation: PulseAnimation { open var pulseAnimation: MotionPulseAnimation {
get { get {
return pulse.animation return pulse.animation
} }
...@@ -44,7 +44,7 @@ open class PulseView: View, Pulseable { ...@@ -44,7 +44,7 @@ open class PulseView: View, Pulseable {
} }
} }
/// PulseAnimation color. /// MotionPulseAnimation color.
@IBInspectable @IBInspectable
open var pulseColor: UIColor { open var pulseColor: UIColor {
get { get {
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
import UIKit import UIKit
open class TableViewCell: UITableViewCell, Pulseable { open class TableViewCell: UITableViewCell, MotionPulseable {
/** /**
A CAShapeLayer used to manage elements that would be affected by A CAShapeLayer used to manage elements that would be affected by
the clipToBounds property of the backing layer. For example, this the clipToBounds property of the backing layer. For example, this
...@@ -42,8 +42,8 @@ open class TableViewCell: UITableViewCell, Pulseable { ...@@ -42,8 +42,8 @@ open class TableViewCell: UITableViewCell, Pulseable {
/// A Pulse reference. /// A Pulse reference.
fileprivate var pulse: MotionPulse! fileprivate var pulse: MotionPulse!
/// PulseAnimation value. /// MotionPulseAnimation value.
open var pulseAnimation: PulseAnimation { open var pulseAnimation: MotionPulseAnimation {
get { get {
return pulse.animation return pulse.animation
} }
...@@ -52,7 +52,7 @@ open class TableViewCell: UITableViewCell, Pulseable { ...@@ -52,7 +52,7 @@ open class TableViewCell: UITableViewCell, Pulseable {
} }
} }
/// PulseAnimation color. /// MotionPulseAnimation color.
@IBInspectable @IBInspectable
open var pulseColor: UIColor { open var pulseColor: UIColor {
get { get {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment