如何在Mac中的Opera上开发NPRuntime插件?
我最近为 Mac OS X 上的网络浏览器开发了插件。
由 XCode 开发,我的包位于 /Library/Internet Plug-ins 中。
Chrome、Safari、Firefox 可以捕获此插件,但 Opera 不能。
我的插件如何被 Opera 捕获?
I have recently developed the plugin for web browsers on Mac OS X.
Developed by XCode, my bundle located in /Library/Internet Plug-ins.
Chrome, Safari, Firefox catch this plugin but Opera doesn't.
How can my plugin be caught by Opera?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
如果没有有关插件的更多信息,很难回答您的问题。
该插件必须位于“/Library/Internet Plug-ins”中,并且捆绑包必须具有 .plugin 扩展名而不是 .bundle。该插件是否列在 opera:plugins 中?
Mozilla 开发者网络有关插件的文章应该非常有用。
Daniel,Opera Software ASA 的 Mac 质量保证人员。
It’s difficult to answer your question without more information about your plug-in.
The plug-in must be located in “/Library/Internet Plug-ins” and the bundle must have a .plugin extension instead of .bundle. Is the plug-in listed in opera:plugins?
This Mozilla Developer Network article on plug-ins should be very useful.
Daniel, Mac Quality Assurance at Opera Software ASA.
如何声明插件信息(名称、版本、MIME 类型等)?大多数浏览器支持新的 Info.plist 方法,但 Opera 可能要求您还使用旧的基于资源的方法。
How do you declare your plugin info (name, version, MIME types, etc.)? Most browsers support the new Info.plist method, but it may be that Opera requires that you also use the old resource-bassed approach.
尝试创建一个 FireBreath 插件,然后看看它的工作方式与您构建自己的插件的方式有何不同。或者,只需使用 FireBreath 插件——它比从头开始制作 NPAPI 插件要容易得多,并且可以解决许多浏览器问题和不一致问题。
FireBreath 插件在 mac 上作为 NPAPI 插件工作,并且据报道可以在 Opera 中工作。
Try creating a FireBreath Plugin and then look at what differs between how it works and how you built yours. Alternately, just use a FireBreath plugin -- it's a heck of a lot easier to deal with than making your NPAPI plugin from scratch and works around a lot of browser issues and inconsistencies.
FireBreath plugins work as NPAPI plugins on mac and have been reported to work in Opera.
我花了几周的时间寻找解决方案,但它看起来非常简单:将 YourPlugin.bundle 重命名为 YourPlugin.plugin !
甚至不需要 .rsrc 文件,因为它是其他地方推荐的。
:)
I spent weeks looking for the solution, but it appeared incredibly simple: rename YourPlugin.bundle to YourPlugin.plugin !
Did not even require the .rsrc file as it was recommended elsewhere.
:)
当 Opera 没有加载插件时,您可以尝试将插件放入 /Library/Internet Plug-Ins/ 中。
我不知道为什么会发生这种情况,因为 Opera 说它可以放在 @ ~/Library/Internet Plug-ins/ Opera 文档
You could try putting you plugin in /Library/Internet Plug-Ins/ When opera didn't load the plugin.
I do not know why this will happen since opera said it could be put @ ~/Library/Internet Plug-ins/ Opera Document