Re: How to add RadioGroup column to DataTable?

2007-09-20 Thread Igor Vaynberg
heh, "there is something wrong" doesnt really give me any context to help
you :)

i would guess you need to put the radiogroup around the entire datatable.

-igor


On 9/20/07, Kevin Liu <[EMAIL PROTECTED]> wrote:
>
> Hi! Igor
>   There is something wrong with The Radios:
>
>   RadioPanel.java:
>   import org.apache.wicket.markup.html.form.Radio;
> import org.apache.wicket.markup.html.form.RadioGroup;
> import org.apache.wicket.markup.html.panel.Panel;
> import org.apache.wicket.model.IModel;
>   public class RadioPanel extends Panel {
>
> private static final long serialVersionUID = 4309638869668046608L;
>public RadioPanel(String id, IModel model){
>   super(id);
>   RadioGroup radioGroup = new RadioGroup("radioGroup");
>   Radio radio = new Radio("radio", model);
>   radioGroup.add(radio);
>   this.add(radioGroup);
> }
> }
>
>   Html:
>   
> 
>   
> 
> 
>
>
>   and I use it in this way:
>   private AbstractColumn makeChioceColumn() {
>   return new AbstractColumn(new Model("Choice"))){
>private static final long serialVersionUID = -8344906560719618814L;
>  public void populateItem(Item cellItem, String componentId, IModel
> model){
> RadioPanel radioPanel = new RadioPanel(componentId, model);
>
> cellItem.add(radioPanel);
>
>}
>   };
> }
>
>   Thank you!
> Igor Vaynberg <[EMAIL PROTECTED]> wrote:
>   create a panel, and put the radiogroup in to it. then extend
> abstractcolumn
> and in populatecolumn create the instance of your panel and add it.
>
> -igor
>
>
> On 9/20/07, Kevin Liu wrote:
> >
> > Hi!
> >
> > Could you tell me how to add RadioGroup column to DataTable ?
> >
> > Thank you very much!
> >
> >
> > -Kevin Liu
> >
> > -
> > Be a better Heartthrob. Get better relationship answers from someone who
> > knows.
> > Yahoo! Answers - Check it out.
>
>
>
> -Kevin Liu
>
> -
> Yahoo! oneSearch: Finally,  mobile search that gives answers, not web
> links.


Re: How to add RadioGroup column to DataTable?

2007-09-20 Thread Kevin Liu
Hi! Igor 
  There is something wrong with The Radios:
   
  RadioPanel.java:
  import org.apache.wicket.markup.html.form.Radio;
import org.apache.wicket.markup.html.form.RadioGroup;
import org.apache.wicket.markup.html.panel.Panel;
import org.apache.wicket.model.IModel;
  public class RadioPanel extends Panel {
 
 private static final long serialVersionUID = 4309638869668046608L;
   public RadioPanel(String id, IModel model){
  super(id);
  RadioGroup radioGroup = new RadioGroup("radioGroup");
  Radio radio = new Radio("radio", model);
  radioGroup.add(radio);
  this.add(radioGroup);
 }
}
   
  Html:
  
 
  
 


   
  and I use it in this way:
  private AbstractColumn makeChioceColumn() {
  return new AbstractColumn(new Model("Choice"))){
   private static final long serialVersionUID = -8344906560719618814L;
 public void populateItem(Item cellItem, String componentId, IModel model){
RadioPanel radioPanel = new RadioPanel(componentId, model);

cellItem.add(radioPanel);

   }
  };
 }
   
  Thank you!
Igor Vaynberg <[EMAIL PROTECTED]> wrote:
  create a panel, and put the radiogroup in to it. then extend abstractcolumn
and in populatecolumn create the instance of your panel and add it.

-igor


On 9/20/07, Kevin Liu wrote:
>
> Hi!
>
> Could you tell me how to add RadioGroup column to DataTable ?
>
> Thank you very much!
>
>
> -Kevin Liu
>
> -
> Be a better Heartthrob. Get better relationship answers from someone who
> knows.
> Yahoo! Answers - Check it out.



-Kevin Liu
   
-
Yahoo! oneSearch: Finally,  mobile search that gives answers, not web links. 

Re: ANN: beturtle.com launched

2007-09-20 Thread John Krasnay
On Thu, Sep 20, 2007 at 09:50:37PM -0400, Joe Toth wrote:
> Hi Everyone,
> 
> We just launched http://beTurtle.com/ - A 'green' social networking
> site. If your interested in healthy living, sustainable practices, have
> 'green' questions or just want to make some new friends, stop on by. Let
> us know what you think, we would really appreciate it.
> 
> It runs on Spring2, Hibernate3, Wicket 1.3 plus many other open source
> projects.  Without Wicket and the other frameworks I wouldn't have been
> able to develop the entire site so quickly. Thank you so much everyone
> for the great framework and answering any questions I had.
> 
> Joe Toth

Congrats, Joe. Nice looking site, even when you View Source!

jk

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



Re: ANN: beturtle.com launched

2007-09-20 Thread chickabee

Simply amazing! Nice to see wicket in action ( yet one more time... ), thanks
for sharing !



WeaZeLb0y wrote:
> 
> Hi Everyone,
> 
> We just launched http://beTurtle.com/ - A 'green' social networking
> site. If your interested in healthy living, sustainable practices, have
> 'green' questions or just want to make some new friends, stop on by. Let
> us know what you think, we would really appreciate it.
> 
> It runs on Spring2, Hibernate3, Wicket 1.3 plus many other open source
> projects.  Without Wicket and the other frameworks I wouldn't have been
> able to develop the entire site so quickly. Thank you so much everyone
> for the great framework and answering any questions I had.
> 
> Joe Toth
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/ANN%3A-beturtle.com-launched-tf4491387.html#a12809777
Sent from the Wicket - User mailing list archive at Nabble.com.


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



ANN: beturtle.com launched

2007-09-20 Thread Joe Toth
Hi Everyone,

We just launched http://beTurtle.com/ - A 'green' social networking
site. If your interested in healthy living, sustainable practices, have
'green' questions or just want to make some new friends, stop on by. Let
us know what you think, we would really appreciate it.

It runs on Spring2, Hibernate3, Wicket 1.3 plus many other open source
projects.  Without Wicket and the other frameworks I wouldn't have been
able to develop the entire site so quickly. Thank you so much everyone
for the great framework and answering any questions I had.

Joe Toth


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



Re: Tracking down an elusive error during migration to 1.3

2007-09-20 Thread David Leangen

I'm still waiting for the classloader problem to be fixed. There is no
point putting this into a quickstart project since this won't reproduce
the same classloader issues.

We don't yet know if it's a problem with wicket or pax wicket. Since
there were no issues with 1.2, it's strange that 1.3 is suddenly broken.

I can think of only two possibilities: wicket 1.2 didn't use
classloaders correctly, and pax wicket compensated for this. So, when
the classloader issues were fixed in 1.3, pax wicket no longer works.

Or,

Classloaders in 1.2 were working just fine, but were broken in the 1.3
branch.



I have too many other things to do right now, and the pax wicket
developer is always being put on other projects, so hasn't had time to
look into this, either.


Once we get the classloader problem fixed, I'll get back to this. I
still have a strong suspicion that the two are related. If it's not,
then I guess it would be worthwhile to create a quickstart.


Thanks for checking in!



On Thu, 2007-09-13 at 10:14 -0700, Eelco Hillenius wrote:
> > Is there a possibility that this issue could be related to a
> > classloading issue that I'm having?
> 
> You could try to write a test case or quickstart project that shows this.
> 
> Eelco


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



Re: Setting focus to a TextField

2007-09-20 Thread John Krasnay
On Thu, Sep 20, 2007 at 03:43:45PM -0700, Doug Leeper wrote:
> 
> I know this is probably one of the most trivial things to do...but I am
> stumped.  No example that I found on the Wicket example site has shown this. 
> I know that AjaxRequestTarget#focusComponent plays a part in this but not
> sure how.  Could someone post a quick code snippet or place on the Wiki on
> how do to this in 1.3?
> 
> Thanks

I include this little script in my base page to always auto-focus the
first text box.

Focus = {};

Focus.setInitialFocus = function() {

// look for inputs with CSS class "invalid" first
var inputs = document.getElementsByTagName("input");
for (var i = 0; i < inputs.length; i++) {
var input = inputs.item(i);
if (input.className.indexOf("invalid") >= 0) {
input.focus();
input.select();
return;
}
}

for (var i = 0; i < inputs.length; i++) {
var input = inputs.item(i);
if (input.type == "text"
|| input.type == "file"
|| input.type == "password"
|| input.type == "radio"
|| input.type == "checkbox") {

// skip it if it's disabled or has the nofocus CSS class
if (!input.disabled && input.className.indexOf("nofocus") ==
-1) {
input.focus();
return;
}
}
}
}

if (window.addEventListener) {
window.addEventListener("load", Focus.setInitialFocus, true);
} else {
if (window.attachEvent) {
window.attachEvent("onload", Focus.setInitialFocus);
}
}

jk

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



Re: maven-jetty-plugin error

2007-09-20 Thread Gwyn Evans
Something very wierd there, as the "(Unsupported major.minor version
49.0)" is the sort of thing you see when you get a JDK 1.4 complaining
about being given 1.5 classes...

I also get the 6.1.1 Jetty plugin when I try...

Does "mvn -U clean jetty:run" make any difference?

/Gwyn

On Friday, September 21, 2007, 12:01:28 AM, auron <[EMAIL PROTECTED]> wrote:

> Hello everyone, 

> (newbie alert!)

> Please forgive me if the contents of this message doesn't belong in wicket.
> I am new to maven, wicket, and jetty, so I am a bit unsure where to ask
> about my problem.

> I installed Java6 SDK, Maven 2.0.7.

> I then ran this as specified by Wicket's website:

> mvn archetype:create -DarchetypeGroupId=org.apache.wicket
> -DarchetypeArtifactId=wicket-archetype-quickstart
> -DarchetypeVersion=1.3.0-beta3
> -DgroupId=com.mycompany
> -DartifactId=myproject

> I went into my the newly created myproject directory and did:

> mvn compile
> mvn package
> mvn jetty:run

> jetty:run threw an error and I was hoping someone can help. Here is the
> error with the -e option:
> [INFO] Scanning for projects...
> [INFO] Searching repository for plugin with prefix: 'jetty'.
> [INFO]
> -
> ---
> [INFO] Building quickstart
> [INFO]task-segment: [jetty:run]
> [INFO]
> -
> ---
> [INFO] Preparing jetty:run
> [INFO] [resources:resources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:compile]
> [INFO] Nothing to compile - all classes are up to date
> [INFO] [resources:testResources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:testCompile]
> [INFO] Nothing to compile - all classes are up to date
> -
> this realm =
> app0.child-container[org.mortbay.jetty:maven-jetty-plugin]
> -some imports omitted-
> Number of imports: 4
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> this realm = plexus.core
> Number of imports: 4
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> -
> [INFO]
> 
> [ERROR] BUILD ERROR
> [INFO]
> 
> [INFO] Internal error in the plugin manager executing goal
> 'org.mortbay.jetty:ma
> ven-jetty-plugin:6.1H.5-beta:run': Unable to find the mojo
> 'org.mortbay.jetty:ma
> ven-jetty-plugin:6.1H.5-beta:run' in the plugin
> 'org.mortbay.jetty:maven-jetty-p
> lugin'
> org/mortbay/jetty/Handler (Unsupported major.minor version 49.0)
> [INFO]
> 
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Internal error in
> the pl
> ugin manager executing goal
> 'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:ru
> n': Unable to find the mojo
> 'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:ru
> n' in the plugin 'org.mortbay.jetty:maven-jetty-plugin'
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
> ultLifecycleExecutor.java:543)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandalone
> Goal(DefaultLifecycleExecutor.java:493)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau
> ltLifecycleExecutor.java:463)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
> dleFailures(DefaultLifecycleExecutor.java:311)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
> ts(DefaultLifecycleExecutor.java:278)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
> fecycleExecutor.java:143)
> at
> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:334)
> at
> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:280)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> sorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:324)
> at
> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)

> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.PluginManagerException: Unable to find
> the mo
> jo 'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:run' 

Re: Setting focus to a TextField

2007-09-20 Thread Gwyn Evans
On Thursday, September 20, 2007, 11:43:45 PM, Doug <[EMAIL PROTECTED]> wrote:

> I know this is probably one of the most trivial things to do...but I am
> stumped.  No example that I found on the Wicket example site has shown this.
> I know that AjaxRequestTarget#focusComponent plays a part in this but not
> sure how.  Could someone post a quick code snippet or place on the Wiki on
> how do to this in 1.3?

Well, the basic code you need is just a
  
document.myform.myinput.focus();
  
in the markup (if you use  you may find it being
executed before that page if fully loaded) but I've not tried using
Wicket to tweak it.

/Gwyn


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



Re: maven-jetty-plugin error

2007-09-20 Thread auron

Thank you very much!

I added 6.1.5 to the maven-jetty plugin entry in maven
and everything works! 

Thanks again!
Jin


Martijn Dashorst wrote:
> 
> Seems like a Java conflict for the Jetty plugin version you are using:
> 
> org/mortbay/jetty/Handler (Unsupported major.minor version 49.0)
> 
> I am not sure which version this is, but I suggest you play with the
> jetty-plugin version a bit.
> 
> You can specify the version directly in your pom with the plugin in
> the  section, or in the pluginManagement section.
> 
> Martijn
> 
> On 9/21/07, auron <[EMAIL PROTECTED]> wrote:
>>
>> Hello everyone,
>>
>> (newbie alert!)
>>
>> Please forgive me if the contents of this message doesn't belong in
>> wicket.
>> I am new to maven, wicket, and jetty, so I am a bit unsure where to ask
>> about my problem.
>>
>> I installed Java6 SDK, Maven 2.0.7.
>>
>> I then ran this as specified by Wicket's website:
>>
>> mvn archetype:create -DarchetypeGroupId=org.apache.wicket
>> -DarchetypeArtifactId=wicket-archetype-quickstart
>> -DarchetypeVersion=1.3.0-beta3
>> -DgroupId=com.mycompany
>> -DartifactId=myproject
>>
>> I went into my the newly created myproject directory and did:
>>
>> mvn compile
>> mvn package
>> mvn jetty:run
>>
>> jetty:run threw an error and I was hoping someone can help. Here is the
>> error with the -e option:
>> [INFO] Scanning for projects...
>> [INFO] Searching repository for plugin with prefix: 'jetty'.
>> [INFO]
>> -
>> ---
>> [INFO] Building quickstart
>> [INFO]task-segment: [jetty:run]
>> [INFO]
>> -
>> ---
>> [INFO] Preparing jetty:run
>> [INFO] [resources:resources]
>> [INFO] Using default encoding to copy filtered resources.
>> [INFO] [compiler:compile]
>> [INFO] Nothing to compile - all classes are up to date
>> [INFO] [resources:testResources]
>> [INFO] Using default encoding to copy filtered resources.
>> [INFO] [compiler:testCompile]
>> [INFO] Nothing to compile - all classes are up to date
>> -
>> this realm = app0.child-container[org.mortbay.jetty:maven-jetty-plugin]
>> -some imports omitted-
>> Number of imports: 4
>> import: [EMAIL PROTECTED]
>> import: [EMAIL PROTECTED]
>> import: [EMAIL PROTECTED]
>> import: [EMAIL PROTECTED]
>> this realm = plexus.core
>> Number of imports: 4
>> import: [EMAIL PROTECTED]
>> import: [EMAIL PROTECTED]
>> import: [EMAIL PROTECTED]
>> import: [EMAIL PROTECTED]
>> -
>> [INFO]
>> 
>> [ERROR] BUILD ERROR
>> [INFO]
>> 
>> [INFO] Internal error in the plugin manager executing goal
>> 'org.mortbay.jetty:ma
>> ven-jetty-plugin:6.1H.5-beta:run': Unable to find the mojo
>> 'org.mortbay.jetty:ma
>> ven-jetty-plugin:6.1H.5-beta:run' in the plugin
>> 'org.mortbay.jetty:maven-jetty-p
>> lugin'
>> org/mortbay/jetty/Handler (Unsupported major.minor version 49.0)
>> [INFO]
>> 
>> [INFO] Trace
>> org.apache.maven.lifecycle.LifecycleExecutionException: Internal error in
>> the pl
>> ugin manager executing goal
>> 'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:ru
>> n': Unable to find the mojo
>> 'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:ru
>> n' in the plugin 'org.mortbay.jetty:maven-jetty-plugin'
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
>> ultLifecycleExecutor.java:543)
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandalone
>> Goal(DefaultLifecycleExecutor.java:493)
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau
>> ltLifecycleExecutor.java:463)
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
>> dleFailures(DefaultLifecycleExecutor.java:311)
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
>> ts(DefaultLifecycleExecutor.java:278)
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
>> fecycleExecutor.java:143)
>> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:334)
>> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
>> at org.apache.maven.cli.MavenCli.main(MavenCli.java:280)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>> java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>> sorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:324)
>> at
>> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>> at org.codehaus.cla

Re: maven-jetty-plugin error

2007-09-20 Thread Martijn Dashorst
Seems like a Java conflict for the Jetty plugin version you are using:

org/mortbay/jetty/Handler (Unsupported major.minor version 49.0)

I am not sure which version this is, but I suggest you play with the
jetty-plugin version a bit.

You can specify the version directly in your pom with the plugin in
the  section, or in the pluginManagement section.

Martijn

On 9/21/07, auron <[EMAIL PROTECTED]> wrote:
>
> Hello everyone,
>
> (newbie alert!)
>
> Please forgive me if the contents of this message doesn't belong in wicket.
> I am new to maven, wicket, and jetty, so I am a bit unsure where to ask
> about my problem.
>
> I installed Java6 SDK, Maven 2.0.7.
>
> I then ran this as specified by Wicket's website:
>
> mvn archetype:create -DarchetypeGroupId=org.apache.wicket
> -DarchetypeArtifactId=wicket-archetype-quickstart
> -DarchetypeVersion=1.3.0-beta3
> -DgroupId=com.mycompany
> -DartifactId=myproject
>
> I went into my the newly created myproject directory and did:
>
> mvn compile
> mvn package
> mvn jetty:run
>
> jetty:run threw an error and I was hoping someone can help. Here is the
> error with the -e option:
> [INFO] Scanning for projects...
> [INFO] Searching repository for plugin with prefix: 'jetty'.
> [INFO]
> -
> ---
> [INFO] Building quickstart
> [INFO]task-segment: [jetty:run]
> [INFO]
> -
> ---
> [INFO] Preparing jetty:run
> [INFO] [resources:resources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:compile]
> [INFO] Nothing to compile - all classes are up to date
> [INFO] [resources:testResources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:testCompile]
> [INFO] Nothing to compile - all classes are up to date
> -
> this realm = app0.child-container[org.mortbay.jetty:maven-jetty-plugin]
> -some imports omitted-
> Number of imports: 4
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> this realm = plexus.core
> Number of imports: 4
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> import: [EMAIL PROTECTED]
> -
> [INFO]
> 
> [ERROR] BUILD ERROR
> [INFO]
> 
> [INFO] Internal error in the plugin manager executing goal
> 'org.mortbay.jetty:ma
> ven-jetty-plugin:6.1H.5-beta:run': Unable to find the mojo
> 'org.mortbay.jetty:ma
> ven-jetty-plugin:6.1H.5-beta:run' in the plugin
> 'org.mortbay.jetty:maven-jetty-p
> lugin'
> org/mortbay/jetty/Handler (Unsupported major.minor version 49.0)
> [INFO]
> 
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Internal error in
> the pl
> ugin manager executing goal
> 'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:ru
> n': Unable to find the mojo
> 'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:ru
> n' in the plugin 'org.mortbay.jetty:maven-jetty-plugin'
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
> ultLifecycleExecutor.java:543)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandalone
> Goal(DefaultLifecycleExecutor.java:493)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau
> ltLifecycleExecutor.java:463)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
> dleFailures(DefaultLifecycleExecutor.java:311)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
> ts(DefaultLifecycleExecutor.java:278)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
> fecycleExecutor.java:143)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:334)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:280)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> sorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:324)
> at
> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.PluginManagerException: Unable to find
> the mo
> jo 'o

maven-jetty-plugin error

2007-09-20 Thread auron

Hello everyone, 

(newbie alert!)

Please forgive me if the contents of this message doesn't belong in wicket.
I am new to maven, wicket, and jetty, so I am a bit unsure where to ask
about my problem.

I installed Java6 SDK, Maven 2.0.7.

I then ran this as specified by Wicket's website:

mvn archetype:create -DarchetypeGroupId=org.apache.wicket
-DarchetypeArtifactId=wicket-archetype-quickstart
-DarchetypeVersion=1.3.0-beta3
-DgroupId=com.mycompany
-DartifactId=myproject

I went into my the newly created myproject directory and did:

mvn compile
mvn package
mvn jetty:run

jetty:run threw an error and I was hoping someone can help. Here is the
error with the -e option:
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'jetty'.
[INFO]
-
---
[INFO] Building quickstart
[INFO]task-segment: [jetty:run]
[INFO]
-
---
[INFO] Preparing jetty:run
[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:compile]
[INFO] Nothing to compile - all classes are up to date
[INFO] [resources:testResources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:testCompile]
[INFO] Nothing to compile - all classes are up to date
-
this realm = app0.child-container[org.mortbay.jetty:maven-jetty-plugin]
-some imports omitted-
Number of imports: 4
import: [EMAIL PROTECTED]
import: [EMAIL PROTECTED]
import: [EMAIL PROTECTED]
import: [EMAIL PROTECTED]
this realm = plexus.core
Number of imports: 4
import: [EMAIL PROTECTED]
import: [EMAIL PROTECTED]
import: [EMAIL PROTECTED]
import: [EMAIL PROTECTED]
-
[INFO]

[ERROR] BUILD ERROR
[INFO]

[INFO] Internal error in the plugin manager executing goal
'org.mortbay.jetty:ma
ven-jetty-plugin:6.1H.5-beta:run': Unable to find the mojo
'org.mortbay.jetty:ma
ven-jetty-plugin:6.1H.5-beta:run' in the plugin
'org.mortbay.jetty:maven-jetty-p
lugin'
org/mortbay/jetty/Handler (Unsupported major.minor version 49.0)
[INFO]

[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Internal error in
the pl
ugin manager executing goal
'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:ru
n': Unable to find the mojo
'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:ru
n' in the plugin 'org.mortbay.jetty:maven-jetty-plugin'
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
ultLifecycleExecutor.java:543)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandalone
Goal(DefaultLifecycleExecutor.java:493)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau
ltLifecycleExecutor.java:463)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
dleFailures(DefaultLifecycleExecutor.java:311)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
ts(DefaultLifecycleExecutor.java:278)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
fecycleExecutor.java:143)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:334)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:280)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)

at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.PluginManagerException: Unable to find
the mo
jo 'org.mortbay.jetty:maven-jetty-plugin:6.1H.5-beta:run' in the plugin
'org.mor
tbay.jetty:maven-jetty-plugin'
at
org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(Defaul
tPluginManager.java:571)
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPlugi
nManager.java:421)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
ultLifecycleExecutor.java:539)
... 16 more
Caused by:
org.codehaus.plexus.component.repository.exception.ComponentLookupExc
eption: Unable to lookup component
'org.apache.maven.plugin.Mojoorg.mortbay.jett
y:maven-jetty-plugin:6.1H.5-beta:run'

Setting focus to a TextField

2007-09-20 Thread Doug Leeper

I know this is probably one of the most trivial things to do...but I am
stumped.  No example that I found on the Wicket example site has shown this. 
I know that AjaxRequestTarget#focusComponent plays a part in this but not
sure how.  Could someone post a quick code snippet or place on the Wiki on
how do to this in 1.3?

Thanks
-- 
View this message in context: 
http://www.nabble.com/Setting-focus-to-a-TextField-tf4490766.html#a12807454
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: replace a Form by another Form with Ajax?

2007-09-20 Thread Eelco Hillenius
On 9/20/07, Potje rode kool <[EMAIL PROTECTED]> wrote:
> How do I replace a Form by another From by using Ajax?
> I understand I have to call setOutputMarkupId(true), but what is more I have
> to do?

replace it in your component tree (form.parent.replace or
form.replaceWith) and tell Wicket's ajax engine to re-render it
(ajaxRequestTarget.addComponent(form).

If the hierarchies of the two forms don't match, wrap them in a panel
and use that for replacement.

Eelco

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



replace a Form by another Form with Ajax?

2007-09-20 Thread Potje rode kool
How do I replace a Form by another From by using Ajax?
I understand I have to call setOutputMarkupId(true), but what is more I have
to do?
Is there an example about this?

Thanks,
Evert


Re: Enums and DropDownChoices in Web Beans

2007-09-20 Thread Dan Syrstad
On 9/20/07, dtoffe <[EMAIL PROTECTED]> wrote:
>
>
> For most cases, the PropertyChangeEvents are ok. But now I'm facing a
> particular problem and I guess I'm trying to use the wrong tool for the
> task.
> Let's say I have a bean with two properties and I want to show them as
> dropdownchoices, but they are related, think for example of the CarMake,
> CarModel, or Country, State pairs, where the first value determines a
> subset
> of possibilities for the second value.
> I would like to select the first value, and have the second
> dropdownchoice to get filtered by the possible values. How should I face
> such a situation ?  I guess having the second dropdownchoice based on an
> enum is not correct, since I only want a (non necessarily contiguous)
> subset
> of values to be allowed.
>
> Thanks for your help !
>
> Daniel



I've created a new example in the
wicket.contrib.webbeans.examples.dependentfields package that illustrates
this. You'll need to get the latest WWB code from SVN (rev 28) to run the
example. The example is based on the Wicket Ajax example with a Car Make and
Model (two dependent drop-down fields). Basically, you need to implement a
custom field for the Car's Model (an enum), because it is dependent on the
Make enum:

public class ModelField extends EnumField
{
private ElementMetaData makeProp;

public ModelField(String id, IModel model, ElementMetaData metaData,
boolean viewOnly)
{
// Init with an empty set of values. We can't build the list until
later.
super(id, model, metaData, viewOnly, Collections.EMPTY_LIST);

// Retrieve the parameter that defines which Make property we need.
makeProp = getDependentProperty(metaData, "makeProp", Make.class);

setValuesModel( new ValuesModel() );
}

private final class ValuesModel extends AbstractReadOnlyModel
{
@Override
public Object getObject(Component component)
{
// Retrieve the value of the dependent property.
Make make = (Make)getDependentPropertyBean(makeProp);
if (make != null) {
// Build a list of models based on the make.
List values = new ArrayList();
for (Model modelChoice : Model.values()) {
if (modelChoice.getMake().equals(make)) {
values.add(modelChoice);
}
}

return values;
}

return Collections.EMPTY_LIST;
}
}
}


And in beanprops, you would say:

Car {
cols: 1;
props:make, model{ makeProp: make };
}

On the "model" property, I specified the "makeProp" parameter (defined by
ModelField) to specify which Make property in your bean that it should be
dependent on. And viola, changing the Car's Make causes the list of choices
for the Car's Model to change - in real-time via Ajax. The advantage here is
that this field can be reused over and over wherever you may have a
Make/Model pair.


Re: CheckGroup form submission bug

2007-09-20 Thread Nick Busey

Thanks a lot for the help! I don't suppose you could post some of these Flex
objects?


Jan Kriesten wrote:
> 
> 
> hi nick,
> 
>> Thanks, this does fix this particular bug, but now I can't add items into
>> the
>> ListView. I'm trying to add items via AJAX, and with reuseItems turned
>> on,
>> it no longer adds the new items to the list like it should be.
> 
> listview isn't designed like that, so this wont work with ajax. i stumbled
> over
> this a couple of month ago when designing an app to insert items with ajax
> into
> a listview, too.
> 
> you have to create your own model to handel listviews, so for one you can
> reuse
> items but also do dynamic inserts which the listview will be aware of. you
> might
> take a look at the code to understand why it's not working.
> 
> i solved this by creating a so-called 'FlexListView' with a
> 'FlexItemModel'
> containing 'FlexItems'. ;-) This View isn't using a List's index to
> reference
> the items but looks them up in a Map, so insert's don't effect the lookup
> to
> reuse Items.
> 
> Hope you get an idea.
> 
> Best regards, --- jan.
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/CheckGroup-form-submission-bug-tf4489122.html#a12803885
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: CheckGroup form submission bug

2007-09-20 Thread Jan Kriesten

hi nick,

> Thanks, this does fix this particular bug, but now I can't add items into the
> ListView. I'm trying to add items via AJAX, and with reuseItems turned on,
> it no longer adds the new items to the list like it should be.

listview isn't designed like that, so this wont work with ajax. i stumbled over
this a couple of month ago when designing an app to insert items with ajax into
a listview, too.

you have to create your own model to handel listviews, so for one you can reuse
items but also do dynamic inserts which the listview will be aware of. you might
take a look at the code to understand why it's not working.

i solved this by creating a so-called 'FlexListView' with a 'FlexItemModel'
containing 'FlexItems'. ;-) This View isn't using a List's index to reference
the items but looks them up in a Map, so insert's don't effect the lookup to
reuse Items.

Hope you get an idea.

Best regards, --- jan.


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



Re: Embedding wicket in jsp error

2007-09-20 Thread hillj2


Al Maw wrote:
> 
> At the very least, you'll need to do what Martijn suggests and set a 
> one-pass render strategy.
> 

Done, with no success.


Al Maw wrote:
> 
> I'd recommend you go and read my blog post about this whole topic:
> http://herebebeasties.com/2007-03-01/jsp-and-wicket-sitting-in-a-tree/
> 
> It comes at things from slightly the other end of the spectrum 
> (embedding JSPs in a Wicket page) but the issues are very similar and 
> you should find it interesting reading.
> 
> You'll probably discover that you want to migrate your template stuff to 
> Wicket anyway at some point, in which case this is the approach you'll 
> need to adopt anyway.
> 

I have seen your blog before.  I was even skimming over it again today
earlier.  I'll have to sit down and read it thoroughly to see what it will
entail to implement, and how long it will take.

I'd love to migrate everything to wicket right now, but it's an very large
app and we barely have time to implement the new component we're working on
now (which IS all wicket).

Thanks for the help.  And thanks to Martijn as well.

Joel
-- 
View this message in context: 
http://www.nabble.com/Embedding-wicket-in-jsp-error-tf4488872.html#a12803501
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: Embedding wicket in jsp error

2007-09-20 Thread hillj2


Martijn Dashorst wrote:
> 
> I don't have any experience with oc4j nor embedding wicket in JSPs,
> but I know two things that can cause trouble:
>  - make sure you use ONE_PASS_RENDER as a render strategy
> 

I actualy did have this set up in our main app.  I just didn't put it in my
small test app.  I changed the render strategy on the test app and got the
same error.


Martijn Dashorst wrote:
> 
>  - don't use oc4j, or at least look at the threads on this list, as
> there have been more problems with oc4j and Wicket.
> 

I know, several of those posts are probably mine. :)  Frankly I've been
about ready to chuck oc4j myself, but it's not my call.  Although it may
come to it if we finally reach a problem that has no workaround.  However,
when I ran the app in Tomcat it also didn't work, so it doesn't look to be
an oc4j specific problem this time (I'm as shocked as you are).

-- 
View this message in context: 
http://www.nabble.com/Embedding-wicket-in-jsp-error-tf4488872.html#a12803370
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: Images Example Question!

2007-09-20 Thread chickabee

Very interesting!  That was easy, all good again, thanks for the help !!





Eelco Hillenius wrote:
> 
> com/ezfizz/whisky/http:/images.overstock.com/f/102/3117/8h/www.overstock.com/images/products/T10577058.jpg
>>
>> If I use Context Image:
>> image = new ContextImage("prodImg",  new Model( "url" ) );
>>
>> Then it shows broken Image and the image property says:
>> >https://lilo:8443/whisky/http://images.overstock.com/f/102/3117/8h/www.overstock.com/images/products/T10577058.jpg
> 
> 
> That is because that is not a context image you're trying to display
> there! Context refers to context path == part of your war.
> 
> What you need to do is write your own class that handles both:
> 
> public class ContextImage extends WebComponent {
> 
>   public ContextImage(String id) {
>   super(id);
>   }
> 
>   public ContextImage(String id, IModel model) {
>   super(id, model);
>   }
> 
>   protected void onComponentTag(final ComponentTag tag) {
>   checkComponentTag(tag, "img");
>   super.onComponentTag(tag);
>   String url = getModelObjectAsString();
>   if (url.startsWith("http")) {
>   tag.put("src", url);
>   } else {
>   tag.put("src", 
> getRequest().getRelativePathPrefixToContextRoot()
> + getModelObjectAsString());
>   }
>   }
> }
> 
> Something like that. Try to look at the source code more. Writing your
> own components often isn't that difficult.
> 
> Eelco
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Images-Example-Question%21-tf4484804.html#a12803139
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 Parameters to Bookmarkable Page

2007-09-20 Thread Flavius


If the page is bookmarked, I don't care about retaining the filter.
I just want the id for the item they want to view.  But if they
clicked the link from the list page (that has a list based on the filter),
then when they return to the list page (save, cancel), I want
to pass the filter back.

The target page looks for the filter and simply passes it back.  if
there's nothing there, it passes nothing back.



Evan Chooly wrote:
> 
> Having the link be both bookmarkable and having that object in the URL
> without persisting seems largely contradictory.  Relying on having the
> object in the session also reduces the effect of making it bookmarkable.
> The only option I see for making it really bookmarkable (stateless) is
> serializing the object to the URL string and deserializing in the page
> constructor.  And that's kinda ugly.
> 
> On 9/20/07, Flavius <[EMAIL PROTECTED]> wrote:
>>
>>
>>
>> If I pass the id, I have to persist the filter someplace, like
>> the session.  I try to avoid putting things on the session
>> since it inhibits performance of session replication in a clustered
>> environment.
>>
>> If I could get to the requestCycle when the link is clicked, it seems
>> like I could pass it along the request.  But the BookmarkablePageLink
>> doesn't have an onClick() event.
>>
>> Thinking out loud, it seems like if there were parameters that were
>> "bookmarkable" (e.g. included in the built url), and others
>> that were not (passed along, but not part of the generated url).
>>
>> Maybe that's something that could be done on a custom RequestCycle.
>> Or maybe it's not so bad having the obj on the session.  :-)
>>
>>
>>
>> Evan Chooly wrote:
>> >
>> > Put the Filter ID in the map.
>> >
>> > On 9/18/07, Flavius <[EMAIL PROTECTED]> wrote:
>> >>
>> >>
>> >> I have two pages, a list page and a detail.  The list page
>> >> can take a filter parameter, or has a default one if one
>> >> is not passed (making it bookmarkable).  When the user
>> >> clicks to go to the detail page, I want to pass that
>> >> filter along, so that when an edit is complete, the
>> >> page can redirect back to the list page with the same
>> >> filter intact.  I also want the detail page to be bookmarkable.
>> >>
>> >> If the detail page gets the filter, it simply passes it back.  If
>> >> not, that's fine too.
>> >>
>> >> I can accomplish this easily by creating a PageParameters:
>> >>
>> >> PageParameters parameters = new PageParameters();
>> >> parameters.put("filter", filter);
>> >>
>> >> BookmarkablePageLink link = new BookmarkablePageLink(name,
>> >> MyDetailPage.class, parameters);
>> >>
>> >> And this works fine.  But I don't like the way
>> >> the URL is created like this:
>> >>
>> >>
>> >>
>> http://localhost/pages/MyDetailPage/item/20/filter/com.foo.bar.Filter%401ae6456/
>> >>
>> >> If the page is bookmarked, the Filter obj doesn't matter anyway.
>> >> I understand why it's there, I'm just trying to figure out a prettier
>> >> URL,
>> >> like
>> >> when I pass a parameter on the requestCycle, setting the response page
>> >> and passing the parameters obj in there.
>> >>
>> >> I've thought of overriding the onClick event for BookmarkablePageLink,
>> >> but
>> >> it's final.  Another option was to pass it on the request or the
>> session.
>> >> That
>> >> would be the last option.
>> >>
>> >> Any insight would be appreciated.
>> >>
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/Passing-Parameters-to-Bookmarkable-Page-tf4478593.html#a12770252
>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>
>> >>
>> >> -
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >>
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Passing-Parameters-to-Bookmarkable-Page-tf4478593.html#a12802323
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Passing-Parameters-to-Bookmarkable-Page-tf4478593.html#a12803086
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: CheckGroup form submission bug

2007-09-20 Thread Nick Busey

Thanks, this does fix this particular bug, but now I can't add items into the
ListView. I'm trying to add items via AJAX, and with reuseItems turned on,
it no longer adds the new items to the list like it should be.


igor.vaynberg wrote:
> 
> if your listview is in a form you have to call
> listview.setreuseitems(true);
> 
> -igor
> 
> 
> On 9/20/07, Nick Busey <[EMAIL PROTECTED]> wrote:
>>
>>
>> So I've got what appears to be a very strange bug. I have a CheckGroup
>> with a
>> ListView of Checks among other things. Everything seems to work fine if
>> you
>> render the form and submit it without any errors the first time. However,
>> if
>> you hit any errors (like not selecting any Checks), and are bounced back
>> to
>> the form with an error rendered, if you select a Check and re-submit it,
>> it
>> dies with the following error:
>>
>> WicketMessage: submitted http post value [check22] for CheckGroup
>> component
>> [14:slurpFormResults:resultPanel:group] contains an illegal relative path
>> element [check22] which does not point to a Check component. Due to this
>> the
>> CheckGroup component cannot resolve the selected Check component pointed
>> to
>> by the illegal value. A possible reason is that componment hierarchy
>> changed
>> between rendering and form submission.
>>
>> Root cause:
>>
>> org.apache.wicket.WicketRuntimeException: submitted http post value
>> [check22] for CheckGroup component
>> [14:slurpFormResults:resultPanel:group]
>> contains an illegal relative path element [check22] which does not point
>> to
>> a Check component. Due to this the CheckGroup component cannot resolve
>> the
>> selected Check component pointed to by the illegal value. A possible
>> reason
>> is that componment hierarchy changed between rendering and form
>> submission.
>> at
>> org.apache.wicket.markup.html.form.CheckGroup.convertValue(CheckGroup.java
>> :141)
>> etc..
>>
>> Here's the code:
>>
>> final ListView contactsList = new
>> ListView("contactRepeater", new
>> PropertyModel(this,
>> "contacts"))
>> {
>> private static final long serialVersionUID = 1L;
>>
>> @Override
>> protected void populateItem(ListItem item)
>> {
>> ExternalContact p = (ExternalContact)
>> item.getModelObject();
>> Check check = new Check("selected", new
>> Model(item.getIndex()));
>> String mail = p.getEMailAddress();
>> if (mail == null)
>> {
>> p.setEMailAddress(p.getUserName
>> ());
>> }
>> check.add(new
>> SimpleAttributeModifier("id", p.getEMailAddress()));
>> // Create and style image
>> StaticImage image = new
>> StaticImage("pic",
>> new Model(p.getImageURL()));
>> String pic = p.getImageURL();
>> Label picBlock = new Label("picBlock",
>> new
>> Model());
>> picBlock.add(new
>> SimpleAttributeModifier("class", "noPictureInactive"));
>> item.add(picBlock);
>> item.add(image);
>> String emailLabel = new String();
>> emailLabel = p.getEMailAddress();
>>
>> item.add(new Label("emailLabel", new
>> Model(emailLabel)));
>> item.add(check);
>> item.add(new
>> SimpleAttributeModifier("for", p.getEMailAddress()));
>> item.add(new
>> SimpleAttributeModifier("class", "pictureContainer " +
>> p.getType().toString()));
>> }
>> };
>> group = new CheckGroup("group", new ArrayList());
>> group.add(contactsList);
>> group.add(new CheckGroupSelector("groupSelect"));
>> group.setOutputMarkupId(true);
>>
>> Any help or ideas would be greatly appreciated. Thanks!
>> --
>> View this message in context:
>> http://www.nabble.com/CheckGroup-form-submission-bug-tf4489122.html#a12802495
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 

-- 
View this message in context: 
http://www.nabble.com/CheckGroup-form-submission-bug-tf4489122.html#a12803008
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL 

Re: Passing Parameters to Bookmarkable Page

2007-09-20 Thread Evan Chooly
Having the link be both bookmarkable and having that object in the URL
without persisting seems largely contradictory.  Relying on having the
object in the session also reduces the effect of making it bookmarkable.
The only option I see for making it really bookmarkable (stateless) is
serializing the object to the URL string and deserializing in the page
constructor.  And that's kinda ugly.

On 9/20/07, Flavius <[EMAIL PROTECTED]> wrote:
>
>
>
> If I pass the id, I have to persist the filter someplace, like
> the session.  I try to avoid putting things on the session
> since it inhibits performance of session replication in a clustered
> environment.
>
> If I could get to the requestCycle when the link is clicked, it seems
> like I could pass it along the request.  But the BookmarkablePageLink
> doesn't have an onClick() event.
>
> Thinking out loud, it seems like if there were parameters that were
> "bookmarkable" (e.g. included in the built url), and others
> that were not (passed along, but not part of the generated url).
>
> Maybe that's something that could be done on a custom RequestCycle.
> Or maybe it's not so bad having the obj on the session.  :-)
>
>
>
> Evan Chooly wrote:
> >
> > Put the Filter ID in the map.
> >
> > On 9/18/07, Flavius <[EMAIL PROTECTED]> wrote:
> >>
> >>
> >> I have two pages, a list page and a detail.  The list page
> >> can take a filter parameter, or has a default one if one
> >> is not passed (making it bookmarkable).  When the user
> >> clicks to go to the detail page, I want to pass that
> >> filter along, so that when an edit is complete, the
> >> page can redirect back to the list page with the same
> >> filter intact.  I also want the detail page to be bookmarkable.
> >>
> >> If the detail page gets the filter, it simply passes it back.  If
> >> not, that's fine too.
> >>
> >> I can accomplish this easily by creating a PageParameters:
> >>
> >> PageParameters parameters = new PageParameters();
> >> parameters.put("filter", filter);
> >>
> >> BookmarkablePageLink link = new BookmarkablePageLink(name,
> >> MyDetailPage.class, parameters);
> >>
> >> And this works fine.  But I don't like the way
> >> the URL is created like this:
> >>
> >>
> >>
> http://localhost/pages/MyDetailPage/item/20/filter/com.foo.bar.Filter%401ae6456/
> >>
> >> If the page is bookmarked, the Filter obj doesn't matter anyway.
> >> I understand why it's there, I'm just trying to figure out a prettier
> >> URL,
> >> like
> >> when I pass a parameter on the requestCycle, setting the response page
> >> and passing the parameters obj in there.
> >>
> >> I've thought of overriding the onClick event for BookmarkablePageLink,
> >> but
> >> it's final.  Another option was to pass it on the request or the
> session.
> >> That
> >> would be the last option.
> >>
> >> Any insight would be appreciated.
> >>
> >>
> >> --
> >> View this message in context:
> >>
> http://www.nabble.com/Passing-Parameters-to-Bookmarkable-Page-tf4478593.html#a12770252
> >> Sent from the Wicket - User mailing list archive at Nabble.com.
> >>
> >>
> >> -
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Passing-Parameters-to-Bookmarkable-Page-tf4478593.html#a12802323
> 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: CheckGroup form submission bug

2007-09-20 Thread Igor Vaynberg
if your listview is in a form you have to call listview.setreuseitems(true);

-igor


On 9/20/07, Nick Busey <[EMAIL PROTECTED]> wrote:
>
>
> So I've got what appears to be a very strange bug. I have a CheckGroup
> with a
> ListView of Checks among other things. Everything seems to work fine if
> you
> render the form and submit it without any errors the first time. However,
> if
> you hit any errors (like not selecting any Checks), and are bounced back
> to
> the form with an error rendered, if you select a Check and re-submit it,
> it
> dies with the following error:
>
> WicketMessage: submitted http post value [check22] for CheckGroup
> component
> [14:slurpFormResults:resultPanel:group] contains an illegal relative path
> element [check22] which does not point to a Check component. Due to this
> the
> CheckGroup component cannot resolve the selected Check component pointed
> to
> by the illegal value. A possible reason is that componment hierarchy
> changed
> between rendering and form submission.
>
> Root cause:
>
> org.apache.wicket.WicketRuntimeException: submitted http post value
> [check22] for CheckGroup component [14:slurpFormResults:resultPanel:group]
> contains an illegal relative path element [check22] which does not point
> to
> a Check component. Due to this the CheckGroup component cannot resolve the
> selected Check component pointed to by the illegal value. A possible
> reason
> is that componment hierarchy changed between rendering and form
> submission.
> at
> org.apache.wicket.markup.html.form.CheckGroup.convertValue(CheckGroup.java
> :141)
> etc..
>
> Here's the code:
>
> final ListView contactsList = new
> ListView("contactRepeater", new
> PropertyModel(this,
> "contacts"))
> {
> private static final long serialVersionUID = 1L;
>
> @Override
> protected void populateItem(ListItem item)
> {
> ExternalContact p = (ExternalContact)
> item.getModelObject();
> Check check = new Check("selected", new
> Model(item.getIndex()));
> String mail = p.getEMailAddress();
> if (mail == null)
> {
> p.setEMailAddress(p.getUserName
> ());
> }
> check.add(new
> SimpleAttributeModifier("id", p.getEMailAddress()));
> // Create and style image
> StaticImage image = new StaticImage("pic",
> new Model(p.getImageURL()));
> String pic = p.getImageURL();
> Label picBlock = new Label("picBlock", new
> Model());
> picBlock.add(new
> SimpleAttributeModifier("class", "noPictureInactive"));
> item.add(picBlock);
> item.add(image);
> String emailLabel = new String();
> emailLabel = p.getEMailAddress();
>
> item.add(new Label("emailLabel", new
> Model(emailLabel)));
> item.add(check);
> item.add(new
> SimpleAttributeModifier("for", p.getEMailAddress()));
> item.add(new
> SimpleAttributeModifier("class", "pictureContainer " +
> p.getType().toString()));
> }
> };
> group = new CheckGroup("group", new ArrayList());
> group.add(contactsList);
> group.add(new CheckGroupSelector("groupSelect"));
> group.setOutputMarkupId(true);
>
> Any help or ideas would be greatly appreciated. Thanks!
> --
> View this message in context:
> http://www.nabble.com/CheckGroup-form-submission-bug-tf4489122.html#a12802495
> 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: Images Example Question!

2007-09-20 Thread Eelco Hillenius
com/ezfizz/whisky/http:/images.overstock.com/f/102/3117/8h/www.overstock.com/images/products/T10577058.jpg
>
> If I use Context Image:
> image = new ContextImage("prodImg",  new Model( "url" ) );
>
> Then it shows broken Image and the image property says:
> >https://lilo:8443/whisky/http://images.overstock.com/f/102/3117/8h/www.overstock.com/images/products/T10577058.jpg


That is because that is not a context image you're trying to display
there! Context refers to context path == part of your war.

What you need to do is write your own class that handles both:

public class ContextImage extends WebComponent {

public ContextImage(String id) {
super(id);
}

public ContextImage(String id, IModel model) {
super(id, model);
}

protected void onComponentTag(final ComponentTag tag) {
checkComponentTag(tag, "img");
super.onComponentTag(tag);
String url = getModelObjectAsString();
if (url.startsWith("http")) {
tag.put("src", url);
} else {
tag.put("src", 
getRequest().getRelativePathPrefixToContextRoot()
+ getModelObjectAsString());
}
}
}

Something like that. Try to look at the source code more. Writing your
own components often isn't that difficult.

Eelco

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



Re: Embedding wicket in jsp error

2007-09-20 Thread Al Maw

hillj2 wrote:

I know this has been discussed before, but none of the previous posts have
helped me solve my problem.  I'm trying to embed a wicket page into a jsp
page (until I have time go back and convert all our jsp's to wicket) using
the  tag.


At the very least, you'll need to do what Martijn suggests and set a 
one-pass render strategy.


I'd recommend you go and read my blog post about this whole topic:
http://herebebeasties.com/2007-03-01/jsp-and-wicket-sitting-in-a-tree/

It comes at things from slightly the other end of the spectrum 
(embedding JSPs in a Wicket page) but the issues are very similar and 
you should find it interesting reading.


You'll probably discover that you want to migrate your template stuff to 
Wicket anyway at some point, in which case this is the approach you'll 
need to adopt anyway.


Good luck.

Best Regards,

Al

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



Re: Images Example Question!

2007-09-20 Thread chickabee

Internal Image URL worked fine but the third party Image URLs still have
problems, 

Here is the sample third party url:
http://images.overstock.com/f/102/3117/8h/www.overstock.com/images/products/T10577058.jpg

If I use Image:
image = new Image("prodImg",   "'url"  );

then I get this:
WARN  - PackageResource- Unable to find package resource [path =
com/ezfizz/whisky/http:/images.overstock.com/f/102/3117/8h/www.overstock.com/images/products/T10577058.jpg

If I use Context Image:
image = new ContextImage("prodImg",  new Model( "url" ) );

Then it shows broken Image and the image property says:
https://lilo:8443/whisky/http://images.overstock.com/f/102/3117/8h/www.overstock.com/images/products/T10577058.jpg

Either way Wicket fails to understand the absoluteness of URLs and prepends
something to make it unusable, 

What are my options now? thanks in advance.





Eelco Hillenius wrote:
> 
>> It's working well now, Thanks for pushing me through.
> 
> No problem. And remember: "don't panic" ;-)
> 
> Eelco
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Images-Example-Question%21-tf4484804.html#a12802592
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: Embedding wicket in jsp error

2007-09-20 Thread Martijn Dashorst
I don't have any experience with oc4j nor embedding wicket in JSPs,
but I know two things that can cause trouble:
 - make sure you use ONE_PASS_RENDER as a render strategy
 - don't use oc4j, or at least look at the threads on this list, as
there have been more problems with oc4j and Wicket.

Martijn

On 9/20/07, hillj2 <[EMAIL PROTECTED]> wrote:
>
> I know this has been discussed before, but none of the previous posts have
> helped me solve my problem.  I'm trying to embed a wicket page into a jsp
> page (until I have time go back and convert all our jsp's to wicket) using
> the  tag.  oc4j throws a ServletException: Error in Servlet,
> with no further information specifying the problem, nor any indication from
> wicket that it's having a problem.  To isolate the problem I tried to
> recreate it in a very small app, so I could rule out any issue with other
> app code/configurations.  This time, I get a more informative (but not
> necessarily more helpful) error message:
>
> java.lang.IllegalStateException: Response has already been committed, be
> sure not to write to the OutputStream or to trigger a commit due to any
> other action before calling this method.
>
> I'm hoping it's the same error in both cases, and the former case just has a
> more generic error message for some reason; but I was hoping someone might
> have a clue why I can't get the embedding to work.  I'm using oc4j 10.1.3.3,
> and wicket beta2.  I tried it on Tomcat also.  It didn't throw an error, but
> the place where the wicket content should be was just empty.
>
> I'd prefer not to have to do this with embedded IFRAME's as I've seen
> suggested.  That's the setup I have now, but when a page loads there's a
> delay loading the IFRAME content, which doesn't look very nice, especially
> since the embedded content is my app's navigation menu.  Any thoughts,
> suggestions, alternate solutions to the embedding issue?
>
> Here's the code from my small test app:
>
> embed.jsp
> 
> 
>  
>   Embed test
>  
>  
>   
>   
>   Here is my JSP content
>  
> 
>
> EmbedServlet.java
> ==
> public class EmbedServlet extends HttpServlet {
>
>   public void doGet(HttpServletRequest request, HttpServletResponse
> response)
> throws ServletException, IOException {
> doPost(request, response);
>   }
>
>   public void doPost(HttpServletRequest request, HttpServletResponse
> response)
> throws ServletException, IOException {
>
> RequestDispatcher rd  =
> request.getRequestDispatcher("/WEB-INF/jsp/embed.jsp");
> rd.forward(request, response);
>
>   }
>
> }
>
> EmbedApplication.java
> =
> public class EmbedApplication extends WebApplication {
>
>   public EmbedApplication() {
> super();
>   }
>
>   public Class getHomePage() {
> return EmbedPage.class;
>   }
>
>   protected void init() {
> System.out.println("* Wicket App initialized *");
>   }
>
> }
>
> EmbedPage.java
> 
> public class EmbedPage extends WebPage {
>   public EmbedPage() {
> super();
>   }
> }
>
> EmbedPage.html
> 
> 
>  
>   Embeded Wicket
>  
>  
>   Here is my wicket content.
>  
> 
>
> web.xml
> ==
> 
>  2.2//EN"
>   "http://java.sun.com/j2ee/dtds/web-app_2.2.dtd";>
> http://www.w3.org/2001/XMLSchema-instance";
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
> http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"; version="2.5"
> xmlns="http://java.sun.com/xml/ns/javaee";>
>   
> EmbedServlet
> EmbedServlet
>   
>   
> EmbedServlet
> /main
>   
>   
> EmbedApplication
>
> org.apache.wicket.protocol.http.WicketServlet
> 
>   applicationClassName
>   EmbedApplication
> 
>   
>   
> EmbedApplication
> /wicket/*
>   
>   
> 35
>   
>   
> html
> text/html
>   
>   
> txt
> text/plain
>   
> 
>
>
>
> Thanks,
> Joel
> --
> View this message in context: 
> http://www.nabble.com/Embedding-wicket-in-jsp-error-tf4488872.html#a12801646
> 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-beta3 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta3/

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



Re: Wicket shopping cart?

2007-09-20 Thread Scott Swank
I'm not sure that PetStore will be of great value.  I'd just start by
defining what you want your cart to contain.  Do you have domain
objects that already correspond to the sort of saleable item you want
in your cart?  If not, then you need that.  Then you really just need
a Cart class with methods to add an item, remove an item, empty
itself, etc.  Then I'd suggest a custom Wicket session with a
getCart() method.

- Scott


On 9/20/07, Tauren Mills <[EMAIL PROTECTED]> wrote:
> If I had to guess, most people who implement a custom shopping system
> have some sort of unique need.  I'll start working on building
> something from scratch.  I'll be using wicket/spring/hibernate to
> build this.
>
> If anyone has suggestions or ideas, I'd love to hear them.  Especially
> when it comes to the entities involved and their relationships.  Maybe
> I should start with the PetStore demo since I haven't looked at it
> recently.  Are there any opinions on the quality of the petstore data
> design (besides the yucky JSF technologies used)?
>
> Thanks,
> Tauren
>
>
> On 9/19/07, Scott Swank <[EMAIL PROTECTED]> wrote:
> > It's a little too idiosyncratic to be of wider use -- i.e. adult &
> > child tickets to the same show should appear together, but with the
> > adult tickets first.  There aren't any particular trade secrets in it,
> > but it would likely be more work to generify (sp?) it than it would be
> > to just write something from scratch.
> >
> > - Scott
> >
> >
> > On 9/19/07, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > > There has been some talk of building a pet store to compare it against
> > > other frameworks (in good spirit though!). But both Eelco and I
> > > haven't had the time to actually contribute to that project. The book
> > > has our highest priority now.
> > >
> > > I think the biggest shopping cart currently online is vegas.com, but
> > > I'm willing to bet an autographed Wicket in Action that they won't be
> > > open sourcing that one anytime soon.
> > >
> > > Martijn
> > >
> > > On 9/20/07, Tauren Mills <[EMAIL PROTECTED]> wrote:
> > > > Martijn,
> > > >
> > > > Great to hear!  I haven't bought the MEAP yet, but that's another
> > > > great reason to!  Perhaps it would make a good starting point.  But
> > > > still, if anyone has developed a more full featured solution and are
> > > > interested in open sourcing it, I'd like to talk.
> > > >
> > > > Tauren
> > > >
> > > >
> > > > On 9/19/07, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > > > > It seems that Wicket in Action has a basic shopping cart described. 
> > > > > :-)
> > > > >
> > > > > Martijn
> > > > >
> > > > > On 9/19/07, Tauren Mills <[EMAIL PROTECTED]> wrote:
> > > > > > I'm looking for an open source shopping cart built in wicket, but
> > > > > > haven't found such a thing yet.  Does anyone know of something out
> > > > > > there?
> > > > > >
> > > > > > I've noticed in several posts that people have been working on
> > > > > > shopping solutions.  Are any of you willing to open source your
> > > > > > solution?  Ultimately, I'd like to make an open source shopping cart
> > > > > > available to the wicket community, but would rather not duplicate
> > > > > > efforts if others would be interested in contributing any existing
> > > > > > codebase.
> > > > > >
> > > > > > Thanks!
> > > > > > Tauren
> > > > > >
> > > > > > -
> > > > > > 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-beta3 is released
> > > > > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta3/
> > > > >
> > > > > -
> > > > > 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]
> > > >
> > > >
> > >
> > >
> > > --
> > > Buy Wicket in Action: http://manning.com/dashorst
> > > Apache Wicket 1.3.0-beta3 is released
> > > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta3/
> > >
> > > -
> > > 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 addition

CheckGroup form submission bug

2007-09-20 Thread Nick Busey

So I've got what appears to be a very strange bug. I have a CheckGroup with a
ListView of Checks among other things. Everything seems to work fine if you
render the form and submit it without any errors the first time. However, if
you hit any errors (like not selecting any Checks), and are bounced back to
the form with an error rendered, if you select a Check and re-submit it, it
dies with the following error:

WicketMessage: submitted http post value [check22] for CheckGroup component
[14:slurpFormResults:resultPanel:group] contains an illegal relative path
element [check22] which does not point to a Check component. Due to this the
CheckGroup component cannot resolve the selected Check component pointed to
by the illegal value. A possible reason is that componment hierarchy changed
between rendering and form submission.

Root cause:

org.apache.wicket.WicketRuntimeException: submitted http post value
[check22] for CheckGroup component [14:slurpFormResults:resultPanel:group]
contains an illegal relative path element [check22] which does not point to
a Check component. Due to this the CheckGroup component cannot resolve the
selected Check component pointed to by the illegal value. A possible reason
is that componment hierarchy changed between rendering and form submission.
at
org.apache.wicket.markup.html.form.CheckGroup.convertValue(CheckGroup.java:141)
etc..

Here's the code:

final ListView contactsList = new ListView("contactRepeater", 
new
PropertyModel(this,
"contacts"))
{
private static final long serialVersionUID = 1L;

@Override
protected void populateItem(ListItem item)
{
ExternalContact p = (ExternalContact) 
item.getModelObject();
Check check = new Check("selected", new 
Model(item.getIndex()));
String mail = p.getEMailAddress();
if (mail == null)
{
p.setEMailAddress(p.getUserName());
}
check.add(new SimpleAttributeModifier("id", 
p.getEMailAddress()));
// Create and style image
StaticImage image = new StaticImage("pic", new 
Model(p.getImageURL()));
String pic = p.getImageURL();
Label picBlock = new Label("picBlock", new 
Model());
picBlock.add(new 
SimpleAttributeModifier("class", "noPictureInactive"));
item.add(picBlock);
item.add(image);
String emailLabel = new String();
emailLabel = p.getEMailAddress();

item.add(new Label("emailLabel", new 
Model(emailLabel)));
item.add(check);
item.add(new SimpleAttributeModifier("for", 
p.getEMailAddress()));
item.add(new SimpleAttributeModifier("class", 
"pictureContainer " +
p.getType().toString()));
}
};
group = new CheckGroup("group", new ArrayList());
group.add(contactsList);
group.add(new CheckGroupSelector("groupSelect"));
group.setOutputMarkupId(true);

Any help or ideas would be greatly appreciated. Thanks!
-- 
View this message in context: 
http://www.nabble.com/CheckGroup-form-submission-bug-tf4489122.html#a12802495
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 Parameters to Bookmarkable Page

2007-09-20 Thread Flavius


If I pass the id, I have to persist the filter someplace, like
the session.  I try to avoid putting things on the session
since it inhibits performance of session replication in a clustered
environment.

If I could get to the requestCycle when the link is clicked, it seems
like I could pass it along the request.  But the BookmarkablePageLink
doesn't have an onClick() event.

Thinking out loud, it seems like if there were parameters that were
"bookmarkable" (e.g. included in the built url), and others
that were not (passed along, but not part of the generated url).

Maybe that's something that could be done on a custom RequestCycle.
Or maybe it's not so bad having the obj on the session.  :-)



Evan Chooly wrote:
> 
> Put the Filter ID in the map.
> 
> On 9/18/07, Flavius <[EMAIL PROTECTED]> wrote:
>>
>>
>> I have two pages, a list page and a detail.  The list page
>> can take a filter parameter, or has a default one if one
>> is not passed (making it bookmarkable).  When the user
>> clicks to go to the detail page, I want to pass that
>> filter along, so that when an edit is complete, the
>> page can redirect back to the list page with the same
>> filter intact.  I also want the detail page to be bookmarkable.
>>
>> If the detail page gets the filter, it simply passes it back.  If
>> not, that's fine too.
>>
>> I can accomplish this easily by creating a PageParameters:
>>
>> PageParameters parameters = new PageParameters();
>> parameters.put("filter", filter);
>>
>> BookmarkablePageLink link = new BookmarkablePageLink(name,
>> MyDetailPage.class, parameters);
>>
>> And this works fine.  But I don't like the way
>> the URL is created like this:
>>
>>
>> http://localhost/pages/MyDetailPage/item/20/filter/com.foo.bar.Filter%401ae6456/
>>
>> If the page is bookmarked, the Filter obj doesn't matter anyway.
>> I understand why it's there, I'm just trying to figure out a prettier
>> URL,
>> like
>> when I pass a parameter on the requestCycle, setting the response page
>> and passing the parameters obj in there.
>>
>> I've thought of overriding the onClick event for BookmarkablePageLink,
>> but
>> it's final.  Another option was to pass it on the request or the session.
>> That
>> would be the last option.
>>
>> Any insight would be appreciated.
>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Passing-Parameters-to-Bookmarkable-Page-tf4478593.html#a12770252
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Passing-Parameters-to-Bookmarkable-Page-tf4478593.html#a12802323
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: DropDownChoice Question

2007-09-20 Thread Clay Lehman
Hey John, Thanks for your advice, the example you gave me should handle
what I need to do.

-Clay

-Original Message-
From: John Krasnay [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 20, 2007 12:15 PM
To: users@wicket.apache.org
Subject: Re: DropDownChoice Question

On Thu, Sep 20, 2007 at 11:33:31AM -0400, Clay Lehman wrote:
> And I want to be able to add a DropDownChoice to my form that is
> something like this and have it automatically update Item.type in my
> model:
> 
>  
> 
>  public class EditItemForm extends Form{ 
> 
>
> 
> public EditItemForm(final String id, final Item item){
> 
> 
> super(id, new CompoundPropertyModel(item));
> 
>  
> 
> List choices = new ArrayList(); 
> 
> choices.add(new Options("1001","Choice1"));
> 
> choices.add(new Options("2004","Choice4"));
> 
> choices.add(new Options("305","Choice5"));
> 
> 
> 
> final DropDownChoice ddc = 
> 
> new DropDownChoice("ddc",new
> PropertyModel(theItem,"type"),choices,new
ChoiceRenderer("display","id")
> ); 
> 
> add(ddc);
> 
> }
> 
>  
> 
> public final void onSubmit(){
> 
> getRequestCycle().setRedirect(false);   
> 
> System.out.println("onSubmit() - theItem.type:
> "+theItem.type);
> 
> }
> 
> protected void validate(){
> 
> super.validate();
> 
> getRequestCycle().setRedirect(false);
> 
> }
> 
> }
> 

Hi Clay,

The trick with DropDownChoice that most people seem to miss is that the
objects that you put in the choices model must be of the same type as
the property you're setting. Since your property is a setting is a
String, you want to make your choices a list of the possible Strings to
which to set it. Try something like this...

final Map choiceMap = new HashMap();
choiceMap.put("1001", "Choice 1");
choiceMap.put("2004", "Choice 4");
choiceMap.put("305", "Choice 5");

List choices = new ArrayList();
choices.add("1001");
choices.add("2004");
choices.add("305");

DropDownChoice ddc = new DropDownChoice(
"ddc", 
new PropertyModel(theItem, "type"), 
choices,
new IChoiceRenderer() {
public Object getDisplayValue(Object object) {
return choiceMap.get(object.toString());
}
public String getIdValue(Object object, int index) {
return object.toString();
}
});

jk

-
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]



Embedding wicket in jsp error

2007-09-20 Thread hillj2

I know this has been discussed before, but none of the previous posts have
helped me solve my problem.  I'm trying to embed a wicket page into a jsp
page (until I have time go back and convert all our jsp's to wicket) using
the  tag.  oc4j throws a ServletException: Error in Servlet,
with no further information specifying the problem, nor any indication from
wicket that it's having a problem.  To isolate the problem I tried to
recreate it in a very small app, so I could rule out any issue with other
app code/configurations.  This time, I get a more informative (but not
necessarily more helpful) error message:

java.lang.IllegalStateException: Response has already been committed, be
sure not to write to the OutputStream or to trigger a commit due to any
other action before calling this method.

I'm hoping it's the same error in both cases, and the former case just has a
more generic error message for some reason; but I was hoping someone might
have a clue why I can't get the embedding to work.  I'm using oc4j 10.1.3.3,
and wicket beta2.  I tried it on Tomcat also.  It didn't throw an error, but
the place where the wicket content should be was just empty.

I'd prefer not to have to do this with embedded IFRAME's as I've seen
suggested.  That's the setup I have now, but when a page loads there's a
delay loading the IFRAME content, which doesn't look very nice, especially
since the embedded content is my app's navigation menu.  Any thoughts,
suggestions, alternate solutions to the embedding issue?

Here's the code from my small test app:

embed.jsp


 
  Embed test
 
 
  
  
  Here is my JSP content
 


EmbedServlet.java
==
public class EmbedServlet extends HttpServlet {

  public void doGet(HttpServletRequest request, HttpServletResponse
response)
throws ServletException, IOException {
doPost(request, response);
  }

  public void doPost(HttpServletRequest request, HttpServletResponse
response)
throws ServletException, IOException {

RequestDispatcher rd  =
request.getRequestDispatcher("/WEB-INF/jsp/embed.jsp");
rd.forward(request, response);

  }

}

EmbedApplication.java
=
public class EmbedApplication extends WebApplication {

  public EmbedApplication() {
super();
  }

  public Class getHomePage() {
return EmbedPage.class;
  }

  protected void init() {
System.out.println("* Wicket App initialized *");
  }

}

EmbedPage.java

public class EmbedPage extends WebPage {
  public EmbedPage() {
super();
  }
}

EmbedPage.html


 
  Embeded Wicket
 
 
  Here is my wicket content.
 


web.xml
==

http://java.sun.com/j2ee/dtds/web-app_2.2.dtd";>
http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"; version="2.5"
xmlns="http://java.sun.com/xml/ns/javaee";>
  
EmbedServlet
EmbedServlet
  
  
EmbedServlet
/main
  
  
EmbedApplication
   
org.apache.wicket.protocol.http.WicketServlet

  applicationClassName
  EmbedApplication

  
  
EmbedApplication
/wicket/*
  
  
35
  
  
html
text/html
  
  
txt
text/plain
  




Thanks,
Joel
-- 
View this message in context: 
http://www.nabble.com/Embedding-wicket-in-jsp-error-tf4488872.html#a12801646
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: Wicket shopping cart?

2007-09-20 Thread Tauren Mills
If I had to guess, most people who implement a custom shopping system
have some sort of unique need.  I'll start working on building
something from scratch.  I'll be using wicket/spring/hibernate to
build this.

If anyone has suggestions or ideas, I'd love to hear them.  Especially
when it comes to the entities involved and their relationships.  Maybe
I should start with the PetStore demo since I haven't looked at it
recently.  Are there any opinions on the quality of the petstore data
design (besides the yucky JSF technologies used)?

Thanks,
Tauren


On 9/19/07, Scott Swank <[EMAIL PROTECTED]> wrote:
> It's a little too idiosyncratic to be of wider use -- i.e. adult &
> child tickets to the same show should appear together, but with the
> adult tickets first.  There aren't any particular trade secrets in it,
> but it would likely be more work to generify (sp?) it than it would be
> to just write something from scratch.
>
> - Scott
>
>
> On 9/19/07, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > There has been some talk of building a pet store to compare it against
> > other frameworks (in good spirit though!). But both Eelco and I
> > haven't had the time to actually contribute to that project. The book
> > has our highest priority now.
> >
> > I think the biggest shopping cart currently online is vegas.com, but
> > I'm willing to bet an autographed Wicket in Action that they won't be
> > open sourcing that one anytime soon.
> >
> > Martijn
> >
> > On 9/20/07, Tauren Mills <[EMAIL PROTECTED]> wrote:
> > > Martijn,
> > >
> > > Great to hear!  I haven't bought the MEAP yet, but that's another
> > > great reason to!  Perhaps it would make a good starting point.  But
> > > still, if anyone has developed a more full featured solution and are
> > > interested in open sourcing it, I'd like to talk.
> > >
> > > Tauren
> > >
> > >
> > > On 9/19/07, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> > > > It seems that Wicket in Action has a basic shopping cart described. :-)
> > > >
> > > > Martijn
> > > >
> > > > On 9/19/07, Tauren Mills <[EMAIL PROTECTED]> wrote:
> > > > > I'm looking for an open source shopping cart built in wicket, but
> > > > > haven't found such a thing yet.  Does anyone know of something out
> > > > > there?
> > > > >
> > > > > I've noticed in several posts that people have been working on
> > > > > shopping solutions.  Are any of you willing to open source your
> > > > > solution?  Ultimately, I'd like to make an open source shopping cart
> > > > > available to the wicket community, but would rather not duplicate
> > > > > efforts if others would be interested in contributing any existing
> > > > > codebase.
> > > > >
> > > > > Thanks!
> > > > > Tauren
> > > > >
> > > > > -
> > > > > 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-beta3 is released
> > > > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta3/
> > > >
> > > > -
> > > > 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]
> > >
> > >
> >
> >
> > --
> > Buy Wicket in Action: http://manning.com/dashorst
> > Apache Wicket 1.3.0-beta3 is released
> > Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta3/
> >
> > -
> > 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: threading issues - continued

2007-09-20 Thread Eelco Hillenius
On 9/20/07, Sam Hough <[EMAIL PROTECTED]> wrote:
>
> Matej,
>
> Sorry for the delay. If you unzip the attached file into the root of src dir
> and point web.xml at TestWicketApplication it should work with 1.3-beta3. We
> have tested on FF2 and IE6 and breaks. Quickest way it to get focus on the
> button and hold down return.
>
> Please let me know if this is not in an easy format for you.
>
> Is slightly different from our real code as I update the whole form as I
> can't target RepeatingView but wanted to keep the code as slim as possible.
> http://www.nabble.com/file/p12794149/test.zip test.zip

It's probably a good idea to open a JIRA issue for this and attach the
zip to that.

Eelco

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



Re: How to add RadioGroup column to DataTable?

2007-09-20 Thread Igor Vaynberg
create a panel, and put the radiogroup in to it. then extend abstractcolumn
and in populatecolumn create the instance of your panel and add it.

-igor


On 9/20/07, Kevin Liu <[EMAIL PROTECTED]> wrote:
>
> Hi!
>
>   Could you tell me how to add RadioGroup column to DataTable ?
>
>   Thank you very much!
>
>
> -Kevin Liu
>
> -
> Be a better Heartthrob. Get better relationship answers from someone who
> knows.
> Yahoo! Answers - Check it out.


Re: WebSession shutdown

2007-09-20 Thread Eelco Hillenius
> The trouble is that the lifecycle of a Wicket WebSession object is not the 
> same as the HTTPSession. When a session is temporary only, you never get a 
> valueUnbound() callback. I'll have to move the resource manager 
> initialization into the valueBound() method; inconvenient but not a problem 
> per se.

Ah yeah, but temporary sessions are volatile anyway. You could
implement a custom request cycle that in onEndRequest checks whether
the session is temporary, and if so, let it call the cleanup method.

> My second objection is that this works, as you said, with the default 
> implmentation of ISessionStore. I would introduce a dependency on the exact 
> implementation of ISessionStore used, not any published API. That somehow 
> fills me with sombre premonitions ;-)
> I still think it would be nice if org.apache.wicket.Session had a proper 
> lifecycle (à la WebApplication.onDestroy()). Should I file a feature request 
> or start a conversation on the dev list?

Sure, you can start a discussion on the dev list, and filing a JIRA
issue makes that it will be a more persistent discussion topic. Having
it here is fine too though.

I'm not sure whether depending on the Session object being put in the
HttpSession is bad for you though. If you are not using that, it
probably means you're working with a custom session store in which
case you could just make sure your cleanup callback gets called by
that, right?

Eelco

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



Re: FilterToolbar

2007-09-20 Thread Tauren Mills
Evan,

See wicket-phonebook in wicket-stuff.

Tauren

On 9/20/07, Evan Chooly <[EMAIL PROTECTED]> wrote:
> Apparently the API between beta3 and the latest SNAPSHOT changed for
> FilterToolbar and now it needs a FilterForm.  I can't find any examples (not
> even unit tests) that show how I should build my page/table with this new
> API.  Does anyone have an example working with the latest code?  Thanks.
>

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



Re: Passing Parameters to Bookmarkable Page

2007-09-20 Thread Evan Chooly
Put the Filter ID in the map.

On 9/18/07, Flavius <[EMAIL PROTECTED]> wrote:
>
>
> I have two pages, a list page and a detail.  The list page
> can take a filter parameter, or has a default one if one
> is not passed (making it bookmarkable).  When the user
> clicks to go to the detail page, I want to pass that
> filter along, so that when an edit is complete, the
> page can redirect back to the list page with the same
> filter intact.  I also want the detail page to be bookmarkable.
>
> If the detail page gets the filter, it simply passes it back.  If
> not, that's fine too.
>
> I can accomplish this easily by creating a PageParameters:
>
> PageParameters parameters = new PageParameters();
> parameters.put("filter", filter);
>
> BookmarkablePageLink link = new BookmarkablePageLink(name,
> MyDetailPage.class, parameters);
>
> And this works fine.  But I don't like the way
> the URL is created like this:
>
>
> http://localhost/pages/MyDetailPage/item/20/filter/com.foo.bar.Filter%401ae6456/
>
> If the page is bookmarked, the Filter obj doesn't matter anyway.
> I understand why it's there, I'm just trying to figure out a prettier URL,
> like
> when I pass a parameter on the requestCycle, setting the response page
> and passing the parameters obj in there.
>
> I've thought of overriding the onClick event for BookmarkablePageLink, but
> it's final.  Another option was to pass it on the request or the session.
> That
> would be the last option.
>
> Any insight would be appreciated.
>
>
> --
> View this message in context:
> http://www.nabble.com/Passing-Parameters-to-Bookmarkable-Page-tf4478593.html#a12770252
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


FilterToolbar

2007-09-20 Thread Evan Chooly
Apparently the API between beta3 and the latest SNAPSHOT changed for
FilterToolbar and now it needs a FilterForm.  I can't find any examples (not
even unit tests) that show how I should build my page/table with this new
API.  Does anyone have an example working with the latest code?  Thanks.


Re: DropDownChoice Question

2007-09-20 Thread John Krasnay
On Thu, Sep 20, 2007 at 11:33:31AM -0400, Clay Lehman wrote:
> And I want to be able to add a DropDownChoice to my form that is
> something like this and have it automatically update Item.type in my
> model:
> 
>  
> 
>  public class EditItemForm extends Form{ 
> 
>
> 
> public EditItemForm(final String id, final Item item){
> 
> 
> super(id, new CompoundPropertyModel(item));
> 
>  
> 
> List choices = new ArrayList(); 
> 
> choices.add(new Options("1001","Choice1"));
> 
> choices.add(new Options("2004","Choice4"));
> 
> choices.add(new Options("305","Choice5"));
> 
> 
> 
> final DropDownChoice ddc = 
> 
> new DropDownChoice("ddc",new
> PropertyModel(theItem,"type"),choices,new ChoiceRenderer("display","id")
> ); 
> 
> add(ddc);
> 
> }
> 
>  
> 
> public final void onSubmit(){
> 
> getRequestCycle().setRedirect(false);   
> 
> System.out.println("onSubmit() - theItem.type:
> "+theItem.type);
> 
> }
> 
> protected void validate(){
> 
> super.validate();
> 
> getRequestCycle().setRedirect(false);
> 
> }
> 
> }
> 

Hi Clay,

The trick with DropDownChoice that most people seem to miss is that the
objects that you put in the choices model must be of the same type as
the property you're setting. Since your property is a setting is a
String, you want to make your choices a list of the possible Strings to
which to set it. Try something like this...

final Map choiceMap = new HashMap();
choiceMap.put("1001", "Choice 1");
choiceMap.put("2004", "Choice 4");
choiceMap.put("305", "Choice 5");

List choices = new ArrayList();
choices.add("1001");
choices.add("2004");
choices.add("305");

DropDownChoice ddc = new DropDownChoice(
"ddc", 
new PropertyModel(theItem, "type"), 
choices,
new IChoiceRenderer() {
public Object getDisplayValue(Object object) {
return choiceMap.get(object.toString());
}
public String getIdValue(Object object, int index) {
return object.toString();
}
});

jk

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



Re: Amsterdam Wicket course; October 6-7

2007-09-20 Thread Reinout van Schouwen
Op dinsdag 18-09-2007 om 16:49 uur [tijdzone -0700], schreef jweekend:

> If anyone would like this to happen, and we can find a suitable host, Al,
> who develops and delivers the course, and I can both make the weekend of
> October 6-7. The course is "Apache Wicket 1.3" (JW703) and the details are 
> http://jweekend.co.uk/dev/JW703 here .

Depending a bit on price, I'd be interested in attending. (Although I
had planned to visit Software Freedom Day[1] on Oct. 6th...)

> PS If you would like to host the course in Amsterdam please contact us to
> discuss details.

ALthough it's one hour traveling away from Amsterdam, I could probably
arrange something in Rotterdam if needed.

[1] http://www.nllgg.nl/softwarefreedomday_2007

regards,

-- 
Reinout van Schouwen




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



DropDownChoice Question

2007-09-20 Thread Clay Lehman
Hey everyone,

 

I am relatively new to using Wicket, and I have a question about using
DropDownChoice's to put a select box on a form.  

 

I want to display choices which have specific ID values for each option
(instead of indexed choices, like most examples I see), and I want to
update a String variable in the object that I am editing based on the ID
that is selected.  I basically want a DropDownChoice that works like a
TextField, where the value updated in the Model is the ID of the
selected option.

 

I created the following SelectChoice class so that I can create choices,
and render them with new ChoiceRenderer("id","value")...

 

public class SelectChoice implements Serializable {

public String id;

public String display;

public SelectChoice (String id, String display){

this.id=id;

this.display=display;

}

}

 

This allows me to properly display the data, but now I get class cast
exceptions, unless the model that I pass in has a SelectOption as its
object.  

 

My main question: 

Is there an easy way to extend/customize the DropDownChoice component,
so that it renders choices from a class like SelectChoice, which has an
id / displayValue pair, but allows me to use a simple PropertyModel as
my model, which updates a String variable with the results of selecting
a choice from the dropdown?

 

For Example I have the an Item class to handle the data: 

 

private static class Item implements Serializable{

private String itemid;

private String name;

private String description;

private String type;

private Collection groups;



public Item(String itemid, String name, String
description,String type,Collection groups){

this.itemid=itemid;

this.name=name;

this.description=description;

this.type=type;

this.groups=groups;

}

}

 

And I want to be able to add a DropDownChoice to my form that is
something like this and have it automatically update Item.type in my
model:

 

 public class EditItemForm extends Form{ 

   

public EditItemForm(final String id, final Item item){


super(id, new CompoundPropertyModel(item));

 

List choices = new ArrayList(); 

choices.add(new Options("1001","Choice1"));

choices.add(new Options("2004","Choice4"));

choices.add(new Options("305","Choice5"));



final DropDownChoice ddc = 

new DropDownChoice("ddc",new
PropertyModel(theItem,"type"),choices,new ChoiceRenderer("display","id")
); 

add(ddc);

}

 

public final void onSubmit(){

getRequestCycle().setRedirect(false);   

System.out.println("onSubmit() - theItem.type:
"+theItem.type);

}

protected void validate(){

super.validate();

getRequestCycle().setRedirect(false);

}

}

 

 

Thanks in advance for any pointers!!

-Clay 

 



Ajax Problem on Page with IFRAME

2007-09-20 Thread SantiagoA

Hallo,
I have a Problem with AJAX functionality. 
I have some InputFields which have an Ajax based refresh
(onUpdate(AjaxRequestTarget target)) like an inputField for birthdate and
one for "AgeInYears". If a birthdate is commited, the Field "AgeInYears"
will be refreshed.
There are some TabPanels on this site, also.
One of them has an IFrame.
If this TabbedPanel is active, then the onUpdate-Methode of the InputFields
won´t be reached.
Is one of the TabbedPanels without an IFrame active, everything works fine.
This happens that way for IE and Firefox.
For Opera i got one Problem more, if the user changes the birthdate, while
the IFrame-panel is active the above written happens too and in addition no
other Panel can be activated by clicking anymore.

Is this a known problem with AJAX and IFrames, or am I doing something
terribly wrong.

Thanks for any help,
Santiago
-- 
View this message in context: 
http://www.nabble.com/Ajax-Problem-on-Page-with-IFRAME-tf4487902.html#a12798348
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: best practice

2007-09-20 Thread Martijn Dashorst
I learnt a lot of the datatable and its cousins. Try building your own
toolbar and column implementation, then you'll see some very elegant
code IMO.

The wicket-examples are a good source, as is the phonebook
application. Of course you could look at the wicket in action sources
(http://wicketinaction.googlecode.com), but you may miss some context
to appreciate the examples.

The Wiki has links to a couple of open source products that use Wicket
as their basis. One is jtrac (jtrac.info), I think Thies Edeling is
also working on some open source time tracking management product.

http://cwiki.apache.org/WICKET/#Index-OtherprojectsrelatedtoWicket

Martijn

On 9/20/07, Sam Hough <[EMAIL PROTECTED]> wrote:
>
> Where is the best place to look for examples of best practice component
> development? I'm falling into my own strange GWT style that probably isn't
> very wicket friendly. Which is probably why I'm struggling to enjoy having
> HTML and components.
>
> Anybody point at any part of wicket.jar or wicket-extensions.jar etc that
> they think I should study to get more into the Wicket way of doing things?
>
>
> --
> View this message in context: 
> http://www.nabble.com/best-practice-tf4487826.html#a12798065
> 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-beta3 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta3/

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



best practice

2007-09-20 Thread Sam Hough

Where is the best place to look for examples of best practice component
development? I'm falling into my own strange GWT style that probably isn't
very wicket friendly. Which is probably why I'm struggling to enjoy having
HTML and components.

Anybody point at any part of wicket.jar or wicket-extensions.jar etc that
they think I should study to get more into the Wicket way of doing things?


-- 
View this message in context: 
http://www.nabble.com/best-practice-tf4487826.html#a12798065
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: Wicket consulting/contracting/outsourcing

2007-09-20 Thread skatz

Boston, MA


Dan Syrstad-2 wrote:
> 
> In what area of the world and what are you looking to do?
> -Dan
> 
> On 9/18/07, skatz <[EMAIL PROTECTED]> wrote:
>>
>>
>> Hi,
>>
>> Can anyone provide me with pointers to individuals or companies providing
>> Wicket consulting/contracting or outsourced personnel?
>>
>> TIA,
>>
>> skatz
>> --
>> View this message in context:
>> http://www.nabble.com/Wicket-consulting-contracting-outsourcing-tf4476525.html#a12764265
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Wicket-consulting-contracting-outsourcing-tf4476525.html#a12797023
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: Enums and DropDownChoices in Web Beans

2007-09-20 Thread dtoffe

For most cases, the PropertyChangeEvents are ok. But now I'm facing a
particular problem and I guess I'm trying to use the wrong tool for the
task.
Let's say I have a bean with two properties and I want to show them as
dropdownchoices, but they are related, think for example of the CarMake,
CarModel, or Country, State pairs, where the first value determines a subset
of possibilities for the second value.
I would like to select the first value, and have the second
dropdownchoice to get filtered by the possible values. How should I face
such a situation ?  I guess having the second dropdownchoice based on an
enum is not correct, since I only want a (non necessarily contiguous) subset
of values to be allowed.

Thanks for your help !

Daniel



Dan Syrstad-2 wrote:
> 
> I assume your real-life case is more involved than just calling info().
> See
> the Introduction/Getting Started documentation at
> http://wicketwebbeans.sourceforge.net for an examples on how to implement
> PropertyChangeEvents and how to do #2 above.
> 

-- 
View this message in context: 
http://www.nabble.com/Enums-and-DropDownChoices-in-Web-Beans-tf4481885.html#a12796948
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: Page expiration

2007-09-20 Thread Swaroop Belur
We are facing the same problem here - but its only with jetty and not with
tomcat.
After a re login everything seems to work fine. Its only the first time.
(i guess the resource was loaded the next time.) The problem
however does not occur with tomcat.

-swaroop

On 9/20/07, Holda, Dariusz <[EMAIL PROTECTED]> wrote:
>
>
> I don't have but from time to time I'm getting this error:
> "ERROR
> Unable to render resource stream
> jar:file:/vendor/Wicket_ext/1.2.6/wicket-extensions-1.2.6.jar!/wicket/ex
> tensions/markup/html/datepicker/style/aqua/menuarrow.gifwicket.WicketRun
> timeException: Unable to render resource stream
> jar:file:/vendor/Wicket_ext/1.2.6/wicket-extensions-1.2.6.jar!/wicket/ex
> tensions/markup/html/datepicker/style/aqua/menuarrow.gif "
>
> Could this be the cause of the problem?
>
> Thx,
> Dariusz
>
> -Original Message-
> From: Dipu Seminlal [mailto:[EMAIL PROTECTED]
> Sent: 20 September 2007 13:03
> To: users@wicket.apache.org
> Subject: Re: Page expiration
>
> Hi,
>
> Can you please check if you have any img tags in your html with empty
> src
> attributes ?
>
> Regards
> Dipu
>
> On 9/20/07, Holda, Dariusz <[EMAIL PROTECTED]> wrote:
> >
> >
> > Hi,
> > I've came across a strange behaviour. I'm running Wicket app on Jetty
> > server and most of the times it's working fine but from time to time
> I'm
> > getting "Page expired" message even if user is actively using the app.
> > Unfortunately it's not happening on the same events. Sometimes it's
> > after pressing 'Save' after choosing a date in DatePicker, sometimes
> > it's happening after clicking on a different tab after editing a
> > textfield.
> > Anyone has an idea what may be the cause of this problem?
> > I'm using wicket-1.2.6 and each of the editable fields has an Ajax
> > behaviour.
> >
> > Thx,
> > Dariusz
> > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> - -
> > - - - - - - -
> >
> > This message is intended only for the personal and confidential use of
> the
> > designated recipient(s) named above.  If you are not the intended
> recipient
> > of this message you are hereby notified that any review,
> dissemination,
> > distribution or copying of this message is strictly prohibited.  This
> > communication is for information purposes only and should not be
> regarded as
> > an offer to sell or as a solicitation of an offer to buy any financial
> > product, an official confirmation of any transaction, or as an
> official
> > statement of Lehman Brothers.  Email transmission cannot be guaranteed
> to be
> > secure or error-free.  Therefore, we do not represent that this
> information
> > is complete or accurate and it should not be relied upon as such.  All
> > information is subject to change without notice.
> >
> >
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> - - - - - - -
>
> This message is intended only for the personal and confidential use of the
> designated recipient(s) named above.  If you are not the intended recipient
> of this message you are hereby notified that any review, dissemination,
> distribution or copying of this message is strictly prohibited.  This
> communication is for information purposes only and should not be regarded as
> an offer to sell or as a solicitation of an offer to buy any financial
> product, an official confirmation of any transaction, or as an official
> statement of Lehman Brothers.  Email transmission cannot be guaranteed to be
> secure or error-free.  Therefore, we do not represent that this information
> is complete or accurate and it should not be relied upon as such.  All
> information is subject to change without notice.
>
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


RE: Page expiration

2007-09-20 Thread Holda, Dariusz

I don't have but from time to time I'm getting this error:
"ERROR
Unable to render resource stream
jar:file:/vendor/Wicket_ext/1.2.6/wicket-extensions-1.2.6.jar!/wicket/ex
tensions/markup/html/datepicker/style/aqua/menuarrow.gifwicket.WicketRun
timeException: Unable to render resource stream
jar:file:/vendor/Wicket_ext/1.2.6/wicket-extensions-1.2.6.jar!/wicket/ex
tensions/markup/html/datepicker/style/aqua/menuarrow.gif "

Could this be the cause of the problem?

Thx,
Dariusz

-Original Message-
From: Dipu Seminlal [mailto:[EMAIL PROTECTED] 
Sent: 20 September 2007 13:03
To: users@wicket.apache.org
Subject: Re: Page expiration

Hi,

Can you please check if you have any img tags in your html with empty
src
attributes ?

Regards
Dipu

On 9/20/07, Holda, Dariusz <[EMAIL PROTECTED]> wrote:
>
>
> Hi,
> I've came across a strange behaviour. I'm running Wicket app on Jetty
> server and most of the times it's working fine but from time to time
I'm
> getting "Page expired" message even if user is actively using the app.
> Unfortunately it's not happening on the same events. Sometimes it's
> after pressing 'Save' after choosing a date in DatePicker, sometimes
> it's happening after clicking on a different tab after editing a
> textfield.
> Anyone has an idea what may be the cause of this problem?
> I'm using wicket-1.2.6 and each of the editable fields has an Ajax
> behaviour.
>
> Thx,
> Dariusz
> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- -
> - - - - - - -
>
> This message is intended only for the personal and confidential use of
the
> designated recipient(s) named above.  If you are not the intended
recipient
> of this message you are hereby notified that any review,
dissemination,
> distribution or copying of this message is strictly prohibited.  This
> communication is for information purposes only and should not be
regarded as
> an offer to sell or as a solicitation of an offer to buy any financial
> product, an official confirmation of any transaction, or as an
official
> statement of Lehman Brothers.  Email transmission cannot be guaranteed
to be
> secure or error-free.  Therefore, we do not represent that this
information
> is complete or accurate and it should not be relied upon as such.  All
> information is subject to change without notice.
>
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
- - - -

This message is intended only for the personal and confidential use of the 
designated recipient(s) named above.  If you are not the intended recipient of 
this message you are hereby notified that any review, dissemination, 
distribution or copying of this message is strictly prohibited.  This 
communication is for information purposes only and should not be regarded as an 
offer to sell or as a solicitation of an offer to buy any financial product, an 
official confirmation of any transaction, or as an official statement of Lehman 
Brothers.  Email transmission cannot be guaranteed to be secure or error-free.  
Therefore, we do not represent that this information is complete or accurate 
and it should not be relied upon as such.  All information is subject to change 
without notice.




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



Re: ModalWindow bug - unable to close when added AjaxButton in content of the window

2007-09-20 Thread Vit Rozkovec
Yes, the form validates, I put the breakpoint at onSubmit and that 
method was invoked.

I tried it also with empty form.
The behavior is following:
when I have only AjaxLinks in the form, it is ok.
When I add AjaxButton, the behavior changes - the first time the modal 
window is displayed, it is possible to close the window with the cross 
in the upper right corner and with any AjaxLink I have in the form. But 
only when the first click goes to one of these elements.
When I first click on the button to close the window, suddently the 
cross and the links became dead too.


Vitek

Matej Knopp wrote:

Are you sure your Form validates, when you click AjaxLink? Because
otherwise the onSubmit is not invoked. Can you put a breakpoint in
onSubmit? Also there is onError handler that is invoked when form
validation fails.

-Matej

On 9/14/07, Vit Rozkovec <[EMAIL PROTECTED]> wrote:
  

I am sorry, I could not replicate it in quickstart. The button works
fine there. For now I solved the problem by replacing AjaxButtons with
AjaxLinks.

Vitek

Matej Knopp wrote:


Plase create a jira issue and attach a quickstart to it. Thanks.

-Matej

On 9/13/07, Vit Rozkovec <[EMAIL PROTECTED]> wrote:

  

Good day,
I am using last snapshot of wicket and there is a problem with modal
window - I create instance of the window and add it to the page. As a
content I use a panel which has these components:

public class ModalConfirmationPanel extends Panel {

public ModalConfirmationPanel(String id, final ModalWindow window) {
super(id);

window.setTitle(getString("titulek"));

Form form = new Form("confirmation");
add(form);
form.add(new TextArea("explanation", new Model("")));
form.add(new AjaxLink("ok") {
@Override
public void onClick(AjaxRequestTarget target) {
window.close(target);
}
});
form.add(new AjaxLink("storno") {
@Override
public void onClick(AjaxRequestTarget target) {
window.close(target);
}
});
//form.add(new AjaxSubmitButton("buttonOk", form) {
//@Override
//protected void onSubmit(AjaxRequestTarget target, Form form) {
//window.close(target);
//}
//});
//form.add(new AjaxButton("buttonStorno", form) {
//@Override
//protected void onSubmit(AjaxRequestTarget target, Form form) {
//window.close(target);
//}
//});


When I uncomment the lines and add AjaxSubmitButtons or AjaxButtons, the
modal window cannot be closed anymore, neither with the buttons, nor
with the close button in the header or with links. When I add just
links, it works ok. It does not matter if there is window.close() method
in the button's onSubmit method.

If you would like I can make a quickstart. I cannot test anymore, but in
beta3 it worked.

Vitek

-
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: Page expiration

2007-09-20 Thread Dipu Seminlal
Hi,

Can you please check if you have any img tags in your html with empty src
attributes ?

Regards
Dipu

On 9/20/07, Holda, Dariusz <[EMAIL PROTECTED]> wrote:
>
>
> Hi,
> I've came across a strange behaviour. I'm running Wicket app on Jetty
> server and most of the times it's working fine but from time to time I'm
> getting "Page expired" message even if user is actively using the app.
> Unfortunately it's not happening on the same events. Sometimes it's
> after pressing 'Save' after choosing a date in DatePicker, sometimes
> it's happening after clicking on a different tab after editing a
> textfield.
> Anyone has an idea what may be the cause of this problem?
> I'm using wicket-1.2.6 and each of the editable fields has an Ajax
> behaviour.
>
> Thx,
> Dariusz
> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> - - - - - - -
>
> This message is intended only for the personal and confidential use of the
> designated recipient(s) named above.  If you are not the intended recipient
> of this message you are hereby notified that any review, dissemination,
> distribution or copying of this message is strictly prohibited.  This
> communication is for information purposes only and should not be regarded as
> an offer to sell or as a solicitation of an offer to buy any financial
> product, an official confirmation of any transaction, or as an official
> statement of Lehman Brothers.  Email transmission cannot be guaranteed to be
> secure or error-free.  Therefore, we do not represent that this information
> is complete or accurate and it should not be relied upon as such.  All
> information is subject to change without notice.
>
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Page expiration

2007-09-20 Thread Holda, Dariusz

Hi,
I've came across a strange behaviour. I'm running Wicket app on Jetty
server and most of the times it's working fine but from time to time I'm
getting "Page expired" message even if user is actively using the app.
Unfortunately it's not happening on the same events. Sometimes it's
after pressing 'Save' after choosing a date in DatePicker, sometimes
it's happening after clicking on a different tab after editing a
textfield. 
Anyone has an idea what may be the cause of this problem?
I'm using wicket-1.2.6 and each of the editable fields has an Ajax
behaviour.

Thx,
Dariusz
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
- - - -

This message is intended only for the personal and confidential use of the 
designated recipient(s) named above.  If you are not the intended recipient of 
this message you are hereby notified that any review, dissemination, 
distribution or copying of this message is strictly prohibited.  This 
communication is for information purposes only and should not be regarded as an 
offer to sell or as a solicitation of an offer to buy any financial product, an 
official confirmation of any transaction, or as an official statement of Lehman 
Brothers.  Email transmission cannot be guaranteed to be secure or error-free.  
Therefore, we do not represent that this information is complete or accurate 
and it should not be relied upon as such.  All information is subject to change 
without notice.




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



Re: New Wicket Portlets Demo available

2007-09-20 Thread Ate Douma

Gwyn Evans wrote:

Probably fairly soon - we've been looking at the changes and
discussing it on the dev list, to try & get an idea if it'll cause a
significant delay with regards to the aim of getting a 1.3 release out
ASAP.  Currently, however, I think the view is that it'll be likely to
be in and we'll do a beta4, then see how it looks.

I think I saw some comment about some rebuilding work of Ate's house -
I don't know any more than that, but if he's quiet for a bit, that
might explain it!

Although that is going to take some of my time away the next 3 months, I still 
be online/able to answer questions normally on a daily basis :)



In the meantime, you could get the baseline code from SVN
(http://svn.apache.org/repos/asf/wicket/tags/wicket-1.3.0-beta3),
apply the patch from the jira issue
https://issues.apache.org/jira/secure/attachment/12366048/wicket-1.3.0-beta3-portlet-support.patch
and build your own copy if you want to have a look prior to that.
(Build with tests disabled "mvn -Dmaven.test.skip=true install" as the
patch missed changing a particular test expectation)

I've just committed a fix for that test case.

Sorry I missed it out but then it didn't fail on me on my own machine (weird!).

Ate



/Gwyn

On Thursday, September 20, 2007, 10:20:23 AM, Dipu <[EMAIL PROTECTED]> wrote:


Hi Ate,



I'm interested in the portlet support which you have implemented in wicket.



Any idea when it might be merged into the trunk?



Regards
Dipu




On 9/17/07, Ate Douma <[EMAIL PROTECTED]> wrote:

I'm really happy to announce that a new and quite feature complete Wicket
Portlets Demo is now available for download at:


http://people.apache.org/~ate/wicket/jetspeed-2.1.3-dev-wicket-demo-installer.jar

I've worked hard the last few weeks to improve the Wicket portlet support
branch and it can now run all Wicket Examples natively as portlet!
See also IRA issue WICKET-658 at
http://issues.apache.org/jira/browse/WICKET-658#action_12528082 where I
have provided more information how to install and use
this demo.

Although there probably are still some minor issues here and there, the
demo will show that portlet development using Wicket is now very much
feasible.

I'd like to invite anyone interested to try out the demo and see it in
action for yourself, and of course please report any encountered
issue/problems to the
dev list.

I've developed the portlet support based on the 1.3.0-beta3 release (with
few minor bugfixes ported back from the trunk), so although the trunk
development has
progressed at it usual aggressive speed, updating the portlet-support to
the latest Wicket trunk shouldn't be too much work (that is: right now!).

As we would like to start using Wicket for a rewrite of the Jetspeed-2
administration portlets *now*, it would be great if the portlet support can
be
incorporated into the trunk as soon as possible. Delaying this until after
the 1.3.0 release would mean being out-of-sync with the main wicket trunk
development
all the time and a lot of work each time we want/need to bring it back in
sync.

Initially, back in May this year, my idea was waiting with merging the
portlet support in the trunk to after the 1.3.0 release.
But as 1.3.0 still isn't released yet and still in beta phase, it would be
much better to merge now otherwise the portlet-support will be constantly
out-of-sync
with the main wicket trunk development, causing a lot of effort each time
we want (or need) to bring it back in sync.

For Jetspeed-2, we would very much like to start using Wicket for a
rewrite of the Jetspeed-2 administration portlet *now*. Having towait until
after the 1.3.0
release, or be dependent on unofficial builds from the portlet-support
branch would be less ideal to say the least.
Other parties, like my own company, already have started using the Wicket
portlet-support branch, so having to delay the merge to trunk really
wouldn't be fun.

AFAICS though, the impact of merging the portlet-support to trunk won't be
big.
I had to make a few (internal) changes in the wicket core, but I don't
think those will have functional side-effects.

To make it easier for the other committers to decide if we can merge the
portlet-support to trunk now, I will create a new JIRA issue for it.
For the changes needed to the current Wicket trunk I'll create separate
patches with explanations why and attach those to that issue.
(note: most of these changes I already described in detail under subtasks
of the WICKET-647 issue).
We can then discuss these changes individually and if need be see if
alternative solutions are possible.
After those changes are reviewed and accepted, the portlet support then
can be merged to the trunk.

WDYT?

Regards,

Ate




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






/Gwyn


-
To unsubscribe, e-mail: [EMAIL 

Re: New Wicket Portlets Demo available

2007-09-20 Thread Gwyn Evans
On Thursday, September 20, 2007, 10:50:30 AM, Ate <[EMAIL PROTECTED]> wrote:

> I've proposed to merge this into trunk now (before -beta4 release),
> but this hasn't been decided or voted upon yet.

Well, you can now vote on it, at least! :-)

/Gwyn


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



RE: WebSession shutdown

2007-09-20 Thread Maeder Thomas
Thanks Eelco, but...

The trouble is that the lifecycle of a Wicket WebSession object is not the same 
as the HTTPSession. When a session is temporary only, you never get a 
valueUnbound() callback. I'll have to move the resource manager initialization 
into the valueBound() method; inconvenient but not a problem per se.
My second objection is that this works, as you said, with the default 
implmentation of ISessionStore. I would introduce a dependency on the exact 
implementation of ISessionStore used, not any published API. That somehow fills 
me with sombre premonitions ;-)
I still think it would be nice if org.apache.wicket.Session had a proper 
lifecycle (à la WebApplication.onDestroy()). Should I file a feature request or 
start a conversation on the dev list?

Thomas

> -Original Message-
> From: Eelco Hillenius [mailto:[EMAIL PROTECTED] 
> Sent: Donnerstag, 20. September 2007 02:39
> To: users@wicket.apache.org
> Subject: Re: WebSession shutdown
> 
> > In our WebSession subclass we manage some resources which 
> need to be 
> > cleaned up when the session goes away (because of timeout, etc). Is 
> > there a recommended way to call a "shutdown()" method on 
> our session 
> > class? I have seen WebApplication.sessionDestroyed(String), but I'm 
> > not sure how to get the wicket session from there (since we don't 
> > necessarily have an active request at that time). Of 
> course, I could 
> > implement my own session store or something like that, but that 
> > approach seems to be a bit hackish.
> 
> As long as you are putting the Wicket Session object in your 
> HttpSession (like the default session stores do) I think you 
> should be able to just let your session class inplement 
> HttpSessionBindingListener and react on valueUnbound. Can you 
> try that and let the list know whether that worked for you?
> 
> 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]



Re: New Wicket Portlets Demo available

2007-09-20 Thread Dipu Seminlal
Thanks Gwyn


Regards
Dipu

On 9/20/07, Gwyn Evans <[EMAIL PROTECTED]> wrote:
>
> Probably fairly soon - we've been looking at the changes and
> discussing it on the dev list, to try & get an idea if it'll cause a
> significant delay with regards to the aim of getting a 1.3 release out
> ASAP.  Currently, however, I think the view is that it'll be likely to
> be in and we'll do a beta4, then see how it looks.
>
> I think I saw some comment about some rebuilding work of Ate's house -
> I don't know any more than that, but if he's quiet for a bit, that
> might explain it!
>
> In the meantime, you could get the baseline code from SVN
> (http://svn.apache.org/repos/asf/wicket/tags/wicket-1.3.0-beta3),
> apply the patch from the jira issue
>
> https://issues.apache.org/jira/secure/attachment/12366048/wicket-1.3.0-beta3-portlet-support.patch
> and build your own copy if you want to have a look prior to that.
> (Build with tests disabled "mvn -Dmaven.test.skip=true install" as the
> patch missed changing a particular test expectation)
>
> /Gwyn
>
> On Thursday, September 20, 2007, 10:20:23 AM, Dipu <
> [EMAIL PROTECTED]> wrote:
>
> > Hi Ate,
>
> > I'm interested in the portlet support which you have implemented in
> wicket.
>
> > Any idea when it might be merged into the trunk?
>
> > Regards
> > Dipu
>
>
> > On 9/17/07, Ate Douma <[EMAIL PROTECTED]> wrote:
> >>
> >> I'm really happy to announce that a new and quite feature complete
> Wicket
> >> Portlets Demo is now available for download at:
> >>
> >>
> >>
> http://people.apache.org/~ate/wicket/jetspeed-2.1.3-dev-wicket-demo-installer.jar
> >>
> >> I've worked hard the last few weeks to improve the Wicket portlet
> support
> >> branch and it can now run all Wicket Examples natively as portlet!
> >> See also IRA issue WICKET-658 at
> >> http://issues.apache.org/jira/browse/WICKET-658#action_12528082 where I
> >> have provided more information how to install and use
> >> this demo.
> >>
> >> Although there probably are still some minor issues here and there, the
> >> demo will show that portlet development using Wicket is now very much
> >> feasible.
> >>
> >> I'd like to invite anyone interested to try out the demo and see it in
> >> action for yourself, and of course please report any encountered
> >> issue/problems to the
> >> dev list.
> >>
> >> I've developed the portlet support based on the 1.3.0-beta3 release
> (with
> >> few minor bugfixes ported back from the trunk), so although the trunk
> >> development has
> >> progressed at it usual aggressive speed, updating the portlet-support
> to
> >> the latest Wicket trunk shouldn't be too much work (that is: right
> now!).
> >>
> >> As we would like to start using Wicket for a rewrite of the Jetspeed-2
> >> administration portlets *now*, it would be great if the portlet support
> can
> >> be
> >> incorporated into the trunk as soon as possible. Delaying this until
> after
> >> the 1.3.0 release would mean being out-of-sync with the main wicket
> trunk
> >> development
> >> all the time and a lot of work each time we want/need to bring it back
> in
> >> sync.
> >>
> >> Initially, back in May this year, my idea was waiting with merging the
> >> portlet support in the trunk to after the 1.3.0 release.
> >> But as 1.3.0 still isn't released yet and still in beta phase, it would
> be
> >> much better to merge now otherwise the portlet-support will be
> constantly
> >> out-of-sync
> >> with the main wicket trunk development, causing a lot of effort each
> time
> >> we want (or need) to bring it back in sync.
> >>
> >> For Jetspeed-2, we would very much like to start using Wicket for a
> >> rewrite of the Jetspeed-2 administration portlet *now*. Having towait
> until
> >> after the 1.3.0
> >> release, or be dependent on unofficial builds from the portlet-support
> >> branch would be less ideal to say the least.
> >> Other parties, like my own company, already have started using the
> Wicket
> >> portlet-support branch, so having to delay the merge to trunk really
> >> wouldn't be fun.
> >>
> >> AFAICS though, the impact of merging the portlet-support to trunk won't
> be
> >> big.
> >> I had to make a few (internal) changes in the wicket core, but I don't
> >> think those will have functional side-effects.
> >>
> >> To make it easier for the other committers to decide if we can merge
> the
> >> portlet-support to trunk now, I will create a new JIRA issue for it.
> >> For the changes needed to the current Wicket trunk I'll create separate
> >> patches with explanations why and attach those to that issue.
> >> (note: most of these changes I already described in detail under
> subtasks
> >> of the WICKET-647 issue).
> >> We can then discuss these changes individually and if need be see if
> >> alternative solutions are possible.
> >> After those changes are reviewed and accepted, the portlet support then
> >> can be merged to the trunk.
> >>
> >> WDYT?
> >>
> >> Regards,
> >>
> >> Ate
> >>
> >>
> >>
> >>
> >> 

Re: threading issues - continued

2007-09-20 Thread Sam Hough

Matej,

Sorry for the delay. If you unzip the attached file into the root of src dir
and point web.xml at TestWicketApplication it should work with 1.3-beta3. We
have tested on FF2 and IE6 and breaks. Quickest way it to get focus on the
button and hold down return.

Please let me know if this is not in an easy format for you.

Is slightly different from our real code as I update the whole form as I
can't target RepeatingView but wanted to keep the code as slim as possible.
http://www.nabble.com/file/p12794149/test.zip test.zip 

Thanks

Sam



Matej Knopp-2 wrote:
> 
> While the repaint is somewhat asynchronous, this shouldn't affect the
> actual form serialization. Can you provide a quickstart that can be
> used to reproduce this problem?
> 
> -Matej
> 
> On 9/19/07, Sam Hough <[EMAIL PROTECTED]> wrote:
>>
>> I'm using 1.3-beta3
>>
>> I think as far as the wicket js is concerned it has finished (as it has
>> done
>> elmt.innerHTML='something') but the problem is that the browser does the
>> re-rendering in a different thread to the java script engine. So when I
>> click the second time the HTML is only partially finished...
>>
>> Maybe I'll have a look at how selenium waits for the browser to "settle".
>> Think this is a common problem for browser based robot testing.
>>
>>
>> Matej Knopp-2 wrote:
>> >
>> > What exact wicket version are you using? With the current trunk the
>> > client side form serialization waits until the previous ajax request
>> > finished even if you submit the form during previous request
>> > processing. But I'm not really sure that this is your issue.
>> >
>> > -Matej
>> >
>> > On 9/19/07, Sam Hough <[EMAIL PROTECTED]> wrote:
>> >>
>> >> Yes. Click A updates part of the form. Click B (very soon after A)
>> also
>> >> submits that form. So my suspicion is that the browser is still busy
>> >> parsing
>> >> the last update and click B sends a form in an intermediate state.
>> >>
>> >> Does that sound likely? I've seen it in the past that after innerHTML
>> you
>> >> have to wait a while to access the DOM.
>> >>
>> >>
>> >> Johan Compagner wrote:
>> >> >
>> >> > do you click fast on a dom portion that is being replaced by the
>> >> previous
>> >> > request?
>> >> >
>> >> > johan
>> >> >
>> >> >
>> >> > On 9/19/07, Sam Hough <[EMAIL PROTECTED]> wrote:
>> >> >>
>> >> >>
>> >> >> Bit more information is that the bean property that is causing the
>> >> >> problem
>> >> >> is
>> >> >> being set to null by my html form via a wicket ajax update...
>> >> >>
>> >> >> Could it be that although wicket is doing everything correctly the
>> DOM
>> >> in
>> >> >> (firefox 2) has not "settled" after the elmt.innerHTML= ... from
>> the
>> >> >> previous ajax response so the next click sends an update that I
>> >> wouldn't
>> >> >> expect?
>> >> >>
>> >> >> Any options in wicket to block the UI till the DOM has settled? Or
>> >> shall
>> >> >> I
>> >> >> point my html monkey at it?
>> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >> >> Sam Hough wrote:
>> >> >> >
>> >> >> > Must be me then. I'll try and pin it down more. Hmmm.
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > Johan Compagner wrote:
>> >> >> >>
>> >> >> >> the nullpointer comes from outside of wicket (criterion class)
>> but
>> >> you
>> >> >> >> say if you click quickly you only get it? all pages are blocked
>> by
>> >> a
>> >> >> >> barrier that is build around the pagemap. its in Session.get
>> page
>> >> >> >> method. only 1 request can pass that at the same time.

but what
>> is
>> >> >> >> suddenly null that you dont expect to be null?
>> >> >> >>
>> >> >> >> On 9/18/07, Sam Hough <[EMAIL PROTECTED]> wrote:
>> >> >> >>>
>> >> >> >>> That is pretty much it. Except that:
>> >> >> >>> Caused by: java.lang.NullPointerException
>> >> >> >>> at
>> >> >> >>> com.namechangedtoprotectguilty.search.Criterion.getHelper(
>> >> >> Criterion.java:200)
>> >> >> >>> at sun.reflect.GeneratedMethodAccessor41.invoke(Unknown Source)
>> >> >> >>> at
>> >> >> >>> sun.reflect.DelegatingMethodAccessorImpl.invoke(
>> >> >> DelegatingMethodAccessorImpl.java:25)
>> >> >> >>> at java.lang.reflect.Method.invoke(Method.java:585)
>> >> >> >>> at
>> >> >> >>>
>> >> >>
>> org.apache.wicket.util.lang.PropertyResolver$MethodGetAndSet.getValue(
>> >> >> PropertyResolver.java:1030)
>> >> >> >>>
>> >> >> >>> Blows up in our code in a way that really looks like a
>> >> multithreading
>> >> >> >>> issue
>> >> >> >>> to me. If I click slowly no problems, if I click quickly on a
>> slow
>> >> >> page
>> >> >> >>> it
>> >> >> >>> reliably blows up. Guess I could put in a sync filter to double
>> >> check
>> >> >> >>> that
>> >> >> >>> it is a sync error. We don't create any threads so apart from
>> >> >> threading
>> >> >> >>> issue I can't see what else it could be...
>> >> >> >>>
>> >> >> >>>
>> >> >> >>> igor.vaynberg wrote:
>> >> >> >>> >
>> >> >> >>> > show us the full stack trace
>> >> >> >>> >
>> >> >> >>> > -igor
>> >> >> >>> >
>> >> >> >>> > On 9/18/07, Sam Hough <[E

Re: New Wicket Portlets Demo available

2007-09-20 Thread Ate Douma

Dipu Seminlal wrote:

Hi Ate,

I'm interested in the portlet support which you have implemented in wicket.

Cool!



Any idea when it might be merged into the trunk?

It is under discussion right now on the dev list.
I've proposed to merge this into trunk now (before -beta4 release), but this 
hasn't been decided or voted upon yet.
I do hope we can wrap this up quickly though.

The discussion is somewhat split up over two different threads which you can 
view in context using nabble:

[1] 
http://www.nabble.com/Please-review-WICKET-983%3A-Merge-the-portlet-support-branch-into-the-trunk-tf4470851.html
[2] 
http://www.nabble.com/Re%3A--jira--Resolved%3A-%28WICKET-647%29-New-Wicket-Portlet-support-tf4467600.html

Feel free to join those and let us know your opinion too :)

Regards,

Ate



Regards
Dipu


On 9/17/07, Ate Douma <[EMAIL PROTECTED]> wrote:

I'm really happy to announce that a new and quite feature complete Wicket
Portlets Demo is now available for download at:


http://people.apache.org/~ate/wicket/jetspeed-2.1.3-dev-wicket-demo-installer.jar

I've worked hard the last few weeks to improve the Wicket portlet support
branch and it can now run all Wicket Examples natively as portlet!
See also IRA issue WICKET-658 at
http://issues.apache.org/jira/browse/WICKET-658#action_12528082 where I
have provided more information how to install and use
this demo.

Although there probably are still some minor issues here and there, the
demo will show that portlet development using Wicket is now very much
feasible.

I'd like to invite anyone interested to try out the demo and see it in
action for yourself, and of course please report any encountered
issue/problems to the
dev list.

I've developed the portlet support based on the 1.3.0-beta3 release (with
few minor bugfixes ported back from the trunk), so although the trunk
development has
progressed at it usual aggressive speed, updating the portlet-support to
the latest Wicket trunk shouldn't be too much work (that is: right now!).

As we would like to start using Wicket for a rewrite of the Jetspeed-2
administration portlets *now*, it would be great if the portlet support can
be
incorporated into the trunk as soon as possible. Delaying this until after
the 1.3.0 release would mean being out-of-sync with the main wicket trunk
development
all the time and a lot of work each time we want/need to bring it back in
sync.

Initially, back in May this year, my idea was waiting with merging the
portlet support in the trunk to after the 1.3.0 release.
But as 1.3.0 still isn't released yet and still in beta phase, it would be
much better to merge now otherwise the portlet-support will be constantly
out-of-sync
with the main wicket trunk development, causing a lot of effort each time
we want (or need) to bring it back in sync.

For Jetspeed-2, we would very much like to start using Wicket for a
rewrite of the Jetspeed-2 administration portlet *now*. Having towait until
after the 1.3.0
release, or be dependent on unofficial builds from the portlet-support
branch would be less ideal to say the least.
Other parties, like my own company, already have started using the Wicket
portlet-support branch, so having to delay the merge to trunk really
wouldn't be fun.

AFAICS though, the impact of merging the portlet-support to trunk won't be
big.
I had to make a few (internal) changes in the wicket core, but I don't
think those will have functional side-effects.

To make it easier for the other committers to decide if we can merge the
portlet-support to trunk now, I will create a new JIRA issue for it.
For the changes needed to the current Wicket trunk I'll create separate
patches with explanations why and attach those to that issue.
(note: most of these changes I already described in detail under subtasks
of the WICKET-647 issue).
We can then discuss these changes individually and if need be see if
alternative solutions are possible.
After those changes are reviewed and accepted, the portlet support then
can be merged to the trunk.

WDYT?

Regards,

Ate




-
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: New Wicket Portlets Demo available

2007-09-20 Thread Gwyn Evans
Probably fairly soon - we've been looking at the changes and
discussing it on the dev list, to try & get an idea if it'll cause a
significant delay with regards to the aim of getting a 1.3 release out
ASAP.  Currently, however, I think the view is that it'll be likely to
be in and we'll do a beta4, then see how it looks.

I think I saw some comment about some rebuilding work of Ate's house -
I don't know any more than that, but if he's quiet for a bit, that
might explain it!

In the meantime, you could get the baseline code from SVN
(http://svn.apache.org/repos/asf/wicket/tags/wicket-1.3.0-beta3),
apply the patch from the jira issue
https://issues.apache.org/jira/secure/attachment/12366048/wicket-1.3.0-beta3-portlet-support.patch
and build your own copy if you want to have a look prior to that.
(Build with tests disabled "mvn -Dmaven.test.skip=true install" as the
patch missed changing a particular test expectation)

/Gwyn

On Thursday, September 20, 2007, 10:20:23 AM, Dipu <[EMAIL PROTECTED]> wrote:

> Hi Ate,

> I'm interested in the portlet support which you have implemented in wicket.

> Any idea when it might be merged into the trunk?

> Regards
> Dipu


> On 9/17/07, Ate Douma <[EMAIL PROTECTED]> wrote:
>>
>> I'm really happy to announce that a new and quite feature complete Wicket
>> Portlets Demo is now available for download at:
>>
>>
>> http://people.apache.org/~ate/wicket/jetspeed-2.1.3-dev-wicket-demo-installer.jar
>>
>> I've worked hard the last few weeks to improve the Wicket portlet support
>> branch and it can now run all Wicket Examples natively as portlet!
>> See also IRA issue WICKET-658 at
>> http://issues.apache.org/jira/browse/WICKET-658#action_12528082 where I
>> have provided more information how to install and use
>> this demo.
>>
>> Although there probably are still some minor issues here and there, the
>> demo will show that portlet development using Wicket is now very much
>> feasible.
>>
>> I'd like to invite anyone interested to try out the demo and see it in
>> action for yourself, and of course please report any encountered
>> issue/problems to the
>> dev list.
>>
>> I've developed the portlet support based on the 1.3.0-beta3 release (with
>> few minor bugfixes ported back from the trunk), so although the trunk
>> development has
>> progressed at it usual aggressive speed, updating the portlet-support to
>> the latest Wicket trunk shouldn't be too much work (that is: right now!).
>>
>> As we would like to start using Wicket for a rewrite of the Jetspeed-2
>> administration portlets *now*, it would be great if the portlet support can
>> be
>> incorporated into the trunk as soon as possible. Delaying this until after
>> the 1.3.0 release would mean being out-of-sync with the main wicket trunk
>> development
>> all the time and a lot of work each time we want/need to bring it back in
>> sync.
>>
>> Initially, back in May this year, my idea was waiting with merging the
>> portlet support in the trunk to after the 1.3.0 release.
>> But as 1.3.0 still isn't released yet and still in beta phase, it would be
>> much better to merge now otherwise the portlet-support will be constantly
>> out-of-sync
>> with the main wicket trunk development, causing a lot of effort each time
>> we want (or need) to bring it back in sync.
>>
>> For Jetspeed-2, we would very much like to start using Wicket for a
>> rewrite of the Jetspeed-2 administration portlet *now*. Having towait until
>> after the 1.3.0
>> release, or be dependent on unofficial builds from the portlet-support
>> branch would be less ideal to say the least.
>> Other parties, like my own company, already have started using the Wicket
>> portlet-support branch, so having to delay the merge to trunk really
>> wouldn't be fun.
>>
>> AFAICS though, the impact of merging the portlet-support to trunk won't be
>> big.
>> I had to make a few (internal) changes in the wicket core, but I don't
>> think those will have functional side-effects.
>>
>> To make it easier for the other committers to decide if we can merge the
>> portlet-support to trunk now, I will create a new JIRA issue for it.
>> For the changes needed to the current Wicket trunk I'll create separate
>> patches with explanations why and attach those to that issue.
>> (note: most of these changes I already described in detail under subtasks
>> of the WICKET-647 issue).
>> We can then discuss these changes individually and if need be see if
>> alternative solutions are possible.
>> After those changes are reviewed and accepted, the portlet support then
>> can be merged to the trunk.
>>
>> WDYT?
>>
>> Regards,
>>
>> Ate
>>
>>
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>



/Gwyn


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



Re: Image Scaling Feature !

2007-09-20 Thread Ayodeji Aladejebi
http://www.javalobby.org/articles/ultimate-image/

On 9/20/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
>
> > I like to know if wicket has any built-in feature for scaling images
> while
> > maintaining aspect ratios, Thanks !
>
> Not sure what exactly you need, but you could take a look at
> ThumbnailImageResource in wicket-extensions.
>
> Eelco
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: New Wicket Portlets Demo available

2007-09-20 Thread Dipu Seminlal
Hi Ate,

I'm interested in the portlet support which you have implemented in wicket.

Any idea when it might be merged into the trunk?

Regards
Dipu


On 9/17/07, Ate Douma <[EMAIL PROTECTED]> wrote:
>
> I'm really happy to announce that a new and quite feature complete Wicket
> Portlets Demo is now available for download at:
>
>
> http://people.apache.org/~ate/wicket/jetspeed-2.1.3-dev-wicket-demo-installer.jar
>
> I've worked hard the last few weeks to improve the Wicket portlet support
> branch and it can now run all Wicket Examples natively as portlet!
> See also IRA issue WICKET-658 at
> http://issues.apache.org/jira/browse/WICKET-658#action_12528082 where I
> have provided more information how to install and use
> this demo.
>
> Although there probably are still some minor issues here and there, the
> demo will show that portlet development using Wicket is now very much
> feasible.
>
> I'd like to invite anyone interested to try out the demo and see it in
> action for yourself, and of course please report any encountered
> issue/problems to the
> dev list.
>
> I've developed the portlet support based on the 1.3.0-beta3 release (with
> few minor bugfixes ported back from the trunk), so although the trunk
> development has
> progressed at it usual aggressive speed, updating the portlet-support to
> the latest Wicket trunk shouldn't be too much work (that is: right now!).
>
> As we would like to start using Wicket for a rewrite of the Jetspeed-2
> administration portlets *now*, it would be great if the portlet support can
> be
> incorporated into the trunk as soon as possible. Delaying this until after
> the 1.3.0 release would mean being out-of-sync with the main wicket trunk
> development
> all the time and a lot of work each time we want/need to bring it back in
> sync.
>
> Initially, back in May this year, my idea was waiting with merging the
> portlet support in the trunk to after the 1.3.0 release.
> But as 1.3.0 still isn't released yet and still in beta phase, it would be
> much better to merge now otherwise the portlet-support will be constantly
> out-of-sync
> with the main wicket trunk development, causing a lot of effort each time
> we want (or need) to bring it back in sync.
>
> For Jetspeed-2, we would very much like to start using Wicket for a
> rewrite of the Jetspeed-2 administration portlet *now*. Having towait until
> after the 1.3.0
> release, or be dependent on unofficial builds from the portlet-support
> branch would be less ideal to say the least.
> Other parties, like my own company, already have started using the Wicket
> portlet-support branch, so having to delay the merge to trunk really
> wouldn't be fun.
>
> AFAICS though, the impact of merging the portlet-support to trunk won't be
> big.
> I had to make a few (internal) changes in the wicket core, but I don't
> think those will have functional side-effects.
>
> To make it easier for the other committers to decide if we can merge the
> portlet-support to trunk now, I will create a new JIRA issue for it.
> For the changes needed to the current Wicket trunk I'll create separate
> patches with explanations why and attach those to that issue.
> (note: most of these changes I already described in detail under subtasks
> of the WICKET-647 issue).
> We can then discuss these changes individually and if need be see if
> alternative solutions are possible.
> After those changes are reviewed and accepted, the portlet support then
> can be merged to the trunk.
>
> WDYT?
>
> Regards,
>
> Ate
>
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Image Scaling Feature !

2007-09-20 Thread Eelco Hillenius
> I like to know if wicket has any built-in feature for scaling images while
> maintaining aspect ratios, Thanks !

Not sure what exactly you need, but you could take a look at
ThumbnailImageResource in wicket-extensions.

Eelco

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



How to add RadioGroup column to DataTable?

2007-09-20 Thread Kevin Liu
Hi!
   
  Could you tell me how to add RadioGroup column to DataTable ?
   
  Thank you very much!


-Kevin Liu
   
-
Be a better Heartthrob. Get better relationship answers from someone who knows.
Yahoo! Answers - Check it out. 

Re: Testing wicket 1.3

2007-09-20 Thread Nino Saturnino Martinez Vazquez Wael

ahh, yeah this are more flexible:)

regards Nino

Frank Bille wrote:

One thing you also could consider is using the TagTester. Currently you can
find a tag by using the getTagById and getTagByWicketId. My orignial plan
was to have several helper methods for finding the html tags you want for
testing.

http://wicketstuff.org/wicket13doc/org/apache/wicket/util/tester/TagTester.html

Frank


On 9/19/07, Nino Saturnino Martinez Vazquez Wael <[EMAIL PROTECTED]>
wrote:
  

Hi Kent

hmm, while this could be okay. I just fear the possibility that tests
may succeed if other components contains foo. This test does not take
hierarchy into account..

For the simple Bbcodecomponent, it will work as I will be testing it
isolated. However if others that are using the component wants to test
that the out come are correct, this could be a potential pitfall.


regards Nino

Kent Tong wrote:


Nino.Martinez wrote:

  

I was wondering how I should be testing with wicket. I've created the
bbcodecomponent, I have a bbcodeLabel. And I would like to write a test
for that. I can see that I can't use the assertLabel as that just gets
modelObjectToString, in the bbcodeLabel some formatting are done during
onComponentTagBody. Is this completely wrong, how should testing be
done? I can see that the dateLabel uses an approach with converters,
although im not sure how this are done. But are this more propper?




try something like:

  WicketTester tester = new WicketTester();
  tester.startPage(Home.class);
  tester.assertContains("foo");


  

-
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: Image Scaling Feature !

2007-09-20 Thread Martijn Dashorst
On 9/20/07, chickabee <[EMAIL PROTECTED]> wrote:
> I like to know if wicket has any built-in feature for scaling images while
> maintaining aspect ratios, Thanks !

There are oodles of image manipulation frameworks out there, there is
no need for Wicket to provide that. And if that fails, you can always
just set the width or the height of the image tag. The browser will
scale the image for you (only set either the width or height, not
both!), the image's filesize will not change though, so your 10MB
picture will still be a whopping 10MB download, even if you tell the
browser it should fit in a 80x120 pixel canvas.

Martijn

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

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



Re: Dojo floating panel

2007-09-20 Thread Gerolf Seitz
sure, you're welcome

On 9/20/07, Federico Fanton <[EMAIL PROTECTED]> wrote:
>
> On Wed, 19 Sep 2007 20:00:46 +0200
> "Gerolf Seitz" <[EMAIL PROTECTED]> wrote:
>
> > hope it works this time ;)
>
> It works very well :) Many thanks for your time and patience!
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Dojo floating panel

2007-09-20 Thread Federico Fanton
On Wed, 19 Sep 2007 20:00:46 +0200
"Gerolf Seitz" <[EMAIL PROTECTED]> wrote:

> hope it works this time ;)

It works very well :) Many thanks for your time and patience!


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



Image Scaling Feature !

2007-09-20 Thread chickabee

Hi, 

I like to know if wicket has any built-in feature for scaling images while
maintaining aspect ratios, Thanks !

-- 
View this message in context: 
http://www.nabble.com/Image-Scaling-Feature-%21-tf4485782.html#a12792030
Sent from the Wicket - User mailing list archive at Nabble.com.


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