Re: mark bookmarkable Link as selected

2013-01-06 Thread Dirk Wichmann

Hi Per,

sorry, but I dont understand?? what means linksto(page) in bpl. Athen
I know the onconfigure method but what should I check there??

Thanks in advance
Cheers Dirk

Mit freundlichem Gruß
*Dirk Wichmann*
d...@team-wichmann.de mailto:d...@team-wichmann.de
Mobil: +49 163 569 2 563
Am 05.01.2013 19:19, schrieb per.newgro:

You could usw linksto(page) in bpl. Athen in onconfigure oft the link you can 
check if this is true and disable the link. Maybe link.getpage helps to.

Cheers Per




Re: mark bookmarkable Link as selected

2013-01-06 Thread Martin Grigorov
He means  org.apache.wicket.markup.html.link.BookmarkablePageLink#linksTo().

By default Wicket disables any link in the current page which points to the
same page. See org.apache.wicket.markup.html.link.Link#isEnabled()


On Sun, Jan 6, 2013 at 2:30 PM, Dirk Wichmann d...@team-wichmann.de wrote:

 Hi Per,

 sorry, but I dont understand?? what means linksto(page) in bpl. Athen
 I know the onconfigure method but what should I check there??

 Thanks in advance
 Cheers Dirk


 Mit freundlichem Gruß
 *Dirk Wichmann*
 d...@team-wichmann.de mailto:d...@team-wichmann.de
 Mobil: +49 163 569 2 563
 Am 05.01.2013 19:19, schrieb per.newgro:

  You could usw linksto(page) in bpl. Athen in onconfigure oft the link you
 can check if this is true and disable the link. Maybe link.getpage helps to.

 Cheers Per





-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com http://jweekend.com/


Re: BeanValidation - IllegalStateException: Could not resolve Property from component

2013-01-06 Thread martin.dilger
Your Code does not show where the PropertyValidator is added.
If you work with CompoundPropertyModels, you need to explicitely configure
the Property, since no Model is available to retrieve the Information.

Wicket expects a Model of Type IPropertyReflectionAwareModel to work.

Just do the following (Dummy Code)

...add(new PropertyValidator(new
Property(YourClass.class,AttributeName;



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/BeanValidation-IllegalStateException-Could-not-resolve-Property-from-component-tp4655159p4655170.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



Constructors take vararg of Component? (Enhancement RFC)

2013-01-06 Thread Zac Bedell
Greetings all,

I was wondering what Wicket users  devs might thing of a possible API change 
for a future version (maybe Wicket 7?) of including a varargs array of 
Component as the final parameter of all of the various MarkupContainer 
subclasses?  I find myself doing things like these a lot:

pnlNoRsvp = new WebMarkupContainer(pnlNoRsvp);
pnlRsvp = new StatusPanel(pnlRsvp);
pnlConfirm = new ConfirmPanel(pnlConfirm);
pnlRsvpRules = new RsvpRulesPanel(pnlRsvpRules);

RsvpPage.this.add(
new Label(event.title),
new CssFeedbackPanel(feedback),
new FormRsvpPage(frmRsvp, cpm) {
  {
add(pnlNoRsvp, pnlRsvp, pnlConfirm);
  }
},
pnlRsvpRules
);

-- or --

FormRsvpPage frmRsvp = new FormRsvpPage(frmRsvp, cpm);
frmRsvp.add(pnlNoRsvp, pnlRsvp, pnlConfirm);

RsvpPage.this.add(
new Label(event.title),
new CssFeedbackPanel(feedback),
frmRsvp,
pnlRsvpRules
);

--

If Form and the various other Wicket MarkupContainer's had constructors with 
Component... as their final parameter, it would be possible to do something 
like:

RsvpPage.this.add(
new Label(event.title),
new CssFeedbackPanel(feedback),
new FormRsvpPage(frmRsvp, cpm, pnlNoRsvp, pnlRsvp, pnlConfirm),
pnlRsvpRules
);

--

Granted, this would balloon the number of constructors throughout the framework 
just to save a bit of typing.  Curious what others might think...

Best regards,
Zac Bedell
-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Constructors take vararg of Component? (Enhancement RFC)

2013-01-06 Thread Robert Szmurlo

Hi,

you can use something like this:

RsvpPage.this.add(
new Label(event.title),
new CssFeedbackPanel(feedback),
new FormRsvpPage(frmRsvp, cpm).add(pnlNoRsvp, pnlRsvp, pnlConfirm),
pnlRsvpRules
);

I am not dev, but I wouldn't break the API.

BR,
Robert Szmurlo

W dniu 2013-01-06 20:24, Zac Bedell pisze:

Greetings all,

I was wondering what Wicket users  devs might thing of a possible API change 
for a future version (maybe Wicket 7?) of including a varargs array of Component as 
the final parameter of all of the various MarkupContainer subclasses?  I find 
myself doing things like these a lot:

 pnlNoRsvp = new WebMarkupContainer(pnlNoRsvp);
 pnlRsvp = new StatusPanel(pnlRsvp);
 pnlConfirm = new ConfirmPanel(pnlConfirm);
 pnlRsvpRules = new RsvpRulesPanel(pnlRsvpRules);

 RsvpPage.this.add(
 new Label(event.title),
 new CssFeedbackPanel(feedback),
 new FormRsvpPage(frmRsvp, cpm) {
   {
 add(pnlNoRsvp, pnlRsvp, pnlConfirm);
   }
 },
 pnlRsvpRules
 );

-- or --
 
 FormRsvpPage frmRsvp = new FormRsvpPage(frmRsvp, cpm);

 frmRsvp.add(pnlNoRsvp, pnlRsvp, pnlConfirm);

 RsvpPage.this.add(
 new Label(event.title),
 new CssFeedbackPanel(feedback),
 frmRsvp,
 pnlRsvpRules
 );

--

If Form and the various other Wicket MarkupContainer's had constructors with 
Component... as their final parameter, it would be possible to do something 
like:

 RsvpPage.this.add(
 new Label(event.title),
 new CssFeedbackPanel(feedback),
 new FormRsvpPage(frmRsvp, cpm, pnlNoRsvp, pnlRsvp, pnlConfirm),
 pnlRsvpRules
 );

--

Granted, this would balloon the number of constructors throughout the framework 
just to save a bit of typing.  Curious what others might think...

Best regards,
Zac Bedell
-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Example of wicket atmosphere with channel

2013-01-06 Thread Noven
Emond,

Sorry for my late reply. Just come back from holiday. I saw at 
contextAwareFilter and find it useful. But I have not tried it yet in my 
project. Currently I still depend on wicketstuff-push instead 
wicket-atmosphere. I was thinking to move to wicket-atmosphere  because it is 
more easy to implement and has less code than wicketstuff-push. 

Regards,
Noven





 From: Emond Papegaaij emond.papega...@gmail.com
To: users@wicket.apache.org 
Sent: Thursday, December 27, 2012 1:56 PM
Subject: Re: Example of wicket atmosphere with channel
 
I presume you are refering to WICKET-4879, There are no examples of the new
API yet, but the changes are not that big. I did not really implement
channels, but made the changes that would allow you to implement channels.
It is now possible to post an event to a single client (rather than all
clients), either via the AtmosphereResource for that client, or its UUID. I
also added a contextAwareFilter() to @Subscribe, which allows you to access
the RequestCycle and session from the filter. This can be used to
differentiate on the receiver of the event, where filter() can only be used
to differentiate on the content of the event. Be careful with this new
method though, because it will not scale very will with large numbers of
concurrent users.

Looking at the code again, I think I'm going to change the Predicate into a
Function on AtmosphereResource. That would allow you to keep track of some
attributes in AtmosphereRequest on which to write your filter, which puts a
lot less weight on the server than setting up a RequestCycle.

Best regards,
Emond Papegaaij


On Thu, Dec 20, 2012 at 8:31 PM, Noven noven_...@yahoo.com wrote:

 Hi,

 I just saw new features released at wicket 6.40. And I am interested to
 see example code of the atmosphere channel. Where can i find the example of
 this feature?

 Thanks.