On 03/23/2010 06:15 PM, caio ariede wrote:
> I have a variable called __static_path, defined before all <script> that
> indicates where my static contents is stored.
> 
> In the code generated by qooxdoo I have the following line:
> 
> var libinfo = 
> {"__out__":{"sourceUri":"static/script"},"chat":{"resourceUri":"static/resource",
> 
> 
> That I configures through config.json:
> 
>  64     "build-script" :
>  65     {
>  66       "compile-options" :
>  67       {
> ...
>  76         "uris"   :
>  77         {
>  78           "script" : "static/script",
>  79           "resource" : "static/resource"
>  80         }
>  81       }
>  82     }
> 
> But how can I specify variable (__static_path) in config.json?

I presume __static_path is somewhat dynamic, so there is no way to have
it at compile time (ie. in the config). If this isn't true and you know
the value of __static_path at compile time, you can use a macro and pass
this in with the invocation of the generator with the -m option (e.g.
generate.py -m StaticPath:<value> ...).

If the __static_path is only known at load time of your application, you
should use the 'decode-uris-plug' (see the thread earlier this week).
This allows you to re-write the URIs used to access resources, using
__static_path (which, obviously, has to be a global variable at this point).

HTH,
T.

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to