Skip to content

Commit

Permalink
swift 4 conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
StefanSuciu authored and Ștefan Suciu committed Apr 26, 2018
1 parent 5aadaa0 commit ae5e77f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion netfox/Core/NFX.swift
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ extension NFX {
navigationController!.navigationBar.tintColor = UIColor.NFXOrangeColor()
navigationController!.navigationBar.barTintColor = UIColor.NFXStarkWhiteColor()
#if !swift(>=4.0)
navigationController!.navigationBar.titleTextAttributes = [NSForegroundColorAttributeName: UIColor.NFXOrangeColor()]
navigationController!.navigationBar.titleTextAttributes = [NSAttributedStringKey.foregroundColor: UIColor.NFXOrangeColor()]
#else
navigationController!.navigationBar.titleTextAttributes = [NSAttributedStringKey.foregroundColor: UIColor.NFXOrangeColor()]
#endif
Expand Down
6 changes: 3 additions & 3 deletions netfox/Core/NFXGenericController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ class NFXGenericController: NFXViewController

for match in matchesBodyHeaders {
#if !swift(>=4.0)
tempMutableString.addAttribute(NSFontAttributeName, value: NFXFont.NFXFontBold(size: 14), range: match.range)
tempMutableString.addAttribute(NSForegroundColorAttributeName, value: NFXColor.NFXOrangeColor(), range: match.range)
tempMutableString.addAttribute(NSAttributedStringKey.font, value: NFXFont.NFXFontBold(size: 14), range: match.range)
tempMutableString.addAttribute(NSAttributedStringKey.foregroundColor, value: NFXColor.NFXOrangeColor(), range: match.range)
#else
tempMutableString.addAttribute(NSAttributedStringKey.font, value: NFXFont.NFXFontBold(size: 14), range: match.range)
tempMutableString.addAttribute(NSAttributedStringKey.foregroundColor, value: NFXColor.NFXOrangeColor(), range: match.range)
Expand All @@ -58,7 +58,7 @@ class NFXGenericController: NFXViewController

for match in matchesKeys {
#if !swift(>=4.0)
tempMutableString.addAttribute(NSForegroundColorAttributeName, value: NFXColor.NFXBlackColor(), range: match.range)
tempMutableString.addAttribute(NSAttributedStringKey.foregroundColor, value: NFXColor.NFXBlackColor(), range: match.range)
#else
tempMutableString.addAttribute(NSAttributedStringKey.foregroundColor, value: NFXColor.NFXBlackColor(), range: match.range)
#endif
Expand Down

0 comments on commit ae5e77f

Please sign in to comment.