ICEfaces
  1. ICEfaces
  2. ICE-6986

Regression: Errors on IE when closing browser after panelTooltip is shown

    Details

    • Assignee Priority:
      P1

      Description

      An error, Stack overflow in IE7 or Out of Memory in IE8, is shown when the browser window is closed after a panelTooltip that uses hideOn="none" is shown. This doesn't seem to be a JavaScript error and there is no stack trace shown in the server logs. These errors are only seen with the ICEfaces EE 1.8.2 P03 release. Other releases are working fine.

        Activity

        Hide
        Arran Mccullough added a comment -

        Attached screen shots of errors and test case. The test case has two pages, plainPage.xhtml will reproduce the error.

        Steps to reproduce issue:

        • Load test case.
        • Hover over the blue box, a tooltip is shown.
        • Close browser, error is shown.

        It doesn't seem to matter if the tooltip is closed or open, it throws the error after its been shown.

        Show
        Arran Mccullough added a comment - Attached screen shots of errors and test case. The test case has two pages, plainPage.xhtml will reproduce the error. Steps to reproduce issue: Load test case. Hover over the blue box, a tooltip is shown. Close browser, error is shown. It doesn't seem to matter if the tooltip is closed or open, it throws the error after its been shown.
        Hide
        Arran Mccullough added a comment -

        Using hideOn="mouseout" seems to work fine.

        Show
        Arran Mccullough added a comment - Using hideOn="mouseout" seems to work fine.
        Hide
        Mircea Toma added a comment -

        The new Prototype 1.7 library seems to be using a simplified test for the existence of the event handlers in Event.stopObserving function:
        Prototype 1.6.* -> if (Object.isUndefined(handler)) { ...
        Prototype 1.7 -> if (!handler) { ...

        When this function is called on page unload to clear the cached handlers (PrototypeJS code) it calls itself recursively when invoked without parameters. The stack overflow occurs when the handler passed in, when Event.observe method is invoked by the tooltip JS code, is the empty string. Event.stopObserving will evaluate it to false and go into an infinite recursive loop.

        Show
        Mircea Toma added a comment - The new Prototype 1.7 library seems to be using a simplified test for the existence of the event handlers in Event.stopObserving function: Prototype 1.6.* -> if (Object.isUndefined(handler)) { ... Prototype 1.7 -> if (!handler) { ... When this function is called on page unload to clear the cached handlers (PrototypeJS code) it calls itself recursively when invoked without parameters. The stack overflow occurs when the handler passed in, when Event.observe method is invoked by the tooltip JS code, is the empty string. Event.stopObserving will evaluate it to false and go into an infinite recursive loop.
        Hide
        Mircea Toma added a comment -

        The fix modifies tooltip JS code to associate a no-op handler instead of '' when using 'none' tooltip configuration to conform to the type of tests Prototype 1.7 is using in Event.stopObserving function.

        Show
        Mircea Toma added a comment - The fix modifies tooltip JS code to associate a no-op handler instead of '' when using 'none' tooltip configuration to conform to the type of tests Prototype 1.7 is using in Event.stopObserving function.
        Hide
        Ken Fyten added a comment -

        Adding icefaces 2 targets.

        Show
        Ken Fyten added a comment - Adding icefaces 2 targets.
        Hide
        Mircea Toma added a comment -

        Applied fix to ICEfaces 2 trunk and maintenance branch.

        Show
        Mircea Toma added a comment - Applied fix to ICEfaces 2 trunk and maintenance branch.

          People

          • Assignee:
            Mircea Toma
            Reporter:
            Arran Mccullough
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: