Skip to content

Commit

Permalink
Convert To Swift 2.0, Fucking Waterfall
Browse files Browse the repository at this point in the history
  • Loading branch information
liushuaikobe committed Sep 27, 2015
1 parent 7af5ac5 commit 22e2019
Show file tree
Hide file tree
Showing 12 changed files with 117 additions and 517 deletions.
4 changes: 2 additions & 2 deletions Cartfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
github "onevcat/Kingfisher" == 1.4.5
github "Alamofire/Alamofire" == 1.3.1
github "onevcat/Kingfisher" >= 1.6
github "Alamofire/Alamofire" ~> 2.0
4 changes: 2 additions & 2 deletions Cartfile.resolved
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
github "Alamofire/Alamofire" "1.3.1"
github "onevcat/Kingfisher" "1.4.5"
github "Alamofire/Alamofire" "2.0.2"
github "onevcat/Kingfisher" "1.6.0"
4 changes: 2 additions & 2 deletions beauties/BeautyCollectionViewCell.swift
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class BeautyCollectionViewCell: UICollectionViewCell {
commonInit()
}

required init(coder aDecoder: NSCoder) {
required init?(coder aDecoder: NSCoder) {
imageView = UIImageView()
super.init(coder: aDecoder)
commonInit()
Expand All @@ -41,7 +41,7 @@ class BeautyCollectionViewCell: UICollectionViewCell {

self.imageView.clipsToBounds = true
self.imageView.frame = self.bounds
self.imageView.autoresizingMask = .FlexibleWidth | .FlexibleHeight
self.imageView.autoresizingMask = [.FlexibleWidth, .FlexibleHeight]
self.imageView.contentMode = .ScaleAspectFill
self.addSubview(self.imageView)
}
Expand Down
2 changes: 1 addition & 1 deletion beauties/BeautyCollectionViewFooter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class BeautyCollectionViewFooter: UICollectionReusableView {
self.commonInit()
}

required init(coder aDecoder: NSCoder) {
required init?(coder aDecoder: NSCoder) {
loadingIndicator = UIActivityIndicatorView(activityIndicatorStyle: .Gray)
super.init(coder: aDecoder)
self.commonInit()
Expand Down
2 changes: 1 addition & 1 deletion beauties/BeautyImageEntity.swift
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class BeautyImageEntity: NSObject, NSCoding {

}

required init(coder aDecoder: NSCoder) {
required init?(coder aDecoder: NSCoder) {
imageUrl = aDecoder.decodeObjectForKey("imageUrl") as? String
imageHeight = aDecoder.decodeObjectForKey("imageHeight") as? Int
imageWidth = aDecoder.decodeObjectForKey("imageWidth") as? Int
Expand Down
4 changes: 2 additions & 2 deletions beauties/BlurView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ import UIKit

extension UIView {
func applyBlurEffect() -> Void {
var blurEffect = UIBlurEffect(style: .Light)
var visualEffectView = UIVisualEffectView(effect: blurEffect)
let blurEffect = UIBlurEffect(style: .Light)
let visualEffectView = UIVisualEffectView(effect: blurEffect)
visualEffectView.frame = self.bounds
self.addSubview(visualEffectView)
}
Expand Down
Loading

0 comments on commit 22e2019

Please sign in to comment.