Skip to content

Commit

Permalink
Update to use color literals
Browse files Browse the repository at this point in the history
  • Loading branch information
jerkoch committed Feb 6, 2017
1 parent 7af9f4f commit 720e8ec
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Example/MailExample/MailViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ extension MailViewController: SwipeTableViewCellDelegate {
return [read]
} else {
let flag = SwipeAction(style: .default, title: "Flag", handler: nil)
flag.backgroundColor = UIColor(colorLiteralRed: 1, green: 148/255, blue: 0, alpha: 1)
flag.backgroundColor = #colorLiteral(red: 1, green: 0.5803921569, blue: 0, alpha: 1)
flag.hidesWhenSelected = true
flag.image = #imageLiteral(resourceName: "Flag")

Expand Down
2 changes: 1 addition & 1 deletion Source/SwipeActionsView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ class SwipeActionsView: UIView {

clipsToBounds = true
translatesAutoresizingMaskIntoConstraints = false
backgroundColor = options.backgroundColor ?? UIColor(colorLiteralRed: 220/255, green: 220/255, blue: 220/255, alpha: 1)
backgroundColor = options.backgroundColor ?? #colorLiteral(red: 0.862745098, green: 0.862745098, blue: 0.862745098, alpha: 1)

addButtons(for: self.actions, withMaximum: maxSize)
}
Expand Down

0 comments on commit 720e8ec

Please sign in to comment.