Martijn,
I tried your solustion(s), but the CSS class of the topicLabel still
not updated.
public TestPage() {
final WebMarkupContainer container = new
WebMarkupContainer(container);
container.setOutputMarkupId(true);
container.add(new ListViewCategory(categories,
Ive got a very similar thing working.
I think you may have to return the highlight value dynamically. Try this
alternative:
item.add(new AttributeModifier(class, true, new AbstractReadOnlyModel() {
@Override public Object getObject() {
return highlight
}
});
On Tue, Jun 23, 2009 at
Thanks Vasu for your replay.
I've tried your suggestion, but didn't work. This is what I get in the
Ajax debuger when I click a certain item:
...
li
a id=topicLink31 href=# onclick=var
I see you are trying to add the class modifier to item which is ListItem
and thats not a HTML component.
In my case, I was adding it to the link or label. I think you may have to do
something like
item.add(new Label(...).add(new AttributeModifier(class, new
AbstractReadOnlyModel() ...
etc.
On
Thanks again Vasu,
I've tried your solution but it does not work yet. Below my code:
public TestPage() {
final WebMarkupContainer container = new
WebMarkupContainer(container);
container.setOutputMarkupId(true);
container.add(new ListViewCategory(categories,
listview.setReuseItems(true)
Martijn
On Wed, Jun 24, 2009 at 5:03 PM, Azzeddine Daddahwaarhei...@gmail.com wrote:
Thanks again Vasu,
I've tried your solution but it does not work yet. Below my code:
public TestPage() {
final WebMarkupContainer container = new
or *always* add the attribute modifier and only output the class value
when needed.
Martijn
On Wed, Jun 24, 2009 at 5:13 PM, Martijn
Dashorstmartijn.dasho...@gmail.com wrote:
listview.setReuseItems(true)
Martijn
On Wed, Jun 24, 2009 at 5:03 PM, Azzeddine Daddahwaarhei...@gmail.com wrote: