Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: launching gif in default browser...?



On Jul 25, 2004, at 6:05 PM, Ando Sonenblick wrote:

> Gang,
>
> My app outputs GIFs, which I want to auto launch into the default
> browser when created.
>
> If I create a url to the outputted GIF file and ask IC to launch it,
> it opens in Preview, which isn't very conducive to actually seeing the
> resulting file animate as it just show individual frames.
>
> I'm wondering what is the best/easiest way to force it to launch into
> the default browser. The only way I see to do it is this:
>
> Get the creator code of the default web broswer with code like:
>
> err = ICGetPref(icInstance, kICHelperHTTP, &icAttr, (Ptr)
> &targetSpec, &dataSize);
> if (err == noErr)
> signature = targetSpec.fCreator;
>
> Then use the creator and apple events to find if running, or launch if
> not, the app with the creator code, then ae the file over to it.
>
> But this seems like a lot of work (and do I really want to be working
> with creator codes these days?!?!)
>
> Anyone have any better solutions?

Rather than having your application open Safari to preview the
animation, why not add a window that uses a WebView to preview the
animation in your application? You would be using the exact same
technology that Safari uses so the results should be indistinguishable
and you won't have to bother the user with launching an external
application. Plus you will have more control over the way the image is
presented (for example you could size the window to "just fit" the
image instead of having to show a full browser window.

Scott

[demime 0.98b removed an attachment of type application/pkcs7-signature which had a name of smime.p7s]
_______________________________________________
carbon-development mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/carbon-development
Do not post admin requests to the list. They will be ignored.


References: 
 >launching gif in default browser...? (From: Ando Sonenblick <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.