For a window we can user window:handle with Cocoa declares in order to use selectors like “setFrame:display:animate:”. Is there an equivalent for the application object. For example to use the “showHelp:” selector I’m currently having to do this:
[code]Declare function NSClassFromString lib “Cocoa.framework” (aClassName as CFStringRef) as Ptr
Declare function sharedApplication lib “Cocoa.framework” selector “sharedApplication” (class_id as Ptr) as Ptr
Declare function showHelp lib “Cocoa.framework” selector “showHelp:” ( appid as Ptr ) as Boolean
Return showHelp( sharedApplication( NSClassFromString(“NSApplication”) ) )
[/code]
It would obviously be neater to do the equivalent of this:
[code]Declare function showHelp lib “Cocoa.framework” selector “showHelp:” ( appid as Ptr ) as Boolean
Return showHelp( App:handle )
[/code]
Any hints would be welcome.