Commit cd147288 by Daniel Dahan

updated MaterialGravityToString to MaterialGravityToValue

parent f868c16f
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
location = "group:Programmatic/TabBar/TabBar.xcodeproj"> location = "group:Programmatic/TabBar/TabBar.xcodeproj">
</FileRef> </FileRef>
<FileRef <FileRef
location = "group:/Users/danieldahan/Dropbox/CosmicMind/Technology/Repositories/Material/Examples/Programmatic/NavigationBar/NavigationBar.xcodeproj"> location = "group:Programmatic/NavigationBar/NavigationBar.xcodeproj">
</FileRef> </FileRef>
<FileRef <FileRef
location = "group:Programmatic/Toolbar/Toolbar.xcodeproj"> location = "group:Programmatic/Toolbar/Toolbar.xcodeproj">
......
...@@ -43,9 +43,7 @@ public enum MaterialBorder { ...@@ -43,9 +43,7 @@ public enum MaterialBorder {
case Border9 case Border9
} }
/** /// Converts the MaterialBorder enum to a CGFloat value.
:name: MaterialBorderToValue
*/
public func MaterialBorderToValue(border: MaterialBorder) -> CGFloat { public func MaterialBorderToValue(border: MaterialBorder) -> CGFloat {
switch border { switch border {
case .None: case .None:
......
...@@ -117,7 +117,7 @@ public class MaterialCollectionViewCell : UICollectionViewCell { ...@@ -117,7 +117,7 @@ public class MaterialCollectionViewCell : UICollectionViewCell {
/// A Preset for the contentsGravity property. /// A Preset for the contentsGravity property.
public var contentsGravityPreset: MaterialGravity { public var contentsGravityPreset: MaterialGravity {
didSet { didSet {
contentsGravity = MaterialGravityToString(contentsGravityPreset) contentsGravity = MaterialGravityToValue(contentsGravityPreset)
} }
} }
......
...@@ -41,9 +41,7 @@ public enum MaterialDepth { ...@@ -41,9 +41,7 @@ public enum MaterialDepth {
case Depth5 case Depth5
} }
/** /// Converts the MaterialDepth enum to a MaterialDepthType value.
:name: MaterialDepthToValue
*/
public func MaterialDepthToValue(depth: MaterialDepth) -> MaterialDepthType { public func MaterialDepthToValue(depth: MaterialDepth) -> MaterialDepthType {
switch depth { switch depth {
case .None: case .None:
......
...@@ -45,10 +45,8 @@ public enum MaterialGravity { ...@@ -45,10 +45,8 @@ public enum MaterialGravity {
case ResizeAspectFill case ResizeAspectFill
} }
/** /// Converts the MaterialGravity enum to a String value.
:name: MaterialGravityToString public func MaterialGravityToValue(gravity: MaterialGravity) -> String {
*/
public func MaterialGravityToString(gravity: MaterialGravity) -> String {
switch gravity { switch gravity {
case .Center: case .Center:
return kCAGravityCenter return kCAGravityCenter
......
...@@ -146,7 +146,7 @@ public class MaterialLayer : CAShapeLayer { ...@@ -146,7 +146,7 @@ public class MaterialLayer : CAShapeLayer {
/// A Preset for the contentsGravity property. /// A Preset for the contentsGravity property.
public var contentsGravityPreset: MaterialGravity { public var contentsGravityPreset: MaterialGravity {
didSet { didSet {
contentsGravity = MaterialGravityToString(contentsGravityPreset) contentsGravity = MaterialGravityToValue(contentsGravityPreset)
} }
} }
......
...@@ -102,7 +102,7 @@ public class MaterialView : UIView { ...@@ -102,7 +102,7 @@ public class MaterialView : UIView {
/// A Preset for the contentsGravity property. /// A Preset for the contentsGravity property.
@IBInspectable public var contentsGravityPreset: MaterialGravity { @IBInspectable public var contentsGravityPreset: MaterialGravity {
didSet { didSet {
contentsGravity = MaterialGravityToString(contentsGravityPreset) contentsGravity = MaterialGravityToValue(contentsGravityPreset)
} }
} }
......
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