diff options
author | MaestroDD <MaestroDD@svn> | 2009-12-21 10:22:04 +0000 |
---|---|---|
committer | MaestroDD <MaestroDD@svn> | 2009-12-21 10:22:04 +0000 |
commit | 5c2dc9fd1e8c378faad2a37f3bbaa356e75512aa (patch) | |
tree | e1fca673cdf2368d4a8616f246fe5a2c627dc7d2 /tools/EventClients | |
parent | 19aade75f5c1e8df90fec27a11f243c6f62bb116 (diff) |
[OSX] update to HIDRemote 1.1.1
git-svn-id: https://xbmc.svn.sourceforge.net/svnroot/xbmc/trunk@25929 568bbfeb-2a22-0410-94d2-cc84cf5bfa90
Diffstat (limited to 'tools/EventClients')
-rw-r--r-- | tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.h | 5 | ||||
-rw-r--r-- | tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.m | 14 |
2 files changed, 16 insertions, 3 deletions
diff --git a/tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.h b/tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.h index 118c32101d..8bbb54bb22 100644 --- a/tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.h +++ b/tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.h @@ -1,6 +1,6 @@ // // HIDRemote.h -// HIDRemote V1.1 +// HIDRemote V1.1.1 // // Created by Felix Schwarz on 06.04.07. // Copyright 2007-2009 IOSPIRIT GmbH. All rights reserved. @@ -265,6 +265,8 @@ typedef enum - (unsigned)activeRemoteControlCount; - (SInt32)lastSeenRemoteControlID; + +- (void)setLastSeenModel:(HIDRemoteModel)aModel; - (HIDRemoteModel)lastSeenModel; - (void)setDelegate:(NSObject <HIDRemoteDelegate> *)newDelegate; @@ -278,7 +280,6 @@ typedef enum #pragma mark -- PUBLIC: Expert APIs -- - (void)setEnableSecureEventInputWorkaround:(BOOL)newEnableSecureEventInputWorkaround; - - (BOOL)enableSecureEventInputWorkaround; - (void)setExclusiveLockLendingEnabled:(BOOL)newExclusiveLockLendingEnabled; diff --git a/tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.m b/tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.m index 502100250f..31ba3be409 100644 --- a/tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.m +++ b/tools/EventClients/Clients/OSXRemote/HIDRemote/HIDRemote.m @@ -1,6 +1,6 @@ // // HIDRemote.m -// HIDRemote V1.1 (13th November 2009) +// HIDRemote V1.1.1 (14th December 2009) // // Created by Felix Schwarz on 06.04.07. // Copyright 2007-2009 IOSPIRIT GmbH. All rights reserved. @@ -399,6 +399,11 @@ static HIDRemote *sHIDRemote = nil; return (_lastSeenModel); } +- (void)setLastSeenModel:(HIDRemoteModel)aModel +{ + _lastSeenModel = aModel; +} + - (void)setSimulateHoldEvents:(BOOL)newSimulateHoldEvents { _simulateHoldEvents = newSimulateHoldEvents; @@ -1586,6 +1591,13 @@ static HIDRemote *sHIDRemote = nil; } break; } + + // As soon as we have received a code that's unique to the Aluminum Remote, we can tell kHIDRemoteButtonCodePlayHold and kHIDRemoteButtonCodeCenterHold apart. + // Prior to that, a long press of the new "Play" button will be submitted as a "kHIDRemoteButtonCodeCenterHold", not a "kHIDRemoteButtonCodePlayHold" code. + if ((buttonCode == kHIDRemoteButtonCodeCenterHold) && (_lastSeenModel == kHIDRemoteModelAluminum)) + { + buttonCode = kHIDRemoteButtonCodePlayHold; + } [((NSObject <HIDRemoteDelegate> *)[self delegate]) hidRemote:self eventWithButton:(buttonCode & (~kHIDRemoteButtonCodeAluminumMask)) isPressed:isPressed fromHardwareWithAttributes:hidAttribsDict]; } |