[ https://issues.apache.org/jira/browse/WICKET-19?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor Vaynberg resolved WICKET-19. --------------------------------- Resolution: Fixed Fix Version/s: 1.3 > putting the size attr on ListChoice vs ListMultipleChoice > --------------------------------------------------------- > > Key: WICKET-19 > URL: https://issues.apache.org/jira/browse/WICKET-19 > Project: Wicket > Issue Type: Improvement > Components: wicket > Affects Versions: 1.2.2 > Environment: JDK 1.5.0_07 > Reporter: Chuck Deal > Priority: Minor > Fix For: 1.3 > > > In working with both ListChoice and ListMultiple choice, the two components > are not consistent when applying the size attr. ListMultipleChoice has a > better approach. > from ListMultipleChoice: > protected final void onComponentTag(final ComponentTag tag) > { > super.onComponentTag(tag); > tag.put("multiple", "multiple"); > > if (!tag.getAttributes().containsKey("size")) > { > tag.put("size", Math.min(maxRows, getChoices().size())); > } > } > This is better for extension purposes because the method is final. It won't > blindly set the size attr as it does on ListChoice. Actually, the real > change that I want is the value that gets applied to the attr in > ListMultipleChoice. But, by adjusting the code to include a check for the > attr first, I could attach a behavior to modify the size attr instead. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.