Library collapse behavior

This commit is contained in:
Chris Li 2016-10-15 10:42:38 -04:00
parent de8c036da9
commit 9f68535e21
3 changed files with 10 additions and 4 deletions

View File

@ -32,8 +32,14 @@ class LibrarySplitViewController: UISplitViewController, UISplitViewControllerDe
// MARK: - UISplitViewControllerDelegate // MARK: - UISplitViewControllerDelegate
func splitViewController(splitViewController: UISplitViewController, collapseSecondaryViewController secondaryViewController: UIViewController, ontoPrimaryViewController primaryViewController: UIViewController) -> Bool { func splitViewController(splitViewController: UISplitViewController, collapseSecondaryViewController secondaryViewController: UIViewController, ontoPrimaryViewController primaryViewController: UIViewController) -> Bool {
guard !isShowingLangFilter else {return false} let secondaryTopController = (secondaryViewController as? UINavigationController)?.topViewController
return true if let _ = secondaryTopController as? LanguageFilterController {
return false
} else if (secondaryTopController as? BookDetailController)?.book != nil {
return false
} else {
return true
}
} }
var isShowingLangFilter: Bool { var isShowingLangFilter: Bool {

View File

@ -49,7 +49,7 @@
</dict> </dict>
</array> </array>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>1.8.1747</string> <string>1.8.1768</string>
<key>ITSAppUsesNonExemptEncryption</key> <key>ITSAppUsesNonExemptEncryption</key>
<false/> <false/>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>

View File

@ -21,7 +21,7 @@
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>1.8.1747</string> <string>1.8.1768</string>
<key>NSExtension</key> <key>NSExtension</key>
<dict> <dict>
<key>NSExtensionMainStoryboard</key> <key>NSExtensionMainStoryboard</key>