如何使用FireBreath创建ActiveX包装器? [英] How is an ActiveX wrapper created with FireBreath?

查看:190
本文介绍了如何使用FireBreath创建ActiveX包装器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我浏览了FireBreath(FB)网站上的Windows和Mac视频教程,所有文档,甚至看过一个人提供的ActiveX示例。

I've been through the Windows and Mac video tutorials on the FireBreath (FB) website, through all the documentation and even seen the ActiveX example that a person has provided.

已经整整一周了,但我仍然不明白如何在FB中创建新项目。网站上唯一说明的是如何编译FB sln,其中已经编写了PluginTest示例。即使对于ActiveX示例,也仅给出代码。没有说明他们如何创建项目。

It's been an entire week, but I still can't understand how to create a new project in FB. The only thing explained on the website is how to get the FB sln compiled, where the PluginTest example is already coded. Even for the ActiveX example, only the code is given. It isn't explained as to how they created the project.

那么如何在FB中创建一个新项目?是否应该仅使用现有的FB sln文件并在其中创建一个新的空项目?我如何知道应该向项目添加哪些类?如何编辑cmakeLists.txt以识别我的项目?运行prep2010.cmd如何使新添加的项目编译?

So how do I create a new project in FB? Should I just take the existing FB sln file and create a new empty project in it? How do I know what classes I should add to the project? How do I edit cmakeLists.txt to recognize my project? How does running prep2010.cmd make my newly added project compile?

如果我需要为ActiveX创建包装,我该如何在Windows中创建该项目?

If I need to create a wrapper for my ActiveX, how do I go about creating that project in Windows?

推荐答案

如果您已经看完了Windows视频教程,但没有看到如何创建新项目,那么您显然就没有注意。 windows mac 告诉您如何使用fbgen创建新项目。

If you have been through the windows video tutorials and didn't see how to create a new project then you were obviously not paying attention. The first video tutorial on both windows and mac tells you how to use fbgen to create a new project.

要获取文字说明,您可以轻松找到它们:

To get text instructions, you can find them fairly easily:

转到 http://firebreath.org ,然后单击 入门。向下滚动到 创建新的插件项目,然后单击

Go to http://firebreath.org and click on "Getting Started". Scroll down to "Creating a new plugin project" and click on the link.

这两种方法基本上都将引导您完成以下步骤:

Either method will walk you through essentially the following steps:

1)安装可视的cmake studio和python(如果没有),则$​​ b $ b 2)获取FireBreath(视频教程建议使用git;我制作了这些教程,因此您可以猜出我的建议方法)。
3)使用python运行fbgen.py并遵循以下步骤。

1) Install cmake, visual studio, and python (if you don't have any of them) 2) Get FireBreath (the video tutorials suggest using git; I made the tutorials, so you can guess my suggested method). 3) Run fbgen.py with python and follow the steps.

恭喜!您现在已经创建了一个新的插件项目!

Congratulations! You have now created a new plugin project!

构建它,您需要运行适合您平台的prep脚本,然后在(visual studio | xcode)中打开build / FireBreath。(sln | xcodeproj)文件。请注意,这取决于您使用的是 Windows 还是 Mac

To build it, you'll need to run the prep script appropriate for your platform and then open the build/FireBreath.(sln | xcodeproj) file in (visual studio | xcode). Note that this differs a bit depending on whether you're on Windows or Mac.

准备脚本(例如prep2010.cmd)不会使您的项目编译;而是使用cmake为您的计算机生成该项目的项目文件,然后将其用于构建项目,如上面链接的页面所述。永远不要直接在构建目录中修改任何内容,而应该在项目目录中修改CMakeLists.txt文件,或者,如果需要进行特定于平台的更改,则可以修改Win / projectDef.cmake和Mac / projectDef.cmake

The prep script (such as prep2010.cmd) does not make your project compile; instead it uses cmake to generate the project files for that project for your computer which can then be used to build the project, as explained in the pages linked above. You should never modify anything in the build directory directly, instead you should modify the CMakeLists.txt file in your project directory or if you have platform-specific changes you need to make you can modify Win/projectDef.cmake and Mac/projectDef.cmake.

FireBreath.org是一个Wiki,因此可以随时帮助我们使这些内容更容易找到;正如您从链接中看到的那样,所有信息都在那里。对我来说,这似乎很容易找到,所以显然我不是一个解决问题的好人(因为我看不到)。

FireBreath.org is a wiki, so feel free to help us make these things easier to find; as you can see from the links all of the information is there. To me it seems easy to find, so obviously I'm not a good one to try to fix the problem (since I can't see it).

制作ActiveX包装器时,有一个执行此操作的示例,但这并不是简单易行做。 FireBreath绝不尝试将其简化为简单操作-这不是FireBreath的目的。 FireBreath只是用于创建浏览器插件的框架。如果您希望您的插件充当Activex包装器,则必须实现所有ActiveX来包含您自己的控件。

As for making an ActiveX wrapper, there is an example of doing this but it's not really something that is just "easy to do". FireBreath does not in any way attempt to make this a simple thing to do -- that's not the purpose of FireBreath. FireBreath is simply a framework for creating browser plugins; if you want your plugin to act as an activex wrapper you'll have to implement all of the activex for containing your control yourself.

希望这是足够的信息,可以帮助您入门。如果您感到困惑,请阅读这些链接。如果您仍然感到困惑,请再次阅读它们-所有这些信息都在那里。如果您仍然感到困惑,请在IRC上的 FireBreath聊天室询问,我将尽力帮助您出来。

Hopefully that's enough information to get you started. If you are confused, please go read those links. If you're still confused, read them again -- all of this information is there. If you're still confused, come ask in the FireBreath chat room on IRC and I'll try to help you figure it out.

这篇关于如何使用FireBreath创建ActiveX包装器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆