changeset 15325:5bd11a72dc58

close button exit mplayer with esc key
author nplourde
date Mon, 02 May 2005 14:40:16 +0000
parents 255559075b28
children f351dd913bc6
files libvo/vo_macosx.m
diffstat 1 files changed, 7 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/vo_macosx.m	Mon May 02 14:00:52 2005 +0000
+++ b/libvo/vo_macosx.m	Mon May 02 14:40:16 2005 +0000
@@ -306,6 +306,7 @@
 								backing:NSBackingStoreBuffered
 								defer:NO];
 
+	[window setDelegate:self];
 	[window setContentView:self];
 	[window setInitialFirstResponder:self];
 	[window setAcceptsMouseMovedEvents:YES];
@@ -665,4 +666,9 @@
 {
 	return YES;
 }
-@end
\ No newline at end of file
+
+- (void)windowWillClose:(NSNotification *)aNotification
+{
+	mplayer_put_key(KEY_ESC);
+}
+@end