ICEfaces
  1. ICEfaces
  2. ICE-11153

refactor duplicated code in CheckboxButton & CheckboxButtons renderers as well as RadioButton and RadioButtons renderers

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.0, EE-4.1.0.GA
    • Fix Version/s: 4.2.BETA, 4.2
    • Component/s: ACE-Components
    • Labels:
      None
    • Environment:
      jsf2 ace

      Description

      duplicate code in the renderers to be refactored.

        Activity

        Judy Guglielmin created issue -
        Judy Guglielmin made changes -
        Field Original Value New Value
        Assignee Judy Guglielmin [ judy.guglielmin ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #49347 Fri Oct 07 14:01:28 MDT 2016 judy.guglielmin ICE-11153 refactored Checkbox components to extend common methods and reduce number of method calls to private methods.
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/ace/component/src/org/icefaces/ace/component/checkboxbuttons/CheckboxButtonsRenderer.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/ace/component/resources/icefaces.ace/checkboxbutton/checkboxbutton.js
        Commit graph MODIFY /icefaces4/trunk/icefaces/ace/component/src/org/icefaces/ace/component/checkboxbutton/CheckboxButtonRenderer.java
        Hide
        Judy Guglielmin added a comment -

        rev 49350

        Show
        Judy Guglielmin added a comment - rev 49350
        Judy Guglielmin made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #49350 Tue Oct 11 17:04:51 MDT 2016 judy.guglielmin ICE-11153 refactor
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/ace/component/src/org/icefaces/ace/component/radiobutton/RadioButtonRenderer.java
        Commit graph MODIFY /icefaces4/trunk/icefaces/ace/component/src/org/icefaces/ace/component/radiobuttons/RadioButtonsRenderer.java
        Hide
        Carmen Cristurean added a comment -

        ICEfaces4 trunk r.49351: a ClassCastException popup occurs when trying to navigate to the ace:radioButtons demos in showcase.
        This was not an issue on r49348.

        Oct 12, 2016 9:51:18 AM com.sun.faces.context.AjaxExceptionHandlerImpl handlePartialResponseError
        SEVERE: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Boolean
        at org.icefaces.ace.component.radiobuttons.RadioButtonsRenderer.encodeButton(RadioButtonsRenderer.java:229)
        at org.icefaces.ace.component.radiobuttons.RadioButtonsRenderer.encodeEnd(RadioButtonsRenderer.java:137)
        at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:920)
        at org.icefaces.ace.renderkit.CoreRenderer.renderChild(CoreRenderer.java:79)
        at org.icefaces.ace.renderkit.CoreRenderer.renderChildren(CoreRenderer.java:63)
        at org.icefaces.ace.component.panel.PanelRenderer.encodeContent(PanelRenderer.java:289)
        at org.icefaces.ace.component.panel.PanelRenderer.encodeMarkup(PanelRenderer.java:136)
        at org.icefaces.ace.component.panel.PanelRenderer.encodeEnd(PanelRenderer.java:75)
        at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:920)
        .......

        Show
        Carmen Cristurean added a comment - ICEfaces4 trunk r.49351: a ClassCastException popup occurs when trying to navigate to the ace:radioButtons demos in showcase. This was not an issue on r49348. Oct 12, 2016 9:51:18 AM com.sun.faces.context.AjaxExceptionHandlerImpl handlePartialResponseError SEVERE: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Boolean at org.icefaces.ace.component.radiobuttons.RadioButtonsRenderer.encodeButton(RadioButtonsRenderer.java:229) at org.icefaces.ace.component.radiobuttons.RadioButtonsRenderer.encodeEnd(RadioButtonsRenderer.java:137) at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:920) at org.icefaces.ace.renderkit.CoreRenderer.renderChild(CoreRenderer.java:79) at org.icefaces.ace.renderkit.CoreRenderer.renderChildren(CoreRenderer.java:63) at org.icefaces.ace.component.panel.PanelRenderer.encodeContent(PanelRenderer.java:289) at org.icefaces.ace.component.panel.PanelRenderer.encodeMarkup(PanelRenderer.java:136) at org.icefaces.ace.component.panel.PanelRenderer.encodeEnd(PanelRenderer.java:75) at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:920) .......
        Carmen Cristurean made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Hide
        Judy Guglielmin added a comment -

        rev 49353

        Show
        Judy Guglielmin added a comment - rev 49353
        Judy Guglielmin made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #49353 Wed Oct 12 11:21:15 MDT 2016 judy.guglielmin ICE-11153 fix regression in refactoring
        Files Changed
        Commit graph MODIFY /icefaces4/trunk/icefaces/ace/component/src/org/icefaces/ace/component/radiobuttons/RadioButtonsRenderer.java
        Carmen Cristurean made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Hide
        Carmen Cristurean added a comment - - edited

        The changes for RadioButton checked in at r 49350 (Jenkins Build #2131) are causing a regression in emporium sample application; this is still an issue at Jenkins Build #2147.

        Browser console errors occur in all browsers if navigating from "Auction List" tab to "Settings" (containing radioButtons), and back to "Auction List". Also, the auction items fail to render on return to the "Auction List" tab, until the page is reloaded (F5).

        Chrome:
        Uncaught TypeError: Cannot read property 'hasChildNodes' of undefined(…)moveSafeToContent @ ace-tabset.js.jsf?ln=icefaces.ace&v=4_2_0_161019:143handlePotentialTabChanges @ ace-tabset.js.jsf?ln=icefaces.ace&v=4_2_0_161019:142updateProperties @ ace-tabset.js.jsf?ln=icefaces.ace&v=4_2_0_161019:136(anonymous function) @ VM396:1runScripts @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1doUpdate @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1response @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1onComplete @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1AjaxEngine.req.xmlReq.onreadystatechange @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1

        FF47:
        TypeError: c is undefined
        http://localhost:8080/emporium1/javax.faces.resource/util/ace-tabset.js.jsf?ln=icefaces.ace&v=4_2_0_161018
        Line 143

        IE11/MS Edge38:
        SCRIPT5007: Unable to get property 'hasChildNodes' of undefined or null reference
        File: ace-tabset.js.jsf, Line: 143, Column: 309

        Show
        Carmen Cristurean added a comment - - edited The changes for RadioButton checked in at r 49350 (Jenkins Build #2131) are causing a regression in emporium sample application; this is still an issue at Jenkins Build #2147. Browser console errors occur in all browsers if navigating from "Auction List" tab to "Settings" (containing radioButtons), and back to "Auction List". Also, the auction items fail to render on return to the "Auction List" tab, until the page is reloaded (F5). Chrome: Uncaught TypeError: Cannot read property 'hasChildNodes' of undefined(…)moveSafeToContent @ ace-tabset.js.jsf?ln=icefaces.ace&v=4_2_0_161019:143handlePotentialTabChanges @ ace-tabset.js.jsf?ln=icefaces.ace&v=4_2_0_161019:142updateProperties @ ace-tabset.js.jsf?ln=icefaces.ace&v=4_2_0_161019:136(anonymous function) @ VM396:1runScripts @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1doUpdate @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1response @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1onComplete @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1AjaxEngine.req.xmlReq.onreadystatechange @ jsf.js.jsf?ln=javax.faces&v=4_2_0_161019:1 FF47: TypeError: c is undefined http://localhost:8080/emporium1/javax.faces.resource/util/ace-tabset.js.jsf?ln=icefaces.ace&v=4_2_0_161018 Line 143 IE11/MS Edge38: SCRIPT5007: Unable to get property 'hasChildNodes' of undefined or null reference File: ace-tabset.js.jsf, Line: 143, Column: 309
        Hide
        Liana Munroe added a comment - - edited

        Tested emporium application with ICEfaces 4 trunk r49461 using Tomcat 8, FF 47, IE 11, Chrome 53, mojarra and myfaces libs. I was no longer able to reproduce the regression issues as listed in the previous comment.

        Show
        Liana Munroe added a comment - - edited Tested emporium application with ICEfaces 4 trunk r49461 using Tomcat 8, FF 47, IE 11, Chrome 53, mojarra and myfaces libs. I was no longer able to reproduce the regression issues as listed in the previous comment.
        Hide
        Judy Guglielmin added a comment - - edited

        resolved with work on ICE-11155

        Show
        Judy Guglielmin added a comment - - edited resolved with work on ICE-11155
        Judy Guglielmin made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Affects Version/s EE-4.1.0.GA [ 12171 ]
        Affects Version/s EE-4.1.1.BETA [ 13079 ]
        Ken Fyten made changes -
        Fix Version/s 4.2.BETA [ 13091 ]
        Fix Version/s 4.2 [ 12870 ]
        Ken Fyten made changes -
        Affects Version/s 4.0 [ 11382 ]
        Ken Fyten made changes -
        Issue Type Bug [ 1 ] Improvement [ 4 ]
        Security Private [ 10001 ]
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Judy Guglielmin
            Reporter:
            Judy Guglielmin
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: