Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

LocationProvider, how to sepcify custom Chrome? "UChrm" or "ChromeML"

18 views
Skip to first unread message

Hai Jie Wu

unread,
Oct 10, 2007, 11:49:47 PM10/10/07
to
Hi all,
I'm using Eclipse SWT Browser(V3.3) on Suse Linux 10, which uses
XULRunner version 1.8.0.1. I need to let JVM loaded Xulrunner runtime
find an additional Chrome position, e.g. i want to specify "/home/
tester/.mozilla/eclipse/chrome" as additional chrome directory. So
that the SWT.Browser can load chrome://... in the SWT Browser

SWT Browser has implemented LocationProvider and registered when
initialing XULRunner in JVM, when I tried with SWT.Browser in
debugging, I can see xulrunner
queries for "UChrm" in getFile() and "ChromeML" in getFiles().

In my testing,
A) Hack SWT java code to return "/home/tester/.mozilla/eclipse/chrome"
when getFile() asking for "UChrm".
Result: Nothing happens when I try to visit my Chrome URI.

B) Hacking SWT java code to return an array of Chrome locations when
getFiles() asking for "ChromeML"
"/usr/lib/xulrunner-1.8.0.1/chrome"
"/home/tester/.mozilla/eclipse/chrome"
Result: This time, I can successfully load registered Chrome URIs.

So my question is:
How can we make it work with "UChrm"? Does UChrm suppose to specify
an user Chrome directory?
Because Eclipse SWT.Browser automatically returns "/home/
tester/.mozilla/eclipse/chrome" when asking for "UChrm", bu if I use
"ChromeML", I must hack the SWT open source code.

Mark Finkle

unread,
Oct 11, 2007, 10:40:51 AM10/11/07
to
"UChrm" doesn't appear to be used for general chrome files, only for
"userChrome.css" and "userContent.css" files.

"ChromeML" is the list of folders where general chrome manifests are
know to exist and should be the folder tag you need to use. You should
be able to add your own directory service provider that handles
"ChromeML" and returns your additional folders.

Hai Jie Wu

unread,
Oct 12, 2007, 1:40:35 AM10/12/07
to
Thanks Mark!
0 new messages