FF 3.5+ 上的 XPCOM 插件支持
我有一个插件,它基本上是一个 IE 等效的 ActiveX 控件,支持脚本。我正在使用 IDL 文件 &我的插件中的 XPCOM Glue - 在 FF 3.5 之前都可以正常工作。 显然,正如我从几个地方读到的,XPCOM 对插件的支持已经消失,但我仍然能够在 FF3.6 中加载和嵌入插件 - 问题是我无法从 JS 访问方法。
我现在很困惑是完全重写我的插件(删除 XPCOM 胶水)还是将 NPObject 添加到相同的插件代码中以使其工作。任何用于转换的示例代码都会有所帮助,我们将非常感谢您的指导。
I have got a plugin which is basically an IE equivalent ActiveX control, that supports scripting. I'm using the IDL file & XPCOM Glue in my Plugin - this works fine upto FF 3.5.
Apparently as I read from several places that XPCOM support for plugins is gone, but still I'm able to load and embed the plugin in FF3.6 - the problem is I'm not able to access the methods from JS.
I'm now confused whether to re-write my plugin completely(remove the XPCOM glue) or to add NPObject to the same plugin code to make it work. Any sample code for the conversion would help and your guidance would be greatly appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您只需要添加 NPRuntime/NPObject 支持即可使其工作。
您还可以借此机会重写它以使用 FireBreath ,这样相同的代码就可以在 IE 和 FireFox 上运行,但那就是由你决定 =]
我就该主题撰写的有用博客文章:
希望有帮助
You just need to add NPRuntime/NPObject support to make it work.
You could also take the opportunity to rewrite it to use FireBreath so the same code works on both IE and FireFox, but that's up to you =]
Useful blog posts I've written on the subject:
Hope it helps