From: Xavier Noria Date: 2007-12-07T00:45:45+09:00 Subject: Re: open browser On Dec 6, 2007, at 1:47 PM, Christian Kerth wrote: > thefed wrote: >> Check out launchy. Its good for opening native applications. >> >> http://rubyforge.org/projects/copiousfreetime/ >> >> launchy is there (used by heel). > > I installed this launchy gem and it works in general, but obviously > not > in my context. I have a small wxruby app with just a task bar tray > menu. > When i click on this tray icon i want the appolication to open the > browser and point to a certain address. The launchy call is processed > when i kill the application, not at clicking time. The basic idea in pseudocode would be: command = windows ? 'start /B' : macosx ? 'open' : '???' system(%Q[#{command} "#{url}"]) The /B flag prevents start from creating a Window on Windows. Problem is I don't think there's a cross-desktop/window manager launcher for Linux. You could look for "/usr/bin/firefox" or whatever but what if it is there but user's default browser is Konqueror? -- fxn