Re: localization

2008-02-06 Thread Nino Saturnino Martinez Vazquez Wael

That should be possible out of the box...:)

Edward Yakop wrote:

Translator translator = new Translator( Locale.GERMAN );
Hotel translatedHotel = translator.translate( hotel );
translatedHotel.getDescription(); // return description in german
translatedHotel.setDescription( "die Beschreibung" ); // persist german 
description



I think it would be very cool to extend that API to have a better
wicket integration.
It would be very cool if we can do the following:


BoundCompoundPropertyModel model = new
TranslatableBoundCompoundPropertyModel( hotel );
TextField descriptionField = ...;
model.bind( descriptionField, "description" );


Regards,
Edward Yakop

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  


--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: wicket-tools-extjs

2008-02-06 Thread C.

On Wed, 2008-02-06 at 20:02 -0700, Jeremy Fergason wrote:
> All,
> 
> I've been trying to use the ExtJS forms from within wicket.  It seemed that
> several people out there were trying to do this with limited success; except
> for the occasional person saying they had done it.  I have got the
> integration working OK at this point and would like to make the integration
> module available to the community at large.  If you are interested in using
> ExtJS forms from within wicket checkout the wicket-tools-extjs module at:
> www.wickettools.org
> 
> I'm pretty new to wicket so please comment on the design with any
> suggestions of how I could improve it.  Also if there is anyone who is
> interested in helping out I would love to have the support.

Hi

What's up with your site using PHP and hosting a Wicket project! :P
Ok.. Just teasing.. looks ok and best of luck!


./C


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Some questions - mainly about session expiration and serialization

2008-02-06 Thread Fabrizio Giudici


On 06/feb/08, at 19:31, Igor Vaynberg wrote:


sure, you can disable the versioning completely, but then you also
wont have a proper backbutton support. versioning is there for a
reason...

-igor


I understand it, but I don't like backbutton support :-)

When I disable the versioning (I suppose I just need to call  
setVersioned(false) in the base page of my hierarchy) what is the  
behaviour when I hit the back button? Will I get "page expired" or  
will I just make the relevant page class to be run?



--
Fabrizio Giudici, Ph.D. - Java Architect, Project Manager
Tidalwave s.a.s. - "We make Java work. Everywhere."
weblogs.java.net/blog/fabriziogiudici - www.tidalwave.it/blog
[EMAIL PROTECTED] - mobile: +39 348.150.6941




Re: wicket-tools-extjs

2008-02-06 Thread Ryan Sonnek
Glancing through the javadocs, that JavascriptBuilder class looks
awefully familiar.  i'm assuming you've seen the
wicketstuff-scriptaculous project?  =)

On Wed, 2008-02-06 at 20:02 -0700, Jeremy Fergason wrote:
> All,
> 
> I've been trying to use the ExtJS forms from within wicket.  It seemed that
> several people out there were trying to do this with limited success; except
> for the occasional person saying they had done it.  I have got the
> integration working OK at this point and would like to make the integration
> module available to the community at large.  If you are interested in using
> ExtJS forms from within wicket checkout the wicket-tools-extjs module at:
> www.wickettools.org
> 
> I'm pretty new to wicket so please comment on the design with any
> suggestions of how I could improve it.  Also if there is anyone who is
> interested in helping out I would love to have the support.
> 
> Hope you find this useful.
> 
> -jdf


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



wicket-tools-extjs

2008-02-06 Thread Jeremy Fergason
All,

I've been trying to use the ExtJS forms from within wicket.  It seemed that
several people out there were trying to do this with limited success; except
for the occasional person saying they had done it.  I have got the
integration working OK at this point and would like to make the integration
module available to the community at large.  If you are interested in using
ExtJS forms from within wicket checkout the wicket-tools-extjs module at:
www.wickettools.org

I'm pretty new to wicket so please comment on the design with any
suggestions of how I could improve it.  Also if there is anyone who is
interested in helping out I would love to have the support.

Hope you find this useful.

-jdf


Re: CompoundModel based on proxies

2008-02-06 Thread Jonathan Locke


makes sense to me.


igor.vaynberg wrote:
> 
> i support it in a non-core module
> 
> -igor
> 
> 
> On Feb 6, 2008 5:41 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
>>
>>
>> so you don't support this model then?
>>
>>
>>
>> igor.vaynberg wrote:
>> >
>> > i disagree. i dont think we should be doing more with cglib in core or
>> > any other bytecode magic. have you ever tried to walk code that uses
>> > bytecode generation? its a nightmare. one of my favorite things about
>> > wicket is that it is just java and its easy as hell to debug. im not
>> > really against putting something like this into extensions, or even
>> > having a new wicket-bytecode/codegen/whatever package that contains
>> > things like these...
>> >
>> > -igor
>> >
>> >
>> > On Feb 6, 2008 5:23 PM, Jonathan Locke <[EMAIL PROTECTED]>
>> wrote:
>> >>
>> >> like BoundCompoundPropertyModel, but safer.  i think this almost might
>> be
>> >> too
>> >> clever as it sacrifices some intuitiveness.  also, it's filling in for
>> a
>> >> missing java feature.  this should really be:
>> >>
>> >> boundModel.bind(component, firstName.property)
>> >>
>> >> (where .property, .field and .method are long-missing declarative
>> >> reflections like .class)
>> >>
>> >> it does make me think we could be doing more with CGLIB in general.
>> our
>> >> model classes ought to be able to detect model changes better using
>> >> proxies,
>> >> for example.
>> >>
>> >>
>> >>
>> >> Scott Swank wrote:
>> >> >
>> >> > One of our more clever developers created a CompoundPropertyModel
>> that
>> >> > uses a cglib proxy to strongly bind the mutators to the model.  It
>> >> > looks like this:
>> >> >
>> >> >   SharedPropertyModel model = new
>> >> > SharedPropertyModel(customer);
>> >> >   this.setModel(model);
>> >> >
>> >> >   FormComponent firstName = new
>> >> > CustomerNameField("firstName").setRequired(true);
>> >> >   model.bind(firstName).to().getFirstName();
>> >> >   add(firstName);
>> >> >
>> >> >   FormComponent lastName = new
>> >> > CustomerNameField("lastName").setRequired(true);
>> >> >   model.bind(lastName).to().getLastName();
>> >> >   add(lastName);
>> >> >
>> >> >   FormComponent addr1 = new
>> >> AddressField("address1").setRequired(true);
>> >> >   model.bind(addr1).to().getAddress().getAddress1();
>> >> >   add(addr1);
>> >> >
>> >> >   FormComponent addr2 = new AddressField("address2");
>> >> >   model.bind(addr2).to().getAddress().getAddress2();
>> >> >   add(addr2);
>> >> >
>> >> >   FormComponent city = new CityField("city");
>> >> >   model.bind(city).to().getAddress().getCity();
>> >> >   add(city);
>> >> >
>> >> > We're happy to share if folk like this approach.  N.B. that the
>> .to()
>> >> > call is for readability rather than out of any necessity.
>> >> >
>> >> > Cheers,
>> >> > Scott
>> >> >
>> >> > --
>> >> > Scott Swank
>> >> > reformed mathematician
>> >> >
>> >> >
>> -
>> >> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >> >
>> >> >
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325663.html
>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>
>> >>
>> >>
>> >> -
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >>
>> >>
>> >
>> > -
>> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325860.html
>>
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325972.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread James Carman
If you're interested in using proxies, you could check out Apache
Commons Proxy.  It hasn't been released yet, but I would imagine we
could get a release out the door in short order if it was wanted.  The
cool thing about ACP is that you can swap out the proxying technology
easily (JDK proxies, CGLIB, and Javassist are currently supported).

On 2/6/08, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> i support it in a non-core module
>
> -igor
>
>
> On Feb 6, 2008 5:41 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
> >
> >
> > so you don't support this model then?
> >
> >
> >
> > igor.vaynberg wrote:
> > >
> > > i disagree. i dont think we should be doing more with cglib in core or
> > > any other bytecode magic. have you ever tried to walk code that uses
> > > bytecode generation? its a nightmare. one of my favorite things about
> > > wicket is that it is just java and its easy as hell to debug. im not
> > > really against putting something like this into extensions, or even
> > > having a new wicket-bytecode/codegen/whatever package that contains
> > > things like these...
> > >
> > > -igor
> > >
> > >
> > > On Feb 6, 2008 5:23 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
> > >>
> > >> like BoundCompoundPropertyModel, but safer.  i think this almost might be
> > >> too
> > >> clever as it sacrifices some intuitiveness.  also, it's filling in for a
> > >> missing java feature.  this should really be:
> > >>
> > >> boundModel.bind(component, firstName.property)
> > >>
> > >> (where .property, .field and .method are long-missing declarative
> > >> reflections like .class)
> > >>
> > >> it does make me think we could be doing more with CGLIB in general. our
> > >> model classes ought to be able to detect model changes better using
> > >> proxies,
> > >> for example.
> > >>
> > >>
> > >>
> > >> Scott Swank wrote:
> > >> >
> > >> > One of our more clever developers created a CompoundPropertyModel that
> > >> > uses a cglib proxy to strongly bind the mutators to the model.  It
> > >> > looks like this:
> > >> >
> > >> >   SharedPropertyModel model = new
> > >> > SharedPropertyModel(customer);
> > >> >   this.setModel(model);
> > >> >
> > >> >   FormComponent firstName = new
> > >> > CustomerNameField("firstName").setRequired(true);
> > >> >   model.bind(firstName).to().getFirstName();
> > >> >   add(firstName);
> > >> >
> > >> >   FormComponent lastName = new
> > >> > CustomerNameField("lastName").setRequired(true);
> > >> >   model.bind(lastName).to().getLastName();
> > >> >   add(lastName);
> > >> >
> > >> >   FormComponent addr1 = new
> > >> AddressField("address1").setRequired(true);
> > >> >   model.bind(addr1).to().getAddress().getAddress1();
> > >> >   add(addr1);
> > >> >
> > >> >   FormComponent addr2 = new AddressField("address2");
> > >> >   model.bind(addr2).to().getAddress().getAddress2();
> > >> >   add(addr2);
> > >> >
> > >> >   FormComponent city = new CityField("city");
> > >> >   model.bind(city).to().getAddress().getCity();
> > >> >   add(city);
> > >> >
> > >> > We're happy to share if folk like this approach.  N.B. that the .to()
> > >> > call is for readability rather than out of any necessity.
> > >> >
> > >> > Cheers,
> > >> > Scott
> > >> >
> > >> > --
> > >> > Scott Swank
> > >> > reformed mathematician
> > >> >
> > >> > -
> > >> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >> > For additional commands, e-mail: [EMAIL PROTECTED]
> > >> >
> > >> >
> > >> >
> > >>
> > >> --
> > >> View this message in context:
> > >> http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325663.html
> > >> Sent from the Wicket - User mailing list archive at Nabble.com.
> > >>
> > >>
> > >>
> > >> -
> > >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >> For additional commands, e-mail: [EMAIL PROTECTED]
> > >>
> > >>
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> > >
> >
> > --
> > View this message in context: 
> > http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325860.html
> >
> > Sent from the Wicket - User mailing list archive at Nabble.com.
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-m

Re: CompoundModel based on proxies

2008-02-06 Thread Scott Swank
There are additional considerations (at least in this implementation),
all of which should be familiar to users of Hibernate or any
proxy-based framework.

1) classes may not be final
2) methods may not be final
3) classes must have a no-method constructor

Some folk may not be happy with these restrictions.

- Scott


On Feb 6, 2008 5:43 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> i support it in a non-core module
>
> -igor
>
>
>
> On Feb 6, 2008 5:41 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
> >
> >
> > so you don't support this model then?
> >
> >
> >
> > igor.vaynberg wrote:
> > >
> > > i disagree. i dont think we should be doing more with cglib in core or
> > > any other bytecode magic. have you ever tried to walk code that uses
> > > bytecode generation? its a nightmare. one of my favorite things about
> > > wicket is that it is just java and its easy as hell to debug. im not
> > > really against putting something like this into extensions, or even
> > > having a new wicket-bytecode/codegen/whatever package that contains
> > > things like these...
> > >
> > > -igor
> > >
> > >
> > > On Feb 6, 2008 5:23 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
> > >>
> > >> like BoundCompoundPropertyModel, but safer.  i think this almost might be
> > >> too
> > >> clever as it sacrifices some intuitiveness.  also, it's filling in for a
> > >> missing java feature.  this should really be:
> > >>
> > >> boundModel.bind(component, firstName.property)
> > >>
> > >> (where .property, .field and .method are long-missing declarative
> > >> reflections like .class)
> > >>
> > >> it does make me think we could be doing more with CGLIB in general. our
> > >> model classes ought to be able to detect model changes better using
> > >> proxies,
> > >> for example.
> > >>
> > >>
> > >>
> > >> Scott Swank wrote:
> > >> >
> > >> > One of our more clever developers created a CompoundPropertyModel that
> > >> > uses a cglib proxy to strongly bind the mutators to the model.  It
> > >> > looks like this:
> > >> >
> > >> >   SharedPropertyModel model = new
> > >> > SharedPropertyModel(customer);
> > >> >   this.setModel(model);
> > >> >
> > >> >   FormComponent firstName = new
> > >> > CustomerNameField("firstName").setRequired(true);
> > >> >   model.bind(firstName).to().getFirstName();
> > >> >   add(firstName);
> > >> >
> > >> >   FormComponent lastName = new
> > >> > CustomerNameField("lastName").setRequired(true);
> > >> >   model.bind(lastName).to().getLastName();
> > >> >   add(lastName);
> > >> >
> > >> >   FormComponent addr1 = new
> > >> AddressField("address1").setRequired(true);
> > >> >   model.bind(addr1).to().getAddress().getAddress1();
> > >> >   add(addr1);
> > >> >
> > >> >   FormComponent addr2 = new AddressField("address2");
> > >> >   model.bind(addr2).to().getAddress().getAddress2();
> > >> >   add(addr2);
> > >> >
> > >> >   FormComponent city = new CityField("city");
> > >> >   model.bind(city).to().getAddress().getCity();
> > >> >   add(city);
> > >> >
> > >> > We're happy to share if folk like this approach.  N.B. that the .to()
> > >> > call is for readability rather than out of any necessity.
> > >> >
> > >> > Cheers,
> > >> > Scott
> > >> >
> > >> > --
> > >> > Scott Swank
> > >> > reformed mathematician
> > >> >
> > >> > -
> > >> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >> > For additional commands, e-mail: [EMAIL PROTECTED]
> > >> >
> > >> >
> > >> >
> > >>
> > >> --
> > >> View this message in context:
> > >> http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325663.html
> > >> Sent from the Wicket - User mailing list archive at Nabble.com.
> > >>
> > >>
> > >>
> > >> -
> > >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >> For additional commands, e-mail: [EMAIL PROTECTED]
> > >>
> > >>
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> > >
> >
> > --
> > View this message in context: 
> > http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325860.html
> >
> > Sent from the Wicket - User mailing list archive at Nabble.com.
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
Scott Swank
reformed mathematician

---

Re: CompoundModel based on proxies

2008-02-06 Thread Igor Vaynberg
i support it in a non-core module

-igor


On Feb 6, 2008 5:41 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
>
>
> so you don't support this model then?
>
>
>
> igor.vaynberg wrote:
> >
> > i disagree. i dont think we should be doing more with cglib in core or
> > any other bytecode magic. have you ever tried to walk code that uses
> > bytecode generation? its a nightmare. one of my favorite things about
> > wicket is that it is just java and its easy as hell to debug. im not
> > really against putting something like this into extensions, or even
> > having a new wicket-bytecode/codegen/whatever package that contains
> > things like these...
> >
> > -igor
> >
> >
> > On Feb 6, 2008 5:23 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
> >>
> >> like BoundCompoundPropertyModel, but safer.  i think this almost might be
> >> too
> >> clever as it sacrifices some intuitiveness.  also, it's filling in for a
> >> missing java feature.  this should really be:
> >>
> >> boundModel.bind(component, firstName.property)
> >>
> >> (where .property, .field and .method are long-missing declarative
> >> reflections like .class)
> >>
> >> it does make me think we could be doing more with CGLIB in general. our
> >> model classes ought to be able to detect model changes better using
> >> proxies,
> >> for example.
> >>
> >>
> >>
> >> Scott Swank wrote:
> >> >
> >> > One of our more clever developers created a CompoundPropertyModel that
> >> > uses a cglib proxy to strongly bind the mutators to the model.  It
> >> > looks like this:
> >> >
> >> >   SharedPropertyModel model = new
> >> > SharedPropertyModel(customer);
> >> >   this.setModel(model);
> >> >
> >> >   FormComponent firstName = new
> >> > CustomerNameField("firstName").setRequired(true);
> >> >   model.bind(firstName).to().getFirstName();
> >> >   add(firstName);
> >> >
> >> >   FormComponent lastName = new
> >> > CustomerNameField("lastName").setRequired(true);
> >> >   model.bind(lastName).to().getLastName();
> >> >   add(lastName);
> >> >
> >> >   FormComponent addr1 = new
> >> AddressField("address1").setRequired(true);
> >> >   model.bind(addr1).to().getAddress().getAddress1();
> >> >   add(addr1);
> >> >
> >> >   FormComponent addr2 = new AddressField("address2");
> >> >   model.bind(addr2).to().getAddress().getAddress2();
> >> >   add(addr2);
> >> >
> >> >   FormComponent city = new CityField("city");
> >> >   model.bind(city).to().getAddress().getCity();
> >> >   add(city);
> >> >
> >> > We're happy to share if folk like this approach.  N.B. that the .to()
> >> > call is for readability rather than out of any necessity.
> >> >
> >> > Cheers,
> >> > Scott
> >> >
> >> > --
> >> > Scott Swank
> >> > reformed mathematician
> >> >
> >> > -
> >> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> > For additional commands, e-mail: [EMAIL PROTECTED]
> >> >
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325663.html
> >> Sent from the Wicket - User mailing list archive at Nabble.com.
> >>
> >>
> >>
> >> -
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
>
> --
> View this message in context: 
> http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325860.html
>
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Jonathan Locke


so you don't support this model then?


igor.vaynberg wrote:
> 
> i disagree. i dont think we should be doing more with cglib in core or
> any other bytecode magic. have you ever tried to walk code that uses
> bytecode generation? its a nightmare. one of my favorite things about
> wicket is that it is just java and its easy as hell to debug. im not
> really against putting something like this into extensions, or even
> having a new wicket-bytecode/codegen/whatever package that contains
> things like these...
> 
> -igor
> 
> 
> On Feb 6, 2008 5:23 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
>>
>> like BoundCompoundPropertyModel, but safer.  i think this almost might be
>> too
>> clever as it sacrifices some intuitiveness.  also, it's filling in for a
>> missing java feature.  this should really be:
>>
>> boundModel.bind(component, firstName.property)
>>
>> (where .property, .field and .method are long-missing declarative
>> reflections like .class)
>>
>> it does make me think we could be doing more with CGLIB in general. our
>> model classes ought to be able to detect model changes better using
>> proxies,
>> for example.
>>
>>
>>
>> Scott Swank wrote:
>> >
>> > One of our more clever developers created a CompoundPropertyModel that
>> > uses a cglib proxy to strongly bind the mutators to the model.  It
>> > looks like this:
>> >
>> >   SharedPropertyModel model = new
>> > SharedPropertyModel(customer);
>> >   this.setModel(model);
>> >
>> >   FormComponent firstName = new
>> > CustomerNameField("firstName").setRequired(true);
>> >   model.bind(firstName).to().getFirstName();
>> >   add(firstName);
>> >
>> >   FormComponent lastName = new
>> > CustomerNameField("lastName").setRequired(true);
>> >   model.bind(lastName).to().getLastName();
>> >   add(lastName);
>> >
>> >   FormComponent addr1 = new
>> AddressField("address1").setRequired(true);
>> >   model.bind(addr1).to().getAddress().getAddress1();
>> >   add(addr1);
>> >
>> >   FormComponent addr2 = new AddressField("address2");
>> >   model.bind(addr2).to().getAddress().getAddress2();
>> >   add(addr2);
>> >
>> >   FormComponent city = new CityField("city");
>> >   model.bind(city).to().getAddress().getCity();
>> >   add(city);
>> >
>> > We're happy to share if folk like this approach.  N.B. that the .to()
>> > call is for readability rather than out of any necessity.
>> >
>> > Cheers,
>> > Scott
>> >
>> > --
>> > Scott Swank
>> > reformed mathematician
>> >
>> > -
>> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325663.html
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325860.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Igor Vaynberg
i disagree. i dont think we should be doing more with cglib in core or
any other bytecode magic. have you ever tried to walk code that uses
bytecode generation? its a nightmare. one of my favorite things about
wicket is that it is just java and its easy as hell to debug. im not
really against putting something like this into extensions, or even
having a new wicket-bytecode/codegen/whatever package that contains
things like these...

-igor


On Feb 6, 2008 5:23 PM, Jonathan Locke <[EMAIL PROTECTED]> wrote:
>
> like BoundCompoundPropertyModel, but safer.  i think this almost might be too
> clever as it sacrifices some intuitiveness.  also, it's filling in for a
> missing java feature.  this should really be:
>
> boundModel.bind(component, firstName.property)
>
> (where .property, .field and .method are long-missing declarative
> reflections like .class)
>
> it does make me think we could be doing more with CGLIB in general. our
> model classes ought to be able to detect model changes better using proxies,
> for example.
>
>
>
> Scott Swank wrote:
> >
> > One of our more clever developers created a CompoundPropertyModel that
> > uses a cglib proxy to strongly bind the mutators to the model.  It
> > looks like this:
> >
> >   SharedPropertyModel model = new
> > SharedPropertyModel(customer);
> >   this.setModel(model);
> >
> >   FormComponent firstName = new
> > CustomerNameField("firstName").setRequired(true);
> >   model.bind(firstName).to().getFirstName();
> >   add(firstName);
> >
> >   FormComponent lastName = new
> > CustomerNameField("lastName").setRequired(true);
> >   model.bind(lastName).to().getLastName();
> >   add(lastName);
> >
> >   FormComponent addr1 = new 
> > AddressField("address1").setRequired(true);
> >   model.bind(addr1).to().getAddress().getAddress1();
> >   add(addr1);
> >
> >   FormComponent addr2 = new AddressField("address2");
> >   model.bind(addr2).to().getAddress().getAddress2();
> >   add(addr2);
> >
> >   FormComponent city = new CityField("city");
> >   model.bind(city).to().getAddress().getCity();
> >   add(city);
> >
> > We're happy to share if folk like this approach.  N.B. that the .to()
> > call is for readability rather than out of any necessity.
> >
> > Cheers,
> > Scott
> >
> > --
> > Scott Swank
> > reformed mathematician
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
>
> --
> View this message in context: 
> http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325663.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Jonathan Locke


another thing that occurs to me is that perhaps the method would be more
generalized we basically made a fill-in for the missing .property feature. 
we could have a method like Reflection.property(expr) return a property
expression string (or a compiled version of it).  this makes me think
there's a missing reflection package in java in general...


Jonathan Locke wrote:
> 
> like BoundCompoundPropertyModel, but safer.  i think this almost might be
> too clever as it sacrifices some intuitiveness.  also, it's filling in for
> a missing java feature.  this should really be:
> 
> boundModel.bind(component, firstName.property)
> 
> (where .property, .field and .method are long-missing declarative
> reflections like .class)
> 
> it does make me think we could be doing more with CGLIB in general. our
> model classes ought to be able to detect model changes better using
> proxies, for example.
> 
> 
> Scott Swank wrote:
>> 
>> One of our more clever developers created a CompoundPropertyModel that
>> uses a cglib proxy to strongly bind the mutators to the model.  It
>> looks like this:
>> 
>>  SharedPropertyModel model = new
>> SharedPropertyModel(customer);
>>  this.setModel(model);
>> 
>>  FormComponent firstName = new
>> CustomerNameField("firstName").setRequired(true);
>>  model.bind(firstName).to().getFirstName();
>>  add(firstName);
>> 
>>  FormComponent lastName = new
>> CustomerNameField("lastName").setRequired(true);
>>  model.bind(lastName).to().getLastName();
>>  add(lastName);
>> 
>>  FormComponent addr1 = new 
>> AddressField("address1").setRequired(true);
>>  model.bind(addr1).to().getAddress().getAddress1();
>>  add(addr1);
>> 
>>  FormComponent addr2 = new AddressField("address2");
>>  model.bind(addr2).to().getAddress().getAddress2();
>>  add(addr2);
>> 
>>  FormComponent city = new CityField("city");
>>  model.bind(city).to().getAddress().getCity();
>>  add(city);
>> 
>> We're happy to share if folk like this approach.  N.B. that the .to()
>> call is for readability rather than out of any necessity.
>> 
>> Cheers,
>> Scott
>> 
>> -- 
>> Scott Swank
>> reformed mathematician
>> 
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>> 
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325688.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Jonathan Locke

like BoundCompoundPropertyModel, but safer.  i think this almost might be too
clever as it sacrifices some intuitiveness.  also, it's filling in for a
missing java feature.  this should really be:

boundModel.bind(component, firstName.property)

(where .property, .field and .method are long-missing declarative
reflections like .class)

it does make me think we could be doing more with CGLIB in general. our
model classes ought to be able to detect model changes better using proxies,
for example.


Scott Swank wrote:
> 
> One of our more clever developers created a CompoundPropertyModel that
> uses a cglib proxy to strongly bind the mutators to the model.  It
> looks like this:
> 
>   SharedPropertyModel model = new
> SharedPropertyModel(customer);
>   this.setModel(model);
> 
>   FormComponent firstName = new
> CustomerNameField("firstName").setRequired(true);
>   model.bind(firstName).to().getFirstName();
>   add(firstName);
> 
>   FormComponent lastName = new
> CustomerNameField("lastName").setRequired(true);
>   model.bind(lastName).to().getLastName();
>   add(lastName);
> 
>   FormComponent addr1 = new 
> AddressField("address1").setRequired(true);
>   model.bind(addr1).to().getAddress().getAddress1();
>   add(addr1);
> 
>   FormComponent addr2 = new AddressField("address2");
>   model.bind(addr2).to().getAddress().getAddress2();
>   add(addr2);
> 
>   FormComponent city = new CityField("city");
>   model.bind(city).to().getAddress().getCity();
>   add(city);
> 
> We're happy to share if folk like this approach.  N.B. that the .to()
> call is for readability rather than out of any necessity.
> 
> Cheers,
> Scott
> 
> -- 
> Scott Swank
> reformed mathematician
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p15325663.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread Eelco Hillenius
On Feb 6, 2008 4:20 PM, gantini <[EMAIL PROTECTED]> wrote:
>
> Resolved
> Incredible. the problem was caused by wrong version of slf4j-log4j12
> library, version 1.0.1 instead of 1.4.2
>
> The right libraries is slf4j-api-1.4.2 + slf4j-log4j12-1.4.2  !!!

I don't understand how that would influence reloading though...

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Passing list of POJOs to AutoCompleteTextField?

2008-02-06 Thread Sam Barnum

I've committed a ticket for this, should have mentioned it here:

https://issues.apache.org/jira/browse/WICKET-1324

-sam

On Feb 6, 2008, at 2:47 PM, Michael Mehrle wrote:


I would be happy to - what is the URL for this? (first time - new
contributor).

In that context - I recently grepped through the Wicket source and
noticed that all the javascript event calls (onchange, onclick, etc.)
are all in the code as plain strings, which is bad practice. Thus I
wrote a *JavaScriptUtil* class that has String constants like CHANGE,
BLUR, DRAG_DROP, etc. (and can be statically imported jdk1.5  
style). The

class also includes Javadoc that describes each event in detail. I
thought that this might be a little contribution to Wicket if you want
it. Let me know and I can submit the source (again, would need the URL
and procedure).

Thanks,

Michael

-Original Message-
From: Igor Vaynberg [mailto:[EMAIL PROTECTED]
Sent: Tuesday, February 05, 2008 5:31 PM
To: users@wicket.apache.org
Subject: Re: Passing list of POJOs to AutoCompleteTextField?

please add an rfe into jira for this.

-igor


On Feb 5, 2008 4:38 PM, Michael Mehrle <[EMAIL PROTECTED]> wrote:

That's exactly what I wound up doing. I wrote my custom renderer that
grabs the name field of my POJO for rendering. Of course that is what
I'm getting back from getModelObjectAsString(). It's a work-around  
and

I

was hoping for a more elegant way of doing this...

Michael


-Original Message-
From: Sam Barnum [mailto:[EMAIL PROTECTED]
Sent: Tuesday, February 05, 2008 4:01 PM
To: users@wicket.apache.org
Subject: Re: Passing list of POJOs to AutoCompleteTextField?

I don't think it is, the getMmodelObject() returns the selected
String.  I've gotten around this by saving the last query string sent
via AJAX.  When the user makes a selection, I iterate over the
options for that query string one more time, and take the POJO whose
rendered string matches the user-selected text.

I'm probably missing something obvious, but I don't think
getModelObject() is it...




--
Sam Barnum
360 Works
http://www.360works.com
415.865.0952



On Feb 5, 2008, at 2:12 PM, Igor Vaynberg wrote:


shouldnt the pojo be availble from getmodelobject()?

-igor


On Jan 29, 2008 11:55 AM, Michael Mehrle <[EMAIL PROTECTED]>
wrote:

I could - if it was a simple matter of extracting the strings from
the
POJOs. Problem is that, once an option is selected, I need the
underlying POJOs to become the model for the rest of the form. Yes,
there's probably a way to hack this, but I would prefer to do this
in a
clean fashion.

I already got the custom renderer working, so I'm making progress.
Task
#2 now is to grab the underlying POJO after selecting it and

populate

the remainder of the form. This seems to be the tough part...
Again, any
help would be appreciated.

Thanks!!

Michael


-Original Message-
From: Igor Vaynberg [mailto:[EMAIL PROTECTED]
Sent: Tuesday, January 29, 2008 11:47 AM
To: users@wicket.apache.org
Subject: Re: Passing list of POJOs to AutoCompleteTextField?

can you not create an iterator adapter that takes an iterator of
pojos
and translates the pojo to some string?

-igor


On Jan 29, 2008 11:14 AM, Michael Mehrle <[EMAIL PROTECTED]>
wrote:

I have a working test page containing an AutoCompleteTextField.

Thus

far

the data feeding it has been an Iterator of strings which is being
passed to its overridden getChoices method. So far so good.

What I need to do now is to pass in an Iterator of POJOs instead

and

have the AutoCompleteTextField render the 'name' field inside
each of
those beans. After some digging in the Wicket source I suspect
that I
need to create a custom renderer that does this - am I on the

right

track here or would you guys suggest a different approach?

Another challenge will be to populate other form fields in the

page

after selecting an option from the AutoCompleteTextField. By
selecting
an option in the dropdown I am basically selecting an entire POJO,

which

is supposed to be used as the model for the other remaining

fields.

For

instance, the POJO will contain address, zip, phone, etc. fields

and

by

selecting the appropriate name in the AutoCompleteTextField it

populates

all other fields with the remaining data in the underlying POJO.
Hope
this makes sense - I think I have an idea of how to implement

this,

but

would appreciate any tips/insights.

Thanks!!

Michael










-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






-

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






-

Re: Reloading resource

2008-02-06 Thread gantini

Resolved
Incredible. the problem was caused by wrong version of slf4j-log4j12
library, version 1.0.1 instead of 1.4.2

The right libraries is slf4j-api-1.4.2 + slf4j-log4j12-1.4.2  !!!

I hope this useful for other newbie of Wicket



gantini wrote:
> 
> I'm very new with Wicket.
> It is possible to automatically reload resource (class and HTML file) ?
> 
> I've set:
> 
>   @Override
>   protected void init() {
>   getResourceSettings().setResourcePollFrequency( 
> Duration.ONE_SECOND );
>   }
> 
> but this don't work for me.
> Thanks.
> 

-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15324915.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Ajax Debugging at a HttpSession level

2008-02-06 Thread mnwicket

Any thoughts on this.  I basically want to be able to turn ajax debugging on
at a HTTPSession level in prod to be able to investigate possible client
service calls without having every other use seeing it.

Thanks
-- 
View this message in context: 
http://www.nabble.com/Ajax-Debugging-at-a-HttpSession-level-tp15324851p15324851.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Martijn Dashorst
If he could leave a comment on the issue that would be great.

If he has more ideas like this, get him to open a JIRA account :)

Martijn

On 2/7/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> I have his approval, but I can get him if you like.  Let me know either way.
>
> On Feb 6, 2008 3:22 PM, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > On 2/7/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> > > No problem.  I didn't even write a line of it.  :)
> >
> > Just for the record keeping: are you allowed to grant us the use of
> > said model? Typically that should be done by the original copyright
> > holder.
> >
> > Martijn
> >
> > --
> >
> > Buy Wicket in Action: http://manning.com/dashorst
> > Apache Wicket 1.3.0 is released
> > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
>
> --
> Scott Swank
> reformed mathematician
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread gantini

Using quickstart and Jetty project (with eclispe) all work correctly
I think that the problem is in myeclipse+tomcat



igor.vaynberg wrote:
> 
> test it out this way:
> 
> go here
> 
> http://wicket.apache.org/quickstart.html
> 
> copy and paste the maven command to create a quickstart project
> find the Start class, right click and do "run as java application"
> 
> this will start embedded jetty, go to localhost:8080, then find
> Index.html, edit it, and refresh the browser. do you see the changes?
> 
> -igor
> 
> 
> On Feb 6, 2008 12:08 PM, gantini <[EMAIL PROTECTED]> wrote:
>>
>> Strangethis dosn't work for me...
>> When wicket starts, in the tomcat console I can read:
>>
>> 
>> *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
>> ***   ^^^***
>> *** Do NOT deploy to your live server(s) without changing this.  ***
>> *** See Application#getConfigurationType() for more information. ***
>>
>>
>> But when I modify any html file, no reload is performed :-((
>>
>> Other suggest for me?
>> G.
>>
>>
>>
>> igor.vaynberg wrote:
>> >
>> > this should automatically be happening if you run wicket in development
>> > mode.
>> > that call you do is not necessary.
>> >
>> > -igor
>> >
>> >
>> > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
>> >>
>> >> Nothing to help me?
>> >>
>> >>
>> >>
>> >> gantini wrote:
>> >> >
>> >> > I'm very new with Wicket.
>> >> > It is possible to automatically reload resource (class and HTML
>> file) ?
>> >> >
>> >> > I've set:
>> >> >
>> >> >   @Override
>> >> >   protected void init() {
>> >> >   getResourceSettings().setResourcePollFrequency(
>> >> Duration.ONE_SECOND );
>> >> >   }
>> >> >
>> >> > but this don't work for me.
>> >> > Thanks.
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
>> >>
>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>
>> >>
>> >> -
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >>
>> >>
>> >
>> > -
>> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
>>
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15324478.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Scott Swank
I have his approval, but I can get him if you like.  Let me know either way.

On Feb 6, 2008 3:22 PM, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> On 2/7/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> > No problem.  I didn't even write a line of it.  :)
>
> Just for the record keeping: are you allowed to grant us the use of
> said model? Typically that should be done by the original copyright
> holder.
>
> Martijn
>
> --
>
> Buy Wicket in Action: http://manning.com/dashorst
> Apache Wicket 1.3.0 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
Scott Swank
reformed mathematician

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Martijn Dashorst
On 2/7/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> No problem.  I didn't even write a line of it.  :)

Just for the record keeping: are you allowed to grant us the use of
said model? Typically that should be done by the original copyright
holder.

Martijn

-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Scott Swank
No problem.  I didn't even write a line of it.  :)

On Feb 6, 2008 2:30 PM, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> Thanks! And I always thought: what happens in Vegas, stays in Vegas...
>
>
> Martijn

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread gantini

Yes!!!
I'm use Eclipe+Myeclipse.
When I change an HTML file, this is automatically deployed. I've checked the
file on the tomcat dir and it is changed

:-(



Martijn Dashorst wrote:
> 
> How do you modify the html, in what tool, how do you ensure the html
> gets inside the deployed and unpacked war running in tomcat?
> 
> Martijn
> 
> On 2/6/08, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
>> Does your IDE copy the HTML files over to the classpath?
>>
>> Martijn
>>
>> On 2/6/08, gantini <[EMAIL PROTECTED]> wrote:
>> >
>> > Strangethis dosn't work for me...
>> > When wicket starts, in the tomcat console I can read:
>> >
>> > 
>> > *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
>> > ***   ^^^***
>> > *** Do NOT deploy to your live server(s) without changing this.  ***
>> > *** See Application#getConfigurationType() for more information. ***
>> >
>> >
>> > But when I modify any html file, no reload is performed :-((
>> >
>> > Other suggest for me?
>> > G.
>> >
>> >
>> > igor.vaynberg wrote:
>> > >
>> > > this should automatically be happening if you run wicket in
>> development
>> > > mode.
>> > > that call you do is not necessary.
>> > >
>> > > -igor
>> > >
>> > >
>> > > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
>> > >>
>> > >> Nothing to help me?
>> > >>
>> > >>
>> > >>
>> > >> gantini wrote:
>> > >> >
>> > >> > I'm very new with Wicket.
>> > >> > It is possible to automatically reload resource (class and HTML
>> file) ?
>> > >> >
>> > >> > I've set:
>> > >> >
>> > >> >   @Override
>> > >> >   protected void init() {
>> > >> >   getResourceSettings().setResourcePollFrequency(
>> > >> Duration.ONE_SECOND );
>> > >> >   }
>> > >> >
>> > >> > but this don't work for me.
>> > >> > Thanks.
>> > >> >
>> > >>
>> > >> --
>> > >> View this message in context:
>> > >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
>> > >>
>> > >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> > >>
>> > >>
>> > >>
>> -
>> > >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > >> For additional commands, e-mail: [EMAIL PROTECTED]
>> > >>
>> > >>
>> > >
>> > > -
>> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > > For additional commands, e-mail: [EMAIL PROTECTED]
>> > >
>> > >
>> > >
>> >
>> > --
>> > View this message in context:
>> http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
>> > Sent from the Wicket - User mailing list archive at Nabble.com.
>> >
>> >
>> > -
>> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >
>> >
>>
>>
>> --
>> Buy Wicket in Action: http://manning.com/dashorst
>> Apache Wicket 1.3.0 is released
>> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
>>
> 
> 
> -- 
> Buy Wicket in Action: http://manning.com/dashorst
> Apache Wicket 1.3.0 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15324032.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread Igor Vaynberg
there is no tomcat-wicket integration, just like there is no
jetty-wicket integration. you simply have to make your ide copy files
to where tomcat loads them from when they are saved.

-igor


On Feb 6, 2008 3:11 PM, gantini <[EMAIL PROTECTED]> wrote:
>
> I don't wont using Jetty I'm Tomcat fan :-)
> I'm usually use Eclipse+MyEclise+Tomcat for my web application (spring MVC).
>
> Is a Tomcat-wicket integration problem?
>
>
>
> igor.vaynberg wrote:
> >
> > test it out this way:
> >
> > go here
> >
> > http://wicket.apache.org/quickstart.html
> >
> > copy and paste the maven command to create a quickstart project
> > find the Start class, right click and do "run as java application"
> >
> > this will start embedded jetty, go to localhost:8080, then find
> > Index.html, edit it, and refresh the browser. do you see the changes?
> >
> > -igor
> >
> >
> > On Feb 6, 2008 12:08 PM, gantini <[EMAIL PROTECTED]> wrote:
> >>
> >> Strangethis dosn't work for me...
> >> When wicket starts, in the tomcat console I can read:
> >>
> >> 
> >> *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
> >> ***   ^^^***
> >> *** Do NOT deploy to your live server(s) without changing this.  ***
> >> *** See Application#getConfigurationType() for more information. ***
> >>
> >>
> >> But when I modify any html file, no reload is performed :-((
> >>
> >> Other suggest for me?
> >> G.
> >>
> >>
> >>
> >> igor.vaynberg wrote:
> >> >
> >> > this should automatically be happening if you run wicket in development
> >> > mode.
> >> > that call you do is not necessary.
> >> >
> >> > -igor
> >> >
> >> >
> >> > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
> >> >>
> >> >> Nothing to help me?
> >> >>
> >> >>
> >> >>
> >> >> gantini wrote:
> >> >> >
> >> >> > I'm very new with Wicket.
> >> >> > It is possible to automatically reload resource (class and HTML
> >> file) ?
> >> >> >
> >> >> > I've set:
> >> >> >
> >> >> >   @Override
> >> >> >   protected void init() {
> >> >> >   getResourceSettings().setResourcePollFrequency(
> >> >> Duration.ONE_SECOND );
> >> >> >   }
> >> >> >
> >> >> > but this don't work for me.
> >> >> > Thanks.
> >> >> >
> >> >>
> >> >> --
> >> >> View this message in context:
> >> >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
> >> >>
> >> >> Sent from the Wicket - User mailing list archive at Nabble.com.
> >> >>
> >> >>
> >> >> -
> >> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >> >>
> >> >>
> >> >
> >> > -
> >> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> > For additional commands, e-mail: [EMAIL PROTECTED]
> >> >
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
> >>
> >> Sent from the Wicket - User mailing list archive at Nabble.com.
> >>
> >>
> >> -
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
>
> --
> View this message in context: 
> http://www.nabble.com/Reloading-resource-tp15268997p15323736.html
>
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread gantini

Windows?!!?! What's Windows? :-)
No windows in my computer!

I'm using ***ONLY*** Linux 



Konstantin Ignatyev-3 wrote:
> 
> I have seen the behavior but that seems to be endemic to windows.
> I have not seen that on Linux or OS X.
> 
> On Wed, Feb 6, 2008 at 12:08 PM, gantini <[EMAIL PROTECTED]> wrote:
> 
>>
>> Strangethis dosn't work for me...
>> When wicket starts, in the tomcat console I can read:
>>
>> 
>> *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
>> ***   ^^^***
>> *** Do NOT deploy to your live server(s) without changing this.  ***
>> *** See Application#getConfigurationType() for more information. ***
>>
>>
>> But when I modify any html file, no reload is performed :-((
>>
>> Other suggest for me?
>> G.
>>
>>
>> igor.vaynberg wrote:
>> >
>> > this should automatically be happening if you run wicket in development
>> > mode.
>> > that call you do is not necessary.
>> >
>> > -igor
>> >
>> >
>> > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
>> >>
>> >> Nothing to help me?
>> >>
>> >>
>> >>
>> >> gantini wrote:
>> >> >
>> >> > I'm very new with Wicket.
>> >> > It is possible to automatically reload resource (class and HTML
>> file)
>> ?
>> >> >
>> >> > I've set:
>> >> >
>> >> >   @Override
>> >> >   protected void init() {
>> >> >   getResourceSettings().setResourcePollFrequency(
>> >> Duration.ONE_SECOND );
>> >> >   }
>> >> >
>> >> > but this don't work for me.
>> >> > Thanks.
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
>> >>
>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>
>> >>
>> >> -
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >>
>> >>
>> >
>> > -
>> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 
> -- 
> Konstantin Ignatyev
> 
> PS: If this is a typical day on planet earth, humans will add fifteen
> million tons of carbon to the atmosphere, destroy 115 square miles of
> tropical rainforest, create seventy-two miles of desert, eliminate between
> forty to one hundred species, erode seventy-one million tons of topsoil,
> add
> 2,700 tons of CFCs to the stratosphere, and increase their population by
> 263,000
> 
> Bowers, C.A. The Culture of Denial: Why the Environmental Movement Needs a
> Strategy for Reforming Universities and Public Schools. New York: State
> University of New York Press, 1997: (4) (5) (p.206)
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15323967.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread gantini

I don't wont using Jetty I'm Tomcat fan :-)
I'm usually use Eclipse+MyEclise+Tomcat for my web application (spring MVC).

Is a Tomcat-wicket integration problem? 


igor.vaynberg wrote:
> 
> test it out this way:
> 
> go here
> 
> http://wicket.apache.org/quickstart.html
> 
> copy and paste the maven command to create a quickstart project
> find the Start class, right click and do "run as java application"
> 
> this will start embedded jetty, go to localhost:8080, then find
> Index.html, edit it, and refresh the browser. do you see the changes?
> 
> -igor
> 
> 
> On Feb 6, 2008 12:08 PM, gantini <[EMAIL PROTECTED]> wrote:
>>
>> Strangethis dosn't work for me...
>> When wicket starts, in the tomcat console I can read:
>>
>> 
>> *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
>> ***   ^^^***
>> *** Do NOT deploy to your live server(s) without changing this.  ***
>> *** See Application#getConfigurationType() for more information. ***
>>
>>
>> But when I modify any html file, no reload is performed :-((
>>
>> Other suggest for me?
>> G.
>>
>>
>>
>> igor.vaynberg wrote:
>> >
>> > this should automatically be happening if you run wicket in development
>> > mode.
>> > that call you do is not necessary.
>> >
>> > -igor
>> >
>> >
>> > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
>> >>
>> >> Nothing to help me?
>> >>
>> >>
>> >>
>> >> gantini wrote:
>> >> >
>> >> > I'm very new with Wicket.
>> >> > It is possible to automatically reload resource (class and HTML
>> file) ?
>> >> >
>> >> > I've set:
>> >> >
>> >> >   @Override
>> >> >   protected void init() {
>> >> >   getResourceSettings().setResourcePollFrequency(
>> >> Duration.ONE_SECOND );
>> >> >   }
>> >> >
>> >> > but this don't work for me.
>> >> > Thanks.
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
>> >>
>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>
>> >>
>> >> -
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >>
>> >>
>> >
>> > -
>> > To unsubscribe, e-mail: [EMAIL PROTECTED]
>> > For additional commands, e-mail: [EMAIL PROTECTED]
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
>>
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15323736.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread Martijn Dashorst
If you use any IDE other than Eclipse, you have to *make* the project
in order to get the html files to refresh.

Martijn

On 2/7/08, gantini <[EMAIL PROTECTED]> wrote:
>
>
> djo.mos wrote:
> >
> > Try waiting for some seconds and keep hitting the refresh button.
> >
>
> Something wrong in my project
> I'm wait for some minutes, and nothing was happened
> --
> View this message in context: 
> http://www.nabble.com/Reloading-resource-tp15268997p15322083.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread gantini


djo.mos wrote:
> 
> Try waiting for some seconds and keep hitting the refresh button.
> 

Something wrong in my project
I'm wait for some minutes, and nothing was happened
-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15322083.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Passing list of POJOs to AutoCompleteTextField?

2008-02-06 Thread Michael Mehrle
I would be happy to - what is the URL for this? (first time - new
contributor).

In that context - I recently grepped through the Wicket source and
noticed that all the javascript event calls (onchange, onclick, etc.)
are all in the code as plain strings, which is bad practice. Thus I
wrote a *JavaScriptUtil* class that has String constants like CHANGE,
BLUR, DRAG_DROP, etc. (and can be statically imported jdk1.5 style). The
class also includes Javadoc that describes each event in detail. I
thought that this might be a little contribution to Wicket if you want
it. Let me know and I can submit the source (again, would need the URL
and procedure).

Thanks,

Michael

-Original Message-
From: Igor Vaynberg [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 05, 2008 5:31 PM
To: users@wicket.apache.org
Subject: Re: Passing list of POJOs to AutoCompleteTextField?

please add an rfe into jira for this.

-igor


On Feb 5, 2008 4:38 PM, Michael Mehrle <[EMAIL PROTECTED]> wrote:
> That's exactly what I wound up doing. I wrote my custom renderer that
> grabs the name field of my POJO for rendering. Of course that is what
> I'm getting back from getModelObjectAsString(). It's a work-around and
I
> was hoping for a more elegant way of doing this...
>
> Michael
>
>
> -Original Message-
> From: Sam Barnum [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, February 05, 2008 4:01 PM
> To: users@wicket.apache.org
> Subject: Re: Passing list of POJOs to AutoCompleteTextField?
>
> I don't think it is, the getMmodelObject() returns the selected
> String.  I've gotten around this by saving the last query string sent
> via AJAX.  When the user makes a selection, I iterate over the
> options for that query string one more time, and take the POJO whose
> rendered string matches the user-selected text.
>
> I'm probably missing something obvious, but I don't think
> getModelObject() is it...
>
>
>
>
> --
> Sam Barnum
> 360 Works
> http://www.360works.com
> 415.865.0952
>
>
>
> On Feb 5, 2008, at 2:12 PM, Igor Vaynberg wrote:
>
> > shouldnt the pojo be availble from getmodelobject()?
> >
> > -igor
> >
> >
> > On Jan 29, 2008 11:55 AM, Michael Mehrle <[EMAIL PROTECTED]>
> > wrote:
> >> I could - if it was a simple matter of extracting the strings from
> >> the
> >> POJOs. Problem is that, once an option is selected, I need the
> >> underlying POJOs to become the model for the rest of the form. Yes,
> >> there's probably a way to hack this, but I would prefer to do this
> >> in a
> >> clean fashion.
> >>
> >> I already got the custom renderer working, so I'm making progress.
> >> Task
> >> #2 now is to grab the underlying POJO after selecting it and
populate
> >> the remainder of the form. This seems to be the tough part...
> >> Again, any
> >> help would be appreciated.
> >>
> >> Thanks!!
> >>
> >> Michael
> >>
> >>
> >> -Original Message-
> >> From: Igor Vaynberg [mailto:[EMAIL PROTECTED]
> >> Sent: Tuesday, January 29, 2008 11:47 AM
> >> To: users@wicket.apache.org
> >> Subject: Re: Passing list of POJOs to AutoCompleteTextField?
> >>
> >> can you not create an iterator adapter that takes an iterator of
> >> pojos
> >> and translates the pojo to some string?
> >>
> >> -igor
> >>
> >>
> >> On Jan 29, 2008 11:14 AM, Michael Mehrle <[EMAIL PROTECTED]>
> >> wrote:
> >>> I have a working test page containing an AutoCompleteTextField.
Thus
> >> far
> >>> the data feeding it has been an Iterator of strings which is being
> >>> passed to its overridden getChoices method. So far so good.
> >>>
> >>> What I need to do now is to pass in an Iterator of POJOs instead
and
> >>> have the AutoCompleteTextField render the 'name' field inside
> >>> each of
> >>> those beans. After some digging in the Wicket source I suspect
> >>> that I
> >>> need to create a custom renderer that does this - am I on the
right
> >>> track here or would you guys suggest a different approach?
> >>>
> >>> Another challenge will be to populate other form fields in the
page
> >>> after selecting an option from the AutoCompleteTextField. By
> >>> selecting
> >>> an option in the dropdown I am basically selecting an entire POJO,
> >> which
> >>> is supposed to be used as the model for the other remaining
fields.
> >> For
> >>> instance, the POJO will contain address, zip, phone, etc. fields
and
> >> by
> >>> selecting the appropriate name in the AutoCompleteTextField it
> >> populates
> >>> all other fields with the remaining data in the underlying POJO.
> >>> Hope
> >>> this makes sense - I think I have an idea of how to implement
this,
> >> but
> >>> would appreciate any tips/insights.
> >>>
> >>> Thanks!!
> >>>
> >>> Michael
> >>>
> >>>
> >>>
> >>>
> >>>

>
> >>> -
> >>> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >>> For additional commands, e-mail: [EMAIL PROTECTED]
> >>>
> >>>
> >>
> >>
-
> >> To unsubscribe, e-mail: [EM

Re: adding extra javascript call in CheckBox

2008-02-06 Thread Beyonder Unknown
Thanks Igor!


 
--
The only constant in life is change.

- Original Message 
From: Igor Vaynberg <[EMAIL PROTECTED]>
To: users@wicket.apache.org
Sent: Wednesday, February 6, 2008 2:19:44 PM
Subject: Re: adding extra javascript call in CheckBox


because 
you 
dont 
call 
super.oncomponenttag()

-igor


On 
Feb 
6, 
2008 
2:14 
PM, 
Beyonder 
Unknown 
<[EMAIL PROTECTED]> 
wrote:
>
> 
Another 
thing 
that 
is 
confusing 
to 
me 
is 
that, 
why 
is 
it 
that 
when 
I 
override 
the 
onComponentTag() 
the 
"name" 
attribute 
in 
the 
generated 
markup 
disappear. 
I'm 
just 
appending 
function 
in 
the 
onClick 
when 
I 
override 
onComponentTag().
>
> 
Thoughts?
>
> 
Thanks,
> 
Wen 
Tong
>
> 
--
> 
The 
only 
constant 
in 
life 
is 
change.
>
> 
- 
Original 
Message 

> 
From: 
Beyonder 
Unknown 
<[EMAIL PROTECTED]>
> 
To: 
users@wicket.apache.org
>
> 
Sent: 
Wednesday, 
February 
6, 
2008 
1:24:16 
PM
> 
Subject: 
Re: 
adding 
extra 
javascript 
call 
in 
CheckBox
>
>
>
> 
Thanks
> 
Igor!
> 
I
> 
appreciate
> 
the
> 
prompt
> 
reply.
>
> 
Best,
> 
Wen
> 
Tong
>
> 
--
> 
The
> 
only
> 
constant
> 
in
> 
life
> 
is
> 
change.
>
> 
-
> 
Original
> 
Message
> 

> 
From:
> 
Igor
> 
Vaynberg
> 
<[EMAIL PROTECTED]>
> 
To:
> 
users@wicket.apache.org
> 
Sent:
> 
Wednesday,
> 
February
> 
6,
> 
2008
> 
10:45:52
> 
AM
> 
Subject:
> 
Re:
> 
adding
> 
extra
> 
javascript
> 
call
> 
in
> 
CheckBox
>
>
> 
tag.put("onclick","executeSomething();"+tag.getattributes().get("onclick"));
>
> 
-igor
>
> 
On
> 
Feb
> 
6,
> 
2008
> 
10:39
> 
AM,
> 
Beyonder
> 
Unknown
> 
<[EMAIL PROTECTED]>
> 
wrote:
> 
>
> 
>
> 
Hi
> 
All,
> 
>
> 
>
> 
I
> 
was
> 
wondering
> 
if
> 
there's
> 
a
> 
way
> 
to
> 
add
> 
or
> 
decorate
> 
a
> 
javascript
> 
call
> 
in
> 
CheckBox?
> 
What
> 
I
> 
did
> 
was:
> 
>
> 
>
> 
new
> 
CheckBox("checkBox",
> 
new
> 
Model())
> 
{
> 
>
>
>
>
>
>
>
>
>
>
>
> 
protected
> 
void
> 
onComponentTag(ComponentTag
> 
tag)
> 
{
> 
>
>
>
>
>
>
>
>
>
>
>
>
>
> 
tag.put("onclick","executeSomething();");
> 
>
>
>
>
>
>
>
>
>
>
>
> 
}
> 
>
> 
>
> 
>
> 
But
> 
it
> 
overrides
> 
the
> 
original
> 
onClick
> 
that
> 
Wicket
> 
is
> 
writing.
> 
Is
> 
there
> 
a
> 
way
> 
that
> 
I
> 
can
> 
decorate
> 
it
> 
so
> 
that
> 
I
> 
can
> 
add
> 
extra
> 
javaScript
> 
call
> 
in
> 
onClick
> 
without
> 
overriding
> 
the
> 
original
> 
click,
> 
like
> 
the
> 
buttons
> 
has
> 
this:
> 
>
> 
>
>
>
> 
protected
> 
IAjaxCallDecorator
> 
getAjaxCallDecorator()
> 
{
> 
>
>
>
>
>
>
>
>
>
> 
return
> 
new
> 
AjaxCallDecorator()
> 
>
> 
>
> 
>
> 
Thanks
> 
in
> 
advance
> 
and
> 
happy
> 
chinese
> 
new
> 
year!
> 
>
> 
>
> 
Best,
> 
>
> 
Wen
> 
Tong
> 
>
> 
>
> 
>
> 
--
> 
>
> 
The
> 
only
> 
constant
> 
in
> 
life
> 
is
> 
change.
> 
>
> 
>
> 
>
> 
>
> 
>
>
>
>
> 

> 
>
> 
Looking
> 
for
> 
last
> 
minute
> 
shopping
> 
deals?
> 
>
> 
Find
> 
them
> 
fast
> 
with
> 
Yahoo!
> 
Search.
> 
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
> 
>
> 
>
> 
-
> 
>
> 
To
> 
unsubscribe,
> 
e-mail:
> 
[EMAIL PROTECTED]
> 
>
> 
For
> 
additional
> 
commands,
> 
e-mail:
> 
[EMAIL PROTECTED]
> 
>
> 
>
>
> 
-
> 
To
> 
unsubscribe,
> 
e-mail:
> 
[EMAIL PROTECTED]
> 
For
> 
additional
> 
commands,
> 
e-mail:
> 
[EMAIL PROTECTED]
>
>
>
>
>
>
>
>
>
> 

> 
Looking
> 
for
> 
last
> 
minute
> 
shopping
> 
deals?
> 
Find
> 
them
> 
fast
> 
with
> 
Yahoo!
> 
Search.
> 
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>
> 
-
> 
To
> 
unsubscribe,
> 
e-mail:
> 
[EMAIL PROTECTED]
> 
For
> 
additional
> 
commands,
> 
e-mail:
> 
[EMAIL PROTECTED]
>
>
>
>
>
>
>  
  
  
 

> 
Never 
miss 
a 
thing.  
Make 
Yahoo 
your 
home 
page.
> 
http://www.yahoo.com/r/hs
>
>
> 
-
> 
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
> 
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]
>
>

-
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]






  

Never miss a thing.  Make Yahoo your home page. 
http://www.yahoo.com/r/hs

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Martijn Dashorst
Thanks! And I always thought: what happens in Vegas, stays in Vegas...

Martijn

On 2/6/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> https://issues.apache.org/jira/browse/WICKET-1327
>
> On Feb 6, 2008 1:12 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> > jira, that way you can click the "im donating attachment to the
> > project through ASL license" checkbox
> >
> > -igor
> >
> >
> >
> > On Feb 6, 2008 1:10 PM, Scott Swank <[EMAIL PROTECTED]> wrote:
> > > The cglib website http://cglib.sourceforge.net/ points here for their
> > > license: http://www.apache.org/foundation/licence-FAQ.html
> > >
> > > So I don't think there are any issues.  :)
> > >
> > > Are there any issues with attaching a zip file to an e-mail, or would
> > > you prefer another means?
> > >
> > >
> > > On Feb 6, 2008 1:06 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> > > > if not cglib i can rewrite that with asm, its license is very liberal
> > > > and we can even embed it into wicket - at least thats what ive done
> > > > for salve to avoid version conflicts with other asm versions.
> > > >
> > > > -igor
> > > >
> > > >
> > > >
> > > > On Feb 6, 2008 1:04 PM, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > > > > please share for Wicket 1.4, if cglib's license is permitting, I think
> > > > > we should add this to core.
> > > > >
> > > > > Martijn
> > > > >
> > > > >
> > > > > On 2/6/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> > > > > > One of our more clever developers created a CompoundPropertyModel 
> > > > > > that
> > > > > > uses a cglib proxy to strongly bind the mutators to the model.  It
> > > > > > looks like this:
> > > > > >
> > > > > > SharedPropertyModel model = new
> > > > > > SharedPropertyModel(customer);
> > > > > > this.setModel(model);
> > > > > >
> > > > > > FormComponent firstName = new
> > > > > > CustomerNameField("firstName").setRequired(true);
> > > > > > model.bind(firstName).to().getFirstName();
> > > > > > add(firstName);
> > > > > >
> > > > > > FormComponent lastName = new 
> > > > > > CustomerNameField("lastName").setRequired(true);
> > > > > > model.bind(lastName).to().getLastName();
> > > > > > add(lastName);
> > > > > >
> > > > > > FormComponent addr1 = new 
> > > > > > AddressField("address1").setRequired(true);
> > > > > > model.bind(addr1).to().getAddress().getAddress1();
> > > > > > add(addr1);
> > > > > >
> > > > > > FormComponent addr2 = new AddressField("address2");
> > > > > > model.bind(addr2).to().getAddress().getAddress2();
> > > > > > add(addr2);
> > > > > >
> > > > > > FormComponent city = new CityField("city");
> > > > > > model.bind(city).to().getAddress().getCity();
> > > > > > add(city);
> > > > > >
> > > > > > We're happy to share if folk like this approach.  N.B. that the 
> > > > > > .to()
> > > > > > call is for readability rather than out of any necessity.
> > > > > >
> > > > > > Cheers,
> > > > > > Scott
> > > > > >
> > > > > > --
> > > > > > Scott Swank
> > > > > > reformed mathematician
> > > > > >
> > > > > > -
> > > > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Buy Wicket in Action: http://manning.com/dashorst
> > > > > Apache Wicket 1.3.0 is released
> > > > > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
> > > > >
> > > > >
> > > > > -
> > > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > > >
> > > > >
> > > >
> > > > -
> > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > >
> > > >
> > >
> > >
> > >
> > > --
> > > Scott Swank
> > > reformed mathematician
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
>
> --
> Scott Swank
> reformed mathematician
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0

--

Re: adding extra javascript call in CheckBox

2008-02-06 Thread Beyonder Unknown

Never mind, I noticed that it doesn't call the super.onComponentTag(). 

my bad.

Wen Tong
 
--
The only constant in life is change.

- Original Message 
From: Beyonder Unknown <[EMAIL PROTECTED]>
To: users@wicket.apache.org
Sent: Wednesday, February 6, 2008 2:14:12 PM
Subject: Re: adding extra javascript call in CheckBox



Another 
thing 
that 
is 
confusing 
to 
me 
is 
that, 
why 
is 
it 
that 
when 
I 
override 
the 
onComponentTag() 
the 
"name" 
attribute 
in 
the 
generated 
markup 
disappear. 
I'm 
just 
appending 
function 
in 
the 
onClick 
when 
I 
override 
onComponentTag().

Thoughts?

Thanks,
Wen 
Tong
 
--
The 
only 
constant 
in 
life 
is 
change.

- 
Original 
Message 

From: 
Beyonder 
Unknown 
<[EMAIL PROTECTED]>
To: 
users@wicket.apache.org
Sent: 
Wednesday, 
February 
6, 
2008 
1:24:16 
PM
Subject: 
Re: 
adding 
extra 
javascript 
call 
in 
CheckBox



Thanks 
Igor! 
I 
appreciate 
the 
prompt 
reply.

Best,
Wen 
Tong
 
--
The 
only 
constant 
in 
life 
is 
change.

- 
Original 
Message 

From: 
Igor 
Vaynberg 
<[EMAIL PROTECTED]>
To: 
users@wicket.apache.org
Sent: 
Wednesday, 
February 
6, 
2008 
10:45:52 
AM
Subject: 
Re: 
adding 
extra 
javascript 
call 
in 
CheckBox


tag.put("onclick","executeSomething();"+tag.getattributes().get("onclick"));

-igor

On 
Feb 
6, 
2008 
10:39 
AM, 
Beyonder 
Unknown 
<[EMAIL PROTECTED]> 
wrote:
>
> 
Hi 
All,
>
> 
I 
was 
wondering 
if 
there's 
a 
way 
to 
add 
or 
decorate 
a 
javascript 
call 
in 
CheckBox? 
What 
I 
did 
was:
>
> 
new 
CheckBox("checkBox", 
new 
Model()) 
{
>  
  
  
  
  
  
  
  
  
  
 
protected 
void 
onComponentTag(ComponentTag 
tag) 
{
>  
  
  
  
  
  
  
  
  
  
  
  
 
tag.put("onclick","executeSomething();");
>  
  
  
  
  
  
  
  
  
  
 
}
>
>
> 
But 
it 
overrides 
the 
original 
onClick 
that 
Wicket 
is 
writing. 
Is 
there 
a 
way 
that 
I 
can 
decorate 
it 
so 
that 
I 
can 
add 
extra 
javaScript 
call 
in 
onClick 
without 
overriding 
the 
original 
click, 
like 
the 
buttons 
has 
this:
>
>  
  
 
protected 
IAjaxCallDecorator 
getAjaxCallDecorator() 
{
>  
  
  
  
  
  
  
  
 
return 
new 
AjaxCallDecorator()
>
>
> 
Thanks 
in 
advance 
and 
happy 
chinese 
new 
year!
>
> 
Best,
> 
Wen 
Tong
>
>
> 
--
> 
The 
only 
constant 
in 
life 
is 
change.
>
>
>
>
>  
  
  
 

> 
Looking 
for 
last 
minute 
shopping 
deals?
> 
Find 
them 
fast 
with 
Yahoo! 
Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>
> 
-
> 
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
> 
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]
>
>

-
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]






  
  
  

Looking 
for 
last 
minute 
shopping 
deals?  
Find 
them 
fast 
with 
Yahoo! 
Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping

-
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]






  
  
  

Never 
miss 
a 
thing.  
Make 
Yahoo 
your 
home 
page. 
http://www.yahoo.com/r/hs

-
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]






  

Never miss a thing.  Make Yahoo your home page. 
http://www.yahoo.com/r/hs

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: adding extra javascript call in CheckBox

2008-02-06 Thread Igor Vaynberg
because you dont call super.oncomponenttag()

-igor


On Feb 6, 2008 2:14 PM, Beyonder Unknown <[EMAIL PROTECTED]> wrote:
>
> Another thing that is confusing to me is that, why is it that when I override 
> the onComponentTag() the "name" attribute in the generated markup disappear. 
> I'm just appending function in the onClick when I override onComponentTag().
>
> Thoughts?
>
> Thanks,
> Wen Tong
>
> --
> The only constant in life is change.
>
> - Original Message 
> From: Beyonder Unknown <[EMAIL PROTECTED]>
> To: users@wicket.apache.org
>
> Sent: Wednesday, February 6, 2008 1:24:16 PM
> Subject: Re: adding extra javascript call in CheckBox
>
>
>
> Thanks
> Igor!
> I
> appreciate
> the
> prompt
> reply.
>
> Best,
> Wen
> Tong
>
> --
> The
> only
> constant
> in
> life
> is
> change.
>
> -
> Original
> Message
> 
> From:
> Igor
> Vaynberg
> <[EMAIL PROTECTED]>
> To:
> users@wicket.apache.org
> Sent:
> Wednesday,
> February
> 6,
> 2008
> 10:45:52
> AM
> Subject:
> Re:
> adding
> extra
> javascript
> call
> in
> CheckBox
>
>
> tag.put("onclick","executeSomething();"+tag.getattributes().get("onclick"));
>
> -igor
>
> On
> Feb
> 6,
> 2008
> 10:39
> AM,
> Beyonder
> Unknown
> <[EMAIL PROTECTED]>
> wrote:
> >
> >
> Hi
> All,
> >
> >
> I
> was
> wondering
> if
> there's
> a
> way
> to
> add
> or
> decorate
> a
> javascript
> call
> in
> CheckBox?
> What
> I
> did
> was:
> >
> >
> new
> CheckBox("checkBox",
> new
> Model())
> {
> >
>
>
>
>
>
>
>
>
>
>
> protected
> void
> onComponentTag(ComponentTag
> tag)
> {
> >
>
>
>
>
>
>
>
>
>
>
>
>
> tag.put("onclick","executeSomething();");
> >
>
>
>
>
>
>
>
>
>
>
> }
> >
> >
> >
> But
> it
> overrides
> the
> original
> onClick
> that
> Wicket
> is
> writing.
> Is
> there
> a
> way
> that
> I
> can
> decorate
> it
> so
> that
> I
> can
> add
> extra
> javaScript
> call
> in
> onClick
> without
> overriding
> the
> original
> click,
> like
> the
> buttons
> has
> this:
> >
> >
>
>
> protected
> IAjaxCallDecorator
> getAjaxCallDecorator()
> {
> >
>
>
>
>
>
>
>
>
> return
> new
> AjaxCallDecorator()
> >
> >
> >
> Thanks
> in
> advance
> and
> happy
> chinese
> new
> year!
> >
> >
> Best,
> >
> Wen
> Tong
> >
> >
> >
> --
> >
> The
> only
> constant
> in
> life
> is
> change.
> >
> >
> >
> >
> >
>
>
>
> 
> >
> Looking
> for
> last
> minute
> shopping
> deals?
> >
> Find
> them
> fast
> with
> Yahoo!
> Search.
> http://tools.search.yahoo.com/newsearch/category.php?category=shopping
> >
> >
> -
> >
> To
> unsubscribe,
> e-mail:
> [EMAIL PROTECTED]
> >
> For
> additional
> commands,
> e-mail:
> [EMAIL PROTECTED]
> >
> >
>
> -
> To
> unsubscribe,
> e-mail:
> [EMAIL PROTECTED]
> For
> additional
> commands,
> e-mail:
> [EMAIL PROTECTED]
>
>
>
>
>
>
>
>
>
> 
> Looking
> for
> last
> minute
> shopping
> deals?
> Find
> them
> fast
> with
> Yahoo!
> Search.
> http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>
> -
> To
> unsubscribe,
> e-mail:
> [EMAIL PROTECTED]
> For
> additional
> commands,
> e-mail:
> [EMAIL PROTECTED]
>
>
>
>
>
>
>   
> 
> Never miss a thing.  Make Yahoo your home page.
> http://www.yahoo.com/r/hs
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: adding extra javascript call in CheckBox

2008-02-06 Thread Beyonder Unknown

Another thing that is confusing to me is that, why is it that when I override 
the onComponentTag() the "name" attribute in the generated markup disappear. 
I'm just appending function in the onClick when I override onComponentTag().

Thoughts?

Thanks,
Wen Tong
 
--
The only constant in life is change.

- Original Message 
From: Beyonder Unknown <[EMAIL PROTECTED]>
To: users@wicket.apache.org
Sent: Wednesday, February 6, 2008 1:24:16 PM
Subject: Re: adding extra javascript call in CheckBox



Thanks 
Igor! 
I 
appreciate 
the 
prompt 
reply.

Best,
Wen 
Tong
 
--
The 
only 
constant 
in 
life 
is 
change.

- 
Original 
Message 

From: 
Igor 
Vaynberg 
<[EMAIL PROTECTED]>
To: 
users@wicket.apache.org
Sent: 
Wednesday, 
February 
6, 
2008 
10:45:52 
AM
Subject: 
Re: 
adding 
extra 
javascript 
call 
in 
CheckBox


tag.put("onclick","executeSomething();"+tag.getattributes().get("onclick"));

-igor

On 
Feb 
6, 
2008 
10:39 
AM, 
Beyonder 
Unknown 
<[EMAIL PROTECTED]> 
wrote:
>
> 
Hi 
All,
>
> 
I 
was 
wondering 
if 
there's 
a 
way 
to 
add 
or 
decorate 
a 
javascript 
call 
in 
CheckBox? 
What 
I 
did 
was:
>
> 
new 
CheckBox("checkBox", 
new 
Model()) 
{
>  
  
  
  
  
  
  
  
  
  
 
protected 
void 
onComponentTag(ComponentTag 
tag) 
{
>  
  
  
  
  
  
  
  
  
  
  
  
 
tag.put("onclick","executeSomething();");
>  
  
  
  
  
  
  
  
  
  
 
}
>
>
> 
But 
it 
overrides 
the 
original 
onClick 
that 
Wicket 
is 
writing. 
Is 
there 
a 
way 
that 
I 
can 
decorate 
it 
so 
that 
I 
can 
add 
extra 
javaScript 
call 
in 
onClick 
without 
overriding 
the 
original 
click, 
like 
the 
buttons 
has 
this:
>
>  
  
 
protected 
IAjaxCallDecorator 
getAjaxCallDecorator() 
{
>  
  
  
  
  
  
  
  
 
return 
new 
AjaxCallDecorator()
>
>
> 
Thanks 
in 
advance 
and 
happy 
chinese 
new 
year!
>
> 
Best,
> 
Wen 
Tong
>
>
> 
--
> 
The 
only 
constant 
in 
life 
is 
change.
>
>
>
>
>  
  
  
 

> 
Looking 
for 
last 
minute 
shopping 
deals?
> 
Find 
them 
fast 
with 
Yahoo! 
Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>
> 
-
> 
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
> 
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]
>
>

-
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]






  
  
  

Looking 
for 
last 
minute 
shopping 
deals?  
Find 
them 
fast 
with 
Yahoo! 
Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping

-
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]






  

Never miss a thing.  Make Yahoo your home page. 
http://www.yahoo.com/r/hs

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



AJAX mouseover popup

2008-02-06 Thread Niels Bo

Hi

I am looking for some wicket code or a component that can show mouseover
popups loaded by AJAX.

Exactly as can be seen on this page 
http://www.mathertel.de/AJAXEngine/S03_AJAXControls/AJAXPopUpDemo.aspx
http://www.mathertel.de/AJAXEngine/S03_AJAXControls/AJAXPopUpDemo.aspx 


Many thanks if someone can help.
Niels
-- 
View this message in context: 
http://www.nabble.com/AJAX-mouseover-popup-tp15312817p15312817.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Scott Swank
https://issues.apache.org/jira/browse/WICKET-1327

On Feb 6, 2008 1:12 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> jira, that way you can click the "im donating attachment to the
> project through ASL license" checkbox
>
> -igor
>
>
>
> On Feb 6, 2008 1:10 PM, Scott Swank <[EMAIL PROTECTED]> wrote:
> > The cglib website http://cglib.sourceforge.net/ points here for their
> > license: http://www.apache.org/foundation/licence-FAQ.html
> >
> > So I don't think there are any issues.  :)
> >
> > Are there any issues with attaching a zip file to an e-mail, or would
> > you prefer another means?
> >
> >
> > On Feb 6, 2008 1:06 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> > > if not cglib i can rewrite that with asm, its license is very liberal
> > > and we can even embed it into wicket - at least thats what ive done
> > > for salve to avoid version conflicts with other asm versions.
> > >
> > > -igor
> > >
> > >
> > >
> > > On Feb 6, 2008 1:04 PM, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > > > please share for Wicket 1.4, if cglib's license is permitting, I think
> > > > we should add this to core.
> > > >
> > > > Martijn
> > > >
> > > >
> > > > On 2/6/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> > > > > One of our more clever developers created a CompoundPropertyModel that
> > > > > uses a cglib proxy to strongly bind the mutators to the model.  It
> > > > > looks like this:
> > > > >
> > > > > SharedPropertyModel model = new
> > > > > SharedPropertyModel(customer);
> > > > > this.setModel(model);
> > > > >
> > > > > FormComponent firstName = new
> > > > > CustomerNameField("firstName").setRequired(true);
> > > > > model.bind(firstName).to().getFirstName();
> > > > > add(firstName);
> > > > >
> > > > > FormComponent lastName = new 
> > > > > CustomerNameField("lastName").setRequired(true);
> > > > > model.bind(lastName).to().getLastName();
> > > > > add(lastName);
> > > > >
> > > > > FormComponent addr1 = new 
> > > > > AddressField("address1").setRequired(true);
> > > > > model.bind(addr1).to().getAddress().getAddress1();
> > > > > add(addr1);
> > > > >
> > > > > FormComponent addr2 = new AddressField("address2");
> > > > > model.bind(addr2).to().getAddress().getAddress2();
> > > > > add(addr2);
> > > > >
> > > > > FormComponent city = new CityField("city");
> > > > > model.bind(city).to().getAddress().getCity();
> > > > > add(city);
> > > > >
> > > > > We're happy to share if folk like this approach.  N.B. that the .to()
> > > > > call is for readability rather than out of any necessity.
> > > > >
> > > > > Cheers,
> > > > > Scott
> > > > >
> > > > > --
> > > > > Scott Swank
> > > > > reformed mathematician
> > > > >
> > > > > -
> > > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > > >
> > > > >
> > > >
> > > >
> > > > --
> > > > Buy Wicket in Action: http://manning.com/dashorst
> > > > Apache Wicket 1.3.0 is released
> > > > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
> > > >
> > > >
> > > > -
> > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > >
> > > >
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> >
> >
> >
> > --
> > Scott Swank
> > reformed mathematician
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
Scott Swank
reformed mathematician

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: adding extra javascript call in CheckBox

2008-02-06 Thread Beyonder Unknown

Thanks Igor! I appreciate the prompt reply.

Best,
Wen Tong
 
--
The only constant in life is change.

- Original Message 
From: Igor Vaynberg <[EMAIL PROTECTED]>
To: users@wicket.apache.org
Sent: Wednesday, February 6, 2008 10:45:52 AM
Subject: Re: adding extra javascript call in CheckBox


tag.put("onclick","executeSomething();"+tag.getattributes().get("onclick"));

-igor

On 
Feb 
6, 
2008 
10:39 
AM, 
Beyonder 
Unknown 
<[EMAIL PROTECTED]> 
wrote:
>
> 
Hi 
All,
>
> 
I 
was 
wondering 
if 
there's 
a 
way 
to 
add 
or 
decorate 
a 
javascript 
call 
in 
CheckBox? 
What 
I 
did 
was:
>
> 
new 
CheckBox("checkBox", 
new 
Model()) 
{
>  
  
  
  
  
  
  
  
  
  
 
protected 
void 
onComponentTag(ComponentTag 
tag) 
{
>  
  
  
  
  
  
  
  
  
  
  
  
 
tag.put("onclick","executeSomething();");
>  
  
  
  
  
  
  
  
  
  
 
}
>
>
> 
But 
it 
overrides 
the 
original 
onClick 
that 
Wicket 
is 
writing. 
Is 
there 
a 
way 
that 
I 
can 
decorate 
it 
so 
that 
I 
can 
add 
extra 
javaScript 
call 
in 
onClick 
without 
overriding 
the 
original 
click, 
like 
the 
buttons 
has 
this:
>
>  
  
 
protected 
IAjaxCallDecorator 
getAjaxCallDecorator() 
{
>  
  
  
  
  
  
  
  
 
return 
new 
AjaxCallDecorator()
>
>
> 
Thanks 
in 
advance 
and 
happy 
chinese 
new 
year!
>
> 
Best,
> 
Wen 
Tong
>
>
> 
--
> 
The 
only 
constant 
in 
life 
is 
change.
>
>
>
>
>  
  
  
 

> 
Looking 
for 
last 
minute 
shopping 
deals?
> 
Find 
them 
fast 
with 
Yahoo! 
Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>
> 
-
> 
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
> 
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]
>
>

-
To 
unsubscribe, 
e-mail: 
[EMAIL PROTECTED]
For 
additional 
commands, 
e-mail: 
[EMAIL PROTECTED]






  

Looking for last minute shopping deals?  
Find them fast with Yahoo! Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Igor Vaynberg
jira, that way you can click the "im donating attachment to the
project through ASL license" checkbox

-igor


On Feb 6, 2008 1:10 PM, Scott Swank <[EMAIL PROTECTED]> wrote:
> The cglib website http://cglib.sourceforge.net/ points here for their
> license: http://www.apache.org/foundation/licence-FAQ.html
>
> So I don't think there are any issues.  :)
>
> Are there any issues with attaching a zip file to an e-mail, or would
> you prefer another means?
>
>
> On Feb 6, 2008 1:06 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> > if not cglib i can rewrite that with asm, its license is very liberal
> > and we can even embed it into wicket - at least thats what ive done
> > for salve to avoid version conflicts with other asm versions.
> >
> > -igor
> >
> >
> >
> > On Feb 6, 2008 1:04 PM, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > > please share for Wicket 1.4, if cglib's license is permitting, I think
> > > we should add this to core.
> > >
> > > Martijn
> > >
> > >
> > > On 2/6/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> > > > One of our more clever developers created a CompoundPropertyModel that
> > > > uses a cglib proxy to strongly bind the mutators to the model.  It
> > > > looks like this:
> > > >
> > > > SharedPropertyModel model = new
> > > > SharedPropertyModel(customer);
> > > > this.setModel(model);
> > > >
> > > > FormComponent firstName = new
> > > > CustomerNameField("firstName").setRequired(true);
> > > > model.bind(firstName).to().getFirstName();
> > > > add(firstName);
> > > >
> > > > FormComponent lastName = new 
> > > > CustomerNameField("lastName").setRequired(true);
> > > > model.bind(lastName).to().getLastName();
> > > > add(lastName);
> > > >
> > > > FormComponent addr1 = new 
> > > > AddressField("address1").setRequired(true);
> > > > model.bind(addr1).to().getAddress().getAddress1();
> > > > add(addr1);
> > > >
> > > > FormComponent addr2 = new AddressField("address2");
> > > > model.bind(addr2).to().getAddress().getAddress2();
> > > > add(addr2);
> > > >
> > > > FormComponent city = new CityField("city");
> > > > model.bind(city).to().getAddress().getCity();
> > > > add(city);
> > > >
> > > > We're happy to share if folk like this approach.  N.B. that the .to()
> > > > call is for readability rather than out of any necessity.
> > > >
> > > > Cheers,
> > > > Scott
> > > >
> > > > --
> > > > Scott Swank
> > > > reformed mathematician
> > > >
> > > > -
> > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > >
> > > >
> > >
> > >
> > > --
> > > Buy Wicket in Action: http://manning.com/dashorst
> > > Apache Wicket 1.3.0 is released
> > > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
> > >
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
>
> --
> Scott Swank
> reformed mathematician
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Daniel Stoch

I'm quite interested too.

Daniel

On 2008-02-06, at 19:27, Carl-Eric Menzel wrote:


Scott Swank wrote:

We're happy to share if folk like this approach.  N.B. that the .to()
call is for readability rather than out of any necessity.


I'm quite interested in this. This looks like it is just crazy and
clever enough to be really useful :-)

Thanks!
Carl-Eric

-
To unsubscribe, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread djo.mos

Hi,

gantini wrote:
> 
> But when I modify any html file, no reload is performed :-((
> 

This may take time, especially with HTML files (in opposition to class files
change) and in an unvisible manner (again in opposition to class files
change where Tomcat reloads the context).

Try waiting for some seconds and keep hitting the refresh button.
-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15312791.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Scott Swank
The cglib website http://cglib.sourceforge.net/ points here for their
license: http://www.apache.org/foundation/licence-FAQ.html

So I don't think there are any issues.  :)

Are there any issues with attaching a zip file to an e-mail, or would
you prefer another means?

On Feb 6, 2008 1:06 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> if not cglib i can rewrite that with asm, its license is very liberal
> and we can even embed it into wicket - at least thats what ive done
> for salve to avoid version conflicts with other asm versions.
>
> -igor
>
>
>
> On Feb 6, 2008 1:04 PM, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > please share for Wicket 1.4, if cglib's license is permitting, I think
> > we should add this to core.
> >
> > Martijn
> >
> >
> > On 2/6/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> > > One of our more clever developers created a CompoundPropertyModel that
> > > uses a cglib proxy to strongly bind the mutators to the model.  It
> > > looks like this:
> > >
> > > SharedPropertyModel model = new
> > > SharedPropertyModel(customer);
> > > this.setModel(model);
> > >
> > > FormComponent firstName = new
> > > CustomerNameField("firstName").setRequired(true);
> > > model.bind(firstName).to().getFirstName();
> > > add(firstName);
> > >
> > > FormComponent lastName = new 
> > > CustomerNameField("lastName").setRequired(true);
> > > model.bind(lastName).to().getLastName();
> > > add(lastName);
> > >
> > > FormComponent addr1 = new 
> > > AddressField("address1").setRequired(true);
> > > model.bind(addr1).to().getAddress().getAddress1();
> > > add(addr1);
> > >
> > > FormComponent addr2 = new AddressField("address2");
> > > model.bind(addr2).to().getAddress().getAddress2();
> > > add(addr2);
> > >
> > > FormComponent city = new CityField("city");
> > > model.bind(city).to().getAddress().getCity();
> > > add(city);
> > >
> > > We're happy to share if folk like this approach.  N.B. that the .to()
> > > call is for readability rather than out of any necessity.
> > >
> > > Cheers,
> > > Scott
> > >
> > > --
> > > Scott Swank
> > > reformed mathematician
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> >
> >
> > --
> > Buy Wicket in Action: http://manning.com/dashorst
> > Apache Wicket 1.3.0 is released
> > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
Scott Swank
reformed mathematician

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Can i assign parameters while calling the application?

2008-02-06 Thread Per Newgro
Hi *,

i use an application. This will be called by different urls via filters in 
web.xml I set a custom init-param for every filter. I can access the
parameter and thus load my data based on the value. So far all ok.

But i'm tired of adding always a new filter and the definition to the web.xml
I would be glad if i could assign my parameter as a url-parameter.
Something like http://localhost:8080/myappl?myparam=2

Is this possible? If it is - how can i access myparam?

Thanks
Per

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: loosely coupled panels: react to model object change

2008-02-06 Thread Daniel Stoch

Hi,

I have implemented such model (as Johan wrote) in our application. It  
uses observer pattern and it has methods like: addListener,  
removeListener and notify(Event event) (Event is an enum). Each panel  
register itself as a proper "events" listener and in onClick() you  
can simply call model.notify(Event.SOME_EVENT) to fire listener  
methods in other panels.


Daniel

On 2008-02-05, at 23:51, Johan Compagner wrote:

What not do that in your model itself? (Observer pattern or  
something like

that)
Just like all the swing models do because of there push nature  
instead of

pull




On Feb 5, 2008 11:05 AM, Gabor Szokoli <[EMAIL PROTECTED]> wrote:


Hi!

We are trying to build our application from loosely coupled panels,
sharing models here and there as needed.
It works wounderfully 90% of the time: as long as the panels contain
wicket components only, and no further UI logic. One panel can update
a model, and the data is reflected in the components of the other
panel, as it should.

But sometimes one panel needs to perform an action when its model
object is changed from an onClick handler on another panel.
OnModelChanged is not called, because the other panel has no direct
reference to this panel to perform a setObject on it, they only share
a model, and do setObject on that.

Where do I put my OnModelObjectChanged event handling code without
sacrificing too much from my lovely loosely coupling?

Any advice is warmly welcome.


Gabor Szokoli

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Igor Vaynberg
if not cglib i can rewrite that with asm, its license is very liberal
and we can even embed it into wicket - at least thats what ive done
for salve to avoid version conflicts with other asm versions.

-igor


On Feb 6, 2008 1:04 PM, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> please share for Wicket 1.4, if cglib's license is permitting, I think
> we should add this to core.
>
> Martijn
>
>
> On 2/6/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> > One of our more clever developers created a CompoundPropertyModel that
> > uses a cglib proxy to strongly bind the mutators to the model.  It
> > looks like this:
> >
> > SharedPropertyModel model = new
> > SharedPropertyModel(customer);
> > this.setModel(model);
> >
> > FormComponent firstName = new
> > CustomerNameField("firstName").setRequired(true);
> > model.bind(firstName).to().getFirstName();
> > add(firstName);
> >
> > FormComponent lastName = new 
> > CustomerNameField("lastName").setRequired(true);
> > model.bind(lastName).to().getLastName();
> > add(lastName);
> >
> > FormComponent addr1 = new 
> > AddressField("address1").setRequired(true);
> > model.bind(addr1).to().getAddress().getAddress1();
> > add(addr1);
> >
> > FormComponent addr2 = new AddressField("address2");
> > model.bind(addr2).to().getAddress().getAddress2();
> > add(addr2);
> >
> > FormComponent city = new CityField("city");
> > model.bind(city).to().getAddress().getCity();
> > add(city);
> >
> > We're happy to share if folk like this approach.  N.B. that the .to()
> > call is for readability rather than out of any necessity.
> >
> > Cheers,
> > Scott
> >
> > --
> > Scott Swank
> > reformed mathematician
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
> --
> Buy Wicket in Action: http://manning.com/dashorst
> Apache Wicket 1.3.0 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: CompoundModel based on proxies

2008-02-06 Thread Martijn Dashorst
please share for Wicket 1.4, if cglib's license is permitting, I think
we should add this to core.

Martijn

On 2/6/08, Scott Swank <[EMAIL PROTECTED]> wrote:
> One of our more clever developers created a CompoundPropertyModel that
> uses a cglib proxy to strongly bind the mutators to the model.  It
> looks like this:
>
> SharedPropertyModel model = new
> SharedPropertyModel(customer);
> this.setModel(model);
>
> FormComponent firstName = new
> CustomerNameField("firstName").setRequired(true);
> model.bind(firstName).to().getFirstName();
> add(firstName);
>
> FormComponent lastName = new 
> CustomerNameField("lastName").setRequired(true);
> model.bind(lastName).to().getLastName();
> add(lastName);
>
> FormComponent addr1 = new 
> AddressField("address1").setRequired(true);
> model.bind(addr1).to().getAddress().getAddress1();
> add(addr1);
>
> FormComponent addr2 = new AddressField("address2");
> model.bind(addr2).to().getAddress().getAddress2();
> add(addr2);
>
> FormComponent city = new CityField("city");
> model.bind(city).to().getAddress().getCity();
> add(city);
>
> We're happy to share if folk like this approach.  N.B. that the .to()
> call is for readability rather than out of any necessity.
>
> Cheers,
> Scott
>
> --
> Scott Swank
> reformed mathematician
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread Igor Vaynberg
test it out this way:

go here

http://wicket.apache.org/quickstart.html

copy and paste the maven command to create a quickstart project
find the Start class, right click and do "run as java application"

this will start embedded jetty, go to localhost:8080, then find
Index.html, edit it, and refresh the browser. do you see the changes?

-igor


On Feb 6, 2008 12:08 PM, gantini <[EMAIL PROTECTED]> wrote:
>
> Strangethis dosn't work for me...
> When wicket starts, in the tomcat console I can read:
>
> 
> *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
> ***   ^^^***
> *** Do NOT deploy to your live server(s) without changing this.  ***
> *** See Application#getConfigurationType() for more information. ***
>
>
> But when I modify any html file, no reload is performed :-((
>
> Other suggest for me?
> G.
>
>
>
> igor.vaynberg wrote:
> >
> > this should automatically be happening if you run wicket in development
> > mode.
> > that call you do is not necessary.
> >
> > -igor
> >
> >
> > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
> >>
> >> Nothing to help me?
> >>
> >>
> >>
> >> gantini wrote:
> >> >
> >> > I'm very new with Wicket.
> >> > It is possible to automatically reload resource (class and HTML file) ?
> >> >
> >> > I've set:
> >> >
> >> >   @Override
> >> >   protected void init() {
> >> >   getResourceSettings().setResourcePollFrequency(
> >> Duration.ONE_SECOND );
> >> >   }
> >> >
> >> > but this don't work for me.
> >> > Thanks.
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
> >>
> >> Sent from the Wicket - User mailing list archive at Nabble.com.
> >>
> >>
> >> -
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
>
> --
> View this message in context: 
> http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
>
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread Igor Vaynberg
im on windows and have never experienced this...

-igor


On Feb 6, 2008 12:22 PM, Konstantin Ignatyev <[EMAIL PROTECTED]> wrote:
> I have seen the behavior but that seems to be endemic to windows.
> I have not seen that on Linux or OS X.
>
>
> On Wed, Feb 6, 2008 at 12:08 PM, gantini <[EMAIL PROTECTED]> wrote:
>
> >
> > Strangethis dosn't work for me...
> > When wicket starts, in the tomcat console I can read:
> >
> > 
> > *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
> > ***   ^^^***
> > *** Do NOT deploy to your live server(s) without changing this.  ***
> > *** See Application#getConfigurationType() for more information. ***
> >
> >
> > But when I modify any html file, no reload is performed :-((
> >
> > Other suggest for me?
> > G.
> >
> >
> > igor.vaynberg wrote:
> > >
> > > this should automatically be happening if you run wicket in development
> > > mode.
> > > that call you do is not necessary.
> > >
> > > -igor
> > >
> > >
> > > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
> > >>
> > >> Nothing to help me?
> > >>
> > >>
> > >>
> > >> gantini wrote:
> > >> >
> > >> > I'm very new with Wicket.
> > >> > It is possible to automatically reload resource (class and HTML file)
> > ?
> > >> >
> > >> > I've set:
> > >> >
> > >> >   @Override
> > >> >   protected void init() {
> > >> >   getResourceSettings().setResourcePollFrequency(
> > >> Duration.ONE_SECOND );
> > >> >   }
> > >> >
> > >> > but this don't work for me.
> > >> > Thanks.
> > >> >
> > >>
> > >> --
> > >> View this message in context:
> > >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
> > >>
> > >> Sent from the Wicket - User mailing list archive at Nabble.com.
> > >>
> > >>
> > >> -
> > >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >> For additional commands, e-mail: [EMAIL PROTECTED]
> > >>
> > >>
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> > >
> >
> > --
> > View this message in context:
> > http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
> > Sent from the Wicket - User mailing list archive at Nabble.com.
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
> --
> Konstantin Ignatyev
>
> PS: If this is a typical day on planet earth, humans will add fifteen
> million tons of carbon to the atmosphere, destroy 115 square miles of
> tropical rainforest, create seventy-two miles of desert, eliminate between
> forty to one hundred species, erode seventy-one million tons of topsoil, add
> 2,700 tons of CFCs to the stratosphere, and increase their population by
> 263,000
>
> Bowers, C.A. The Culture of Denial: Why the Environmental Movement Needs a
> Strategy for Reforming Universities and Public Schools. New York: State
> University of New York Press, 1997: (4) (5) (p.206)
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: mounted url bug or request for enhancement

2008-02-06 Thread Dan Kaplan
I didn't see any response to this so I'm going to bump it once.

-Original Message-
From: Dan Kaplan [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 05, 2008 11:36 AM
To: users@wicket.apache.org
Subject: RE: mounted url bug or request for enhancement

I made a very big typo in that last paragraph.  It should have said:
But my complaint is that even though it
does that, you can still type /home/foo/bar into the url and it'll render
*home* for you.

-Original Message-
From: Dan Kaplan [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 05, 2008 11:33 AM
To: users@wicket.apache.org
Subject: mounted url bug or request for enhancement

Hello,

 

I'm testing this sandbox webapp I made that looks like this:

 

package web;

 

import org.apache.wicket.protocol.http.WebApplication;

 

public class SandboxApplication extends WebApplication {

 

protected void init() {

mountBookmarkablePage("/home", Home.class);

}

 

 

public Class getHomePage() {

return Home.class;

}

}

 

I notice that you can visit /home/foo/bar and it will render /home for you.
I learned yesterday that Wicket is considering foo to be a parameter
variable and bar to be a parameter value.  I think that's a very unusual and
error prone default, but that's not the main thing I want to talk about.

 

If I replace my init method with this: mount(new
QueryStringUrlCodingStrategy("/home", Home.class));  That should make
parameters look like this: ?foo=bar  But my complaint is that even though it
does that, you can still type /home/foo/bar into the url and it'll render
[home] for you.  IMO, it should give a 404 in that situation.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: IPropertyResolver interface for property models

2008-02-06 Thread Daniel Stoch
Well I forget that PropertyResolver works with maps, so custom models  
probably are not necessary then :). Thanks for tip.
But in my application I have to use some solutions from other  
application layer (persistance layer), where a special mechanisms to  
track changes in objects are implemented. So I must make general  
interface for this in Wicket.


Daniel

On 2008-02-06, at 21:34, Daniel Stoch wrote:

This is exactly how ObjectEditor default implementation would looks  
like: it contains hashmap for edited values.
Simple HashMap as a model is not a good solution, because you must  
somehow initialize it with object properties' values first. I think  
a better is to hide such details inside an interface (like  
ObjectEditor), then you can also easily cancel (revert) changes.  
But even using a HashMap you cannot simply use property models  
(normal and compound) to access values, you must implement another  
custom models for that. These models will be probably very similar  
to standard property models, the only difference is how they access  
object values = how their property resolver works :).


Daniel


On 2008-02-06, at 19:51, Johan Compagner wrote:


Why not just return a hashmap as the model object and have besides
that hashmap your real object



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Trouble with IE and images loaded through css

2008-02-06 Thread Matej Knopp
You can have transparent pngs without alpha blending (1 bit
transparency). I believe IE6 supports that. It's useful if your images
need more than 255+1 color palette.

-Matej

On Feb 6, 2008 9:42 PM, Philip A. Chapman <[EMAIL PROTECTED]> wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
> Thanks Matej.  For now, I've converted to .gif until I can find a better
> solution.
>
> Matej Knopp wrote:
> > Hi,
> >
> > I'm affraid the url for alphaimageloader needs to be absolute. IE
> > can't handle relative urls for filters. That is a problem because in
> > wicket all you get are relative URLs. And you probably don't want to
> > tie your application to a specific context anyway.
> >
> > 
> > I've personally have resigned to try to force IE6 to show transparent
> > pictures. I usually use two variants of each transparent picture - one
> > with alpha map for sane browsers and one with transparent color for
> > IE6. Hopefully won't be too long before IE6 share drops so low it
> > won't be worth supporting anymore.
> > 
> >
> > -Matej
> >
> >
> >
> > On Feb 6, 2008 7:37 PM, Philip A. Chapman <[EMAIL PROTECTED]> wrote:
>
> > Guys,
> >
> > Under the source dir that contains my page and html, I have two dirs,
> > css and images.  Inside css, I have two files, main.css and ie.css.
> > These css files reference images, such as:
> >
> > main.css:
> >
> > a.download-but{
> > float:right;
> > width:111px;
> > height:26px;
> > margin:0;
> > background:url(../images/download-audio.png) no-repeat 0 0;
> > text-indent:-px;
> > }
> >
> > ie.css:
> >
> > * html a.download-but{
> > background:url(none.gif);
> > 
> > filter:progid:dximagetransform.microsoft.alphaimageloader(src='images/download-audio.png',
> > sizingmethod='crop');
> > cursor:pointer;
> > }
> >
> > I have two links in the header.  mainCSS and ieCSS.  I have the
> > following code in the page:
> >
> > WebClientInfo info =
> > (WebClientInfo)((WebSession)Session.get()).getClientInfo();
> > add(new StyleSheetReference("mainCSS", getClass(), "css/main.css"));
> > StyleSheetReference ssref = new StyleSheetReference("ieCSS", getClass(),
> > "css/ie.css");
> > add(ssref);
> > if
> > (!info.getProperties().getNavigatorAppName().equalsIgnoreCase("Microsoft
> > Internet Explorer")) {
> > ssref.setVisible(false);
> > }
> >
> > My problem is that under IE, the images are not loaded.  I've tried
> > changing the image url it ../images/download-audio.png, but that didn't
> > work.
> >
> > Any suggestions?
> >>
> - -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
>
> - --
> Philip A. Chapman
>
> Desktop and Web Application Development:
> Java, .NET, PostgreSQL, MySQL, MSSQL
> Linux, Windows 2000, Windows XP
>
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFHqhuZAdpynRSGw3URAj+sAJ9SQ8+Ym1799KtJ6SQ5Ypd0gsWtAACcCfl2
> EMHl3j7D/Av3ubI1bF1Pq/8=
> =Il1L
>
> -END PGP SIGNATURE-
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
Resizable and reorderable grid components.
http://www.inmethod.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread Martijn Dashorst
How do you modify the html, in what tool, how do you ensure the html
gets inside the deployed and unpacked war running in tomcat?

Martijn

On 2/6/08, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> Does your IDE copy the HTML files over to the classpath?
>
> Martijn
>
> On 2/6/08, gantini <[EMAIL PROTECTED]> wrote:
> >
> > Strangethis dosn't work for me...
> > When wicket starts, in the tomcat console I can read:
> >
> > 
> > *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
> > ***   ^^^***
> > *** Do NOT deploy to your live server(s) without changing this.  ***
> > *** See Application#getConfigurationType() for more information. ***
> >
> >
> > But when I modify any html file, no reload is performed :-((
> >
> > Other suggest for me?
> > G.
> >
> >
> > igor.vaynberg wrote:
> > >
> > > this should automatically be happening if you run wicket in development
> > > mode.
> > > that call you do is not necessary.
> > >
> > > -igor
> > >
> > >
> > > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
> > >>
> > >> Nothing to help me?
> > >>
> > >>
> > >>
> > >> gantini wrote:
> > >> >
> > >> > I'm very new with Wicket.
> > >> > It is possible to automatically reload resource (class and HTML file) ?
> > >> >
> > >> > I've set:
> > >> >
> > >> >   @Override
> > >> >   protected void init() {
> > >> >   getResourceSettings().setResourcePollFrequency(
> > >> Duration.ONE_SECOND );
> > >> >   }
> > >> >
> > >> > but this don't work for me.
> > >> > Thanks.
> > >> >
> > >>
> > >> --
> > >> View this message in context:
> > >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
> > >>
> > >> Sent from the Wicket - User mailing list archive at Nabble.com.
> > >>
> > >>
> > >> -
> > >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >> For additional commands, e-mail: [EMAIL PROTECTED]
> > >>
> > >>
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> > >
> >
> > --
> > View this message in context: 
> > http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
> > Sent from the Wicket - User mailing list archive at Nabble.com.
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
> --
> Buy Wicket in Action: http://manning.com/dashorst
> Apache Wicket 1.3.0 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0
>


-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread Martijn Dashorst
Does your IDE copy the HTML files over to the classpath?

Martijn

On 2/6/08, gantini <[EMAIL PROTECTED]> wrote:
>
> Strangethis dosn't work for me...
> When wicket starts, in the tomcat console I can read:
>
> 
> *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
> ***   ^^^***
> *** Do NOT deploy to your live server(s) without changing this.  ***
> *** See Application#getConfigurationType() for more information. ***
>
>
> But when I modify any html file, no reload is performed :-((
>
> Other suggest for me?
> G.
>
>
> igor.vaynberg wrote:
> >
> > this should automatically be happening if you run wicket in development
> > mode.
> > that call you do is not necessary.
> >
> > -igor
> >
> >
> > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
> >>
> >> Nothing to help me?
> >>
> >>
> >>
> >> gantini wrote:
> >> >
> >> > I'm very new with Wicket.
> >> > It is possible to automatically reload resource (class and HTML file) ?
> >> >
> >> > I've set:
> >> >
> >> >   @Override
> >> >   protected void init() {
> >> >   getResourceSettings().setResourcePollFrequency(
> >> Duration.ONE_SECOND );
> >> >   }
> >> >
> >> > but this don't work for me.
> >> > Thanks.
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
> >>
> >> Sent from the Wicket - User mailing list archive at Nabble.com.
> >>
> >>
> >> -
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
>
> --
> View this message in context: 
> http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread Konstantin Ignatyev
I have seen the behavior but that seems to be endemic to windows.
I have not seen that on Linux or OS X.

On Wed, Feb 6, 2008 at 12:08 PM, gantini <[EMAIL PROTECTED]> wrote:

>
> Strangethis dosn't work for me...
> When wicket starts, in the tomcat console I can read:
>
> 
> *** WARNING: Wicket is running in DEVELOPMENT mode.  ***
> ***   ^^^***
> *** Do NOT deploy to your live server(s) without changing this.  ***
> *** See Application#getConfigurationType() for more information. ***
>
>
> But when I modify any html file, no reload is performed :-((
>
> Other suggest for me?
> G.
>
>
> igor.vaynberg wrote:
> >
> > this should automatically be happening if you run wicket in development
> > mode.
> > that call you do is not necessary.
> >
> > -igor
> >
> >
> > On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
> >>
> >> Nothing to help me?
> >>
> >>
> >>
> >> gantini wrote:
> >> >
> >> > I'm very new with Wicket.
> >> > It is possible to automatically reload resource (class and HTML file)
> ?
> >> >
> >> > I've set:
> >> >
> >> >   @Override
> >> >   protected void init() {
> >> >   getResourceSettings().setResourcePollFrequency(
> >> Duration.ONE_SECOND );
> >> >   }
> >> >
> >> > but this don't work for me.
> >> > Thanks.
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
> >>
> >> Sent from the Wicket - User mailing list archive at Nabble.com.
> >>
> >>
> >> -
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Konstantin Ignatyev

PS: If this is a typical day on planet earth, humans will add fifteen
million tons of carbon to the atmosphere, destroy 115 square miles of
tropical rainforest, create seventy-two miles of desert, eliminate between
forty to one hundred species, erode seventy-one million tons of topsoil, add
2,700 tons of CFCs to the stratosphere, and increase their population by
263,000

Bowers, C.A. The Culture of Denial: Why the Environmental Movement Needs a
Strategy for Reforming Universities and Public Schools. New York: State
University of New York Press, 1997: (4) (5) (p.206)


Re: Trouble with IE and images loaded through css

2008-02-06 Thread Philip A. Chapman
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Thanks Matej.  For now, I've converted to .gif until I can find a better
solution.

Matej Knopp wrote:
> Hi,
> 
> I'm affraid the url for alphaimageloader needs to be absolute. IE
> can't handle relative urls for filters. That is a problem because in
> wicket all you get are relative URLs. And you probably don't want to
> tie your application to a specific context anyway.
> 
> 
> I've personally have resigned to try to force IE6 to show transparent
> pictures. I usually use two variants of each transparent picture - one
> with alpha map for sane browsers and one with transparent color for
> IE6. Hopefully won't be too long before IE6 share drops so low it
> won't be worth supporting anymore.
> 
> 
> -Matej
> 
> 
> 
> On Feb 6, 2008 7:37 PM, Philip A. Chapman <[EMAIL PROTECTED]> wrote:
> Guys,
> 
> Under the source dir that contains my page and html, I have two dirs,
> css and images.  Inside css, I have two files, main.css and ie.css.
> These css files reference images, such as:
> 
> main.css:
> 
> a.download-but{
> float:right;
> width:111px;
> height:26px;
> margin:0;
> background:url(../images/download-audio.png) no-repeat 0 0;
> text-indent:-px;
> }
> 
> ie.css:
> 
> * html a.download-but{
> background:url(none.gif);
> 
> filter:progid:dximagetransform.microsoft.alphaimageloader(src='images/download-audio.png',
> sizingmethod='crop');
> cursor:pointer;
> }
> 
> I have two links in the header.  mainCSS and ieCSS.  I have the
> following code in the page:
> 
> WebClientInfo info =
> (WebClientInfo)((WebSession)Session.get()).getClientInfo();
> add(new StyleSheetReference("mainCSS", getClass(), "css/main.css"));
> StyleSheetReference ssref = new StyleSheetReference("ieCSS", getClass(),
> "css/ie.css");
> add(ssref);
> if
> (!info.getProperties().getNavigatorAppName().equalsIgnoreCase("Microsoft
> Internet Explorer")) {
> ssref.setVisible(false);
> }
> 
> My problem is that under IE, the images are not loaded.  I've tried
> changing the image url it ../images/download-audio.png, but that didn't
> work.
> 
> Any suggestions?
>>
- -
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>

- --
Philip A. Chapman

Desktop and Web Application Development:
Java, .NET, PostgreSQL, MySQL, MSSQL
Linux, Windows 2000, Windows XP

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHqhuZAdpynRSGw3URAj+sAJ9SQ8+Ym1799KtJ6SQ5Ypd0gsWtAACcCfl2
EMHl3j7D/Av3ubI1bF1Pq/8=
=Il1L
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: IPropertyResolver interface for property models

2008-02-06 Thread Daniel Stoch
This is exactly how ObjectEditor default implementation would looks  
like: it contains hashmap for edited values.
Simple HashMap as a model is not a good solution, because you must  
somehow initialize it with object properties' values first. I think a  
better is to hide such details inside an interface (like  
ObjectEditor), then you can also easily cancel (revert) changes. But  
even using a HashMap you cannot simply use property models (normal  
and compound) to access values, you must implement another custom  
models for that. These models will be probably very similar to  
standard property models, the only difference is how they access  
object values = how their property resolver works :).


Daniel


On 2008-02-06, at 19:51, Johan Compagner wrote:


Why not just return a hashmap as the model object and have besides
that hashmap your real object

On 2/6/08, Daniel Stoch <[EMAIL PROTECTED]> wrote:

On Feb 6, 2008 3:45 PM, Johan Compagner <[EMAIL PROTECTED]> wrote:
If we has such an interface then we need to rewrite most things  
because

now

its just a static method and then we need to have instances.


I know that. It is not a simple change.


i guess you want then to have AbstractPropertyModel to have a
getPropertyResolver method
that you can override and give something else back?


Yes exactly.



But i still dont get what you really have
What is your model object eventually where a property model works  
on?




I try to better explain this. When editing object I don't want to
store changes directly to this object (eg. until form submit), but
these edited values are "cached" in special ObjectEditor:

public interface ObjectEditor extends IClusterable {
  Object getEditedObject();
  Object getPropertyValue(String propertyExpression);
  void setPropertyValue(String propertyExpression, Object value);
  void commitChanges();
  void cancelChanges();
}

Sample use:
Form form = new Form("formId", new EditorCompoundPropertyModel(new
ObjectEditorImpl(baseObjectModel)));
where: baseObjectModel is a model (or can be directly any  
Serializable

object) with object to edit.
Inside EditorCompoundPropertyModel EditorPropertyModel is created
(instead of PropertyModel) which plays with ObjectEditor.

When you change value in form component (eg. DropDownChoice with
wantOnSelectionChangedNotifications=true) then a new value is stored
in ObjectEditor (by calling setPropertyValue()) and base edited  
object

stays unchanged. Form components to get value for display use
EditorPropertyModel and this model getObject() method calls
ObjectEditor.getPropertyValue() which checks if current property  
value

has been changed: if yes then this value comes from ObjectEditor
cache, otherwise it comes directly from edited object. My own
implementation of IPropertyResolver would call ObjectEditor
getPropertyValue/setPropertyValue methods.

Such ObjectEditor allows me to track changes in my object, original
object stays unchanged until I commit changes. When user press
"Cancel" button I can revert all changes by
ObjectEditor.cancelChanges(), I can edit non-serializable  
objects, ...


My proposition with IPropertyResolver is for discussion only. It is
not a thing "we must have" :).
By now, I have already implemented my own EditorPropertyResolver and
EditorCompoundPropertyResolver which play with such ObjectEditor.

Daniel

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Trouble with IE and images loaded through css

2008-02-06 Thread Matej Knopp
Hi,

I'm affraid the url for alphaimageloader needs to be absolute. IE
can't handle relative urls for filters. That is a problem because in
wicket all you get are relative URLs. And you probably don't want to
tie your application to a specific context anyway.


I've personally have resigned to try to force IE6 to show transparent
pictures. I usually use two variants of each transparent picture - one
with alpha map for sane browsers and one with transparent color for
IE6. Hopefully won't be too long before IE6 share drops so low it
won't be worth supporting anymore.


-Matej



On Feb 6, 2008 7:37 PM, Philip A. Chapman <[EMAIL PROTECTED]> wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
> Guys,
>
> Under the source dir that contains my page and html, I have two dirs,
> css and images.  Inside css, I have two files, main.css and ie.css.
> These css files reference images, such as:
>
> main.css:
>
> a.download-but{
> float:right;
> width:111px;
> height:26px;
> margin:0;
> background:url(../images/download-audio.png) no-repeat 0 0;
> text-indent:-px;
> }
>
> ie.css:
>
> * html a.download-but{
> background:url(none.gif);
> 
> filter:progid:dximagetransform.microsoft.alphaimageloader(src='images/download-audio.png',
> sizingmethod='crop');
> cursor:pointer;
> }
>
> I have two links in the header.  mainCSS and ieCSS.  I have the
> following code in the page:
>
> WebClientInfo info =
> (WebClientInfo)((WebSession)Session.get()).getClientInfo();
> add(new StyleSheetReference("mainCSS", getClass(), "css/main.css"));
> StyleSheetReference ssref = new StyleSheetReference("ieCSS", getClass(),
> "css/ie.css");
> add(ssref);
> if
> (!info.getProperties().getNavigatorAppName().equalsIgnoreCase("Microsoft
> Internet Explorer")) {
> ssref.setVisible(false);
> }
>
> My problem is that under IE, the images are not loaded.  I've tried
> changing the image url it ../images/download-audio.png, but that didn't
> work.
>
> Any suggestions?
> - --
> Philip A. Chapman
>
> Desktop and Web Application Development:
> Java, .NET, PostgreSQL, MySQL, MSSQL
> Linux, Windows 2000, Windows XP
>
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFHqf5MAdpynRSGw3URAu+RAJ987XEjNuRFCpVHg8OWya99IsLlOQCfXQkI
> leINHwBSkP9cKtF2VFWiOMQ=
> =xUt9
> -END PGP SIGNATURE-
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
Resizable and reorderable grid components.
http://www.inmethod.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Evaluating Wicket

2008-02-06 Thread Eelco Hillenius
> currently I'm evaluating wicket as the future framework in our company. I
> already found a lot of information but still there is some missing.

Don't forget to read the first chapter of Wicket In Action, which you
can download for free at: http://www.manning.com/dashorst/. I do my
best there to explain what kind of problems Wicket solves.

Cheers,

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Reloading resource

2008-02-06 Thread gantini

Strangethis dosn't work for me...
When wicket starts, in the tomcat console I can read:


*** WARNING: Wicket is running in DEVELOPMENT mode.  ***
***   ^^^***
*** Do NOT deploy to your live server(s) without changing this.  ***
*** See Application#getConfigurationType() for more information. ***


But when I modify any html file, no reload is performed :-((

Other suggest for me?
G.


igor.vaynberg wrote:
> 
> this should automatically be happening if you run wicket in development
> mode.
> that call you do is not necessary.
> 
> -igor
> 
> 
> On Feb 5, 2008 3:01 PM, gantini <[EMAIL PROTECTED]> wrote:
>>
>> Nothing to help me?
>>
>>
>>
>> gantini wrote:
>> >
>> > I'm very new with Wicket.
>> > It is possible to automatically reload resource (class and HTML file) ?
>> >
>> > I've set:
>> >
>> >   @Override
>> >   protected void init() {
>> >   getResourceSettings().setResourcePollFrequency(
>> Duration.ONE_SECOND );
>> >   }
>> >
>> > but this don't work for me.
>> > Thanks.
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Reloading-resource-tp15268997p15300053.html
>>
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Reloading-resource-tp15268997p15312660.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Evaluating Wicket

2008-02-06 Thread Jonathan Locke


be careful only to evaluate performance in wicket in deployment mode.
development mode is subject to a potentially very high level of overhead
that you don't want to profile.


René Samselnig wrote:
> 
> Hi people,
> 
> currently I'm evaluating wicket as the future framework in our company. I
> already found a lot of information but still there is some missing. I hope
> you can help me out answering these questions.
> 
> * What experience do you have regarding performance of wicket
> applications?
> * Is there a way to cluster wicket applications?
> * Does wicket use any proprietary, non-standard technologies?
> * How does wicket care about session hijacking or sql injection?
> * Is there an easy way to implement SSO?
> * Can I integrate wicket applications into any content management system?
> 
> If you have an answer to any of these questions don't hesitate to ignore
> the others - any input is welcome!
> 
> Thanks in advance,
> René
> 

-- 
View this message in context: 
http://www.nabble.com/Evaluating-Wicket-tp15306535p15312176.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [wicketstuff] Accordion component?

2008-02-06 Thread Advanced Technology®
+1

2008/2/6, Nino Saturnino Martinez Vazquez Wael <[EMAIL PROTECTED]>:
>
> I almost have a component ready for wicketstuff.. Should I spend the
> extra hour generalizing it and putting it up on wicketstuff?
>
> http://www.hedgerwow.com/360/mwd/accordion/demo.php
>
> --
> Nino Martinez Wael
> Java Specialist @ Jayway DK
> http://www.jayway.dk
> +45 2936 7684
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
AT(R)


Re: IPropertyResolver interface for property models

2008-02-06 Thread Johan Compagner
Why not just return a hashmap as the model object and have besides
that hashmap your real object

On 2/6/08, Daniel Stoch <[EMAIL PROTECTED]> wrote:
> On Feb 6, 2008 3:45 PM, Johan Compagner <[EMAIL PROTECTED]> wrote:
> > If we has such an interface then we need to rewrite most things because
> now
> > its just a static method and then we need to have instances.
>
> I know that. It is not a simple change.
>
> > i guess you want then to have AbstractPropertyModel to have a
> > getPropertyResolver method
> > that you can override and give something else back?
>
> Yes exactly.
>
> >
> > But i still dont get what you really have
> > What is your model object eventually where a property model works on?
> >
>
> I try to better explain this. When editing object I don't want to
> store changes directly to this object (eg. until form submit), but
> these edited values are "cached" in special ObjectEditor:
>
> public interface ObjectEditor extends IClusterable {
>   Object getEditedObject();
>   Object getPropertyValue(String propertyExpression);
>   void setPropertyValue(String propertyExpression, Object value);
>   void commitChanges();
>   void cancelChanges();
> }
>
> Sample use:
> Form form = new Form("formId", new EditorCompoundPropertyModel(new
> ObjectEditorImpl(baseObjectModel)));
> where: baseObjectModel is a model (or can be directly any Serializable
> object) with object to edit.
> Inside EditorCompoundPropertyModel EditorPropertyModel is created
> (instead of PropertyModel) which plays with ObjectEditor.
>
> When you change value in form component (eg. DropDownChoice with
> wantOnSelectionChangedNotifications=true) then a new value is stored
> in ObjectEditor (by calling setPropertyValue()) and base edited object
> stays unchanged. Form components to get value for display use
> EditorPropertyModel and this model getObject() method calls
> ObjectEditor.getPropertyValue() which checks if current property value
> has been changed: if yes then this value comes from ObjectEditor
> cache, otherwise it comes directly from edited object. My own
> implementation of IPropertyResolver would call ObjectEditor
> getPropertyValue/setPropertyValue methods.
>
> Such ObjectEditor allows me to track changes in my object, original
> object stays unchanged until I commit changes. When user press
> "Cancel" button I can revert all changes by
> ObjectEditor.cancelChanges(), I can edit non-serializable objects, ...
>
> My proposition with IPropertyResolver is for discussion only. It is
> not a thing "we must have" :).
> By now, I have already implemented my own EditorPropertyResolver and
> EditorCompoundPropertyResolver which play with such ObjectEditor.
>
> Daniel
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: adding extra javascript call in CheckBox

2008-02-06 Thread Igor Vaynberg
tag.put("onclick","executeSomething();"+tag.getattributes().get("onclick"));

-igor

On Feb 6, 2008 10:39 AM, Beyonder Unknown <[EMAIL PROTECTED]> wrote:
>
> Hi All,
>
> I was wondering if there's a way to add or decorate a javascript call in 
> CheckBox? What I did was:
>
> new CheckBox("checkBox", new Model()) {
> protected void onComponentTag(ComponentTag tag) {
> tag.put("onclick","executeSomething();");
> }
>
>
> But it overrides the original onClick that Wicket is writing. Is there a way 
> that I can decorate it so that I can add extra javaScript call in onClick 
> without overriding the original click, like the buttons has this:
>
> protected IAjaxCallDecorator getAjaxCallDecorator() {
> return new AjaxCallDecorator()
>
>
> Thanks in advance and happy chinese new year!
>
> Best,
> Wen Tong
>
>
> --
> The only constant in life is change.
>
>
>
>
>   
> 
> Looking for last minute shopping deals?
> Find them fast with Yahoo! Search.  
> http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



adding extra javascript call in CheckBox

2008-02-06 Thread Beyonder Unknown

Hi All,

I was wondering if there's a way to add or decorate a javascript call in 
CheckBox? What I did was: 

new CheckBox("checkBox", new Model()) {
protected void onComponentTag(ComponentTag tag) {
tag.put("onclick","executeSomething();");
}
 

But it overrides the original onClick that Wicket is writing. Is there a way 
that I can decorate it so that I can add extra javaScript call in onClick 
without overriding the original click, like the buttons has this: 

protected IAjaxCallDecorator getAjaxCallDecorator() {
return new AjaxCallDecorator() 


Thanks in advance and happy chinese new year!

Best,
Wen Tong


--
The only constant in life is change.




  

Looking for last minute shopping deals?  
Find them fast with Yahoo! Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Trouble with IE and images loaded through css

2008-02-06 Thread Philip A. Chapman
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Guys,

Under the source dir that contains my page and html, I have two dirs,
css and images.  Inside css, I have two files, main.css and ie.css.
These css files reference images, such as:

main.css:

a.download-but{
float:right;
width:111px;
height:26px;
margin:0;
background:url(../images/download-audio.png) no-repeat 0 0;
text-indent:-px;
}

ie.css:

* html a.download-but{
background:url(none.gif);

filter:progid:dximagetransform.microsoft.alphaimageloader(src='images/download-audio.png',
sizingmethod='crop');
cursor:pointer;
}

I have two links in the header.  mainCSS and ieCSS.  I have the
following code in the page:

WebClientInfo info =
(WebClientInfo)((WebSession)Session.get()).getClientInfo();
add(new StyleSheetReference("mainCSS", getClass(), "css/main.css"));
StyleSheetReference ssref = new StyleSheetReference("ieCSS", getClass(),
"css/ie.css");
add(ssref);
if
(!info.getProperties().getNavigatorAppName().equalsIgnoreCase("Microsoft
Internet Explorer")) {
ssref.setVisible(false);
}

My problem is that under IE, the images are not loaded.  I've tried
changing the image url it ../images/download-audio.png, but that didn't
work.

Any suggestions?
- --
Philip A. Chapman

Desktop and Web Application Development:
Java, .NET, PostgreSQL, MySQL, MSSQL
Linux, Windows 2000, Windows XP

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHqf5MAdpynRSGw3URAu+RAJ987XEjNuRFCpVHg8OWya99IsLlOQCfXQkI
leINHwBSkP9cKtF2VFWiOMQ=
=xUt9
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Some questions - mainly about session expiration and serialization

2008-02-06 Thread Igor Vaynberg
On Feb 6, 2008 10:28 AM, Fabrizio Giudici <[EMAIL PROTECTED]> wrote:
>
> >
> > Are you using our modal window implementation or your own?
>
> Wicket implementation. BTW, I have another modal window that doesn't
> create problem. I'll later post the code, when I'm able to cut it down.

are you using it to popup a panel or a page? i think the panel popup
doesnt generally work well, the page version works better. also make
sure you popup the page in a different pagemap.

> >
> >> 3. I have still some confusion about serialization of things
> >> in sessions. I've always got some objects that are not
> >> serializable and caused tons of exceptions in log files, but
> >> no harm other than it. I'm now wondering whether they can
> >> trigger one of the above problems, and anyway before going
> >> into production I'd like to face with this issue in a
> >> definitive fashion. I know about the possibility of using
> >> detachable objects, nevertheless I need first to understand
> >> why this serialization thing can't be disabled - after all
> >> I've got no need for clustering in near future (and if I
> >> should do it, I'd probably go with Terracotta). Also, in
> >> version 1.2 I once saw that there was a UserSession (?)
> >> method that looked like it was useful for disabling
> >> serialization, and I had a mental note about using it, but
> >> it looks like it disappeared in 1.3.0. Hints?
> >
> > Serialization has always been needed in wicket for things other then
> > cluster replication. Versioning has been one of those reasons. We
> > would use serialization mostly for cloning an object, so that we can
> > keep a reference to its previous state for rolling back a version.
> > With 1.3.1 this has changed dramatically. In order to free up session
> > space (1.2 would keep x pages in session) 1.3.1 only keeps the most
> > current page in session and spools older pages to disk via
> > serialization. So if you hit a page that has a serialization problem
> > and later come back to it via back button and click a link/submit a
> > form you will get a page expired error. My recommendation is to make
> > sure you use detachable models or make your objects serializable. In
> > the meantime, try
> >
> > class MyApplication extends WebApplication { ISessionStore
> > newSessionStore() { return new HttpSessionStore();}}
> >
> > that will turn off disk spooling and will make 1.3 behave more like
> > 1.2 in that regard.
>
> Ok, I'll try this just to see if it can at least solve immediately
> the problem, then go for some refactoring. My question is: but if I
> don't need (and don't want) page versioning, and I disable it, is
> serialization still necessary?

sure, you can disable the versioning completely, but then you also
wont have a proper backbutton support. versioning is there for a
reason...

-igor

>
> --
>
> Fabrizio Giudici, Ph.D. - Java Architect, Project Manager
> Tidalwave s.a.s. - "We make Java work. Everywhere."
> weblogs.java.net/blog/fabriziogiudici - www.tidalwave.it/blog
> [EMAIL PROTECTED] - mobile: +39 348.150.6941
>
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: localization

2008-02-06 Thread Edward Yakop
> Translator translator = new Translator( Locale.GERMAN );
> Hotel translatedHotel = translator.translate( hotel );
> translatedHotel.getDescription(); // return description in german
> translatedHotel.setDescription( "die Beschreibung" ); // persist german 
> description

I think it would be very cool to extend that API to have a better
wicket integration.
It would be very cool if we can do the following:


BoundCompoundPropertyModel model = new
TranslatableBoundCompoundPropertyModel( hotel );
TextField descriptionField = ...;
model.bind( descriptionField, "description" );


Regards,
Edward Yakop

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Some questions - mainly about session expiration and serialization

2008-02-06 Thread Fabrizio Giudici




Are you using our modal window implementation or your own?


Wicket implementation. BTW, I have another modal window that doesn't  
create problem. I'll later post the code, when I'm able to cut it down.





3. I have still some confusion about serialization of things
in sessions. I've always got some objects that are not
serializable and caused tons of exceptions in log files, but
no harm other than it. I'm now wondering whether they can
trigger one of the above problems, and anyway before going
into production I'd like to face with this issue in a
definitive fashion. I know about the possibility of using
detachable objects, nevertheless I need first to understand
why this serialization thing can't be disabled - after all
I've got no need for clustering in near future (and if I
should do it, I'd probably go with Terracotta). Also, in
version 1.2 I once saw that there was a UserSession (?)
method that looked like it was useful for disabling
serialization, and I had a mental note about using it, but
it looks like it disappeared in 1.3.0. Hints?


Serialization has always been needed in wicket for things other then
cluster replication. Versioning has been one of those reasons. We
would use serialization mostly for cloning an object, so that we can
keep a reference to its previous state for rolling back a version.
With 1.3.1 this has changed dramatically. In order to free up session
space (1.2 would keep x pages in session) 1.3.1 only keeps the most
current page in session and spools older pages to disk via
serialization. So if you hit a page that has a serialization problem
and later come back to it via back button and click a link/submit a
form you will get a page expired error. My recommendation is to make
sure you use detachable models or make your objects serializable. In
the meantime, try

class MyApplication extends WebApplication { ISessionStore
newSessionStore() { return new HttpSessionStore();}}

that will turn off disk spooling and will make 1.3 behave more like
1.2 in that regard.


Ok, I'll try this just to see if it can at least solve immediately  
the problem, then go for some refactoring. My question is: but if I  
don't need (and don't want) page versioning, and I disable it, is  
serialization still necessary?


--
Fabrizio Giudici, Ph.D. - Java Architect, Project Manager
Tidalwave s.a.s. - "We make Java work. Everywhere."
weblogs.java.net/blog/fabriziogiudici - www.tidalwave.it/blog
[EMAIL PROTECTED] - mobile: +39 348.150.6941




Re: CompoundModel based on proxies

2008-02-06 Thread Carl-Eric Menzel
Scott Swank wrote:
> We're happy to share if folk like this approach.  N.B. that the .to()
> call is for readability rather than out of any necessity.

I'm quite interested in this. This looks like it is just crazy and
clever enough to be really useful :-)

Thanks!
Carl-Eric

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [wicketstuff] Accordion component?

2008-02-06 Thread Uwe Schäfer

Nino Saturnino Martinez Vazquez Wael schrieb:
I almost have a component ready for wicketstuff.. Should I spend the 
extra hour generalizing it and putting it up on wicketstuff?



http://www.hedgerwow.com/360/mwd/accordion/demo.php


SURE!


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: localization

2008-02-06 Thread Nino Saturnino Martinez Vazquez Wael
As you might have guessed we use cglib to wrap domain classes and proyx 
them... This approach lets you "inject" localizing into existing systems..


So you do this:

@Translatable
public class Hotel {


 private Long id;

 private String name;

 @Translate
 private String description;

 [...getter & setter...]
}


Translator translator = new Translator( Locale.GERMAN );
Hotel translatedHotel = translator.translate( hotel );
translatedHotel.getDescription(); // return description in german
translatedHotel.setDescription( "die Beschreibung" ); // persist german 
description


And with a little code you can wrap this into your session and voila you 
have localizing onthe fly:) Im working on this part as we speak..:)



Nino Saturnino Martinez Vazquez Wael wrote:

Hi

If you have trouble localizing your backend components, domain classes 
etc... Look no futher:)


http://code.google.com/p/jpa-translator/ (licensed under apache)

Disclaimer, im one of the authors:) But it fits really great into 
wicket and it's plugable too...




--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: CompoundModel based on proxies

2008-02-06 Thread Hoover, William
very nice!

-Original Message-
From: Scott Swank [mailto:[EMAIL PROTECTED]
Sent: Wednesday, February 06, 2008 12:57 PM
To: Wicket User List
Subject: CompoundModel based on proxies


One of our more clever developers created a CompoundPropertyModel that
uses a cglib proxy to strongly bind the mutators to the model.  It
looks like this:

SharedPropertyModel model = new
SharedPropertyModel(customer);
this.setModel(model);

FormComponent firstName = new
CustomerNameField("firstName").setRequired(true);
model.bind(firstName).to().getFirstName();
add(firstName);

FormComponent lastName = new 
CustomerNameField("lastName").setRequired(true);
model.bind(lastName).to().getLastName();
add(lastName);

FormComponent addr1 = new 
AddressField("address1").setRequired(true);
model.bind(addr1).to().getAddress().getAddress1();
add(addr1);

FormComponent addr2 = new AddressField("address2");
model.bind(addr2).to().getAddress().getAddress2();
add(addr2);

FormComponent city = new CityField("city");
model.bind(city).to().getAddress().getCity();
add(city);

We're happy to share if folk like this approach.  N.B. that the .to()
call is for readability rather than out of any necessity.

Cheers,
Scott

-- 
Scott Swank
reformed mathematician

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Evaluating Wicket

2008-02-06 Thread djo.mos

Ah, just an addition about performance:
  Session size can be a bottleneck in performance, so one have just to be
careful about what to put in his session and by using detachable models for
example.


-- 
View this message in context: 
http://www.nabble.com/Evaluating-Wicket-tp15306535p15309398.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



CompoundModel based on proxies

2008-02-06 Thread Scott Swank
One of our more clever developers created a CompoundPropertyModel that
uses a cglib proxy to strongly bind the mutators to the model.  It
looks like this:

SharedPropertyModel model = new
SharedPropertyModel(customer);
this.setModel(model);

FormComponent firstName = new
CustomerNameField("firstName").setRequired(true);
model.bind(firstName).to().getFirstName();
add(firstName);

FormComponent lastName = new 
CustomerNameField("lastName").setRequired(true);
model.bind(lastName).to().getLastName();
add(lastName);

FormComponent addr1 = new 
AddressField("address1").setRequired(true);
model.bind(addr1).to().getAddress().getAddress1();
add(addr1);

FormComponent addr2 = new AddressField("address2");
model.bind(addr2).to().getAddress().getAddress2();
add(addr2);

FormComponent city = new CityField("city");
model.bind(city).to().getAddress().getCity();
add(city);

We're happy to share if folk like this approach.  N.B. that the .to()
call is for readability rather than out of any necessity.

Cheers,
Scott

-- 
Scott Swank
reformed mathematician

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problems with ResourceModel and StringResourceModel

2008-02-06 Thread Igor Vaynberg
dont know about 1.2, but in 1.3 there is a constructor that takes an
instance of application, so you would do new WicketTester(new
MyApplication());

-igor


On Feb 6, 2008 9:11 AM, Marco Aurélio Silva <[EMAIL PROTECTED]> wrote:
> How to make it use my application subclass?
> WicketTester.set(Application application) trow this exception:
>
> wicket.WicketRuntimeException: Use Application.init() method for
> configuring your application object
> at wicket.Application.getSettings(Application.java:606)
> at wicket.Application.getDebugSettings(Application.java:449)
> at 
> wicket.protocol.http.HttpSessionStore.setAttribute(HttpSessionStore.java:51)
> at 
> wicket.protocol.http.AbstractHttpSessionStore.bind(AbstractHttpSessionStore.java:165)
> at 
> wicket.protocol.http.MockWebApplication.setupRequestAndResponse(MockWebApplication.java:411)
> at wicket.util.tester.WicketTester.startPage(WicketTester.java:230)
> at AppTester.testHome(AppTester.java:56)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:324)
> at junit.framework.TestCase.runTest(TestCase.java:164)
> at junit.framework.TestCase.runBare(TestCase.java:130)
> at junit.framework.TestResult$1.protect(TestResult.java:106)
> at junit.framework.TestResult.runProtected(TestResult.java:124)
> at junit.framework.TestResult.run(TestResult.java:109)
> at junit.framework.TestCase.run(TestCase.java:120)
> at junit.framework.TestSuite.runTest(TestSuite.java:230)
> at junit.framework.TestSuite.run(TestSuite.java:225)
> at 
> org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
> at 
> org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
> at 
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
> at 
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
> at 
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
> at 
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
>
>
>
>
> On Feb 6, 2008 1:55 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> > you have to make wicket tester use _your_ application subclass
> >
> > -igor
> >
> >
> >
> > On Feb 6, 2008 8:50 AM, Marco Aurélio Silva <[EMAIL PROTECTED]> wrote:
> > > Hi all
> > >
> > > I'm writing test cases for my wicket application (1.2.6), and I'm
> > > having problems with the ResourceModel and StringResourceModel. It
> > > seems like when loaded by a WicketTester (with startPage method) these
> > > components doesn't load the global resource file
> > > "MyApplication.properties". If I put the key on a property file with
> > > the same name of the page, it works. When I run the same page in
> > > tomcat, it works fine.
> > >
> > >
> > > Thank you
> > > Marco
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Evaluating Wicket

2008-02-06 Thread Patrick Angeles

Hi Rene,

Some answers...

* What experience do you have regarding performance of wicket applications?
We're still in development, but so far performance hasn't been an issue.

* Is there a way to cluster wicket applications?
Yes. Same way you would cluster any webapp. Wicket also has a number of
different clustering strategies available.

* Does wicket use any proprietary, non-standard technologies?
Wicket core depends on various OSS libraries, all commercial friendly (ASL
compatible).

* How does wicket care about session hijacking or sql injection?

Session hijacking - not an expert on this, but if I understand correctly,
this is mostly a JavaScript concern, so just be careful when you write/use
Javascript components.
SQL Injection - In general, Wicket's architecture makes it harder for these
kinds of attacks because state is kept on the server side (as opposed to URL
parameters). That being said, this really has more to do with the
persistence layer that you use. So long as you shy away from assembling your
own SQL query strings you should be OK.

* Is there an easy way to implement SSO?
Internal SSO between webapps is possible via the Servlet container, provided
all webapps run in the same container. If that doesn't apply to you, you
should be able to write a custom authorization strategy for Wicket.

* Can I integrate wicket applications into any content management system?
Depends on what you want to do here. That being said, there are several
native Wicket CMS systems under development.


René Samselnig wrote:
> 
> Hi people,
> 
> currently I'm evaluating wicket as the future framework in our company. I
> already found a lot of information but still there is some missing. I hope
> you can help me out answering these questions.
> 
> * What experience do you have regarding performance of wicket
> applications?
> * Is there a way to cluster wicket applications?
> * Does wicket use any proprietary, non-standard technologies?
> * How does wicket care about session hijacking or sql injection?
> * Is there an easy way to implement SSO?
> * Can I integrate wicket applications into any content management system?
> 
> If you have an answer to any of these questions don't hesitate to ignore
> the others - any input is welcome!
> 
> Thanks in advance,
> René
> 

-- 
View this message in context: 
http://www.nabble.com/Evaluating-Wicket-tp15306535p15309004.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Evaluating Wicket

2008-02-06 Thread Scott Swank
The chief advantage in my mind is that the code is all Java.  I was
easily (2 dozen lines of code) able to write a behavior that
replicates model between related form components so that when someone
types a first name into a field it is replicated to other first name
fields and those fields are updated real-time via ajax.  (The person
who is checking into the hotel is usually the person who is picking up
the tickets to the show, for example).  That sort of flexibility means
that I have not hit a nasty road block with Wicket.

Cheers,
Scott


On Feb 6, 2008 8:36 AM, Maeder Thomas <[EMAIL PROTECTED]> wrote:
> Having gone trough a web framework evaluation myself in the last year, my 
> recommendation is to actually build a small wicket application. The benefits 
> over other web frameworks are very real, but not evident from studying the 
> brochures.
>
> Thomas

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Evaluating Wicket

2008-02-06 Thread djo.mos

Hi,
 I'm myself discovering Wicket, but I'll try to nswer some of your questions
;)


René Samselnig wrote:
> 
> * What experience do you have regarding performance of wicket
> applications?
> 

I haven't built a large application with Wicket yet, but in a JPA CRUD
examples I made, Wicket performs better than JSF IMO, I mean I did not made
a serious benchmarking, but I can notice the difference with my bare eyes.

René Samselnig wrote:
> 
> * Is there a way to cluster wicket applications?
> 
Hell yes ! It's one of the major features of the 1.3 version I think.


René Samselnig wrote:
> 
> * Does wicket use any proprietary, non-standard technologies?
> 
Well, being an Open Source and ASF Licensed, the answer is clearly NO.


René Samselnig wrote:
> 
> * How does wicket care about session hijacking or sql injection?
> 
Session Hijacking: One nifty feature of Wicket is that you can pass
parameters betwwen pages as Java parameters, thus not exposing them outside
the runtime environment.
Regarding the SQL Injection, this has absolutely nothing to do with Wicket
nor any other Web Framework.
JDBC solves this (using the query parameters).


René Samselnig wrote:
> 
> * Is there an easy way to implement SSO?
> 
Sorry, this question is not not for me.


René Samselnig wrote:
> 
> * Can I integrate wicket applications into any content management system?
> 
Well, this seems a bit delicate to achieve in Wicket, for the simple reason
of the 1..1 relationship between a HTML page and a WebPage class ...

Regards.
-- 
View this message in context: 
http://www.nabble.com/Evaluating-Wicket-tp15306535p15309002.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Mounting page at root

2008-02-06 Thread oliverw

All right. Now I feel stupid. Thanks it worked!


Janos Cserep-3 wrote:
> 
>>
>> Is it possible at all to have content at / ? Trying to mount something at
>> "/"
>> results in an error and I'm wondering of there's a workaround.
> 
> 
> By default it displays your home page (actually the page represented by
> the
> page class returned by WebApplication's getHomePage() method) if you
> configure WicketFilter to the /* url.
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Mounting-page-at-root-tp15300055p15308737.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



localization

2008-02-06 Thread Nino Saturnino Martinez Vazquez Wael

Hi

If you have trouble localizing your backend components, domain classes 
etc... Look no futher:)


http://code.google.com/p/jpa-translator/ (licensed under apache)

Disclaimer, im one of the authors:) But it fits really great into wicket 
and it's plugable too...


--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[wicketstuff] Accordion component?

2008-02-06 Thread Nino Saturnino Martinez Vazquez Wael
I almost have a component ready for wicketstuff.. Should I spend the 
extra hour generalizing it and putting it up on wicketstuff?


http://www.hedgerwow.com/360/mwd/accordion/demo.php

--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Doubt in wicket and multiple views

2008-02-06 Thread Patrick Angeles

So long as everything runs in the same webapp, you should be able to use the
same model. From a wicket application, you can always get to the request
object to get to the virtual host, so you can use that info to present a
different view.


Mathias P.W Nilsson wrote:
> 
> Hi!
> 
> I have one model and 4 different web applications. All webapplications is
> using the same model but different views. There is Different virtual hosts
> on the same server. Can I use wicket for this? 
> 
> ie
> 
> Domain1.se, Domain1.com, Domain2.se, Domain2.com same server different
> virtual hosts same model with Wicket.
> 

-- 
View this message in context: 
http://www.nabble.com/Doubt-in-wicket-and-multiple-views-tp15306737p15307866.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problems with ResourceModel and StringResourceModel

2008-02-06 Thread Marco Aurélio Silva
How to make it use my application subclass?
WicketTester.set(Application application) trow this exception:

wicket.WicketRuntimeException: Use Application.init() method for
configuring your application object
at wicket.Application.getSettings(Application.java:606)
at wicket.Application.getDebugSettings(Application.java:449)
at 
wicket.protocol.http.HttpSessionStore.setAttribute(HttpSessionStore.java:51)
at 
wicket.protocol.http.AbstractHttpSessionStore.bind(AbstractHttpSessionStore.java:165)
at 
wicket.protocol.http.MockWebApplication.setupRequestAndResponse(MockWebApplication.java:411)
at wicket.util.tester.WicketTester.startPage(WicketTester.java:230)
at AppTester.testHome(AppTester.java:56)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at junit.framework.TestCase.runTest(TestCase.java:164)
at junit.framework.TestCase.runBare(TestCase.java:130)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:120)
at junit.framework.TestSuite.runTest(TestSuite.java:230)
at junit.framework.TestSuite.run(TestSuite.java:225)
at 
org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
at 
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)



On Feb 6, 2008 1:55 PM, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> you have to make wicket tester use _your_ application subclass
>
> -igor
>
>
>
> On Feb 6, 2008 8:50 AM, Marco Aurélio Silva <[EMAIL PROTECTED]> wrote:
> > Hi all
> >
> > I'm writing test cases for my wicket application (1.2.6), and I'm
> > having problems with the ResourceModel and StringResourceModel. It
> > seems like when loaded by a WicketTester (with startPage method) these
> > components doesn't load the global resource file
> > "MyApplication.properties". If I put the key on a property file with
> > the same name of the page, it works. When I run the same page in
> > tomcat, it works fine.
> >
> >
> > Thank you
> > Marco
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: IPropertyResolver interface for property models

2008-02-06 Thread Daniel Stoch
Thanks for your response. Your solution looks interesting and even
quite similar to mine, but... :)

My ObjectEditor interface is like your "Map editedValues, IModel
underlyingModel" coupled together. But underlyingModel in my solution
holds the whole object, not a single property:

Object getEditedObject() {
  return underlyingModel.getObject();
}

I have original object and edited values stored inside one
ObjectEditor instance (therefore in one model). I can have a different
implementations of this interface. In your solution you must have 2
models for each property (one overlay model and one underlyingModel).
Another thing is maybe less important, but EditorPropertyModel and
CompoundEditorPropertyModel works the same way like standard property
models when object passed to them is not an ObjectEditor.

According to your concept ObjectEditor could have a method:
  IModel getPropertyModel(String propertyExpression); // or maybe
createPropertyModel ?
instead of:
  Object getPropertyValue(String propertyExpression);
  void setPropertyValue(String propertyExpression, Object value);

Daniel

On Feb 6, 2008 5:20 PM, Maeder Thomas <[EMAIL PROTECTED]> wrote:
> If I understand this correctly, you're trying to keep an overlay while
> editing an object. Why not do this:
>
> class OverlayModel extends Model {
> OverlayModel(Map editedValues, IModel underlyingModel, String
> propertyName) {
> ...remember the parameters in instance variables
> }
>
> public Object getObject() {
> if (editedValues.containsKey(propertyName)) {
> return editedValues.get(propertyName);
> } else {
> return underlyingModel.getObject();
> }
> }
>
> public abstract void setObject(Object obj) {
> if (isEquals(obj, getObject()) {
> editValues.put(obj);
> }
> }
> }
>
> As underlying models, you would use PropertyModel instances. When you
> want to revert the values, you just clear the Map.
>
> Thomas
>
>
> > I try to better explain this. When editing object I don't
> > want to store changes directly to this object (eg. until form
> > submit), but these edited values are "cached" in special ObjectEditor:
> >
> > public interface ObjectEditor extends IClusterable {
> >   Object getEditedObject();
> >   Object getPropertyValue(String propertyExpression);
> >   void setPropertyValue(String propertyExpression, Object value);
> >   void commitChanges();
> >   void cancelChanges();
> > }
> >

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problems with ResourceModel and StringResourceModel

2008-02-06 Thread Igor Vaynberg
you have to make wicket tester use _your_ application subclass

-igor


On Feb 6, 2008 8:50 AM, Marco Aurélio Silva <[EMAIL PROTECTED]> wrote:
> Hi all
>
> I'm writing test cases for my wicket application (1.2.6), and I'm
> having problems with the ResourceModel and StringResourceModel. It
> seems like when loaded by a WicketTester (with startPage method) these
> components doesn't load the global resource file
> "MyApplication.properties". If I put the key on a property file with
> the same name of the page, it works. When I run the same page in
> tomcat, it works fine.
>
>
> Thank you
> Marco
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Problems with ResourceModel and StringResourceModel

2008-02-06 Thread Marco Aurélio Silva
Hi all

I'm writing test cases for my wicket application (1.2.6), and I'm
having problems with the ResourceModel and StringResourceModel. It
seems like when loaded by a WicketTester (with startPage method) these
components doesn't load the global resource file
"MyApplication.properties". If I put the key on a property file with
the same name of the page, it works. When I run the same page in
tomcat, it works fine.


Thank you
Marco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Block second click

2008-02-06 Thread Igor Vaynberg
there is a mask component in wicketstuff-minis. you can write a call
decorator that will bring up the mask that will cover the whole screen
and prevent the user from clicking.

-igor


On Feb 6, 2008 4:37 AM, Matthijs Wensveen <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I have a Link (not Ajax) on a component that does some heavyweight
> processing in onClick. During this processing I want to block other
> clicks from the same user. Is there a generic way to block multiple
> requests on the same link? I would prefer a solution without Ajax /
> JavaScript, but if that's impossible then that's okay.
>
> Thanks,
> Matthijs
>
> --
> Matthijs Wensveen
> Func. Internet Integration
> W http://www.func.nl
> T +31 20 423
> F +31 20 4223500
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Some questions - mainly about session expiration and serialization

2008-02-06 Thread Igor Vaynberg
On Feb 6, 2008 4:40 AM, [EMAIL PROTECTED]
<[EMAIL PROTECTED]> wrote:
> 1. I've always experienced some sudden "session expiration"
> problems with no apparent reason (I mean, the user wasn't
> actually sleeping). But they happened only once in a while.
> After upgrading to 1.3 they occur very often and they have
> quickly become the issue on the top of the list and I've to
> fix it immediately, since it's jeopardizing the acceptance
> tests performed by my customer. I've already searched in
> forums and tried some change (such as disabling versioning),
> but I got no benefit from it.

My guess is that #3 is causing it...see my answer there.

> 2. I have a modal window used to enter a date (I can't use
> the already provided component since this a special date)
> that has been working from several months. After upgrading
> to 1.3 it deterministically causes a session expired
> whenever it's closed (since this is deterministic I bet it's
> a different thing than the above).

Are you using our modal window implementation or your own?

> 3. I have still some confusion about serialization of things
> in sessions. I've always got some objects that are not
> serializable and caused tons of exceptions in log files, but
> no harm other than it. I'm now wondering whether they can
> trigger one of the above problems, and anyway before going
> into production I'd like to face with this issue in a
> definitive fashion. I know about the possibility of using
> detachable objects, nevertheless I need first to understand
> why this serialization thing can't be disabled - after all
> I've got no need for clustering in near future (and if I
> should do it, I'd probably go with Terracotta). Also, in
> version 1.2 I once saw that there was a UserSession (?)
> method that looked like it was useful for disabling
> serialization, and I had a mental note about using it, but
> it looks like it disappeared in 1.3.0. Hints?

Serialization has always been needed in wicket for things other then
cluster replication. Versioning has been one of those reasons. We
would use serialization mostly for cloning an object, so that we can
keep a reference to its previous state for rolling back a version.
With 1.3.1 this has changed dramatically. In order to free up session
space (1.2 would keep x pages in session) 1.3.1 only keeps the most
current page in session and spools older pages to disk via
serialization. So if you hit a page that has a serialization problem
and later come back to it via back button and click a link/submit a
form you will get a page expired error. My recommendation is to make
sure you use detachable models or make your objects serializable. In
the meantime, try

class MyApplication extends WebApplication { ISessionStore
newSessionStore() { return new HttpSessionStore();}}

that will turn off disk spooling and will make 1.3 behave more like
1.2 in that regard.

-igor



>
> Thanks in advance..
>
> --
> Fabrizio Giudici, Ph.D. - Java Architect, Project Manager
> Tidalwave s.a.s. - "We make Java work. Everywhere."
> weblogs.java.net/blog/fabriziogiudici -
> www.tidalwave.it/blog
> [EMAIL PROTECTED] - mobile: +39 348.150.6941
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Evaluating Wicket

2008-02-06 Thread Maeder Thomas
Having gone trough a web framework evaluation myself in the last year, my 
recommendation is to actually build a small wicket application. The benefits 
over other web frameworks are very real, but not evident from studying the 
brochures. 

Thomas

> -Original Message-
> From: René Samselnig [mailto:[EMAIL PROTECTED] 
> Sent: Mittwoch, 6. Februar 2008 14:13
> To: users@wicket.apache.org
> Subject: Evaluating Wicket
> 
> 
> Hi people,
> 
> currently I'm evaluating wicket as the future framework in 
> our company. I already found a lot of information but still 
> there is some missing. I hope you can help me out answering 
> these questions.
> 
> * What experience do you have regarding performance of wicket 
> applications?
> * Is there a way to cluster wicket applications?
> * Does wicket use any proprietary, non-standard technologies?
> * How does wicket care about session hijacking or sql injection?
> * Is there an easy way to implement SSO?
> * Can I integrate wicket applications into any content 
> management system?
> 
> If you have an answer to any of these questions don't 
> hesitate to ignore the others - any input is welcome!
> 
> Thanks in advance,
> René
> --
> View this message in context: 
> http://www.nabble.com/Evaluating-Wicket-tp15306535p15306535.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Evaluating Wicket

2008-02-06 Thread Igor Vaynberg
On Feb 6, 2008 5:12 AM, René Samselnig <[EMAIL PROTECTED]> wrote:
>
> Hi people,
>
> currently I'm evaluating wicket as the future framework in our company. I
> already found a lot of information but still there is some missing. I hope
> you can help me out answering these questions.
>
> * What experience do you have regarding performance of wicket applications?
> * Is there a way to cluster wicket applications?

as of 1.3.1 wicket is clustered the same way any other webapp is.

> * Does wicket use any proprietary, non-standard technologies?

it is an apache project, so the answer to proprietary is no.
non-standard? wicket is not a sun standard itself...

> * How does wicket care about session hijacking or sql injection?

it doesnt. sql injection should be handled by using prepared
statements with parameters. how would a webapp framework help you
here? dont see how it cna help with session hijacking since that
happens at a layer above wicket - servlet container.

> * Is there an easy way to implement SSO?

ssos usually work as a filter that is above your app. since wicket
itself is a filter i dont see any major problems.

> * Can I integrate wicket applications into any content management system?

*any* is a very broad category, so the answer would be 'no' since im
sure it is possible to find at least one cms there that will not play
nice :)

-igor

>
> If you have an answer to any of these questions don't hesitate to ignore the
> others - any input is welcome!
>
> Thanks in advance,
> René
> --
> View this message in context: 
> http://www.nabble.com/Evaluating-Wicket-tp15306535p15306535.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: IPropertyResolver interface for property models

2008-02-06 Thread Maeder Thomas
g.. getting late, the setter should be:

public abstract void setObject(Object obj) {
if (!isEquals(obj, getObject()) {
editedValues.put(obj);
}
} 

Thomas

> -Original Message-
> From: Maeder Thomas [mailto:[EMAIL PROTECTED] 
> Sent: Mittwoch, 6. Februar 2008 17:20
> To: users@wicket.apache.org
> Subject: RE: IPropertyResolver interface for property models
> 
> If I understand this correctly, you're trying to keep an 
> overlay while editing an object. Why not do this:
> 
> class OverlayModel extends Model {
>   OverlayModel(Map editedValues, IModel underlyingModel, String
> propertyName) {
>   ...remember the parameters in instance variables
>   }
> 
>   public Object getObject() {
>   if (editedValues.containsKey(propertyName)) {
>   return editedValues.get(propertyName);
>   } else {
>   return underlyingModel.getObject();
>   }
>   }
> 
>   public abstract void setObject(Object obj) {
>   if (isEquals(obj, getObject()) {
>   editValues.put(obj);
>   }
>   }
> }
> 
> As underlying models, you would use PropertyModel instances. 
> When you want to revert the values, you just clear the Map.
> 
> Thomas
> 
> > -Original Message-
> > From: Daniel Stoch [mailto:[EMAIL PROTECTED]
> > Sent: Mittwoch, 6. Februar 2008 16:31
> > To: users@wicket.apache.org
> > Subject: Re: IPropertyResolver interface for property models
> > 
> > On Feb 6, 2008 3:45 PM, Johan Compagner 
> <[EMAIL PROTECTED]> wrote:
> > > If we has such an interface then we need to rewrite most things 
> > > because now its just a static method and then we need to
> > have instances.
> > 
> > I know that. It is not a simple change.
> > 
> > > i guess you want then to have AbstractPropertyModel to have a 
> > > getPropertyResolver method that you can override and give 
> something 
> > > else back?
> > 
> > Yes exactly.
> > 
> > >
> > > But i still dont get what you really have What is your 
> model object 
> > > eventually where a property model works on?
> > >
> > 
> > I try to better explain this. When editing object I don't want to 
> > store changes directly to this object (eg. until form submit), but 
> > these edited values are "cached" in special ObjectEditor:
> > 
> > public interface ObjectEditor extends IClusterable {
> >   Object getEditedObject();
> >   Object getPropertyValue(String propertyExpression);
> >   void setPropertyValue(String propertyExpression, Object value);
> >   void commitChanges();
> >   void cancelChanges();
> > }
> > 
> > Sample use:
> > Form form = new Form("formId", new
> > EditorCompoundPropertyModel(new ObjectEditorImpl(baseObjectModel)));
> > where: baseObjectModel is a model (or can be directly any 
> Serializable
> > object) with object to edit.
> > Inside EditorCompoundPropertyModel EditorPropertyModel is created 
> > (instead of PropertyModel) which plays with ObjectEditor.
> > 
> > When you change value in form component (eg. DropDownChoice with
> > wantOnSelectionChangedNotifications=true) then a new value 
> is stored 
> > in ObjectEditor (by calling setPropertyValue()) and base 
> edited object 
> > stays unchanged. Form components to get value for display use 
> > EditorPropertyModel and this model
> > getObject() method calls
> > ObjectEditor.getPropertyValue() which checks if current 
> property value 
> > has been changed: if yes then this value comes from ObjectEditor 
> > cache, otherwise it comes directly from edited object. My own 
> > implementation of IPropertyResolver would call ObjectEditor 
> > getPropertyValue/setPropertyValue methods.
> > 
> > Such ObjectEditor allows me to track changes in my object, original 
> > object stays unchanged until I commit changes. When user press 
> > "Cancel" button I can revert all changes by 
> > ObjectEditor.cancelChanges(), I can edit non-serializable 
> objects, ...
> > 
> > My proposition with IPropertyResolver is for discussion only. 
> > It is not a thing "we must have" :).
> > By now, I have already implemented my own 
> EditorPropertyResolver and 
> > EditorCompoundPropertyResolver which play with such ObjectEditor.
> > 
> > Daniel
> > 
> > 
> -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > 
> > 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: IPropertyResolver interface for property models

2008-02-06 Thread Maeder Thomas
If I understand this correctly, you're trying to keep an overlay while
editing an object. Why not do this:

class OverlayModel extends Model {
OverlayModel(Map editedValues, IModel underlyingModel, String
propertyName) {
...remember the parameters in instance variables
}

public Object getObject() {
if (editedValues.containsKey(propertyName)) {
return editedValues.get(propertyName);
} else {
return underlyingModel.getObject();
}
}

public abstract void setObject(Object obj) {
if (isEquals(obj, getObject()) {
editValues.put(obj);
}
}
}

As underlying models, you would use PropertyModel instances. When you
want to revert the values, you just clear the Map.

Thomas

> -Original Message-
> From: Daniel Stoch [mailto:[EMAIL PROTECTED] 
> Sent: Mittwoch, 6. Februar 2008 16:31
> To: users@wicket.apache.org
> Subject: Re: IPropertyResolver interface for property models
> 
> On Feb 6, 2008 3:45 PM, Johan Compagner <[EMAIL PROTECTED]> wrote:
> > If we has such an interface then we need to rewrite most things 
> > because now its just a static method and then we need to 
> have instances.
> 
> I know that. It is not a simple change.
> 
> > i guess you want then to have AbstractPropertyModel to have a 
> > getPropertyResolver method that you can override and give something 
> > else back?
> 
> Yes exactly.
> 
> >
> > But i still dont get what you really have What is your model object 
> > eventually where a property model works on?
> >
> 
> I try to better explain this. When editing object I don't 
> want to store changes directly to this object (eg. until form 
> submit), but these edited values are "cached" in special ObjectEditor:
> 
> public interface ObjectEditor extends IClusterable {
>   Object getEditedObject();
>   Object getPropertyValue(String propertyExpression);
>   void setPropertyValue(String propertyExpression, Object value);
>   void commitChanges();
>   void cancelChanges();
> }
> 
> Sample use:
> Form form = new Form("formId", new 
> EditorCompoundPropertyModel(new ObjectEditorImpl(baseObjectModel)));
> where: baseObjectModel is a model (or can be directly any Serializable
> object) with object to edit.
> Inside EditorCompoundPropertyModel EditorPropertyModel is 
> created (instead of PropertyModel) which plays with ObjectEditor.
> 
> When you change value in form component (eg. DropDownChoice with
> wantOnSelectionChangedNotifications=true) then a new value is 
> stored in ObjectEditor (by calling setPropertyValue()) and 
> base edited object stays unchanged. Form components to get 
> value for display use EditorPropertyModel and this model 
> getObject() method calls
> ObjectEditor.getPropertyValue() which checks if current 
> property value has been changed: if yes then this value comes 
> from ObjectEditor cache, otherwise it comes directly from 
> edited object. My own implementation of IPropertyResolver 
> would call ObjectEditor getPropertyValue/setPropertyValue methods.
> 
> Such ObjectEditor allows me to track changes in my object, 
> original object stays unchanged until I commit changes. When 
> user press "Cancel" button I can revert all changes by 
> ObjectEditor.cancelChanges(), I can edit non-serializable objects, ...
> 
> My proposition with IPropertyResolver is for discussion only. 
> It is not a thing "we must have" :).
> By now, I have already implemented my own 
> EditorPropertyResolver and EditorCompoundPropertyResolver 
> which play with such ObjectEditor.
> 
> Daniel
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Block second click

2008-02-06 Thread Timo Rantalaiho
On Wed, 06 Feb 2008, Matthijs Wensveen wrote:
> I have a Link (not Ajax) on a component that does some heavyweight 
> processing in onClick. During this processing I want to block other 
> clicks from the same user. Is there a generic way to block multiple 
> requests on the same link? I would prefer a solution without Ajax / 
> JavaScript, but if that's impossible then that's okay.

Components are stateful, so maybe you could just keep the
state in your Link?

  @Override onClick() {
  if (!isEnabled()) {
  return;  // this shouldnt happen though?
  }
  try {
  setEnabled(false);
  doSomeHeavyWeightProcessing();
  } finally {
  setEnabled(true);
  }
  }

This creates a little race condition but if you can produce 
it you could try using a real lock mechanism.

Best wishes,
Timo

-- 
Timo Rantalaiho   
Reaktor Innovations Oyhttp://www.ri.fi/ >

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Block second click

2008-02-06 Thread Nino Saturnino Martinez Vazquez Wael



Matthijs Wensveen wrote:

Hello,

I have a Link (not Ajax) on a component that does some heavyweight 
processing in onClick. During this processing I want to block other 
clicks from the same user. Is there a generic way to block multiple 
requests on the same link?
I would prefer a solution without Ajax / JavaScript, but if that's 
impossible then that's okay.


I dont think thats possible, maybe with some meta refresh... Otherwise 
popup a layer with a higher z-index and that will block all until page 
reload, for minimal js.. Or use one of the ajax indicating stuff..

Thanks,
Matthijs



--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Doubt in wicket and multiple views

2008-02-06 Thread Janos Cserep
If you're looking for a way to use different layouts, templates for
different virtual servers you have several options:

- use the Session.setStyle() to set the style... you can do this in a custom
WebRequest and by examining the server name of the request url. Then you can
have different .html and .properties file per virtual host, but the same
usage.

- use a Border to incorporate all style information (adding css reference,
the main layout, etc). I prefer this approach - I have an ancestor Page that
always adds a border which border is made by a factory method I have on my
subclassed webapplication. This way I can create different borders and thus
different layouts and styles for different  pages - or I could even have
different styles based on any request parameters.

The second approach can be seen in live at www.szeretgom.hu (sorry it is not
available in English yet...)

If you navigate to http://szeretgom.hu/portal/content/title/Wiki/ you get a
different layout (which is created by a different border). A third kind of
border is displayed at this URL:
http://szeretgom.hu/portal/blog/pages/cserepj/

These are all handled by the same web application and it would be quite easy
to modify my code to return different borders based on the request url's
server name...

Hope this helps...



> I have one model and 4 different web applications. All webapplications is
> using the same model but different views. There is Different virtual hosts
> on the same server. Can I use wicket for this?
>
>
>
-- 
János Cserép - [EMAIL PROTECTED]
Web: http://www.szeretgom.hu
Skype: cserepj


Re: Session Expiration. UnauthorizedComponentInstantiationException. PageExpiredException. IllegalStateException. Ajax and Bookmarkable links.

2008-02-06 Thread mattsmith

Here's what we ended up doing to address this (since there didn't seem to be
a consistent approach to handling the variety of scenarios from the the
framework's perspective):

1.  Disabled the back button by agressively expiring visited pages (negating
a huge benefit of using wicket in the first place :).  
2.  Remove the bookmarkablePage link from the equation.
3.  onRuntimeException() in our custom request cycle handles the various
exceptions (PageExpired, Unauthorized,etc)
4.  custom modification to our web session to prevent feedback message
clearing in some cases of #3 where the message was getting too aggressively
cleared.
5.  we are not using the expired page setting that comes with wicket because
it didn't seem to cover the variety of scenarios mentioned.

We would have really liked to see this handling offered with some default
mechanism in wicket (For common scenarios mentioned in my prior msg).

- Matt


Matt Smith-20 wrote:
> 
> A co-worker and I are looking into how to provide a consistent
> handling of session expiration with an AuthenticatedWebApplication.
> 
> If a session expires, ideally, we'd like to provide a consistent
> behavior of redirecting to a login page with a helpful message (i.e. -
> "Your session expired, please re-login"), re-authenticate, and then
> proceed to the original request regardless of what type of request is
> made of the server.
> 
> Examples of the scenarios we'd like to handle consistently are:
> 1.   User logs in.  Session expires, then user clicks a wicket
> generated Page link.
> 2.   User logs in.  Session expires, then user clicks the back button
> in the browser and then clicks on a wicket generated component link.
> 3.   User logs in.  User performs an action which results in them
> being redirected to a bookmarkable page.  The session expires, then
> user submits a form
> 4.   User logs in.  User performs an action which results in them
> being redirected to a bookmarkable page.  The session expires, then
> user clicks a wicket generated link on the current page.
> 5.   User logs in.  User performs an action which results in them
> being redirected to a bookmarkable page.  The session expires, then
> user triggers an AJAX request of the server.
> 6.   User logs in.  The session expires.  User then triggers an AJAX
> request of the server.
> 7.   User logs in.  The session expires, then user gets redirected to
> login page (thus creating a new session).   User then clicks back and
> clicks on a wicket generated link, gets redirected to a login page,
> clicks back, clicks a wicket generated link.
> 
> The examples above seem to cause various behaviors in:
> #1.  The Web app's UnauthorizedComponentInstantiation listener is
> fired and given the page the user was on as an argument (thus
> redirecting them directly to the page without a message).
> #2 throws an UnauthorizedComponentInstantiationException
> #3 throws a PageExpiredException
> #4 throws a PageExpiredException
> #5 throws a PageExpiredException
> #6 throws an IllegalStateException (unmatched key/value pairs).
> #7  A WicketRuntimeException exception is thrown ("component not found
> in page")(because the page id in the link is referring to a different
> page in the current/new session than the page it referred to in the
> old session).  It seems that using nextnumber id's (starting at 0)
> allows for potential overlap in id's between a new session and an old
> session.
> 
> We are able to handle PageExpiredException consistently by overriding
> onRuntimeException() in our own custom RequestCycle.
> 
> Is there a way we can specify some consistent behavior for the other
> scenarios?
> 
> - Matt
> http://netsmith.blogspot.com
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Session-Expiration.-UnauthorizedComponentInstantiationException.-PageExpiredException.-IllegalStateException.-Ajax-and-Bookmarkable-links.-tp15272371p15306738.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Doubt in wicket and multiple views

2008-02-06 Thread Mathias P.W Nilsson

Hi!

I have one model and 4 different web applications. All webapplications is
using the same model but different views. There is Different virtual hosts
on the same server. Can I use wicket for this? 

ie

Domain1.se, Domain1.com, Domain2.se, Domain2.com same server different
virtual hosts same model with Wicket.
-- 
View this message in context: 
http://www.nabble.com/Doubt-in-wicket-and-multiple-views-tp15306737p15306737.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Some questions - mainly about session expiration and serialization

2008-02-06 Thread Erik van Oosten

Hi Fabrizio,

In 1.3 everything is serialized to disk at some time. So'll have to make 
things serializable, whether you are clustering or not (even with 
Terracotta).


Secondly, I very very very strongly recommend detachable models. Let me 
repeat, I really recommend detachable models. Large, or many non 
detachable models will fill up your session space quickly.


I am not sure your problems will go away with these changes, but I dare 
to bet on it.


Good luck and regards,
Erik.



[EMAIL PROTECTED] wrote:

Hi to all.

This is my first post, here's a quick introduction of
myself. My name is Fabrizio Giudici, I'm a senior architect
and I've been working with Wicket for a bit more than one
year.

I've recently upgraded to 1.3..



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: IPropertyResolver interface for property models

2008-02-06 Thread Daniel Stoch
On Feb 6, 2008 3:45 PM, Johan Compagner <[EMAIL PROTECTED]> wrote:
> If we has such an interface then we need to rewrite most things because now
> its just a static method and then we need to have instances.

I know that. It is not a simple change.

> i guess you want then to have AbstractPropertyModel to have a
> getPropertyResolver method
> that you can override and give something else back?

Yes exactly.

>
> But i still dont get what you really have
> What is your model object eventually where a property model works on?
>

I try to better explain this. When editing object I don't want to
store changes directly to this object (eg. until form submit), but
these edited values are "cached" in special ObjectEditor:

public interface ObjectEditor extends IClusterable {
  Object getEditedObject();
  Object getPropertyValue(String propertyExpression);
  void setPropertyValue(String propertyExpression, Object value);
  void commitChanges();
  void cancelChanges();
}

Sample use:
Form form = new Form("formId", new EditorCompoundPropertyModel(new
ObjectEditorImpl(baseObjectModel)));
where: baseObjectModel is a model (or can be directly any Serializable
object) with object to edit.
Inside EditorCompoundPropertyModel EditorPropertyModel is created
(instead of PropertyModel) which plays with ObjectEditor.

When you change value in form component (eg. DropDownChoice with
wantOnSelectionChangedNotifications=true) then a new value is stored
in ObjectEditor (by calling setPropertyValue()) and base edited object
stays unchanged. Form components to get value for display use
EditorPropertyModel and this model getObject() method calls
ObjectEditor.getPropertyValue() which checks if current property value
has been changed: if yes then this value comes from ObjectEditor
cache, otherwise it comes directly from edited object. My own
implementation of IPropertyResolver would call ObjectEditor
getPropertyValue/setPropertyValue methods.

Such ObjectEditor allows me to track changes in my object, original
object stays unchanged until I commit changes. When user press
"Cancel" button I can revert all changes by
ObjectEditor.cancelChanges(), I can edit non-serializable objects, ...

My proposition with IPropertyResolver is for discussion only. It is
not a thing "we must have" :).
By now, I have already implemented my own EditorPropertyResolver and
EditorCompoundPropertyResolver which play with such ObjectEditor.

Daniel

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Mounting page at root

2008-02-06 Thread Janos Cserep
>
> So I take it, it's currently not possible.
>


Looks like I was not clear enough, sorry:)

Configure your wicket filter to /* and return the page class you want to
view as / as the home page in your application class. You don't have to
mount anything, it will be displayed as /


Re: Page Expired Clustering?

2008-02-06 Thread wicket21

Hi, 

does anyone know what is the equivelant of this solution that would work
with tomcat?
We have the same problem using Wicket 1.2.6 with Tomcat 5.5.25, and the info
at http://cwiki.apache.org/WICKET/tomcat-clustering.html doesn't really
work.

We do a simple test with 2 tomcats behind an Apache (using mod_jk) and
sessions do not replicate correctly from one tomcat to the other.

Any help would be welcome...



Bushby wrote:
> 
> Thanks for the push in the right direction.  I believe we have the problem
> solved.  We needed to add a session-descriptor in the weblogic.xml file.
> 
> 
> PersistentStoreType
> replicated_if_clustered
> 
> 
> Again thanks for the quick response.  You helped save the wicket project. 
> It was hours from going to struts because of time issues.
> 
> 
> 
> Bushby wrote:
>> 
>> The home page gets displayed and the only 2 things on the page are links
>> to other pages.  One of the links goes to a page with 2 TextFields, 2
>> DatePickers, and a button.  The other page has fields to capture typical
>> credit card information.  The form for this page has a Spring service but
>> it does not hold reference.  It asks the application for the bean.  All
>> pojo's are Serializable.
>> 
>> 
>> 
>> Matej Knopp-2 wrote:
>>> 
>>> Also, are you sure everything on you page and in session is
>>> serializable?
>>> 
>>> -Matej
>>> 
>>> On 9/26/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
 > I am having trouble with a wicket application returning page expired
 when any
 > link or button is clicked on.  When the application is deployed on a
 server
 > with an Apache Weblogic integration the application works fine.  When
 the
 > application is deployed on a server with an Apache Weblogic cluster
 all
 > links and buttons return page expired.  I am using Wicket 1.2.6 and
 JDK 1.4.
 > The wicket application is also integrated with hibernate and Spring. 
 Any
 > help would be greatly appreciated.

 Do you use sticky sessions? Make sure the HttpSession gets replicated.

 Eelco

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


>>> 
>>> -
>>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>>> For additional commands, e-mail: [EMAIL PROTECTED]
>>> 
>>> 
>>> 
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Page-Expired-Clustering--tp12892290p15306703.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



  1   2   >