On Jul 18, 2005, at 11:47 PM, Martijn Dashorst wrote:

String[][] foo = {{"foo", "bar"}, {"foo", "bar"}};
new ListView("rows", Arrays.toList(foo)){
   public void populateItem(ListItem item) {
       String[] foo = (String[])item.getModelObject();
       add new ListView("cols", Arrays.toList(foo)) {
           public void populateItem(ListItem item2) {
               item2.add(new Label("colvalue", item.getModelObject());
           }
       }
   }
};

should work when you get it compiling.

So that translates to:

 <tbody>
   <tr wicket:id="rows">
     <td wicket:id="cols">...</td>
   </tr>
 </tbody>

The example in the ListView javadoc is a bit odd:

          <tbody>
            <tr id="wicket-rows" class="even">
                <td><span id="wicket-id">Test ID</span></td>

Shouldn't that read wicket:id="rows" and wicket:id="id" ?

 S.



-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
Wicket-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to