Pergunta

Doing a bit of a research on Mozilla's XUL framework. I've built a desktop app on a Mac and now I'm wondering is it possible to include a dynamic library written in C++ to the app or use a C++ code? If yes, how can I do this?

Thanks, Peter

Foi útil?

Solução

Yes, via XPCOM. You can't just include random libraries as JavaScript can't call native functions.

Outras dicas

Yes! I was looking into the same thing as you and I found that you need Mozilla rendering engine Gecko in the form of an SDK to do this task. Essentially you can parse C++ and XUL and the output will be printed in a window generated by the engine. You can also parse other languages like HTML, CSS, ext. Note that you may have to use some Javascript to make changes to the output on the front end generated by your c++ code.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top