Hi Tubal, Well, i have bad news for you, that won't work. All of the JS methods listed as "Available only to local Userscripts" on http://fluidapp.com/developer are unforutnately, only available to Userscripts during the window onload event. After that (including in user event handler functions) they cannot be executed.
If you're thinking that totally sux, you are absolutely right. I wanted to figure out how to allow calls to these methods only from Userscripts, but to allow them at any time. But it was very important for security reasons to not allow random scripts from the web execute those methods too. Unfortunately, i never was able to find a way to discover where a JS user event handler function originated (from userscript [local] or from the web [remote]). The only time i was able to make that distinction was on the initial load of the userscript. So I erred on the side of caution, and disabled the methods at all other times. So basically, some of those methods are useless. Sorry, but Fluid is totally a freeware/freetime project, and I never got around to trying to fix that. TD On Fri, May 1, 2009 at 10:09 AM, Tubal Martin <[email protected]> wrote: > > Well, first of all, Fluid is a great app, my congrats Todd!!! > > For a regular mac user everything is a breeze and usually works as > expected, however, for developers like me who write userscripts it's > really frustrating to have a Fluid Js API with methods that simply do > not work. > > > I'm using Fluid 0.9.6 > > > The 3 most important methods I need to be working are: > > - window.fluid.addDockMenuItem("mytitle", onclickHandler) > > - The onclick callback function in window.fluid.showGrowlNotification > () > > - window.fluid.activate() > > > No matter how I write my Js code or where I place it in my code, these > methods do not work. > > > Thanks in advance Todd!!! > > > > > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "fluidapp" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/fluidapp?hl=en -~----------~----~----~----~------~----~------~--~---
