Kirix Support Forums

XULRunner 2.0 support?

Please post all general questions, comments, bug reports, and any other wxWebConnect feedback here.

XULRunner 2.0 support?

Postby jdx on Tue Jan 25, 2011 6:55 am

I dropped the current 2.0 beta to replace the 1.9.x version used in the wxWB sample app, it isn't working. I didn't look further yet but are there any obvious problems, like "it doesn't work with 2.0", I should be aware of?
jdx
Registered User
 
Posts: 17
Joined: Wed Jan 19, 2011 2:35 pm

Re: XULRunner 2.0 support?

Postby jonmmorgan on Tue Jan 25, 2011 10:21 pm

I don't expect the current version will work with more than one version at a time. At the moment, 1.9.2 is the best supported. This is because some of the interfaces used change their ID in every release of XULRunner, meaning you.

It would theoretically be possible to support multiple versions by detecting which version is used and using different versions of the interface (as Kirix does to a limited extent with 1.8 and 1.9.2), or by getting some or all of the interfaces from the XULRunner runtime directory rather than hardcoding them in wxWebConnect. To the best of my knowledge, no one has really worked on either of these.

I intend to look into XULRunner 2 support sometime (if no one else has got to it first), but it's unlikely to be for several months.
jonmmorgan
Registered User
 
Posts: 94
Joined: Fri May 14, 2010 9:48 am

Re: XULRunner 2.0 support?

Postby jonmmorgan on Mon Sep 12, 2011 9:41 am

Even several months was an underestimate, but I've started working on this in the last few days. At the moment what I have in a hacked start is starting to work with XR 2.0. Outstanding issues that I know of are:
1. Preferences support doesn't work (and without hacking it it actually stops the engine starting up at all). This requires the (hopefully relatively simple) job of migrating from the deprecated nsIPrefs to the new preferences API.

2. Some of the Javascript string handling functions that my extension ExecuteScriptWithResult() relies on have been removed. I'm still having issues figuring out how to replace them (at the moment, I get random numbers like "9.189052317084192e-300" out whatever I put in).

There could be other issues when I figure out how to fix these, so for now it's very much a work in progress.

I am doing the solution with conditional compilation, so it will be possible to either build a version that targets 1.9.2 or a version that targets 2.0 (but not one that targets both). I think this will be easier to maintain and continue to develop than the multiple interfaces approach used by Kirix to try and support both 1.8 and 1.9.2.
jonmmorgan
Registered User
 
Posts: 94
Joined: Fri May 14, 2010 9:48 am

Re: XULRunner 2.0 support?

Postby jonmmorgan on Tue Sep 13, 2011 8:32 am

I have migrated preferences to use the new preferences interface (which is actually supported in 1.9.2 as well as 2.0).
I have also fixed the problem with ExecuteScriptWithResult (I was using a 2.0 executable with headers from 1.9.2, and the Javascript data structures had changed).

However, I have observed other problems with it:
1. It didn't always seem to get the focus correctly.
2. The up and down arrow keys didn't seem to work within the web control (though the Page Up and Page Down did).

For the moment, I will drop back to 1.9.2 support, since 2.0 didn't fix the list bug I wanted to see fixed and I have a lot more confidence in 1.9.2. At some future point I will probably revisit XULRunner 2.0, and maybe 5.0, 6.0, 7.0, ...

You can see my changes at https://github.com/jonmmorgan/wxwebconnect/.
Note that this also drops support for 1.8, as I do not use it and it got in the way.
jonmmorgan
Registered User
 
Posts: 94
Joined: Fri May 14, 2010 9:48 am

Return to wxWebConnect Questions, Thoughts & Feedback