realbasic-nug
[Top] [All Lists]

Re: LaunchServicesOpenXMBS without opening documents?

To: REALbasic NUG <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: LaunchServicesOpenXMBS without opening documents?
From: Charles Yeomans <charles at declareSub dot com>
Date: Fri, 27 Apr 2007 15:26:51 -0400
Delivered-to: listarchive at realsoftware dot com
Delivered-to: realbasic-nug at lists dot realsoftware dot com
References: <36D2893C-4A1A-4993-91B1-2370F7D2C414 at tribu dot ch> <5B81E6CF-A1AF-4C28-AC8B-666A252F9957 at declareSub dot com> <BADDB1C0-5B9F-4F49-8AD1-A9F9ADF481F8 at tribu dot ch>
On Apr 27, 2007, at 3:09 PM, Arnaud Nicolet wrote:

> Le 27 avr. 07 à 20:40 Soir, Charles Yeomans a écrit:
>
>> The LaunchServices function you want is LSOpenApplication, with the
>> kLSLaunchDontSwitch option.  If the MBS plugins don't have it, then
>> it is not hard to declare and call it.
>
> In fact, it sounds harder than I thought.
> The LSOpenApplication requires a parameter (LSApplicationParameters)
> that sounds "enhanced" for me (I'm not an expert on converting c
> declares to RB).
>
> I have this structure to be passed:
>
> struct LSApplicationParameters {
>     CFIndex version;
>     LSLaunchFlags flags;
>     const FSRef * application;
>     void * asyncLaunchRefCon;
>     CFDictionaryRef environment;
>     CFArrayRef argv;
>     AppleEvent * initialEvent
> };
> typedef struct LSApplicationParameters LSApplicationParameters;
>
> I don't know what is the version I must provide.
> Also, I don't know what type "flags" is expected to be (probably an
> integer, but it is not said).
> I'm lost for most of the parameters.


I have a chapter on Launch Services in my book on declares, but this  
function was added in Tiger, and so was not covered.  Hang on.

Charles Yeomans


_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>


<Prev in Thread] Current Thread [Next in Thread>