Skip to content

Commit

Permalink
🔀 Merge pull request #677 from MrKai77/673-hide-and-minimize-not-work…
Browse files Browse the repository at this point in the history
…ing-correctly

🐞 Move window activation to after minimizing/hiding
  • Loading branch information
MrKai77 authored Jan 22, 2025
2 parents ccab30f + e2908ff commit 0e38036
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Loop/Window Management/WindowEngine.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,6 @@ enum WindowEngine {
let windowTitle = window.nsRunningApplication?.localizedName ?? window.title ?? "<unknown>"
print("Resizing \(windowTitle) to \(action.direction) on \(screen.localizedName)")

// Note that this is only really useful when "Resize window under cursor" is enabled
if Defaults[.focusWindowOnResize] {
window.activate()
}

// If the action is to hide or minimize, perform the action then return
if action.direction == .hide {
window.toggleHidden()
Expand All @@ -43,6 +38,11 @@ enum WindowEngine {
return
}

// Note that this is only really useful when "Resize window under cursor" is enabled
if Defaults[.focusWindowOnResize] {
window.activate()
}

if shouldRecord {
WindowRecords.record(window, action)
}
Expand Down

0 comments on commit 0e38036

Please sign in to comment.