[vlc-commits] macosx: use CoreInteraction code for the media key triggers
Felix Paul Kühne
git at videolan.org
Fri May 18 16:18:29 CEST 2012
vlc | branch: master | Felix Paul Kühne <fkuehne at videolan.org> | Fri May 18 16:14:07 2012 +0200| [8548e873e73f7e2838fee5e758eeb31ce158f5bb] | committer: Felix Paul Kühne
macosx: use CoreInteraction code for the media key triggers
no functional change
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=8548e873e73f7e2838fee5e758eeb31ce158f5bb
---
modules/gui/macosx/intf.m | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/modules/gui/macosx/intf.m b/modules/gui/macosx/intf.m
index 7fed53b..f7e36d7 100644
--- a/modules/gui/macosx/intf.m
+++ b/modules/gui/macosx/intf.m
@@ -845,15 +845,15 @@ static VLCMain *_o_sharedMainInstance = nil;
int keyRepeat = (keyFlags & 0x1);
if( keyCode == NX_KEYTYPE_PLAY && keyState == 0 )
- var_SetInteger( p_intf->p_libvlc, "key-action", ACTIONID_PLAY_PAUSE );
+ [[VLCCoreInteraction sharedInstance] play];
if( (keyCode == NX_KEYTYPE_FAST || keyCode == NX_KEYTYPE_NEXT) && !b_mediakeyJustJumped )
{
if( keyState == 0 && keyRepeat == 0 )
- var_SetInteger( p_intf->p_libvlc, "key-action", ACTIONID_NEXT );
+ [[VLCCoreInteraction sharedInstance] next];
else if( keyRepeat == 1 )
{
- var_SetInteger( p_intf->p_libvlc, "key-action", ACTIONID_JUMP_FORWARD_SHORT );
+ [[VLCCoreInteraction sharedInstance] forwardShort];
b_mediakeyJustJumped = YES;
[self performSelector:@selector(resetMediaKeyJump)
withObject: NULL
@@ -864,10 +864,10 @@ static VLCMain *_o_sharedMainInstance = nil;
if( (keyCode == NX_KEYTYPE_REWIND || keyCode == NX_KEYTYPE_PREVIOUS) && !b_mediakeyJustJumped )
{
if( keyState == 0 && keyRepeat == 0 )
- var_SetInteger( p_intf->p_libvlc, "key-action", ACTIONID_PREV );
+ [[VLCCoreInteraction sharedInstance] previous];
else if( keyRepeat == 1 )
{
- var_SetInteger( p_intf->p_libvlc, "key-action", ACTIONID_JUMP_BACKWARD_SHORT );
+ [[VLCCoreInteraction sharedInstance] backwardShort];
b_mediakeyJustJumped = YES;
[self performSelector:@selector(resetMediaKeyJump)
withObject: NULL
More information about the vlc-commits
mailing list