Revision: 12345 http://sourceforge.net/p/skim-app/code/12345 Author: hofman Date: 2021-06-08 22:06:30 +0000 (Tue, 08 Jun 2021) Log Message: ----------- Stop type select helper when ending a sheet
Modified Paths: -------------- trunk/SKTypeSelectHelper.m Modified: trunk/SKTypeSelectHelper.m =================================================================== --- trunk/SKTypeSelectHelper.m 2021-06-01 09:34:11 UTC (rev 12344) +++ trunk/SKTypeSelectHelper.m 2021-06-08 22:06:30 UTC (rev 12345) @@ -181,7 +181,10 @@ if (isProcessing == NO) { [[NSNotificationCenter defaultCenter] removeObserver:self]; - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(typeSelectCleanTimeout:) name:NSWindowWillCloseNotification object:[NSApp keyWindow]]; + if ([[NSApp keyWindow] isSheet]) + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(typeSelectCleanTimeout:) name:NSWindowDidEndSheetNotification object:[NSApp keyWindow]]; + else + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(typeSelectCleanTimeout:) name:NSWindowWillCloseNotification object:[NSApp keyWindow]]; if ([editor delegate]) [(SKTypeSelectHelper *)[editor delegate] typeSelectCleanTimeout:nil]; [editor setDelegate:self]; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. _______________________________________________ Skim-app-commit mailing list Skim-app-commit@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/skim-app-commit