From dfa720254dc2d65d27da3449992a7db1e08739a4 Mon Sep 17 00:00:00 2001 From: Steve Checkoway Date: Fri, 10 Feb 2006 09:21:39 +0000 Subject: [PATCH] dict -> properties --- stepmania/src/archutils/Darwin/HIDDevice.cpp | 20 +++++++++---------- .../src/archutils/Darwin/JoystickDevice.cpp | 6 +++--- .../src/archutils/Darwin/JoystickDevice.h | 2 +- .../src/archutils/Darwin/KeyboardDevice.cpp | 2 +- .../src/archutils/Darwin/KeyboardDevice.h | 2 +- 5 files changed, 16 insertions(+), 16 deletions(-) diff --git a/stepmania/src/archutils/Darwin/HIDDevice.cpp b/stepmania/src/archutils/Darwin/HIDDevice.cpp index 57b1fce900..1e42f71e52 100644 --- a/stepmania/src/archutils/Darwin/HIDDevice.cpp +++ b/stepmania/src/archutils/Darwin/HIDDevice.cpp @@ -175,7 +175,7 @@ void HIDDevice::AddLogicalDevice( const void *value, void *context ) if( CFGetTypeID(CFTypeRef(value)) != CFDictionaryGetTypeID() ) return; - CFDictionaryRef dict = CFDictionaryRef( value ); + CFDictionaryRef properties = CFDictionaryRef( value ); HIDDevice *This = (HIDDevice *)context; CFArrayRef elements; CFTypeRef object; @@ -183,16 +183,16 @@ void HIDDevice::AddLogicalDevice( const void *value, void *context ) CFTypeID numID = CFNumberGetTypeID(); // Get usage page - object = CFDictionaryGetValue( dict, CFSTR(kIOHIDElementUsagePageKey) ); + object = CFDictionaryGetValue( properties, CFSTR(kIOHIDElementUsagePageKey) ); if( !object || CFGetTypeID(object) != numID || !IntValue(object, usagePage) ) return; // Get usage - object = CFDictionaryGetValue( dict, CFSTR(kIOHIDElementUsageKey) ); + object = CFDictionaryGetValue( properties, CFSTR(kIOHIDElementUsageKey) ); if( !object || CFGetTypeID(object) != numID || !IntValue(object, usage) ) return; - if( !(elements = (CFArrayRef)CFDictionaryGetValue( dict, CFSTR(kIOHIDElementKey))) ) + if( !(elements = (CFArrayRef)CFDictionaryGetValue( properties, CFSTR(kIOHIDElementKey))) ) return; if( !This->AddLogicalDevice(usagePage, usage) ) @@ -208,7 +208,7 @@ void HIDDevice::AddElement( const void *value, void *context ) if( CFGetTypeID(CFTypeRef(value)) != CFDictionaryGetTypeID() ) return; - CFDictionaryRef dict = CFDictionaryRef( value ); + CFDictionaryRef properties = CFDictionaryRef( value ); HIDDevice *This = (HIDDevice *)context; CFTypeRef object; CFTypeID numID = CFNumberGetTypeID(); @@ -216,7 +216,7 @@ void HIDDevice::AddElement( const void *value, void *context ) CFArrayRef elements; // Recursively add elements - if( (elements = (CFArrayRef)CFDictionaryGetValue(dict, CFSTR(kIOHIDElementKey))) ) + if( (elements = (CFArrayRef)CFDictionaryGetValue(properties, CFSTR(kIOHIDElementKey))) ) { CFRange r = { 0, CFArrayGetCount(elements) }; @@ -224,21 +224,21 @@ void HIDDevice::AddElement( const void *value, void *context ) } // Get usage page - object = CFDictionaryGetValue( dict, CFSTR(kIOHIDElementUsagePageKey) ); + object = CFDictionaryGetValue( properties, CFSTR(kIOHIDElementUsagePageKey) ); if( !object || CFGetTypeID(object) != numID || !IntValue(object, usagePage) ) return; // Get usage - object = CFDictionaryGetValue( dict, CFSTR(kIOHIDElementUsageKey) ); + object = CFDictionaryGetValue( properties, CFSTR(kIOHIDElementUsageKey) ); if( !object || CFGetTypeID(object) != numID || !IntValue(object, usage) ) return; // Get cookie - object = CFDictionaryGetValue( dict, CFSTR(kIOHIDElementCookieKey) ); + object = CFDictionaryGetValue( properties, CFSTR(kIOHIDElementCookieKey) ); if( !object || CFGetTypeID(object) != numID || !IntValue(object, cookie) ) return; - This->AddElement( usagePage, usage, cookie, dict ); + This->AddElement( usagePage, usage, cookie, properties ); } /* diff --git a/stepmania/src/archutils/Darwin/JoystickDevice.cpp b/stepmania/src/archutils/Darwin/JoystickDevice.cpp index eba076c88c..8a5f68d267 100644 --- a/stepmania/src/archutils/Darwin/JoystickDevice.cpp +++ b/stepmania/src/archutils/Darwin/JoystickDevice.cpp @@ -33,7 +33,7 @@ bool JoystickDevice::AddLogicalDevice( int usagePage, int usage ) return true; } -void JoystickDevice::AddElement( int usagePage, int usage, int cookie, const CFDictionaryRef dict ) +void JoystickDevice::AddElement( int usagePage, int usage, int cookie, const CFDictionaryRef properties ) { CFTypeRef object; CFTypeID numID = CFNumberGetTypeID(); @@ -48,11 +48,11 @@ void JoystickDevice::AddElement( int usagePage, int usage, int cookie, const CFD int iMin = 0; int iMax = 0; - object = CFDictionaryGetValue( dict, CFSTR(kIOHIDElementMinKey) ); + object = CFDictionaryGetValue( properties, CFSTR(kIOHIDElementMinKey) ); if( object && CFGetTypeID(object) == numID ) IntValue( object, iMin ); - object = CFDictionaryGetValue( dict, CFSTR(kIOHIDElementMaxKey) ); + object = CFDictionaryGetValue( properties, CFSTR(kIOHIDElementMaxKey) ); if( object && CFGetTypeID(object) == numID ) IntValue( object, iMax ); diff --git a/stepmania/src/archutils/Darwin/JoystickDevice.h b/stepmania/src/archutils/Darwin/JoystickDevice.h index 3ab3551142..bcea47d650 100644 --- a/stepmania/src/archutils/Darwin/JoystickDevice.h +++ b/stepmania/src/archutils/Darwin/JoystickDevice.h @@ -23,7 +23,7 @@ private: protected: bool AddLogicalDevice( int usagePage, int usage ); - void AddElement( int usagePage, int usage, int cookie, const CFDictionaryRef dict ); + void AddElement( int usagePage, int usage, int cookie, const CFDictionaryRef properties ); void Open(); public: diff --git a/stepmania/src/archutils/Darwin/KeyboardDevice.cpp b/stepmania/src/archutils/Darwin/KeyboardDevice.cpp index 6eed5c64a1..3a728bb7f1 100644 --- a/stepmania/src/archutils/Darwin/KeyboardDevice.cpp +++ b/stepmania/src/archutils/Darwin/KeyboardDevice.cpp @@ -8,7 +8,7 @@ bool KeyboardDevice::AddLogicalDevice( int usagePage, int usage ) return usagePage == kHIDPage_GenericDesktop && usage == kHIDUsage_GD_Keyboard; } -void KeyboardDevice::AddElement( int usagePage, int usage, int cookie, const CFDictionaryRef dict ) +void KeyboardDevice::AddElement( int usagePage, int usage, int cookie, const CFDictionaryRef properties ) { if( usagePage != kHIDPage_KeyboardOrKeypad ) return; diff --git a/stepmania/src/archutils/Darwin/KeyboardDevice.h b/stepmania/src/archutils/Darwin/KeyboardDevice.h index c76ea5f8a3..d87a039ca0 100644 --- a/stepmania/src/archutils/Darwin/KeyboardDevice.h +++ b/stepmania/src/archutils/Darwin/KeyboardDevice.h @@ -11,7 +11,7 @@ private: protected: bool AddLogicalDevice( int usagePage, int usage ); - void AddElement( int usagePage, int usage, int cookie, const CFDictionaryRef dict ); + void AddElement( int usagePage, int usage, int cookie, const CFDictionaryRef properties ); void Open(); public: