-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
80 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
// | ||
// BackwardCompatibility.swift | ||
// Mew | ||
// | ||
// Created by tarunon on 2018/10/01. | ||
// Copyright © 2018年 Mercari. All rights reserved. | ||
// | ||
|
||
import UIKit | ||
|
||
#if swift(>=4.2) | ||
#else | ||
|
||
extension UIViewController { | ||
func addChild(_ childViewController: UIViewController) { | ||
addChildViewController(childViewController) | ||
} | ||
|
||
func willMove(toParent newParent: UIViewController?) { | ||
willMove(toParentViewController: newParent) | ||
} | ||
|
||
func didMove(toParent newParent: UIViewController?) { | ||
didMove(toParentViewController: newParent) | ||
} | ||
|
||
func removeFromParent() { | ||
removeFromParentViewController() | ||
} | ||
} | ||
|
||
extension UICollectionView { | ||
static var elementKindSectionHeader: String { | ||
return UICollectionElementKindSectionHeader | ||
} | ||
|
||
static var elementKindSectionFooter: String { | ||
return UICollectionElementKindSectionFooter | ||
} | ||
} | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters