npapi

Developing an out-of-process browser plugin on Mac OS X v10.6 -- restriction against platform APIs?

I'm currently developing a browser plugin for MacOSX 10.6, and am planning to use the netscape API for portability across browsers and architectures. According to Apple's documentation, as of 10.6 such plugins run out-of-process to improve the integrity of the browser session. What I'm concerned about is the following directive they give...

NPAPI plugin in QTWebKit

I know its possible to integrate NPAPI plugins with QTWebKit as its been supported since the release of QT 4.5. My question is, should I go and design my plugin according to the Mozilla/Gecko documentaion -Which is probably the only available/reliable documentation for NPAPI beside some really old book called "Programming NetScape Plug-...

Non-drawing Mozilla plug-in

I have some dll that implements some logic. I want to create wrapper that will be accessible from JavaScript of HTML page in Mozilla browser. I have found npruntime framework,but it seems supports only window control, i don't need GUI. I am looking for mechanism like ActiveXObject implemented in Internet Explorer. ...

Firefox 3.6 plugins fail on Mac?

I just upgraded my mac to Firefox 3.6, and now neither of my TIFF Viewing plugins work. in 3.5, If I had Quicktime on, then I'd get the tiff, viewed through quicktime. If I had Quicktime disabled, but my own plugin, AcellViewTIFF enabled, then I would get ViewTIFF viewing the TIFF. Since I'm the author of ViewTIFF, That's how I had it ...

NPAPI plugin : NPN_Invoke returns false

Hi, I have the following code in my npapi plugin: NPIdentifier idcreate = NPN_GetStringIdentifier("createElement"); NPVariant ret; VOID_TO_NPVARIANT(ret); NPVariant arg; STRINGZ_TO_NPVARIANT("div",arg); bool result = NPN_Invoke(instance(), NPVARIANT_TO_OBJECT(doc), idcreate, &arg, 1, &ret); The return ...

NPAPI plugin inject script

Hi, I'm developing an npapi plugin. I am trying to inject a script into the current webpage of the browser,but am not able to do it. Any hints or suggestions as to how i should proceed with it, would be really helpful. Thanks ...

compile npapi plugin in Mac OSX?

I only have ssh access to a Mac OSX 10.6 computer, so, Xcode is out of scope. Currently, I have trouble to figure out the right format of g++ output: do I need to append -shared and -fPIC, or -dynamiclib or other magic flag in order to get a firefox recognizable binary? ...

Npapi set timer function

I'm still running Firefox 2.0.0. For backward compatibility reasons I'd like to know weather there is a easy way to replace the NPN_PluginThreadAsyncCall, NPN_ScheduleTimer mechanism that the newer npapi supplies. The only solution that I would come up with is to evaluate a javascript "setTimeout" that would call the plugin then ......

Firefox Gecko SDK : NPP_GetValue not getting called

Hi, I have tried out the NPRuntime sample provided with the Gecko SDK 1.9.1 with the help of this link. It works perfectly fine with Firefox 3.6. Following the above steps I created a new scripting plugin (npmyplugin.dll). I am currently placing npmyplugin.dll in a folder other than Firefox/plugins. I am registering the associated mim...

How can I get an NPAPI plugin to read an "src" tag

Hi, i'm a little stuck on getting a plugin to work. I need it to take a "src" parameter but I can't seem to make it do this. So i've basically got the npsimple basic plugin. It's probably something really silly i'm missing Joe ...

Same origin policy javascript

Hi, I'm writing an NPAPI plugin that injects a script with a src located at my server. After the injection, my plugin tries to call a function in the script. But this doesnt seem to work. I think the reason is the same origin policy, but im not sure how to overcome it. The call to the function works if i inject the script code complete...

How come NPRuntime require xpt file ?

I am trying to make sense of whatever I learned about NPRuntime. Here is a example of NPRuntime plugin from from mozilla-central of NPRuntime plugin, which mentions following lines // ============================== 145 // ! Scriptability related code ! 146 // ============================== 147 // 148 // here the plugin is asked by Mozi...

Embedded Webkit - script callbacks how?

On windows, when the "Shell.Explorer" ActiveX control is embedded in an application it is possible to register an "external" handler - on object that implements IDispatch, such that scripts on the web page can call out to the hosting application. <button onclick="window.external.Test('called from script code')">test</button> Now, ive ...

sample mac Firefox Plugins?

I'm trying to re-write an old image-viewing plugin for the mac. The old version uses QuickDraw (I said it was old) and resources (really really old) and so it doesn't work in Firefox 3.6 (which is why I'm re-writing it) I know some Objective C, and so I figure I'm going co re-write this in that using new-fangled Mac routines and nibs, e...

Show a window from 32-bit NPAPI Plugin in 64-bit Safari

I have an old NPAPI plugin for OS X that I'm trying to refit for use with Snow Leopard's version of Safari. My problem is that when I switch Safari to 64-bit mode, it changes the plugin environment to out of process mode (where plugins are hosted by a 32-bit WebKitPluginHost process). And now my toolbar palettes are not visible on screen...

Screen capture from NPAPI or javascript

Hi, I'm writing an npapi plugin. I was wondering if there is a way to capture the browser screen from my plugin using either npapi or javascript. Any help would be appreciated. Thanks ...

Event path in Mozilla plugin on Mac

I'm writing a mozilla plugin on the mac. I'm trying to capture events like button clicks, etc. I've done the normal thing of creating my views in inteface builder, and linking the sentActions to methods in my program. This works in stand-alone programs. However, in my NPAPI plugin, those methods never get called. The button reacts, depr...

Chrome plugin process - npapi plugin

Hi, I'm writing an npapi plugin in Qt. My plugin works perfectly on firefox and opera. The problem in chrome i guess is regarding the "process-per-plugin" setup. What happens is, when i first open a page, the plugin is injected and all works as per expected. But when i navigate from that page to another one, in the new page, the plugin s...

Chrome plugin removal

Hi, I'm writing an NPAPI plugin. In every webpage that the browser goes to, I inject my plugin with an object tag. Something like: <object id="myplugin" type="plugin-mime-type" > In some pages where i dont want it, after injection i remove it by finding the element using the id and doing a document.removeChild. From my logging i found...

Any general purpose NPAPI plugin to invoke external download tools?

Hi all, I am looking for a general purpose NPAPI plugin that can used to invoke GetRight/FlashGet/OrbitDownloader/InternetDownloadManager/etc. Has anyone written that already? It's like FlashGot for NPAPI browsers. ...