You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Peter Parson (JIRA)" <ji...@apache.org> on 2008/12/06 09:31:44 UTC
[jira] Created: (WICKET-1969) Add IRepeatableBehavior for
DataViews, ListViews etc.
Add IRepeatableBehavior for DataViews, ListViews etc.
------------------------------------------------------
Key: WICKET-1969
URL: https://issues.apache.org/jira/browse/WICKET-1969
Project: Wicket
Issue Type: Wish
Components: wicket
Reporter: Peter Parson
Having an IRepeatableBehavior for repeatable views (allowing hooking into populateItem) would be quite useful. There are quite common tasks one could stuff into those behaviors, e.g.
* apply CSS class names to list item element dependent on index (e.g. first, last, odd, even)
* output separators for all but the last item
* show/hide elements depending on index, e.g. to clear CSS float after 5 items or display table header row every 20th line
Things like that are implemented frequently. Sublassing every repeatable once for this purpose would be an option, however I think this would be better as behavior, even more since there are several types of repeatable components.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WICKET-1969) Add IRepeatableBehavior for
DataViews, ListViews etc.
Posted by "Peter Parson (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-1969?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Peter Parson updated WICKET-1969:
---------------------------------
Priority: Minor (was: Major)
> Add IRepeatableBehavior for DataViews, ListViews etc.
> ------------------------------------------------------
>
> Key: WICKET-1969
> URL: https://issues.apache.org/jira/browse/WICKET-1969
> Project: Wicket
> Issue Type: Wish
> Components: wicket
> Reporter: Peter Parson
> Priority: Minor
>
> Having an IRepeatableBehavior for repeatable views (allowing hooking into populateItem) would be quite useful. There are quite common tasks one could stuff into those behaviors, e.g.
> * apply CSS class names to list item element dependent on index (e.g. first, last, odd, even)
> * output separators for all but the last item
> * show/hide elements depending on index, e.g. to clear CSS float after 5 items or display table header row every 20th line
> Things like that are implemented frequently. Sublassing every repeatable once for this purpose would be an option, however I think this would be better as behavior, even more since there are several types of repeatable components.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (WICKET-1969) Add IRepeatableBehavior for
DataViews, ListViews etc.
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-1969?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor Vaynberg resolved WICKET-1969.
-----------------------------------
Resolution: Won't Fix
Assignee: Igor Vaynberg
each repeater in wicket provides easy access to item generation via a factory method. it is trivial to implement it like so:
mylistview#newlistitem() { item i=super.newlistitem(); i.add(mybehavior); return i; }
> Add IRepeatableBehavior for DataViews, ListViews etc.
> ------------------------------------------------------
>
> Key: WICKET-1969
> URL: https://issues.apache.org/jira/browse/WICKET-1969
> Project: Wicket
> Issue Type: Wish
> Components: wicket
> Reporter: Peter Parson
> Assignee: Igor Vaynberg
> Priority: Minor
>
> Having an IRepeatableBehavior for repeatable views (allowing hooking into populateItem) would be quite useful. There are quite common tasks one could stuff into those behaviors, e.g.
> * apply CSS class names to list item element dependent on index (e.g. first, last, odd, even)
> * output separators for all but the last item
> * show/hide elements depending on index, e.g. to clear CSS float after 5 items or display table header row every 20th line
> Things like that are implemented frequently. Sublassing every repeatable once for this purpose would be an option, however I think this would be better as behavior, even more since there are several types of repeatable components.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WICKET-1969) Add IRepeatableBehavior for
DataViews, ListViews etc.
Posted by "Timo Rantalaiho (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-1969?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12656984#action_12656984 ]
Timo Rantalaiho commented on WICKET-1969:
-----------------------------------------
By overriding newItem you can do this quite easily already.
There's already OddEvenItem (or OddEvenRowItem or something
like that).
> Add IRepeatableBehavior for DataViews, ListViews etc.
> ------------------------------------------------------
>
> Key: WICKET-1969
> URL: https://issues.apache.org/jira/browse/WICKET-1969
> Project: Wicket
> Issue Type: Wish
> Components: wicket
> Reporter: Peter Parson
> Priority: Minor
>
> Having an IRepeatableBehavior for repeatable views (allowing hooking into populateItem) would be quite useful. There are quite common tasks one could stuff into those behaviors, e.g.
> * apply CSS class names to list item element dependent on index (e.g. first, last, odd, even)
> * output separators for all but the last item
> * show/hide elements depending on index, e.g. to clear CSS float after 5 items or display table header row every 20th line
> Things like that are implemented frequently. Sublassing every repeatable once for this purpose would be an option, however I think this would be better as behavior, even more since there are several types of repeatable components.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.