Browse files

update casting for 10.6 usage of Keyboard UGens

  • Loading branch information...
1 parent 2682031 commit 1ffa97e8258f93a0a0d218fc1785c4b149d15163 Joshua Parmenter committed Feb 28, 2010
Showing with 17 additions and 0 deletions.
  1. +17 −0 common/Source/plugins/KeyboardUGens.cpp
View
17 common/Source/plugins/KeyboardUGens.cpp
@@ -61,6 +61,21 @@ extern "C"
//////////////////////////////////////////////////////////////////////////////////////////////////
#if SC_DARWIN
+# if (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1050)
+
+void* gstate_update_func(void* arg)
+{
+ KeyboardUGenGlobalState* gstate = &gKeyStateGlobals;
+ for (;;) {
+ Point p;
+ GetKeys((BigEndianUInt32*)gstate->keys);
+ usleep(17000);
+ }
+
+ return 0;
+}
+
+#else
void* gstate_update_func(void* arg)
{
@@ -74,6 +89,8 @@ void* gstate_update_func(void* arg)
return 0;
}
+#endif
+
#elif defined(SC_WIN32)
void* gstate_update_func(void* arg)

0 comments on commit 1ffa97e

Please sign in to comment.