macos: undo close all windows

This commit is contained in:
Mitchell Hashimoto
2025-06-06 16:03:20 -07:00
parent d92db73f25
commit aeede903f5

View File

@@ -710,7 +710,11 @@ class TerminalController: BaseTerminalController {
}
static private func closeAllWindowsImmediately() {
all.forEach { $0.close() }
let undoManager = (NSApp.delegate as? AppDelegate)?.undoManager
undoManager?.beginUndoGrouping()
all.forEach { $0.closeWindowImmediately() }
undoManager?.setActionName("Close All Windows")
undoManager?.endUndoGrouping()
}
// MARK: Undo/Redo