Hi,

I'm still working on my JS i18n-support-stuff. Next roadblock: so far, I 
refered to JS for my widgets like this:

js_dir = pkg_resources.resource_filename("i18ntest",
                                          "static/javascript")
w.register_static_directory("i18ntest", js_dir)

test_js = w.JSLink("i18ntest", "test.js")

But as I want to include the i18n-js-code from a standard TG-widget (the 
same way mochikit can be included), I wondered if there is a way for a 
TG-widget to get a referennce to the running projects static directories 
so that I can just add

tg.include_widgets = ['turbogears.js_i18n']

to app.cfg and then use

/static/javascript/messages-en.js

for the catalog files.

If there is no way, then I'd be interested in any other way to 
default-include a certain widget in every page. I would then settle for 
something like

js_i18n_widget = turbogears.i18n.JSI18NWidget(jsdir="i18ntest")

Any suggestions?

Diez


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to