Fwd: [Gtk-osx-users] Custom URL Handler



John,

  I'd sent this to the list some time ago, though nobody replied....

Is this functionality something you'd be willing to roll into the distribution gtk-osx and igemacintegration?

https://github.com/pheller/ige-mac-integration

Regards,

  Phil

Begin forwarded message:

> From: Phillip Heller <pheller me com>
> Date: January 9, 2011 8:52:25 PM EST
> To: GTK+-2 OSX Users <gtk-osx-users lists sourceforge net>
> Subject: Re: [Gtk-osx-users] Custom URL Handler
> Reply-To: GTK+-2 OSX Users <gtk-osx-users lists sourceforge net>
> 
> 
> On Aug 25, 2010, at 10:50 AM, Phillip Heller wrote:
> 
> <snip>
> 
>> If you're reading this, John, any chance we could get a method in OSXApplication to install a handler for NSURLProtocol?
> 
> <snip>
> 
> Greetings,
> 
> I've tried numerous (hackish) methods to hook a custom URL handler to my pygtk application with no success, so I've come back around to doing it via Cocoa.
> 
> I've got a proof-of-concept implementation for gtk_osxapplication which mostly works, though is likely illustrative of my utter lack of Objective-C experience.
> 
> With respect to the one issue: I install the handler in an applicationWillFinishLoading method within the GtkApplicationDelegate implementation, though it does not seem to process the URL which may have been used to invoke the application (if it were not previously running).
> 
> You can find my fork here:  https://github.com/pheller/ige-mac-integration
> 
> Once the source tree is built and installed, try the python bindings like so:
> 
> % cd ige-mac-integration/bindings/python/gtk_osxapplication
> % python ./setup.py py2app
> % open dist/test-integration.app (just once, to register the URL handler with LaunchServices)  then, quit....
> 
> Now, try some invocations:
> 
> % open gtk-osx://foo  (if the test application isn't running, this will just open the application)
> % open gtk-osx://bar  (this should open a MessageDialog)
> 
> I hope this is useful for others, and hopefully someone might have an idea why the URL used to launch the app doesn't seem to be processed....
> 
> Regards,
> 
>  Phil------------------------------------------------------------------------------
> Gaining the trust of online customers is vital for the success of any company
> that requires sensitive data to be transmitted over the Web.   Learn how to 
> best implement a security strategy that keeps consumers' information secure 
> and instills the confidence they need to proceed with transactions.
> http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________
> Gtk-osx-users mailing list
> Gtk-osx-users lists sourceforge net
> https://lists.sourceforge.net/lists/listinfo/gtk-osx-users

Attachment: smime.p7s
Description: S/MIME cryptographic signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]