mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2026-12-04 19:29:41 +00:00
Fix 5043
This commit is contained in:
2 files changed
+10
-3
No files matched your search
@@ -33,6 +33,8 @@ final class MainFeedCollectionViewController: UICollectionViewController, Undoab
|
||||
}
|
||||
}
|
||||
|
||||
private static let logger = Logger(subsystem: Bundle.main.bundleIdentifier!, category: "MainFeedCollectionViewController")
|
||||
|
||||
private let keyboardManager = KeyboardManager(type: .sidebar)
|
||||
override var keyCommands: [UIKeyCommand]? {
|
||||
|
||||
@@ -98,16 +100,21 @@ final class MainFeedCollectionViewController: UICollectionViewController, Undoab
|
||||
|
||||
override func viewDidAppear(_ animated: Bool) {
|
||||
super.viewDidAppear(animated)
|
||||
|
||||
Self.logger.debug("MainFeedCollectionViewController: viewDidAppear")
|
||||
/// On iPhone, once the deselection animation has completed, set `isAnimating`
|
||||
/// to false and this will allow selection.
|
||||
if traitCollection.userInterfaceIdiom == .phone {
|
||||
if traitCollection.userInterfaceIdiom == .phone && UIDevice.current.orientation == .portrait {
|
||||
if collectionView.indexPathsForSelectedItems != nil {
|
||||
coordinator.selectSidebarItem(indexPath: nil, animations: [.select])
|
||||
DispatchQueue.main.asyncAfter(deadline: .now() + 0.3, execute: {
|
||||
self.isAnimating = false
|
||||
})
|
||||
}
|
||||
return
|
||||
} else if traitCollection.userInterfaceIdiom == .phone && UIDevice.current.orientation.isLandscape {
|
||||
DispatchQueue.main.asyncAfter(deadline: .now() + 0.3, execute: {
|
||||
self.isAnimating = false
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -216,7 +216,7 @@ final class MainTimelineModernViewController: UIViewController, UndoableCommandR
|
||||
self.navigationController?.navigationBar.alpha = 1
|
||||
}
|
||||
}
|
||||
if traitCollection.userInterfaceIdiom == .phone {
|
||||
if traitCollection.userInterfaceIdiom == .phone && UIDevice.current.orientation.isPortrait {
|
||||
if coordinator?.currentArticle != nil {
|
||||
if let indexPath = collectionView?.indexPathsForSelectedItems?.first {
|
||||
collectionView?.deselectItem(at: indexPath, animated: true)
|
||||
|
||||
Reference in new issue
Block a user