Used an adapted MethodGenerator to generate methods too for functions that have the object as the second arg after a first CFAllocatorRef arg (which we pass as NULL always anyway).
diff --git a/Mac/Modules/cf/cfscan.py b/Mac/Modules/cf/cfscan.py
index 7941875..b8ccb31 100644
--- a/Mac/Modules/cf/cfscan.py
+++ b/Mac/Modules/cf/cfscan.py
@@ -58,6 +58,12 @@
if t in OBJECTS and m == "InMode":
classname = "Method"
listname = t + "_methods"
+ # Special case for the silly first AllocatorRef argument
+ if t == 'CFAllocatorRef' and m == 'InMode' and len(arglist) > 1:
+ t, n, m = arglist[1]
+ if t in OBJECTS and m == "InMode":
+ classname = "MethodSkipArg1"
+ listname = t + "_methods"
return classname, listname
def writeinitialdefs(self):
@@ -85,9 +91,7 @@
"CFStringGetCharactersPtr",
"CFStringGetCString",
"CFStringGetCharacters",
- # OSX only, to be done
-## "CFURLCreateWithFileSystemPath",
-## "CFURLCreateStringWithFileSystemPath",
+ "CFURLCreateStringWithFileSystemPath", # Gone in later releases
]
def makegreylist(self):