Clear split zoom when jumping to unread
This commit is contained in:
parent
1e90981947
commit
02854441e9
1 changed files with 5 additions and 1 deletions
|
|
@ -2205,12 +2205,16 @@ class TabManager: ObservableObject {
|
|||
|
||||
func focusTabFromNotification(_ tabId: UUID, surfaceId: UUID? = nil) {
|
||||
let wasSelected = selectedTabId == tabId
|
||||
let desiredPanelId = surfaceId ?? tabs.first(where: { $0.id == tabId })?.focusedPanelId
|
||||
guard let tab = tabs.first(where: { $0.id == tabId }) else { return }
|
||||
let desiredPanelId = surfaceId ?? tab.focusedPanelId
|
||||
#if DEBUG
|
||||
if let desiredPanelId {
|
||||
AppDelegate.shared?.armJumpUnreadFocusRecord(tabId: tabId, surfaceId: desiredPanelId)
|
||||
}
|
||||
#endif
|
||||
// Jump-to-unread should reveal the destination pane instead of keeping an old split-zoom
|
||||
// state active around it.
|
||||
tab.clearSplitZoom()
|
||||
suppressFocusFlash = true
|
||||
focusTab(tabId, surfaceId: desiredPanelId, suppressFlash: true)
|
||||
if wasSelected {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue