[Laszlo-dev] adding sys info to lzpix - issues with dhtml
Jim Grandy
jgrandy at openlaszlo.org
Thu Aug 10 16:34:41 EDT 2006
Is Debug.versionInfo available in non-debug builds?
I was just copying what is used in Laszlo Explorer. If canvas.version
and ?lzt=serverinfo are obsolete, we should update Laszlo Explorer as
well.
jim
On Aug 10, 2006, at 4:51 AM, P T Withington wrote:
> Have a look at Debug.versionInfo, which I think gives all the
> version info you could want. Perhaps this should be promoted out
> of the debugger to be available in any app? (I don't think
> canvas.version is what you want. I believe it is there to enable
> some backwards compatibility, rather than reflect version
> information.)
>
> On 2006-08-10, at 01:20 EDT, Jim Grandy wrote:
>
>> I thought I'd add code to LZPIX to display the OpenLaszlo version
>> (canvas.version) and build number (from app.lzx?lzt=serverinfo). This
>> should help QA (and everyone else) verify what build we have deployed
>> on labs and elsewhere.
>>
>> I added this line after the includes in app.lzx:
>>
>> <dataset name="sinfo" src="http:app.lzx?lzt=serverinfo"
>> request="true" />
>>
>> And these lines after the "links" view:
>>
>> <view name="sysinfo" x="12" y="570">
>> <simplelayout spacing="-3" />
>> <text resize="true" fontsize="9" text="${'OpenLaszlo
>> Version: ' + canvas.version}" />
>> <view>
>> <text fontsize="9" text="OpenLaszlo Build: "/>
>> <text resize="true" fontsize="9" datapath="sinfo:/*/
>> @build"/>
>> <simplelayout axis="x"/>
>> </view>
>> </view> <!-- end sysinfo -->
>>
>> This works nicely in Flash, but I see two problems in DHTML. The
>> first isn't a big deal: canvas.version isn't hooked up yet, so I get
>> 'undefined' -- I'll file a bug.
>>
>> Second, I get a Javascript error in Firefox (and Opera) with the
>> databound text view. The error is "$2 has no properties" and is in
>> the first line of this block of compiled code:
>>
>> 6218 for(var $13=0;$13<$2.childNodes.length;$13++){
>> 6219 if($2.childNodes[$13].nodeType==LzDataNode.ELEMENT_NODE){
>> 6220 $12++
>> 6221 if(!$11||$12>=$11[0]){
>> 6222 $4.push($2.childNodes[$13])
>> 6223 }
>> 6224 if($11&&$12==$11[1]){
>> 6225 break
>> 6226 }
>> 6227 }
>>
>> Have I just run into a place where our XML processing hasn't caught
>> up in DHTML, or is this a bug? If a bug, is it already filed? If not,
>> I'll file one.
>>
>> jim
>> _______________________________________________
>> Laszlo-dev mailing list
>> Laszlo-dev at openlaszlo.org
>> http://www.openlaszlo.org/mailman/listinfo/laszlo-dev
>
More information about the Laszlo-dev
mailing list