Skip to content

Commit 75a8139

Browse files
committed
Swift4.2
1 parent a445f74 commit 75a8139

File tree

65 files changed

+409
-2160
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+409
-2160
lines changed

WRNavigationBar/WRNavigationBar.swift

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ extension UINavigationBar:WRAwakeProtocol
183183

184184
var titleColor:UIColor?
185185
for attribute in originTitleTextAttributes {
186-
if attribute.key == NSAttributedStringKey.foregroundColor {
186+
if attribute.key == NSAttributedString.Key.foregroundColor {
187187
titleColor = attribute.value as? UIColor
188188
break
189189
}
@@ -194,8 +194,8 @@ extension UINavigationBar:WRAwakeProtocol
194194
return
195195
}
196196

197-
if attributes[NSAttributedStringKey.foregroundColor.rawValue] == nil {
198-
attributes.updateValue(originTitleColor, forKey: NSAttributedStringKey.foregroundColor.rawValue)
197+
if attributes[NSAttributedString.Key.foregroundColor.rawValue] == nil {
198+
attributes.updateValue(originTitleColor, forKey: NSAttributedString.Key.foregroundColor.rawValue)
199199
}
200200
wr_setTitleTextAttributes(attributes)
201201
}
@@ -237,12 +237,12 @@ extension UINavigationController: WRFatherAwakeProtocol
237237
fileprivate func setNeedsNavigationBarUpdate(titleColor: UIColor)
238238
{
239239
guard let titleTextAttributes = navigationBar.titleTextAttributes else {
240-
navigationBar.titleTextAttributes = [NSAttributedStringKey.foregroundColor:titleColor]
240+
navigationBar.titleTextAttributes = [NSAttributedString.Key.foregroundColor:titleColor]
241241
return
242242
}
243243

244244
var newTitleTextAttributes = titleTextAttributes
245-
newTitleTextAttributes.updateValue(titleColor, forKey: NSAttributedStringKey.foregroundColor)
245+
newTitleTextAttributes.updateValue(titleColor, forKey: NSAttributedString.Key.foregroundColor)
246246
navigationBar.titleTextAttributes = newTitleTextAttributes
247247
}
248248

@@ -317,7 +317,7 @@ extension UINavigationController: WRFatherAwakeProtocol
317317
var displayLink:CADisplayLink? = CADisplayLink(target: self, selector: #selector(popNeedDisplay))
318318
// UITrackingRunLoopMode: 界面跟踪 Mode,用于 ScrollView 追踪触摸滑动,保证界面滑动时不受其他 Mode 影响
319319
// NSRunLoopCommonModes contains kCFRunLoopDefaultMode and UITrackingRunLoopMode
320-
displayLink?.add(to: RunLoop.main, forMode: .commonModes)
320+
displayLink?.add(to: RunLoop.main, forMode: RunLoop.Mode.common)
321321
CATransaction.setCompletionBlock {
322322
displayLink?.invalidate()
323323
displayLink = nil
@@ -334,7 +334,7 @@ extension UINavigationController: WRFatherAwakeProtocol
334334
@objc func wr_popToRootViewControllerAnimated(_ animated: Bool) -> [UIViewController]?
335335
{
336336
var displayLink:CADisplayLink? = CADisplayLink(target: self, selector: #selector(popNeedDisplay))
337-
displayLink?.add(to: RunLoop.main, forMode: .commonModes)
337+
displayLink?.add(to: RunLoop.main, forMode: RunLoop.Mode.common)
338338
CATransaction.setCompletionBlock {
339339
displayLink?.invalidate()
340340
displayLink = nil
@@ -381,7 +381,7 @@ extension UINavigationController: WRFatherAwakeProtocol
381381
@objc func wr_pushViewController(_ viewController: UIViewController, animated: Bool)
382382
{
383383
var displayLink:CADisplayLink? = CADisplayLink(target: self, selector: #selector(pushNeedDisplay))
384-
displayLink?.add(to: RunLoop.main, forMode: .commonModes)
384+
displayLink?.add(to: RunLoop.main, forMode: RunLoop.Mode.common)
385385
CATransaction.setCompletionBlock {
386386
displayLink?.invalidate()
387387
displayLink = nil

WRNavigationBar_swift/Podfile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,4 @@ use_frameworks!
88

99
target ‘WRNavigationBar_swift’ do
1010

11-
#swift
12-
pod 'Kingfisher'
13-
1411
end

WRNavigationBar_swift/Podfile.lock

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,3 @@
1-
PODS:
2-
- Kingfisher (4.3.1)
1+
PODFILE CHECKSUM: f271f06bc2e6c032fbdc2389d1ab0d2f2eecd650
32

4-
DEPENDENCIES:
5-
- Kingfisher
6-
7-
SPEC CHECKSUMS:
8-
Kingfisher: 75541c4b62f02e1fde6f9772303de3d9ebe8f5b3
9-
10-
PODFILE CHECKSUM: eedd5593b4e862f4a6b0ebf6fd6f3f022a9f6b1d
11-
12-
COCOAPODS: 1.3.1
3+
COCOAPODS: 1.5.3

WRNavigationBar_swift/Pods/Kingfisher/LICENSE

Lines changed: 0 additions & 22 deletions
This file was deleted.

WRNavigationBar_swift/Pods/Kingfisher/README.md

Lines changed: 0 additions & 114 deletions
This file was deleted.

WRNavigationBar_swift/Pods/Manifest.lock

Lines changed: 2 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)