Popping browser to front
  • I have a bunch of AppleScripts that follow a similar pattern: they take the current clipboard contents, turn it into a URL to an intranet server, and then use "open location" to go to the URL. In addition, some of them pop up a dialogue to ask for additional info that gets merged into the URL.

    These scripts worked fine when I was running Leopard and FS 2.3.6. I recently upgraded to Snow Leopard, and noticed that when the scripts pop up a dialogue, it wasn't brought to the front. I had to hide all windows to find it.

    Upgrading to FS 2.5 fixed that problem, but now when those scripts open the location, Safari doesn't pop to the front. I have to switch to it manually. This only happens with the scripts that display a dialogue.

    Adding

    tell application "Safari" to activate

    to the end of the script seems to solve the problem, but it would be nice if I didn't have to do this in all the scripts.
  • Thanks for the feedback. This is one of the challenges in FastScripts, to adapt to the changing behaviors of the scriptable applications -- and AppleScript itself -- as the various releases of OS X change things in subtle ways.

    I think the fact that it doesn't activate automatically is actually a good thing, since it's possible somebody would want to open the location and NOT open the browser. But I can see how the change in behavior is frustrating. I think it's out of FastScripts's hands in this case though.

    Daniel
Start a New Discussion

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!