[Xquartz-dev] LSBackgroundOnly at runtime

Derek Fawcus dfawcus at cisco.com
Wed Dec 5 15:14:26 PST 2007


On Wed, Dec 05, 2007 at 09:12:04AM -0800, Kyle McKay wrote:
> 
> 
> Are you calling TransformProcessType as early as possible?  Also keep  
> in mind that when you're started by the finder, you'll get this extra  
> argument that starts with -psn_.  But it seems like you could call  
> TransformProcessType immediately in main if argc<=1 or argc==2 and  
> argv[1] starts with "-psn_" or maybe I have the sense of that test  
> backwards, but you get the idea about the extra argument you have to  
> account for.

Actually - just what does '-psn_' imply?

Given that it is passed when started by launch services,  I was assuming
it meant the 'TransformProcessType' has already been called by the process
before the exec(2) was called to start the application.

i.e. that the app is being informed about the PSN which has already created.

This would seem to fit with keyboard events being available for an program run
from the cli which then uses TransformProcessType (i.e. not in a bundle,  and
not started by 'open -a').

DF


More information about the Xquartz-dev mailing list