History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: LPP-4540
Type: Bug Bug
Status: Verified Verified
Resolution: Fixed
Priority: P1 P1
Assignee: Unassigned
Reporter: Benjamin Shine
Votes: 0
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
OpenLaszlo

Laszlo Explorer hierarchical menu does not display in dhtml/firefox/opera/safari

Created: 20/Aug/07 05:05 PM   Updated: 24/Oct/07 02:05 PM
Component/s: SA - Laszlo Explorer
Affects Version/s: 4.0.5WaffleCone
Fix Version/s: 4.0.5WaffleCone

Time Tracking:
Not Specified

File Attachments: 1. Zip Archive lpp-4540.zip (2 kb)


Severity: Critical
Fixed in Change#: 6,299
Runtime: N/A
Fix in hand: False


 Description  « Hide
Go to http://localhost:8080/wafflecone/laszlo-explorer/index.jsp?lzr=dhtml
The left-nav background appears, but the hierarchical menu does not appear.

 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Benjamin Shine - 23/Aug/07 03:01 PM
I've tracked this down to a data loading problem; assigning to Henry for investigation.

Max Carlson - 28/Aug/07 01:41 PM
This broke at r6134:

Change 20070817-ptw-3 by ptw@dueling-banjos.local on 2007-08-17 07:12:53 EDT
    in /Users/ptw/OpenLaszlo/wafflecone
    for http://svn.openlaszlo.org/openlaszlo/branches/wafflecone

Summary: Remove `make` trampoline from Class system

Bugs Fixed:
LPP-1605 'ctor precedence is wrong'
LPP-4365 'Adding prototype functions to builtin objects a bit broken'
LPP-4513 'Compiler Improvements to address performance'

Technical Reviewer: max (Message-ID: <46C62AAF.1070400@openlaszlo.org>)
QA Reviewer: hminsky (pending)

Details:
    LzDefs: Rework LzInheritedHash to not require .make.

    Class: Rework contstructors to call .initialize, .make retained
    for backwards-compatibility. Split out class validation code.

    Compiler: Remove passThroughNodes before dispatching. Print new
    expressions with correct associativity.

    JavascriptGenerator, JavascriptCompressor, CodeGenerator: Remove
    translation of new to .make

    Parser.jjt: Learn how to correctly parse a `new` expressions and
    maintain associativity.

Tests:
    smokecheck in swf7, swf8, dhtml

Max Carlson - 29/Aug/07 10:56 PM
Simplified testcase that shows the issue - the red boxes only show up in debug mode.

Max Carlson - 29/Aug/07 10:58 PM
Okay, so the testcase I attached is a stumper. Not sure why it starts failing as of r6134, or why the red boxes show up in DHTML debug mode, but don't show up in non-debug mode.

P T Withington - 30/Aug/07 05:11 AM
If I remove the indent constraint, the boxes show up. Maybe that is a clue?

P T Withington - 30/Aug/07 08:56 PM
Henry and I tracked it down to the rewrite of LzInheritedHash to operate without make. Henry discovered that either making sure the xtor function had a name (it is normally stripped in non-debug mode) or removing the setting of this.constructor inside that (which was really only intended for debugging), makes things work. Apparently there is something we don't know about setting the constructor property of instances, at least in some Javascript interpreters. This idiom is used elsewhere in our Class code to make inheritance and super calls work, so it apparently is ok, but only sometimes.

The simple fix is to just remove the this.constructor setting from the code (with a comment).

But maybe it is better to not pretend that LzInheritedHash can be made with a new expression at all, to replace all those calls with something like makeInheritedHash which goes back to the simple portable mechanism we had before?

The current implementation has to switch on as/js because as does not allow you to return a value from a constructor (still, even though it is called for by the standard).

P T Withington - 31/Aug/07 07:24 AM
r6299 | ptw | 2007-08-31 10:23:13 -0400 (Fri, 31 Aug 2007) | 19 lines
Changed paths:
   M /openlaszlo/branches/wafflecone/WEB-INF/lps/lfc/core/LzDefs.lzs

Change 20070830-ptw-B by ptw@dueling-banjos.local on 2007-08-30 17:11:24 EDT
    in /Users/ptw/OpenLaszlo/wafflecone-2
    for http://svn.openlaszlo.org/openlaszlo/branches/wafflecone

Summary: Make LzInheritedHash work again

Bugs Fixed:
LPP-4540 'Laszlo Explorer hierarchical menu does not display in dhtml/firefox/opera/safari'

Technical Reviewer: hqm (Message-ID: <8c61fad60708310706p6838294boa435d725ad86a44c@mail.gmail.com>)
QA Reviewer: max (pending)

Details:
    Don't try to set instance constructor, which seems to break Javascript

Tests:
    Max's test case from Jira works correctly in non-debug DHTML

Steve O'Sullivan - 24/Oct/07 02:05 PM
Tested in r6938 on Safari 2.0.4, Opera 9.24 in DHTML and swf7. Hierarchical menus in navbar are rendered. VErified.