Say, for example, I look at the examples that come with the API. I
can run the examples doing something like:
/usr/bin/ggl-gtk -sa -nd -gp api/samples/gadgets/HelloWorld
and I get a nice, standalone version of the HelloWorld that I can play
with. I can zip this up into a .gg file and embed it into my desktop
if I want.
I would like to be able to use the gadgets API within these apps,
specifically something like:
var prefs = new gadgets.Prefs();
var lang = prefs.getLang(); // returns ISO 639-1 language code
var country = prefs.getCountry(); // returns ISO 3161-1 alpha 2 code
but when I do, I get:
main.js:24: ReferenceError: gadgets is not defined.
Using the regular examples where you have modules deployed to the web
which look like this:
<?xml version="1.0" encoding="UTF-8" ?>
<Module>
<ModulePrefs title="hello world example" />
<Content type="html">
<![CDATA[
<insert javascript stuff here>
]]>
</Content>
</Module>
the gadgets.Prefs() works fine. I guess what I want to know is, what
is the difference between projects defined like the above
HelloWorld.xml and projects like a HelloWorld.gg?
cheers,
Kris
--
You received this message because you are subscribed to the Google Groups "google-gadgets-for-linux-user" group.
To post to this group, send email to google-gadgets...@googlegroups.com.
To unsubscribe from this group, send email to google-gadgets-for-l...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-gadgets-for-linux-user?hl=en.