diff options
author | nplourde <nplourde@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2005-05-02 14:40:16 +0000 |
---|---|---|
committer | nplourde <nplourde@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2005-05-02 14:40:16 +0000 |
commit | d07fabd85fa281a750a920efc5afb5532912270b (patch) | |
tree | bc323d102e9e85b57848eeadd79d4183471ecfcd /libvo/vo_macosx.m | |
parent | 86e49b65ede20a9f5a23a0823ff4e36f213a2d91 (diff) | |
download | mpv-d07fabd85fa281a750a920efc5afb5532912270b.tar.bz2 mpv-d07fabd85fa281a750a920efc5afb5532912270b.tar.xz |
close button exit mplayer with esc key
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@15326 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo/vo_macosx.m')
-rw-r--r-- | libvo/vo_macosx.m | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libvo/vo_macosx.m b/libvo/vo_macosx.m index dc669c510c..3a9e746ab8 100644 --- a/libvo/vo_macosx.m +++ b/libvo/vo_macosx.m @@ -306,6 +306,7 @@ static uint32_t control(uint32_t request, void *data, ...) backing:NSBackingStoreBuffered defer:NO]; + [window setDelegate:self]; [window setContentView:self]; [window setInitialFirstResponder:self]; [window setAcceptsMouseMovedEvents:YES]; @@ -665,4 +666,9 @@ static uint32_t control(uint32_t request, void *data, ...) { return YES; } -@end
\ No newline at end of file + +- (void)windowWillClose:(NSNotification *)aNotification +{ + mplayer_put_key(KEY_ESC); +} +@end |