summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorculler <culler>2025-03-13 13:43:52 (GMT)
committerculler <culler>2025-03-13 13:43:52 (GMT)
commit2d24c82f4c4aedc39acf0571c817b0a5a42f5343 (patch)
treea4acaf6ea0edf6f9ec674902149fb5a2ad8360d1
parentb661de17978833dec2413fdaf013305d7462ed01 (diff)
downloadtk-core-aqua_key_windows.zip
tk-core-aqua_key_windows.tar.gz
tk-core-aqua_key_windows.tar.bz2
Check the TK_ALREADY_DEAD flag before making a window become the key window.core-aqua_key_windows
-rw-r--r--macosx/tkMacOSXWm.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/macosx/tkMacOSXWm.c b/macosx/tkMacOSXWm.c
index 1990df2..d6a238a 100644
--- a/macosx/tkMacOSXWm.c
+++ b/macosx/tkMacOSXWm.c
@@ -852,7 +852,9 @@ void TkMacOSXAssignNewKeyWindow(
WmInfo *wmPtr;
BOOL isOnScreen;
winPtr = TkMacOSXGetTkWindow(w);
- if (!winPtr || !winPtr->wmInfoPtr) {
+ if (!winPtr
+ || !winPtr->wmInfoPtr
+ || (winPtr->flags & TK_ALREADY_DEAD)) {
continue;
}
wmPtr = winPtr->wmInfoPtr;