bpo-44828: Avoid leaving a zombie Save panel. (GH-29371)

Patch by Marc Culler of the Tk project.
This commit is contained in:
Ned Deily 2021-11-02 17:06:11 -04:00 committed by GitHub
parent e312f38f7b
commit d53d9e7f4f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -18,7 +18,7 @@
if (returnCode >= NSAlertFirstButtonReturn) {
Tcl_Obj *resultObj = Tcl_NewStringObj(alertButtonStrings[
@@ -350,49 +350,41 @@
@@ -350,49 +350,42 @@
FilePanelCallbackInfo *callbackInfo)
{
NSInteger modalReturnCode;
@ -85,6 +85,7 @@
- [panel close];
+ returnCode:modalReturnCode
+ contextInfo:callbackInfo ];
+ [parent endSheet:panel];
}
+ } else {
+ modalReturnCode = [panel runModal];