Hi Thomas,
yes, you are correct. A "generate source" only complains with a _warning_
like "- Unknown expression as argument to translation method at line ###".
No warnings/complains during "generate build" or "generate lint".
I have a "NO WARNINGS @ compile/build" rule; and I wanted to inform the list
about this possible "workaround".
Cheers,
Peter
On 2010-11-08 15:29 thron7 wrote:
>
> On 11/08/2010 11:13 AM, Peter Schneider wrote:
>> Hi Sak,
>>
>> to be able to use variables as argument of the "tr()" method you have (at
>> least) 2 options:
>>
>> a) Cover it by "eval"
>> <code>
>> // ...
>> var vMessage = getResultStringFromBackend();
>> foo.setLabel( eval("this.tr(vMessage);") );
>> // ...
>> </code>
>>
>> b) Use the "square bracket syntax" to trick the generator (a great trick by
>> Tobias Oetiker; see http://bugzilla.qooxdoo.org/show_bug.cgi?id=2639#c1)
>> <code>
>> // ...
>> var vMessage = getResultStringFromBackend();
>> foo.setLabel( this['tr'](vMessage) );
>> // ...
>> </code>
>
> None of this is necessary anymore since 1.2, look at the linked bug.
>
> T.
------------------------------------------------------------------------------
The Next 800 Companies to Lead America's Growth: New Video Whitepaper
David G. Thomson, author of the best-selling book "Blueprint to a
Billion" shares his insights and actions to help propel your
business during the next growth cycle. Listen Now!
http://p.sf.net/sfu/SAP-dev2dev
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel