summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXWm.c
diff options
context:
space:
mode:
authorKevin Walzer <kw@codebykevin.com>2015-03-21 01:22:36 (GMT)
committerKevin Walzer <kw@codebykevin.com>2015-03-21 01:22:36 (GMT)
commit50ec1ecb24801b023618048a6704fa12670671d9 (patch)
treeaecf3fb93bddea1561e21b4945307339af8f0d7e /macosx/tkMacOSXWm.c
parentf22c4207e5275f1e2c792672b41f6828372d6203 (diff)
downloadtk-50ec1ecb24801b023618048a6704fa12670671d9.zip
tk-50ec1ecb24801b023618048a6704fa12670671d9.tar.gz
tk-50ec1ecb24801b023618048a6704fa12670671d9.tar.bz2
Cleanup and simplification of memory management in event loop; now works more smoothly; thanks to Marc Culler for patches
Diffstat (limited to 'macosx/tkMacOSXWm.c')
-rw-r--r--macosx/tkMacOSXWm.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/macosx/tkMacOSXWm.c b/macosx/tkMacOSXWm.c
index a852ac9..8459bdd 100644
--- a/macosx/tkMacOSXWm.c
+++ b/macosx/tkMacOSXWm.c
@@ -22,6 +22,8 @@
#include "tkMacOSXDebug.h"
#include <Carbon/Carbon.h>
+#define DEBUG_ZOMBIES 0
+
/*
#ifdef TK_MAC_DEBUG
#define TK_MAC_DEBUG_WINDOWS
@@ -338,6 +340,17 @@ static void RemapWindows(TkWindow *winPtr,
{
id _i1, _i2;
}
+
+- (id) retain
+{
+#if DEBUG_ZOMBIES
+ const char *title = [[self title] UTF8String];
+ if (title != NULL) {
+ printf("Retaining %s with count %lu\n", title, [self retainCount]);
+ }
+#endif
+ return [super retain];
+}
@end
@implementation TKWindow
@@ -785,7 +798,6 @@ TkWmDeadWindow(
if (parent) {
[parent removeChildWindow:window];
}
- [window setExcludedFromWindowsMenu:YES];
[window close];
TkMacOSXUnregisterMacWindow(window);
if (winPtr->window) {