fix memory management bugs in game-input.backend.iokit

db4
Joe Groff 2008-07-19 12:02:24 -07:00
parent b5d2f7f219
commit cad006719f
1 changed files with 2 additions and 8 deletions

View File

@ -80,15 +80,9 @@ SINGLETON: iokit-game-input-backend
game-devices-matching-seq hid-manager-matching ;
: device-property ( device key -- value )
[
<NSString> IOHIDDeviceGetProperty
[ &CFRelease plist> ] [ f ] if*
] with-destructors ;
<NSString> IOHIDDeviceGetProperty plist> ;
: element-property ( element key -- value )
[
<NSString> IOHIDElementGetProperty
[ &CFRelease plist> ] [ f ] if*
] with-destructors ;
<NSString> IOHIDElementGetProperty plist> ;
: set-element-property ( element key value -- )
[ <NSString> ] [ >plist ] bi* IOHIDElementSetProperty drop ;
: transfer-element-property ( element from-key to-key -- )