[richfaces-issues] [JBoss JIRA] Commented: (RF-11266) showcase - Tree Adaptors - selection of nodes does not work and it is possible to expand only one node on IE9

Brian Leathem (JIRA) jira-events at lists.jboss.org
Thu Sep 1 23:50:26 EDT 2011


    [ https://issues.jboss.org/browse/RF-11266?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12625921#comment-12625921 ] 

Brian Leathem commented on RF-11266:
------------------------------------

The reason the above exception is thrown, is because the _deleteNode_ method in jsf.js has special handling in it for IE

{code:title=jsf.js, line 551}
        /**
         * Deletes node
         * @param node
         * @ignore
         */
        var deleteNode = function deleteNode(node) {
            if (!node) {
                return;
            }
            if (!isIE()) {
                // nothing special required
                if (!node.parentNode) {
                    // if there's no parent, there's nothing to do
                    return;
                }
                node.parentNode.removeChild(node);
                return;
            }
            // The rest of this code is specialcasing for IE
            if (node.nodeName.toLowerCase() === "body") {
                // special case for removing body under IE.
                deleteChildren(node);
                try {
                    node.outerHTML = '';
                } catch (ex) {
                    // fails under some circumstances, but not in RI
                    // supplied responses.  If we've gotten here, it's
                    // fairly safe to leave a lingering body tag rather than
                    // fail outright
                }
                return;
            }
            var temp = node.ownerDocument.createElement('div');
            var parent = node.parentNode;
            temp.appendChild(parent.removeChild(node));
            // Now clean up the temporary element
            try {
                temp.outerHTML = ''; //prevent leak in IE
            } catch (ex) {
                // at least we tried.  Fails in some circumstances,
                // but not in RI supplied responses.  Better to leave a lingering
                // temporary div than to fail outright.
            }
        };
{code}

The exception is thrown when the IE specific code is run.  If the execution path is altered to not run the IE specific code, then the component behaves as expected.

It seems as though this is a known JSF issue:
http://java.net/jira/browse/JAVASERVERFACES-2063

> showcase - Tree Adaptors - selection of nodes does not work and it is possible to expand only one node on IE9
> -------------------------------------------------------------------------------------------------------------
>
>                 Key: RF-11266
>                 URL: https://issues.jboss.org/browse/RF-11266
>             Project: RichFaces
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: showcase
>    Affects Versions: 4.1.0.Milestone1
>         Environment: richfaces-showcase-4.1.0.20110805-M1-jee6.war
> container - JBoss AS 6.0.0.Final
> browser - IE 9
>            Reporter: Juraj Huska
>              Labels: ie9
>             Fix For: 4.1.0.Milestone2
>
>
> When I try to select any node, it is not highlighted and it is possible to expand only one node. After expanding one node, clicking on other expand signs does not work.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the richfaces-issues mailing list