Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Fix a conflict between ClickToFlash and PandoraJam Apps
The ClickToFlash plug-in for Safari (recently hinted here) has an unwelcome side effect: it breaks the application PandoraJam, because PandoraJam uses WebKit and Flash to build its interaction window.

I wrote an AppleScript that works around this problem by deactivating ClickToFlash just long enough to launch PandoraJam, then reactivating ClickToFlash. Here's the code:
--PandoraJam Launcher 1.04
--Mar 10, 2009 4:08 AM   
--© Jeff Porten 2009
--Latest version here: http://www.jeffporten.com/?p=933
--Donations accepted if you find this script useful

--1.04: increased delay to 3 seconds out
--1.02: changed delay time to quarter-second in, 1 second out
--TODO: is launcher affecting thumbs up/down controls?
--TODO: is UseLauncher pref expiring?

tell application "Finder"
    --look for CTF in user folder and /Library
    set c2fLoc to false
    if exists file "ClickToFlash.plugin" of folder "Internet Plug-Ins" of (path to library folder) then
        set c2fLoc to file "ClickToFlash.plugin" of folder "Internet Plug-Ins" of (path to library folder)
    else if exists file "ClickToFlash.plugin" of folder "Internet Plug-Ins" of (path to library folder from user domain) then
        set c2fLoc to file "ClickToFlash.plugin" of folder "Internet Plug-Ins" of (path to library folder from user domain)
    end if
    
    --this might break or ask for a password when run from a non-admin account; I haven't tested this
    if c2fLoc is not false then -- a document value isn't considered "true" by AppleScript? Silly.
        set c2fHome to c2fLoc's folder
        move c2fLoc to (path to desktop folder)
        delay 0.25
        tell application "PandoraJam"
            activate
        end tell
        delay 3
        move (file "ClickToFlash.plugin" of (path to desktop folder)) to c2fHome
    end if
end tell
Use the above script in place of the PandoraJam -- run the script instead of launching PandoraJam, and it'll do the rest. (Check this post on my blog for the latest and greatest version, and some more detail on the issue.)

[robg adds: I haven't tested this one.]

Update: There's an available workaround to this problem now (as of July 2009).
    •    
  • Currently 2.33 / 5
  • 1
  • 2
  • 3
  • 4
  • 5
  (6 votes cast)
 
[7,128 views]  

Fix a conflict between ClickToFlash and PandoraJam | 2 comments | Create New Account
Click here to return to the 'Fix a conflict between ClickToFlash and PandoraJam' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Fix a conflict between ClickToFlash and PandoraJam
Authored by: Stormchild on Mar 27, '09 08:19:45AM

This seems needlessly complicated. Can't you just add the affected site to the whitelist?



[ Reply to This | # ]
Fix a conflict between ClickToFlash and PandoraJam
Authored by: chrononaut on Mar 27, '09 11:00:56AM

Unfortunately PandoraJam doesn't react the same way as a browser-based application. Adding the domain to the ClickToFlash whitelist works for PandoraBoy but not PandoraJam. PandoraJam shows a missing plug-in icon instead of the ClickToFlash replacement image.

By the way, this script works wonderfully. I am listening to PandoraJam right now.

:D



[ Reply to This | # ]