From 43d0d0c8894ca81720150acc242fa7336b5e6106 Mon Sep 17 00:00:00 2001 From: Maurice Parker Date: Sat, 3 Aug 2019 13:24:51 -0500 Subject: [PATCH] Reformat statement --- iOS/AppCoordinator.swift | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/iOS/AppCoordinator.swift b/iOS/AppCoordinator.swift index 687f594d5..9f6ee86d8 100644 --- a/iOS/AppCoordinator.swift +++ b/iOS/AppCoordinator.swift @@ -75,7 +75,9 @@ class AppCoordinator: NSObject, UndoableCommandRunner { } var isThreePanelMode: Bool { - return rootSplitViewController.traitCollection.userInterfaceIdiom == .pad && !rootSplitViewController.isCollapsed && rootSplitViewController.displayMode == .allVisible + return rootSplitViewController.traitCollection.userInterfaceIdiom == .pad && + !rootSplitViewController.isCollapsed && + rootSplitViewController.displayMode == .allVisible } var rootNode: Node { @@ -607,14 +609,14 @@ class AppCoordinator: NSObject, UndoableCommandRunner { extension AppCoordinator: UISplitViewControllerDelegate { - func splitViewController(_ svc: UISplitViewController, willChangeTo displayMode: UISplitViewController.DisplayMode) { - guard rootSplitViewController.traitCollection.userInterfaceIdiom == .pad && !rootSplitViewController.isCollapsed else { + func splitViewController(_ splitViewController: UISplitViewController, willChangeTo displayMode: UISplitViewController.DisplayMode) { + guard splitViewController.traitCollection.userInterfaceIdiom == .pad && !splitViewController.isCollapsed else { return } - if rootSplitViewController.displayMode != .allVisible && displayMode == .allVisible { + if splitViewController.displayMode != .allVisible && displayMode == .allVisible { transitionToThreePanelMode() } - if rootSplitViewController.displayMode == .allVisible && displayMode != .allVisible { + if splitViewController.displayMode == .allVisible && displayMode != .allVisible { transitionFromThreePanelMode() } }