add ajaxeventbehavior to the label
On Thu, Jun 14, 2012 at 8:57 PM, oliver.stef <ova...@gmail.com> wrote: > Hi, > > i want to use a label inside listView and i want the user will press on the > label - and the > onClick method will work. but what i get is this msg.: > > "The method onClick() from the type new Label(){} is never used locally". > I don't know why?!?!?!?!?! > > this is my implement: > > List list = Arrays.asList(new String[] { "a", "b", "c" }); > > @SuppressWarnings("unchecked") > ListView listview = new ListView("listview", list) { > > protected void populateItem(ListItem item) { > > String s = (String)item.getModelObject(); > item.add(new Label("label", item.getModel()) > { > private static final long > serialVersionUID = 1L; > > private void onClick() > { > System.out.println("Hello); > > } > } > ); > } > }; > add(listview); > > thanks! > > > -- > View this message in context: > http://apache-wicket.1842946.n4.nabble.com/on-click-on-a-label-in-a-listview-onClicke-method-never-used-localy-tp4649981.html > Sent from the Users forum mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > -- thanks, Vineet Semwal --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org