Re: [Wicket-user] [Request for enhancement] TabbedPanel

2007-05-17 Thread Alex Objelean

Though it can be a solution, it is not a natural one... because I want to
make the difference between outer and inner tab-row, not between outer vs
inner tab-panel.


John Krasnay wrote:
 
 Ahh, I see...the problem is *nested* tabs. Sorry for not picking that up
 earlier. However, I think the same principle applies, no? Just give the
 inner tab panel a different CSS class than the outer one.
 
 jk
 
 On Wed, May 16, 2007 at 07:39:04AM -0700, Alex Objelean wrote:
 
 This solution adds the css class the the entire tabbedPanel container,
 subsequently all nested tabbedPanels will be treated the same way
 What I
 need is to identify the tab-row container
 
 
 John Krasnay wrote:
  
  In fact now that I think of it, you don't even need the wrapper div.
  Remember that the TabbedPanel renders the tabs *inside* the tag to
  which it's attached. That tag can contain the CSS class that makes that
  set of tabs unique:
  
div wicket:id=tabs class=greentabs/div
  
add(new TabbedPanel(tabs, tabs));
  
  The result is like this:
  
div class=greentabs
  div class=tab-row
  ...
  /div
/div
  
  If you need to determine the class dynamically, just add an appropriate
  behaviour to the TabbedPanel:
  
add(new TabbedPanel(tabs, tabs)
  .add(new AttributeModifier(class, new Model(purpletabs;
  
  jk
  
  On Wed, May 16, 2007 at 06:28:57AM -0700, Alex Objelean wrote:
  
  That is the problem. How can I attach a WebMarkupContainer to a
 tab-row
  container?
  The markup is generated by TabbedPanel and I cannot manipulate it's
  markup... :(
  
  
  Hi Alex,
  
  The way I've tackled this is to have a wrapper div around the entire
 tab
  panel, like so...
  
  div class=mytabs
div class=tab-row
  ul
...
  /ul
/div
  /div
  
  You just need to add the wrapper div to your CSS selector:
  
  div.mytabs li {
background-color: green;
  }
  
  Then you can have different wrapper divs for different styling:
  
  div.othertabs li {
background-color: purple;
  }
  
  If you need to dynamically manipulate the wrapper div, simply attach a
  WebMarkupContainer to it.
  
  HTH
  
  jk
  
  On Wed, May 16, 2007 at 04:33:37AM -0700, Alex Objelean wrote:
   
   Currently, the markup generated for the tabbedPanel component looks
  like
   this:
   
   [code]
   wicket:panel
   div class=tab-row
   ul
   li wicket:id=tabs
# [[tab title]] 
   /li
   /ul
   /div
   [panel]
   /wicket:panel
   [/code]
   
   I think that it would be more useful to add a container to the
 existing
   tabs, so the resulted markup would look like this:
   
   [code]
   wicket:panel
   div wicket:id=tabsContainer class=tab-row
   ul
   li wicket:id=tabs
# [[tab title]] 
   /li
   /ul
   /div
   [panel]
   /wicket:panel
   [/code]
   
   This way you can append a new css class to this container (using
   AttributeAppender behavior) and can control the specific visual
  appearance
   of the tabbed panel... It is not enough to have only tab-row
 class,
   because if you have nested tabbed panels (which have different
 styling)
  it
   is hard to style them as you want... And finally, you give the
  developer a
   freedom to do what he wants with this container...
   
   What do you think?
   
   Thank you!
   
  
  -- 
  View this message in context:
 
 http://www.nabble.com/-Request-for-enhancement--TabbedPanel-tf3764064.html#a10641787
  Sent from the Wicket - User mailing list archive at Nabble.com.
  
  
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
  
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
 -- 
 View this message in context:
 http://www.nabble.com/-Request-for-enhancement--TabbedPanel-tf3764064.html#a10642947
 Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 

[Wicket-user] [Question] Asynchronous Ajax

2007-05-17 Thread Alex Objelean

I've noticed that having two components with AjaxEventBehavior attached to
each of them, trigger a synchronous ajax call:

Button b1 = new Button(b1);
b1.add(new AjaxEventBehavior(onclick) {
  protected void onEvent(final AjaxRequestTarget target) {
doSomethingSlow1();
  }
});
Button b2 = new Button(b2);
b2.add(new AjaxEventBehavior(onclick) {
  protected void onEvent(final AjaxRequestTarget target) {
doSomethingSlow2();
  }
});

Clicking b1, and immediately after that b2 cause the following message in
wicket-debug window:  INFO: Chanel busy - postponing 
Can I force a parallel execution of doSomethingSlow1 and doSomethingSlow2?

Thank you,
Alex.

just wondering if it is possible to make them asynchronous.
-- 
View this message in context: 
http://www.nabble.com/-Question--Asynchronous-Ajax-tf3770294.html#a10659589
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] trunk build error?!

2007-05-17 Thread Matej Knopp
Yeah, the test is broken. But it shouldn't hinder wicket
functionality. For now you can build it with -Dmaven.test.skip=true.

-Matej

On 5/17/07, Jan Kriesten [EMAIL PROTECTED] wrote:

 hi,

 i just checked out the latest trunk (revision 538801) and get this test error:

 [surefire] Running org.apache.wicket.util.io.WicketOutputStreamTest
 [surefire] Tests run: 5, Failures: 0, Errors: 1, Time elapsed: 0,213 sec
  FAILURE !!

 system: mac os x / jdk 1.5 / maven 2.0.5

 should i worry?

 other revisions were ok. since i need to change Radio.java and
 FormComponent.java so i can use FormComponentLabel for Radio, i somewhat 
 depend
 on building wicket myself. :-)

 regards, --- jan.



 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] [Question] Asynchronous Ajax

2007-05-17 Thread Matej Knopp
You can't. The requests are asynchronous (they don't block request),
but they are scheduled in channel so one request waits until the
previous one finishes.

Problem is that the pagemap is locked, so you can't have two requests
running on parallel on the same pagemap. If you have operation that
takes too long you should use a worker thread and a periodical
polling.

Btw. I don't understand why you are using AjaxEventBehavior on button
instead of just using AjaxLink?

-Matej

On 5/17/07, Alex Objelean [EMAIL PROTECTED] wrote:

 I've noticed that having two components with AjaxEventBehavior attached to
 each of them, trigger a synchronous ajax call:

 Button b1 = new Button(b1);
 b1.add(new AjaxEventBehavior(onclick) {
   protected void onEvent(final AjaxRequestTarget target) {
 doSomethingSlow1();
   }
 });
 Button b2 = new Button(b2);
 b2.add(new AjaxEventBehavior(onclick) {
   protected void onEvent(final AjaxRequestTarget target) {
 doSomethingSlow2();
   }
 });

 Clicking b1, and immediately after that b2 cause the following message in
 wicket-debug window:  INFO: Chanel busy - postponing
 Can I force a parallel execution of doSomethingSlow1 and doSomethingSlow2?

 Thank you,
 Alex.

 just wondering if it is possible to make them asynchronous.
 --
 View this message in context: 
 http://www.nabble.com/-Question--Asynchronous-Ajax-tf3770294.html#a10659589
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AjaxSubmitButton IE vs. FF Behavior

2007-05-17 Thread Igor Vaynberg

you have to catch the enter keypress on every textfield and submit the form
using ajax. you can do that using some javascript magic and some behavior
that adds this magic to onload event.

so in your basepage or baseform youd do: add(new FixIe7EnterKeyBehavior());

-igor


On 5/16/07, Joe Toth [EMAIL PROTECTED] wrote:


Using Wicket 1.2.6

Using FF 2.0 when I click on the submit button or hit 'enter' on a field
in the form the ajax call is processed.

With IE 7.0 when I click on the submit button, the ajax class is
processed, BUT when I hit 'enter' the form submits normally.

Any idea what I can do to keep the same behavior all around and make IE 7
'enter' behave the same as the click?

Thanks

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] WicketTester Sessions (1.3.0-incubating-beta1)

2007-05-17 Thread severian

Yes, I raised JIRA bug WICKET-574.
-- 
View this message in context: 
http://www.nabble.com/WicketTester---Sessions-%281.3.0-incubating-beta1%29-tf3759412.html#a10659833
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Extra bits added to URL

2007-05-17 Thread Igor Vaynberg

this is done by automatic multitab support. you are opening a new window or
a new tab that points to a wicket app already open in another? this is done
by our automatic multipage support, and while ugly it is necessary if you
want your app to run in multiple tabs/windows correctly. if not, you can
turn it off in settings.

-igor


On 5/16/07, Chris Colman [EMAIL PROTECTED] wrote:


I have an Echo application which has a link to a Wicket generated page.
I use the nice form http://www.mysite.com/appname/pagename/param1/value1
as the URL but when I activate the link the Wicket page appears with
extra bits added to the URL that I don't add.

It will add something like: /wicket:pageMapName/wicket-6
To the end of my nicely formed URL. Any idea why wicket does this and
any idea how to stop  it?

Using wicket 1.2.6.

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] [Request for enhancement] TabbedPanel

2007-05-17 Thread Igor Vaynberg

i dont like adding a container that users can mock with. if you want to go
that far then just create your own tabbedpanel, its only a few lines of
code. what i can see is some overridable method to add a css class to that
tab row, will that work?

-igor


On 5/16/07, Alex Objelean [EMAIL PROTECTED] wrote:



Though it can be a solution, it is not a natural one... because I want to
make the difference between outer and inner tab-row, not between outer vs
inner tab-panel.


John Krasnay wrote:

 Ahh, I see...the problem is *nested* tabs. Sorry for not picking that up
 earlier. However, I think the same principle applies, no? Just give the
 inner tab panel a different CSS class than the outer one.

 jk

 On Wed, May 16, 2007 at 07:39:04AM -0700, Alex Objelean wrote:

 This solution adds the css class the the entire tabbedPanel container,
 subsequently all nested tabbedPanels will be treated the same way
 What I
 need is to identify the tab-row container


 John Krasnay wrote:
 
  In fact now that I think of it, you don't even need the wrapper div.
  Remember that the TabbedPanel renders the tabs *inside* the tag to
  which it's attached. That tag can contain the CSS class that makes
that
  set of tabs unique:
 
div wicket:id=tabs class=greentabs/div
 
add(new TabbedPanel(tabs, tabs));
 
  The result is like this:
 
div class=greentabs
  div class=tab-row
  ...
  /div
/div
 
  If you need to determine the class dynamically, just add an
appropriate
  behaviour to the TabbedPanel:
 
add(new TabbedPanel(tabs, tabs)
  .add(new AttributeModifier(class, new Model(purpletabs;
 
  jk
 
  On Wed, May 16, 2007 at 06:28:57AM -0700, Alex Objelean wrote:
 
  That is the problem. How can I attach a WebMarkupContainer to a
 tab-row
  container?
  The markup is generated by TabbedPanel and I cannot manipulate it's
  markup... :(
 
 
  Hi Alex,
 
  The way I've tackled this is to have a wrapper div around the entire
 tab
  panel, like so...
 
  div class=mytabs
div class=tab-row
  ul
...
  /ul
/div
  /div
 
  You just need to add the wrapper div to your CSS selector:
 
  div.mytabs li {
background-color: green;
  }
 
  Then you can have different wrapper divs for different styling:
 
  div.othertabs li {
background-color: purple;
  }
 
  If you need to dynamically manipulate the wrapper div, simply attach
a
  WebMarkupContainer to it.
 
  HTH
 
  jk
 
  On Wed, May 16, 2007 at 04:33:37AM -0700, Alex Objelean wrote:
  
   Currently, the markup generated for the tabbedPanel component
looks
  like
   this:
  
   [code]
   wicket:panel
   div class=tab-row
   ul
   li wicket:id=tabs
# [[tab title]]
   /li
   /ul
   /div
   [panel]
   /wicket:panel
   [/code]
  
   I think that it would be more useful to add a container to the
 existing
   tabs, so the resulted markup would look like this:
  
   [code]
   wicket:panel
   div wicket:id=tabsContainer class=tab-row
   ul
   li wicket:id=tabs
# [[tab title]]
   /li
   /ul
   /div
   [panel]
   /wicket:panel
   [/code]
  
   This way you can append a new css class to this container (using
   AttributeAppender behavior) and can control the specific visual
  appearance
   of the tabbed panel... It is not enough to have only tab-row
 class,
   because if you have nested tabbed panels (which have different
 styling)
  it
   is hard to style them as you want... And finally, you give the
  developer a
   freedom to do what he wants with this container...
  
   What do you think?
  
   Thank you!
  
 
  --
  View this message in context:
 

http://www.nabble.com/-Request-for-enhancement--TabbedPanel-tf3764064.html#a10641787
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 

-
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:

http://www.nabble.com/-Request-for-enhancement--TabbedPanel-tf3764064.html#a10642947
 Sent from the Wicket - User mailing list archive at Nabble.com.




Re: [Wicket-user] [Question] Asynchronous Ajax

2007-05-17 Thread Alex Objelean

Matej, thank you for your answer!

I am using Button just because I forgot about AjaxLink :)... anyway, it has
exactly the same effect, isn't it?


Matej Knopp-2 wrote:
 
 You can't. The requests are asynchronous (they don't block request),
 but they are scheduled in channel so one request waits until the
 previous one finishes.
 
 Problem is that the pagemap is locked, so you can't have two requests
 running on parallel on the same pagemap. If you have operation that
 takes too long you should use a worker thread and a periodical
 polling.
 
 Btw. I don't understand why you are using AjaxEventBehavior on button
 instead of just using AjaxLink?
 
 -Matej
 
 On 5/17/07, Alex Objelean [EMAIL PROTECTED] wrote:

 I've noticed that having two components with AjaxEventBehavior attached
 to
 each of them, trigger a synchronous ajax call:

 Button b1 = new Button(b1);
 b1.add(new AjaxEventBehavior(onclick) {
   protected void onEvent(final AjaxRequestTarget target) {
 doSomethingSlow1();
   }
 });
 Button b2 = new Button(b2);
 b2.add(new AjaxEventBehavior(onclick) {
   protected void onEvent(final AjaxRequestTarget target) {
 doSomethingSlow2();
   }
 });

 Clicking b1, and immediately after that b2 cause the following message in
 wicket-debug window:  INFO: Chanel busy - postponing
 Can I force a parallel execution of doSomethingSlow1 and
 doSomethingSlow2?

 Thank you,
 Alex.

 just wondering if it is possible to make them asynchronous.
 --
 View this message in context:
 http://www.nabble.com/-Question--Asynchronous-Ajax-tf3770294.html#a10659589
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 
http://www.nabble.com/-Question--Asynchronous-Ajax-tf3770294.html#a10660005
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] [Request for enhancement] TabbedPanel

2007-05-17 Thread Alex Objelean

Yes, it is acceptable an solution...
Also, I thought about somehow dynamically providing markup for the tab-row
container, or having a possibility to decorate it with you own container...
any thoughts?


igor.vaynberg wrote:
 
 i dont like adding a container that users can mock with. if you want to go
 that far then just create your own tabbedpanel, its only a few lines of
 code. what i can see is some overridable method to add a css class to that
 tab row, will that work?
 
 -igor
 
 
 On 5/16/07, Alex Objelean [EMAIL PROTECTED] wrote:


 Though it can be a solution, it is not a natural one... because I want to
 make the difference between outer and inner tab-row, not between outer vs
 inner tab-panel.


 John Krasnay wrote:
 
  Ahh, I see...the problem is *nested* tabs. Sorry for not picking that
 up
  earlier. However, I think the same principle applies, no? Just give the
  inner tab panel a different CSS class than the outer one.
 
  jk
 
  On Wed, May 16, 2007 at 07:39:04AM -0700, Alex Objelean wrote:
 
  This solution adds the css class the the entire tabbedPanel container,
  subsequently all nested tabbedPanels will be treated the same way
  What I
  need is to identify the tab-row container
 
 
  John Krasnay wrote:
  
   In fact now that I think of it, you don't even need the wrapper div.
   Remember that the TabbedPanel renders the tabs *inside* the tag to
   which it's attached. That tag can contain the CSS class that makes
 that
   set of tabs unique:
  
 div wicket:id=tabs class=greentabs/div
  
 add(new TabbedPanel(tabs, tabs));
  
   The result is like this:
  
 div class=greentabs
   div class=tab-row
   ...
   /div
 /div
  
   If you need to determine the class dynamically, just add an
 appropriate
   behaviour to the TabbedPanel:
  
 add(new TabbedPanel(tabs, tabs)
   .add(new AttributeModifier(class, new Model(purpletabs;
  
   jk
  
   On Wed, May 16, 2007 at 06:28:57AM -0700, Alex Objelean wrote:
  
   That is the problem. How can I attach a WebMarkupContainer to a
  tab-row
   container?
   The markup is generated by TabbedPanel and I cannot manipulate it's
   markup... :(
  
  
   Hi Alex,
  
   The way I've tackled this is to have a wrapper div around the
 entire
  tab
   panel, like so...
  
   div class=mytabs
 div class=tab-row
   ul
 ...
   /ul
 /div
   /div
  
   You just need to add the wrapper div to your CSS selector:
  
   div.mytabs li {
 background-color: green;
   }
  
   Then you can have different wrapper divs for different styling:
  
   div.othertabs li {
 background-color: purple;
   }
  
   If you need to dynamically manipulate the wrapper div, simply
 attach
 a
   WebMarkupContainer to it.
  
   HTH
  
   jk
  
   On Wed, May 16, 2007 at 04:33:37AM -0700, Alex Objelean wrote:
   
Currently, the markup generated for the tabbedPanel component
 looks
   like
this:
   
[code]
wicket:panel
div class=tab-row
ul
li wicket:id=tabs
 # [[tab title]]
/li
/ul
/div
[panel]
/wicket:panel
[/code]
   
I think that it would be more useful to add a container to the
  existing
tabs, so the resulted markup would look like this:
   
[code]
wicket:panel
div wicket:id=tabsContainer class=tab-row
ul
li wicket:id=tabs
 # [[tab title]]
/li
/ul
/div
[panel]
/wicket:panel
[/code]
   
This way you can append a new css class to this container (using
AttributeAppender behavior) and can control the specific visual
   appearance
of the tabbed panel... It is not enough to have only tab-row
  class,
because if you have nested tabbed panels (which have different
  styling)
   it
is hard to style them as you want... And finally, you give the
   developer a
freedom to do what he wants with this container...
   
What do you think?
   
Thank you!
   
  
   --
   View this message in context:
  
 
 http://www.nabble.com/-Request-for-enhancement--TabbedPanel-tf3764064.html#a10641787
   Sent from the Wicket - User mailing list archive at Nabble.com.
  
  
  
 
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
 -
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   

Re: [Wicket-user] Need to reload app in tomcat aftering adding a variant markup

2007-05-17 Thread Jean-Baptiste Quenot
* Igor Vaynberg:

 is the modification watcher what  causes file handles to be left
 open? how do you expect that to be enabled in production?

This is another  problem: it's when Wicket  looks for modification
times in a JAR.  As it makes no sense to look inside a JAR whether
a template is  modified, the file handle leaking (caused  by a bug
in  the JVM)  has been  fixed by  only looking  at the  JAR file's
modification  time.  But  the  current  usecase is  to  look at  a
directory, not a JAR anyway.
-- 
 Jean-Baptiste Quenot
aka  John Banana   Qwerty
http://caraldi.com/jbq/

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Updating formComponents on round trip

2007-05-17 Thread kubino

Hi , maybe somebody can help me.

I have form with radiogroup holding ListView of posibble models ...

When the the form is first loaded textFields are filled well, but when I
click the radio button(round trip is made), variable selectedSystem is
updated but textfields are not.  I tried different methods in
onSelectionChanged method like process(), processInput() but nothing leads
in good result.  What I am doing wrong ? Any help will be appreciated.

public class MyForm extends Form {

private ListInterfaceSystemModel systems;

private InterfaceSystemModel selectedSystem;

public MyForm() {

selectedSystem = systems.get(0);

interfaceSystemRadioGroup = new RadioGroup(interfaceSystemRadioGroup,
new PropertyModel(this,selectedSystem)) { 

  
  @Override
  protected boolean wantOnSelectionChangedNotifications() {
return true;
  }
  
  @Override
  protected void onModelChanging() {
// unselection old value  
selectedSystem.setSelected(false);  

  }
  
  @Override
  protected void onSelectionChanged(Object arg0) {

  }

 interfacesSystemsTable = new ListView(interfaceSystems, systems) {
   
  
  @Override
  protected void populateItem(final ListItem item) {

final InterfaceSystemModel model =
(InterfaceSystemModel)item.getModelObject();

  item.add(new Radio(interfaceSystemsRadio,model.getModel()));
  item.add(new Label(system_name,model.getName()));
  item.add(new Label(description,model.getDescription()));
  
}
};


TextField nameTextField = new TextField(name,new
PropertyModel(selectedSystem,name));
TextField descTextField = new TextField(desc,new
PropertyModel(selectedSystem,desc));

add(interfaceSystemRadioGroup.add(interfacesSystemsTable));

add(nameTextField);
add(descTextField);

}


-- 
View this message in context: 
http://www.nabble.com/Updating-formComponents-on-round-trip-tf3770603.html#a10660535
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Modal window warning message

2007-05-17 Thread Nikhil Gahlot

Hi,

I am using Modal Window with a form. But whenever I click Submit button
on this window to submit a form
I am getting an alert message Are you sure you want to navigate away
from this page? Reloading this page will cause the modal window disappear.
Press OK to continue, or Cancel to stay on the current page. 
Now I want to prevent this alert message from getting displayed. Is
there any way to do that? 

Thanks
Nikhil
-- 
View this message in context: 
http://www.nabble.com/Modal-window-warning-message-tf3770780.html#a10661044
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Modal window warning message

2007-05-17 Thread Matej Knopp
You should use AjaxSubmitButton and submit the form using Ajax.

-Matej

On 5/17/07, Nikhil Gahlot [EMAIL PROTECTED] wrote:

 Hi,

 I am using Modal Window with a form. But whenever I click Submit button
 on this window to submit a form
 I am getting an alert message Are you sure you want to navigate away
 from this page? Reloading this page will cause the modal window disappear.
 Press OK to continue, or Cancel to stay on the current page.
 Now I want to prevent this alert message from getting displayed. Is
 there any way to do that?

 Thanks
 Nikhil
 --
 View this message in context: 
 http://www.nabble.com/Modal-window-warning-message-tf3770780.html#a10661044
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] css class for DataTable column?

2007-05-17 Thread Andrew Klochkov
What's the best way to add css class to a DataTable column?
The only way I see is to extend Panel and use it as a headers toolbar,
but I'd like to have all the functionality the HeadersToolbar already has!

-- 
Andrew Klochkov


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] solved

2007-05-17 Thread Andrew Klochkov
Andrew Klochkov wrote:
 What's the best way to add css class to a DataTable column?
 The only way I see is to extend Panel and use it as a headers toolbar,
 but I'd like to have all the functionality the HeadersToolbar already has!

   
I can add class attr to the cells.

-- 
Andrew Klochkov


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AjaxSubmitButton IE vs. FF Behavior

2007-05-17 Thread kubino

Can you show us the code, later ? I have to solve it too...


 Thanks.



WeaZeLb0y wrote:
 
 Using Wicket 1.2.6
 
 Using FF 2.0 when I click on the submit button or hit 'enter' on a field
 in
 the form the ajax call is processed.
 
 With IE 7.0 when I click on the submit button, the ajax class is
 processed,
 BUT when I hit 'enter' the form submits normally.
 
 Any idea what I can do to keep the same behavior all around and make IE 7
 'enter' behave the same as the click?
 
 Thanks
 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 
http://www.nabble.com/AjaxSubmitButton-IE-vs.-FF-Behavior-tf3769244.html#a10662291
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Need to reload app in tomcat aftering adding a variant markup

2007-05-17 Thread Thomas R. Corbin
On Wednesday 16 May 2007 4:37 pm, Chris Colman escreveu:
   This is  true, but  I understand  Chris has  a general  need for
   markup  reloading  in  production  as  well  (though  I  haven't
   understood   yet  how   Chris  creates   the  markup   files  at
   runtime). Or did  I misunderstand  that? And though  disabled in
   deployment mode by default, he  could enable it for his specific
   application.
 
  Indeed, ModificationWatcher  acting on previously not  found files
  should be done only in development mode by default, and Chris will
  just have to enable it for his deployment.

 How do I do that? Will it slow things down?

 Maybe the option to add a method that allows explicit clearing of the
 cache would be very useful because then we it can be high performance
 most of the time and just rebuild the cache when we indicate there is a
 new markup file.

Would exposing that via a JMX bean be useful so that when you add new 
markup, 
you can tickle the JMX bean to clear the markup?

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] solved

2007-05-17 Thread Thomas R. Corbin
On Thursday 17 May 2007 5:00 am, Andrew Klochkov escreveu:
 Andrew Klochkov wrote:
  What's the best way to add css class to a DataTable column?
  The only way I see is to extend Panel and use it as a headers toolbar,
  but I'd like to have all the functionality the HeadersToolbar already
  has!

 I can add class attr to the cells.

How do you do that?

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] script in head breaking page parameters

2007-05-17 Thread Markus Sabadello

Hi,

I have a page (a google gadget) which is going to be called from an external
source with parameters. Here is an example URL:

http://www.freexri.com/tools/GadgetExec?resolveType=SEP

So I set up a QueryStringUrlCodingStrategy, thinking that my page will be
constructed with a nice PageParameters argument.
This basically works fine, but when the page is rendered, it contains the
following script in the head:

script type=text/javascript !--/*--![CDATA[/*!--*/
if (window.name=='') {
window.location=/tools/GadgetExec?resolveType=%5BLjava.lang.String%3B%401a0ae6dwicket:pageMapName=wicket-1;
}
/*--]]*//script

So the page is basically invoked a second time with the following URL:

http://www.freexri.com/tools/GadgetExec?resolveType=%5BLjava.lang.String%3B%401a0ae6dwicket:pageMapName=wicket-1

Now when I read the resolveType parameter, it only contains nonsense
(%5BLjava.lang.String%3B%401a0ae6d).

To me it looks like a String array gets toString()ed, but why does Wicket
mess it up like that?

Happy about any help
Markus
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] solved

2007-05-17 Thread Andrew Klochkov
Thomas R. Corbin wrote:
 On Thursday 17 May 2007 5:00 am, Andrew Klochkov escreveu:
   
 Andrew Klochkov wrote:
 
 What's the best way to add css class to a DataTable column?
 The only way I see is to extend Panel and use it as a headers toolbar,
 but I'd like to have all the functionality the HeadersToolbar already
 has!
   
 I can add class attr to the cells.
 

   How do you do that?

   
By overriding DataTable.newCellItem. So if I use PropertyColumn
instances only I can use property expressions as css class names:

@Override
protected Item newCellItem(String id, int index, IModel model) {
PropertyColumn column = (PropertyColumn) model.getObject();
Item item = super.newCellItem(id, index, model);
item.add(new AttributeAppender(class, new
Model(column.getPropertyExpression()),  ));
return item;
}

-- 
Andrew Klochkov


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] [Request for enhancement] TabbedPanel

2007-05-17 Thread Igor Vaynberg

looks like i wont be able to get to it immediately, please add an rfe and i
will prob do it over the weekend.

-igor


On 5/17/07, Alex Objelean [EMAIL PROTECTED] wrote:



Yes, it is acceptable an solution...
Also, I thought about somehow dynamically providing markup for the tab-row
container, or having a possibility to decorate it with you own
container...
any thoughts?


igor.vaynberg wrote:

 i dont like adding a container that users can mock with. if you want to
go
 that far then just create your own tabbedpanel, its only a few lines of
 code. what i can see is some overridable method to add a css class to
that
 tab row, will that work?

 -igor


 On 5/16/07, Alex Objelean [EMAIL PROTECTED] wrote:


 Though it can be a solution, it is not a natural one... because I want
to
 make the difference between outer and inner tab-row, not between outer
vs
 inner tab-panel.


 John Krasnay wrote:
 
  Ahh, I see...the problem is *nested* tabs. Sorry for not picking that
 up
  earlier. However, I think the same principle applies, no? Just give
the
  inner tab panel a different CSS class than the outer one.
 
  jk
 
  On Wed, May 16, 2007 at 07:39:04AM -0700, Alex Objelean wrote:
 
  This solution adds the css class the the entire tabbedPanel
container,
  subsequently all nested tabbedPanels will be treated the same
way
  What I
  need is to identify the tab-row container
 
 
  John Krasnay wrote:
  
   In fact now that I think of it, you don't even need the wrapper
div.
   Remember that the TabbedPanel renders the tabs *inside* the tag to
   which it's attached. That tag can contain the CSS class that makes
 that
   set of tabs unique:
  
 div wicket:id=tabs class=greentabs/div
  
 add(new TabbedPanel(tabs, tabs));
  
   The result is like this:
  
 div class=greentabs
   div class=tab-row
   ...
   /div
 /div
  
   If you need to determine the class dynamically, just add an
 appropriate
   behaviour to the TabbedPanel:
  
 add(new TabbedPanel(tabs, tabs)
   .add(new AttributeModifier(class, new
Model(purpletabs;
  
   jk
  
   On Wed, May 16, 2007 at 06:28:57AM -0700, Alex Objelean wrote:
  
   That is the problem. How can I attach a WebMarkupContainer to a
  tab-row
   container?
   The markup is generated by TabbedPanel and I cannot manipulate
it's
   markup... :(
  
  
   Hi Alex,
  
   The way I've tackled this is to have a wrapper div around the
 entire
  tab
   panel, like so...
  
   div class=mytabs
 div class=tab-row
   ul
 ...
   /ul
 /div
   /div
  
   You just need to add the wrapper div to your CSS selector:
  
   div.mytabs li {
 background-color: green;
   }
  
   Then you can have different wrapper divs for different styling:
  
   div.othertabs li {
 background-color: purple;
   }
  
   If you need to dynamically manipulate the wrapper div, simply
 attach
 a
   WebMarkupContainer to it.
  
   HTH
  
   jk
  
   On Wed, May 16, 2007 at 04:33:37AM -0700, Alex Objelean wrote:
   
Currently, the markup generated for the tabbedPanel component
 looks
   like
this:
   
[code]
wicket:panel
div class=tab-row
ul
li wicket:id=tabs
 # [[tab title]]
/li
/ul
/div
[panel]
/wicket:panel
[/code]
   
I think that it would be more useful to add a container to the
  existing
tabs, so the resulted markup would look like this:
   
[code]
wicket:panel
div wicket:id=tabsContainer class=tab-row
ul
li wicket:id=tabs
 # [[tab title]]
/li
/ul
/div
[panel]
/wicket:panel
[/code]
   
This way you can append a new css class to this container
(using
AttributeAppender behavior) and can control the specific visual
   appearance
of the tabbed panel... It is not enough to have only tab-row
  class,
because if you have nested tabbed panels (which have different
  styling)
   it
is hard to style them as you want... And finally, you give the
   developer a
freedom to do what he wants with this container...
   
What do you think?
   
Thank you!
   
  
   --
   View this message in context:
  
 

http://www.nabble.com/-Request-for-enhancement--TabbedPanel-tf3764064.html#a10641787
   Sent from the Wicket - User mailing list archive at Nabble.com.
  
  
  
 

-
   This SF.net email is sponsored by DB2 Express
   Download DB2 Express C - the FREE version of DB2 express and take
   control of your XML. No limits. Just data. Click to get it now.
   http://sourceforge.net/powerbar/db2/
   ___
   Wicket-user mailing list
   Wicket-user@lists.sourceforge.net
   https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 

-
   This SF.net email is sponsored by DB2 Express

[Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread Julian Klappenbach

http://graemerocher.blogspot.com/2007/05/grails-wicket-wonders-of-grails-plug-in.html
(SFW)

Graeme pinged me as soon as I got online this morning to tell me about his
work on integrating Wicket and Groovy, a Rails implementation based on the
Java scripting language, Groovy.

As you'll read, the integration took him *20 minutes*, and the result was
the following:

  1. Wicket classes can be utilized as-is from wicket jars inside a
  Groovy environment, meaning that there's no concern of keeping a
  Groovy-based mirror of Wicket synchronized.
  2. Wicket classes can take advantage of GORM, with dynamic methods
  (This is very, very, cool)
  3. Developers can take advantage of closures, and all other nice
  features of Groovy

Graeme warned me that he hadn't tested much more than a Hello World
example.  But in getting even those two simple words out, a lot had to be
going on under the hood.  I'd be surprised if there were issues lurking
beyond.

If you haven't heard of Grails, or would like to know more, I have a short
post here at:

http://tapestryofthoughts.blogspot.com/2007/05/grails-rails-gone-groovy.html

For more in-depth, there's the Grails site at:

http://grails.codehaus.org/

-jjk
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] css class for DataTable column?

2007-05-17 Thread Igor Vaynberg

i believe matej is working on this, no?

-igor


On 5/17/07, Andrew Klochkov [EMAIL PROTECTED] wrote:


What's the best way to add css class to a DataTable column?
The only way I see is to extend Panel and use it as a headers toolbar,
but I'd like to have all the functionality the HeadersToolbar already has!

--
Andrew Klochkov


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] script in head breaking page parameters

2007-05-17 Thread Igor Vaynberg

please open a bug, and if you can provide a quickstart that reproduces it.
alternatively turn off auto-multi-window support in settings as a workaround
- that is what is causing this javascript/redirect.

-igor


On 5/17/07, Markus Sabadello [EMAIL PROTECTED] wrote:


Hi,

I have a page (a google gadget) which is going to be called from an
external source with parameters. Here is an example URL:

http://www.freexri.com/tools/GadgetExec?resolveType=SEP

So I set up a QueryStringUrlCodingStrategy, thinking that my page will be
constructed with a nice PageParameters argument.
This basically works fine, but when the page is rendered, it contains the
following script in the head:

script type=text/javascript !--/*--![CDATA[/*!--*/
if (window.name=='') { 
window.location=/tools/GadgetExec?resolveType=%5BLjava.lang.String%3B%401a0ae6dwicket:pageMapName=wicket-1;
}
/*--]]*//script

So the page is basically invoked a second time with the following URL:


http://www.freexri.com/tools/GadgetExec?resolveType=%5BLjava.lang.String%3B%401a0ae6dwicket:pageMapName=wicket-1

Now when I read the resolveType parameter, it only contains nonsense
(%5BLjava.lang.String%3B%401a0ae6d).

To me it looks like a String array gets toString()ed, but why does Wicket
mess it up like that?

Happy about any help
Markus


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] How can I pass in the user's login and password to avoid the login page?

2007-05-17 Thread Thomas R. Corbin

Our client unfortunately wants to have urls be able to contain the user's 
login and a hashed/encrypted password so that the user can avoid having to 
waste time on the login page.   We can't really convince them that it may not 
be a good idea.   Essentially they want single-signon, but they're not 
prepared to work with the it department on that at this time (and I'm not 
sure how to do that in wicket yet, either).   So what they really, really 
want is that when our swing app brings up a web page in a browser, we add the 
user's login and hashed password to the url.

But I'm having trouble figuring out how or where to grab that info and bypass 
the login page redirect, and the login page can't seem to grab that info from 
the request.Which makes sense since the page parameters are normally 
really for the original page and not the login page.

I've been looking at: AuthenticatedWebApplicationonUnauthorizedInstantiation, 
but it's final so I can't override it, and I'm not really sure if it's the 
right place anyway.   I've added my own 
IUnauthorizedComponentInstantiationListener, but I'm not sure how to get the 
request parameters in the listener.

Does anyone have any hints?

Thanks,
Tom

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread Thomas R. Corbin
On Thursday 17 May 2007 11:04 am, Julian Klappenbach escreveu:
 http://graemerocher.blogspot.com/2007/05/grails-wicket-wonders-of-grails-pl
ug-in.html (SFW)

 Graeme pinged me as soon as I got online this morning to tell me about his
 work on integrating Wicket and Groovy, a Rails implementation based on the
 Java scripting language, Groovy.

 As you'll read, the integration took him *20 minutes*, and the result was
 the following:

1. Wicket classes can be utilized as-is from wicket jars inside a
Groovy environment, meaning that there's no concern of keeping a
Groovy-based mirror of Wicket synchronized.
2. Wicket classes can take advantage of GORM, with dynamic methods
(This is very, very, cool)
3. Developers can take advantage of closures, and all other nice
features of Groovy

 Graeme warned me that he hadn't tested much more than a Hello World
 example.  But in getting even those two simple words out, a lot had to be
 going on under the hood.  I'd be surprised if there were issues lurking
 beyond.

 If you haven't heard of Grails, or would like to know more, I have a short
 post here at:

 http://tapestryofthoughts.blogspot.com/2007/05/grails-rails-gone-groovy.htm
l

 For more in-depth, there's the Grails site at:

 http://grails.codehaus.org/

wicket-grails would be truly cool.   I'm using groovy in some code 
backing 
some of my pages and it's pretty cool.   Especially with having spring being 
able to reload those groovy beans.Only problem for us is that our client 
won't let us use hibernate. ;(

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] [Request for enhancement] TabbedPanel

2007-05-17 Thread Alex Objelean

Thank you Igor!

Jira issue created:

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

Alex.


igor.vaynberg wrote:
 
 looks like i wont be able to get to it immediately, please add an rfe and
 i
 will prob do it over the weekend.
 
 -igor
 
 
 On 5/17/07, Alex Objelean [EMAIL PROTECTED] wrote:


 Yes, it is acceptable an solution...
 Also, I thought about somehow dynamically providing markup for the
 tab-row
 container, or having a possibility to decorate it with you own
 container...
 any thoughts?


 igor.vaynberg wrote:
 
  i dont like adding a container that users can mock with. if you want to
 go
  that far then just create your own tabbedpanel, its only a few lines of
  code. what i can see is some overridable method to add a css class to
 that
  tab row, will that work?
 
  -igor
 
 
  On 5/16/07, Alex Objelean [EMAIL PROTECTED] wrote:
 
 
  Though it can be a solution, it is not a natural one... because I want
 to
  make the difference between outer and inner tab-row, not between outer
 vs
  inner tab-panel.
 
 
  John Krasnay wrote:
  
   Ahh, I see...the problem is *nested* tabs. Sorry for not picking
 that
  up
   earlier. However, I think the same principle applies, no? Just give
 the
   inner tab panel a different CSS class than the outer one.
  
   jk
  
   On Wed, May 16, 2007 at 07:39:04AM -0700, Alex Objelean wrote:
  
   This solution adds the css class the the entire tabbedPanel
 container,
   subsequently all nested tabbedPanels will be treated the same
 way
   What I
   need is to identify the tab-row container
  
  
   John Krasnay wrote:
   
In fact now that I think of it, you don't even need the wrapper
 div.
Remember that the TabbedPanel renders the tabs *inside* the tag
 to
which it's attached. That tag can contain the CSS class that
 makes
  that
set of tabs unique:
   
  div wicket:id=tabs class=greentabs/div
   
  add(new TabbedPanel(tabs, tabs));
   
The result is like this:
   
  div class=greentabs
div class=tab-row
...
/div
  /div
   
If you need to determine the class dynamically, just add an
  appropriate
behaviour to the TabbedPanel:
   
  add(new TabbedPanel(tabs, tabs)
.add(new AttributeModifier(class, new
 Model(purpletabs;
   
jk
   
On Wed, May 16, 2007 at 06:28:57AM -0700, Alex Objelean wrote:
   
That is the problem. How can I attach a WebMarkupContainer to a
   tab-row
container?
The markup is generated by TabbedPanel and I cannot manipulate
 it's
markup... :(
   
   
Hi Alex,
   
The way I've tackled this is to have a wrapper div around the
  entire
   tab
panel, like so...
   
div class=mytabs
  div class=tab-row
ul
  ...
/ul
  /div
/div
   
You just need to add the wrapper div to your CSS selector:
   
div.mytabs li {
  background-color: green;
}
   
Then you can have different wrapper divs for different styling:
   
div.othertabs li {
  background-color: purple;
}
   
If you need to dynamically manipulate the wrapper div, simply
  attach
  a
WebMarkupContainer to it.
   
HTH
   
jk
   
On Wed, May 16, 2007 at 04:33:37AM -0700, Alex Objelean wrote:

 Currently, the markup generated for the tabbedPanel component
  looks
like
 this:

 [code]
 wicket:panel
 div class=tab-row
 ul
 li wicket:id=tabs
  # [[tab title]]
 /li
 /ul
 /div
 [panel]
 /wicket:panel
 [/code]

 I think that it would be more useful to add a container to the
   existing
 tabs, so the resulted markup would look like this:

 [code]
 wicket:panel
 div wicket:id=tabsContainer class=tab-row
 ul
 li wicket:id=tabs
  # [[tab title]]
 /li
 /ul
 /div
 [panel]
 /wicket:panel
 [/code]

 This way you can append a new css class to this container
 (using
 AttributeAppender behavior) and can control the specific
 visual
appearance
 of the tabbed panel... It is not enough to have only tab-row
   class,
 because if you have nested tabbed panels (which have different
   styling)
it
 is hard to style them as you want... And finally, you give the
developer a
 freedom to do what he wants with this container...

 What do you think?

 Thank you!

   
--
View this message in context:
   
  
 
 http://www.nabble.com/-Request-for-enhancement--TabbedPanel-tf3764064.html#a10641787
Sent from the Wicket - User mailing list archive at Nabble.com.
   
   
   
  
 
 -
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and
 take
control of your XML. No limits. 

[Wicket-user] DateField initializes value to current date

2007-05-17 Thread Dragos Bobes
I have a form with a not required date field. The problem is that when 
the form is submitted and no value was selected in the date field, the 
date field is initialized to current date.
Is this an intended behaviour and if yes how can I avoid it.
I pasted an example code bellow.

Thanks
Dragos

import java.util.Date;

import org.apache.wicket.markup.html.WebPage;
import org.apache.wicket.markup.html.form.Button;
import org.apache.wicket.markup.html.form.Form;
import org.apache.wicket.model.CompoundPropertyModel;
import org.apache.wicket.extensions.yui.calendar.DateField;

public class DateTest extends WebPage {

private Date _date;
   
public DateTest() {
Form form = new Form(myForm, new CompoundPropertyModel(this));
add(form);
form.add(new DateField(date));
form.add(new Button(btn));
}
   
public Date getDate() {
System.out.println(get date  + _date);
return _date;
}
   
public void setDate(Date date) {
System.out.println(set date  + date);
_date = date;
}
}


  form wicket:id=myForm
  span wicket:id=date /span
  input type=submit wicket:id=btn /
  /form

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Page Expiration when first clicking AJAX

2007-05-17 Thread Jonathan Locke


Did we find a resolution for this yet?  We are having the same problem in
Wicket 1.3 trunk and I'm about to start investigating.  Any definite
information or conclusions (whether complete or not) would be very much
appreciated.


Andrew Berman wrote:
 
 I am having a strange issue.  If I access my site for the first time (I
 clear all cookies, sessions, and cache before going to the site), the page
 comes up fine.  However, if I click one of the AJAX links, I get a page
 expired error.  Any thoughts why this is happening?  I see it create a new
 session and the cookie, but it looks like the Ajax link is not valid for
 some reason.  I am using Wicket 1.2.6.  Any thoughts?
 
 Thanks for any help,
 
 Andrew
 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 
http://www.nabble.com/Page-Expiration-when-first-clicking-AJAX-tf3729176.html#a10669922
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] How can I pass in the user's login and password to avoid the login page?

2007-05-17 Thread Igor Vaynberg

i would extend webrequestcodingstrategy, override encode() and append the
parameters you need to the url it normally returns.

-igor

On 5/17/07, Thomas R. Corbin [EMAIL PROTECTED] wrote:



Our client unfortunately wants to have urls be able to contain the user's
login and a hashed/encrypted password so that the user can avoid having to
waste time on the login page.   We can't really convince them that it may
not
be a good idea.   Essentially they want single-signon, but they're not
prepared to work with the it department on that at this time (and I'm not
sure how to do that in wicket yet, either).   So what they really, really
want is that when our swing app brings up a web page in a browser, we add
the
user's login and hashed password to the url.

But I'm having trouble figuring out how or where to grab that info and
bypass
the login page redirect, and the login page can't seem to grab that info
from
the request.Which makes sense since the page parameters are normally
really for the original page and not the login page.

I've been looking at:
AuthenticatedWebApplicationonUnauthorizedInstantiation,
but it's final so I can't override it, and I'm not really sure if it's the
right place anyway.   I've added my own
IUnauthorizedComponentInstantiationListener, but I'm not sure how to get
the
request parameters in the listener.

Does anyone have any hints?

Thanks,
Tom

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] autolink-problem with img and relative path

2007-05-17 Thread Thomas Singer
Is everybody of the wicket-team celebrating Ascension Day? ;) I really would 
like to get that issue solved before becoming a father tomorrow. Thanks in 
advance.

Tom


Thomas Singer wrote:
 Maybe the answer to the following question is the problem's solution:
 How it is intented to add an own IAutolinkResolverDelegate to the
 AutoLinkResolver?
 
 Tom
 
 
 Thomas Singer wrote:
 I have a WebPage pages.Index (mapping to /index.html) whose markup 
 contains an img-tag with the relative path ../../../screenshots/foo.png 
 (the 1st ../ to get out of the pages-package, the 2nd ../ to get out 
 of the classes-directory, the third ../ to get out of the 
 WEB-INF-directory). This has the advantage, that the path is already
 valid 
 in my undeployed project.

 Unfortunately, the autolink resolver seems not able to convert it to a
 valid 
 path:

 java.lang.IllegalArgumentException: Invalid path
 ../../../screenshots/foo.png
  at wicket.util.lang.Packages.absolutePath(Packages.java:109)
  at wicket.util.lang.Packages.absolutePath(Packages.java:46)
  at
 wicket.markup.html.PackageResource.exists(PackageResource.java:263)
  at
 wicket.markup.resolver.AutoLinkResolver$ResourceReferenceAutolink.init(AutoLinkResolver.java:547)
  at
 wicket.markup.resolver.AutoLinkResolver$AbstractAutolinkResolverDelegate.newPackageResourceReferenceAutoComponent(AutoLinkResolver.java:118)
  at
 wicket.markup.resolver.AutoLinkResolver$ResourceReferenceResolverDelegate.newAutoComponent(AutoLinkResolver.java:620)
  at
 wicket.markup.resolver.AutoLinkResolver.resolveAutomaticLink(AutoLinkResolver.java:832)
  at
 wicket.markup.resolver.AutoLinkResolver.resolve(AutoLinkResolver.java:763)
  at wicket.MarkupContainer.renderNext(MarkupContainer.java:1361)
 ...
 I would have expected it to convert the path to /screenshots/foo.png.
 How 
 can I work around this issue? Is it possible to plug in an own resolver 
 implementation? If so, where can I find some documentation (beside digging 
 the source code)?

 

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] [Request for enhancement] TabbedPanel

2007-05-17 Thread eddmosphere

That would be niceee! :D

Edd



igor.vaynberg wrote:
 
 looks like i wont be able to get to it immediately, please add an rfe and
 i
 will prob do it over the weekend.
 
 -igor
 
 
 On 5/17/07, Alex Objelean [EMAIL PROTECTED] wrote:


 Yes, it is acceptable an solution...
 Also, I thought about somehow dynamically providing markup for the
 tab-row
 container, or having a possibility to decorate it with you own
 container...
 any thoughts?


 igor.vaynberg wrote:
 
  i dont like adding a container that users can mock with. if you want to
 go
  that far then just create your own tabbedpanel, its only a few lines of
  code. what i can see is some overridable method to add a css class to
 that
  tab row, will that work?
 
  -igor
 
 
  On 5/16/07, Alex Objelean [EMAIL PROTECTED] wrote:
 
 
  Though it can be a solution, it is not a natural one... because I want
 to
  make the difference between outer and inner tab-row, not between outer
 vs
  inner tab-panel.
 
 
  John Krasnay wrote:
  
   Ahh, I see...the problem is *nested* tabs. Sorry for not picking
 that
  up
   earlier. However, I think the same principle applies, no? Just give
 the
   inner tab panel a different CSS class than the outer one.
  
   jk
  
   On Wed, May 16, 2007 at 07:39:04AM -0700, Alex Objelean wrote:
  
   This solution adds the css class the the entire tabbedPanel
 container,
   subsequently all nested tabbedPanels will be treated the same
 way
   What I
   need is to identify the tab-row container
  
  
   John Krasnay wrote:
   
In fact now that I think of it, you don't even need the wrapper
 div.
Remember that the TabbedPanel renders the tabs *inside* the tag
 to
which it's attached. That tag can contain the CSS class that
 makes
  that
set of tabs unique:
   
  div wicket:id=tabs class=greentabs/div
   
  add(new TabbedPanel(tabs, tabs));
   
The result is like this:
   
  div class=greentabs
div class=tab-row
...
/div
  /div
   
If you need to determine the class dynamically, just add an
  appropriate
behaviour to the TabbedPanel:
   
  add(new TabbedPanel(tabs, tabs)
.add(new AttributeModifier(class, new
 Model(purpletabs;
   
jk
   
On Wed, May 16, 2007 at 06:28:57AM -0700, Alex Objelean wrote:
   
That is the problem. How can I attach a WebMarkupContainer to a
   tab-row
container?
The markup is generated by TabbedPanel and I cannot manipulate
 it's
markup... :(
   
   
Hi Alex,
   
The way I've tackled this is to have a wrapper div around the
  entire
   tab
panel, like so...
   
div class=mytabs
  div class=tab-row
ul
  ...
/ul
  /div
/div
   
You just need to add the wrapper div to your CSS selector:
   
div.mytabs li {
  background-color: green;
}
   
Then you can have different wrapper divs for different styling:
   
div.othertabs li {
  background-color: purple;
}
   
If you need to dynamically manipulate the wrapper div, simply
  attach
  a
WebMarkupContainer to it.
   
HTH
   
jk
   
On Wed, May 16, 2007 at 04:33:37AM -0700, Alex Objelean wrote:

 Currently, the markup generated for the tabbedPanel component
  looks
like
 this:

 [code]
 wicket:panel
 div class=tab-row
 ul
 li wicket:id=tabs
  # [[tab title]]
 /li
 /ul
 /div
 [panel]
 /wicket:panel
 [/code]

 I think that it would be more useful to add a container to the
   existing
 tabs, so the resulted markup would look like this:

 [code]
 wicket:panel
 div wicket:id=tabsContainer class=tab-row
 ul
 li wicket:id=tabs
  # [[tab title]]
 /li
 /ul
 /div
 [panel]
 /wicket:panel
 [/code]

 This way you can append a new css class to this container
 (using
 AttributeAppender behavior) and can control the specific
 visual
appearance
 of the tabbed panel... It is not enough to have only tab-row
   class,
 because if you have nested tabbed panels (which have different
   styling)
it
 is hard to style them as you want... And finally, you give the
developer a
 freedom to do what he wants with this container...

 What do you think?

 Thank you!

   
--
View this message in context:
   
  
 
 http://www.nabble.com/-Request-for-enhancement--TabbedPanel-tf3764064.html#a10641787
Sent from the Wicket - User mailing list archive at Nabble.com.
   
   
   
  
 
 -
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and
 take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

Re: [Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread howzat

Without going into too much detail about how Grails works (I expect there is
plenty of info on the web about this), could you give us a bit more of an
idea about why this love-child is a cool idea and how a Wicket user
would benefit from working with Wicket+Grails on top of, for example,
Hibernate  Spring? 
What is in Grails that would make Wicket better for web-app development? 
Is it just the integration of Groovy or is there something more for a Wicket
user? 



jklappenbach wrote:
 
 http://graemerocher.blogspot.com/2007/05/grails-wicket-wonders-of-grails-plug-in.html
 (SFW)
 
 Graeme pinged me as soon as I got online this morning to tell me about his
 work on integrating Wicket and Groovy, a Rails implementation based on the
 Java scripting language, Groovy.
 
 As you'll read, the integration took him *20 minutes*, and the result was
 the following:
 
1. Wicket classes can be utilized as-is from wicket jars inside a
Groovy environment, meaning that there's no concern of keeping a
Groovy-based mirror of Wicket synchronized.
2. Wicket classes can take advantage of GORM, with dynamic methods
(This is very, very, cool)
3. Developers can take advantage of closures, and all other nice
features of Groovy
 
 Graeme warned me that he hadn't tested much more than a Hello World
 example.  But in getting even those two simple words out, a lot had to be
 going on under the hood.  I'd be surprised if there were issues lurking
 beyond.
 
 If you haven't heard of Grails, or would like to know more, I have a short
 post here at:
 
 http://tapestryofthoughts.blogspot.com/2007/05/grails-rails-gone-groovy.html
 
 For more in-depth, there's the Grails site at:
 
 http://grails.codehaus.org/
 
 -jjk
 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 
http://www.nabble.com/Gricket%3A-The-Love-Child-of-Grails-and-Wicket-tf3772804.html#a10670591
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Custom Message Resolver

2007-05-17 Thread Scott Sauyet
I did warn you [1] I'd be back!  :-)

It looks like I will be using Wicket for my next project, but I ran into 
an interesting little issue that I'm not sure how to solve.  How can I 
allow templates that have something like wicket:message's included but 
with my own custom resolver?

The application will have multiple deployments, and each customer will 
be able to tweak the look and feel of the output.  Most of that will be 
handled by CSS changes and choices of several pre-built HTML templates. 
  But there will also be a need for certain sections of the templates to 
be customizable to allow what is essentially free-form data including 
arbitrary name-value pairs.  There will be real logic involved in 
looking up the dynamic value for each name, and I can't simply stick the 
data in properties file.

Since each installation will only serve one language, i18n will not be 
an issue, so I might be able to do this by replacing the 
WicketMessageResolver with a custom implementation.  Or I could add my 
own IComponentResolver.  But are there extension points that would let 
me do either of these, or will I have to hack up my own version of 
Wicket just for this?

Or, even better, is there something already in place that would simply 
let me hook in a custom means of resolving either the message key or my 
own construct?

   -- Scott

[1] http://tinyurl.com/2jqy48


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread Thomas R. Corbin
On Thursday 17 May 2007 2:19 pm, howzat escreveu:
 Without going into too much detail about how Grails works (I expect there
 is plenty of info on the web about this), could you give us a bit more of
 an idea about why this love-child is a cool idea and how a Wicket user
 would benefit from working with Wicket+Grails on top of, for example,
 Hibernate  Spring?
 What is in Grails that would make Wicket better for web-app development?
 Is it just the integration of Groovy or is there something more for a
 Wicket user?

I think the groovy integration is a good start, though you certainly 
don't 
need grails for that.   In fact there's a wicket-contrib-groovy project 
already underway.

But grails seems like an interesting project and wicket is certainly 
lots of 
fun.   But it all depends on how well the integration works, and I'm not sure 
about that part of it.   It seems like GORM and some of grails other tools 
could be quite nice, though there's already the databinder stuff.   If you're 
an avid fan of groovy, then you also get the groovy configuration of spring 
rather than the xml configuration.   From the blog entry in the original 
email, it looks like they even do groovy configuration of the web.xml file.   
So a lot of it depends on how much you like grails and groovy and how well 
the integration is done.



 jklappenbach wrote:
  http://graemerocher.blogspot.com/2007/05/grails-wicket-wonders-of-grails-
 plug-in.html (SFW)
 
  Graeme pinged me as soon as I got online this morning to tell me about
  his work on integrating Wicket and Groovy, a Rails implementation based
  on the Java scripting language, Groovy.
 
  As you'll read, the integration took him *20 minutes*, and the result was
  the following:
 
 1. Wicket classes can be utilized as-is from wicket jars inside a
 Groovy environment, meaning that there's no concern of keeping a
 Groovy-based mirror of Wicket synchronized.
 2. Wicket classes can take advantage of GORM, with dynamic methods
 (This is very, very, cool)
 3. Developers can take advantage of closures, and all other nice
 features of Groovy
 
  Graeme warned me that he hadn't tested much more than a Hello World
  example.  But in getting even those two simple words out, a lot had to be
  going on under the hood.  I'd be surprised if there were issues lurking
  beyond.
 
  If you haven't heard of Grails, or would like to know more, I have a
  short post here at:
 
  http://tapestryofthoughts.blogspot.com/2007/05/grails-rails-gone-groovy.h
 tml
 
  For more in-depth, there's the Grails site at:
 
  http://grails.codehaus.org/
 
  -jjk
 
  -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Append custom req paramaters to AjaxLink

2007-05-17 Thread mchack

Would it be possible or reasonable to extend an AjaxLink to include
additional request parameters. My reason is that I would like to include
multiple AjaxLinks in a page and would like to only define one anonymous
inner class to handle the requests, using unique request parameters to
distinguish between the requests. This would make my page generation more
efficient and would eliminate the creation of unnecessary server side
objects.

Thanks
-- 
View this message in context: 
http://www.nabble.com/Append-custom-req-paramaters-to-AjaxLink-tf3773939.html#a10671020
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread Julian Klappenbach

Grails integrates Hibernate and Spring together, automatically generating
the clue-code of descriptors and general lifecycle / management code that is
necessary for implementation, but not by the application developer.  Groovy
has a lot of strength as a scripting language (that gets compiled down to
byte code), and I think there are some who just prefer the syntax, grammar,
and the types of expressions that have the flavor of Java but the freedom
not commonly associated with it.

But, beyond that, there's the GORM layer, which is the innovation that
Rails based application frameworks bring to the table.  I've long joked
about the development of a DWIM function (Do What I Mean), where you
wouldn't have to write a line of code, just define meta-data...  That's
essentially what GORM does.  Most middle tier functionality is focused on
database model accessors, the getters and setters of the database via
entities or domain objects.  Largely, the code one writes to filter result
sets is boilerplate, an idea that Rails architects acknowledged and solved.
For example, you can execute the following method without ever having
implemented it:

gorm.getUserByFirstNameAndZipCode(...)

The runtime will parse the method name using camel-case and naming
conventions, and derive the expected method signature, as well as the
associated business logic to execute.  The result is the desired set of
business objects, and again, you don't have to write a single line of code
other than the definition of your domain objects.  I've looked over the code
that performs the parsing and execution, and there's not a huge price to pay
for it.

Altogether, adding Wicket to a Grails opens a lot of doors.

The only problem with Grails in the past, and the RoR family in general, is
that they've focused on an MVC architecture.  This runs counter to the
Wicket spirit of doing things.  That Graeme was able to demonstrate kicking
the Spring MVC controller out in favor of Wicket proved to me that Grails is
more than a RoR knock-off.  It's a viable model to consider for future
projects.

Still a few things to iron out, but I'm impressed.

-jjk

On 5/17/07, howzat [EMAIL PROTECTED] wrote:



Without going into too much detail about how Grails works (I expect there
is
plenty of info on the web about this), could you give us a bit more of an
idea about why this love-child is a cool idea and how a Wicket user
would benefit from working with Wicket+Grails on top of, for example,
Hibernate  Spring?
What is in Grails that would make Wicket better for web-app development?
Is it just the integration of Groovy or is there something more for a
Wicket
user?



jklappenbach wrote:


http://graemerocher.blogspot.com/2007/05/grails-wicket-wonders-of-grails-plug-in.html
 (SFW)

 Graeme pinged me as soon as I got online this morning to tell me about
his
 work on integrating Wicket and Groovy, a Rails implementation based on
the
 Java scripting language, Groovy.

 As you'll read, the integration took him *20 minutes*, and the result
was
 the following:

1. Wicket classes can be utilized as-is from wicket jars inside a
Groovy environment, meaning that there's no concern of keeping a
Groovy-based mirror of Wicket synchronized.
2. Wicket classes can take advantage of GORM, with dynamic methods
(This is very, very, cool)
3. Developers can take advantage of closures, and all other nice
features of Groovy

 Graeme warned me that he hadn't tested much more than a Hello World
 example.  But in getting even those two simple words out, a lot had to
be
 going on under the hood.  I'd be surprised if there were issues lurking
 beyond.

 If you haven't heard of Grails, or would like to know more, I have a
short
 post here at:


http://tapestryofthoughts.blogspot.com/2007/05/grails-rails-gone-groovy.html

 For more in-depth, there's the Grails site at:

 http://grails.codehaus.org/

 -jjk


-
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



--
View this message in context:
http://www.nabble.com/Gricket%3A-The-Love-Child-of-Grails-and-Wicket-tf3772804.html#a10670591
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net

[Wicket-user] Process Page After Redirect

2007-05-17 Thread Joe Toth

I have a Template class that each page extends. In the template it does...

*boolean* isSecure = ((WebRequest) WebRequestCycle.*get*().getRequest*()).*
getHttpServletRequest().isSecure();
String url = http://www.google-analytics.com/urchin.js;
*if* (isSecure) {
   url = https://ssl.google-analytics.com/urchin.js;
}
...to determine which url to use.

I'm using http://cwiki.apache.org/WICKET/how-to-switch-to-ssl-mode.html to
switch to SSL mode.

The problem I'm having is when I'm not in SSL mode and I click on a link to
a page that should be in SSL. I think the following happens:
1. The requested page get processed
2. The redirect to SSL mode occurs to the page that is has just been
processed.

I need it to process the page AFTER the redirect occurs so when I call
httpRequest.isSecure() it will return true.

How can I achieve this?

Thanks!
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Vertical Tabs

2007-05-17 Thread eddmosphere

How would I do that? Not sure I understood..

Thanks, Edd


igor.vaynberg wrote:
 
 if you set a class on the tab panel then you can use that class to scope
 the
 css styles properly
 
 -igor
 
 
 On 2/20/07, burnayev [EMAIL PROTECTED] wrote:


 Thank you Igor.

 I'm trying to implement nested tabs - basic navigation pattern where you
 have horizontal tabs on top and vertical tabs at left within a particular
 tab panel.

 I fiddled a little with styling the inner tabs and haven't come to a
 satisfactory result so far. The problem seems to be the fact that both
 tab
 panels internally use the same CSS classes for styling, namely tab-row
 and
 tab-panel.

 Is there a way to dynamically change the associated classes?

 Thanks,
 Borys


 igor.vaynberg wrote:
 
  you can style tabbedpanel in extensions
 
  the tabs are just a ul
 
  -igor
 
 
  On 2/19/07, burnayev [EMAIL PROTECTED] wrote:
 
 
  How do I create vertically stacked tabs? Is it possible to style
 and/or
  extend the extensions tab component or do I have to create my own?
  --
 

 --
 View this message in context:
 http://www.nabble.com/Vertical-Tabs-tf3254943.html#a9062788
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 Take Surveys. Earn Cash. Influence the Future of IT
 Join SourceForge.net's Techsay panel and you'll get the chance to share
 your
 opinions on IT  business topics through brief surveys-and earn cash
 http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

 
 -
 Take Surveys. Earn Cash. Influence the Future of IT
 Join SourceForge.net's Techsay panel and you'll get the chance to share
 your
 opinions on IT  business topics through brief surveys-and earn cash
 http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 
http://www.nabble.com/Vertical-Tabs-tf3254943.html#a10671840
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] How can I pass in the user's login and password to avoid the login page?

2007-05-17 Thread Thomas R. Corbin
On Thursday 17 May 2007 2:08 pm, Igor Vaynberg escreveu:
 i would extend webrequestcodingstrategy, override encode() and append the
 parameters you need to the url it normally returns.

Sorry, but I didn't quite understand how to get the parameters I need 
in the 
encode method, nor how appending it would resolve the issue.   I think I just 
don't quite get the encode method/encoding strategy anyway.

What I did instead was to provide my own RequestCycle class and in 
onBeginRequest, look at the HttpServletRequest's uri and pull out the info I 
need and then call 

AuthenticatedWebSession.get().signIn( userName, hashedPassword )

I am not sure it's entirely robust, but it does seem to work pretty 
well.   I 
think that in the encoding strategy code I could do pretty much the same 
thing, but the onBeginRequest method seems like a good place for it.  It's 
only that maybe in the encoding strategy code I might have a shot at a 
RequestParameters object with the url info I need so I wouldn't need to parse 
the uri?

Do you think I'm heading for trouble this way?
Thanks,
Tom


 -igor

 On 5/17/07, Thomas R. Corbin [EMAIL PROTECTED] wrote:
  Our client unfortunately wants to have urls be able to contain the user's
  login and a hashed/encrypted password so that the user can avoid having
  to waste time on the login page.   We can't really convince them that it
  may not
  be a good idea.   Essentially they want single-signon, but they're not
  prepared to work with the it department on that at this time (and I'm not
  sure how to do that in wicket yet, either).   So what they really, really
  want is that when our swing app brings up a web page in a browser, we add
  the
  user's login and hashed password to the url.
 
  But I'm having trouble figuring out how or where to grab that info and
  bypass
  the login page redirect, and the login page can't seem to grab that info
  from
  the request.Which makes sense since the page parameters are normally
  really for the original page and not the login page.
 
  I've been looking at:
  AuthenticatedWebApplicationonUnauthorizedInstantiation,
  but it's final so I can't override it, and I'm not really sure if it's
  the right place anyway.   I've added my own
  IUnauthorizedComponentInstantiationListener, but I'm not sure how to get
  the
  request parameters in the listener.
 
  Does anyone have any hints?
 
  Thanks,
  Tom
 
  -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Accessing a static resource in my webapp dir

2007-05-17 Thread Matt Welch

Putting shared css and javascript resource into the java package hierarchy
would seem to eliminate one of the advantages of using a framework like
Wicket; the clean separation of  responsibilities between HTML page
developers and java developers. Of course, I'm probably already long past
the point of no return in that respect because of the need to put the HTML
templates in the java package hierarchy. Oh well. I'll probably do as you
suggest and put the file in the java package. Thanks for making me aware of
that option.

As far as the version goes, I'm using the maven snapshots available using
the following repository:
   repository
   idWicket/id
   urlhttp://wicketstuff.org/maven/repository/url
   snapshots
   enabledtrue/enabled
   /snapshots
   releases
   enabledfalse/enabled
   /releases
   /repository

and this is the dependency definition:

   dependency
   groupIdorg.apache.wicket/groupId
   artifactIdwicket/artifactId
   version1.3.0-incubating-SNAPSHOT/version
   /dependency

Is there a newer/better way? We tried to use the incubating-beta1 version
but had a dependency problem with something related to jdk 1.4.

-Matt


On 5/15/07, Igor Vaynberg [EMAIL PROTECTED] wrote:


what version are you using? if you are using a recent trunk (1 day old)
please report this as a bug.

-igor


On 5/15/07, Matt Welch  [EMAIL PROTECTED] wrote:

 I have a stylesheet called base.css that sits in a directory called
 styles that is in my base webapp directory. I have the following
 stylesheet reference in an HTML template called Login.html:

 link rel=stylesheet type=text/css href=styles/base.css
 media=screen /

 When I go to the login page, the browser URL looks like the following:

 http://132.253.103.70:8080/daily/app/pages/Login

 Note that daily is the name of the webapp, and app is the name of
 the wicket application.

 If I look at the source of the page in my browser, the stylesheet
 reference has been modified to look like:

 link href=../../../styles/base.css rel=stylesheet
 type=text/css media=screen/

 It looks like this was resolved with one too many ../. Is this a bug
 or am I doing something wrong in my configuration? Is there a better way to
 deal with my stylesheets and other static resources that aren't explicitly
 part of a component?

 Thanks!
 Matt




 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Custom Message Resolver

2007-05-17 Thread Juergen Donnerstag
Wicket is very flexible and modular. You can write your own
MyWicketMessageResolver and register it with the application. How to
do it? Just see how WicketMessageResolver is registered. It is realy
simple.

I don't see how IComponentResolver can help you, but may I missed the point.

Looking at Localizer and how it works to find a property value might
help you as well.

Juergen

On 5/17/07, Scott Sauyet [EMAIL PROTECTED] wrote:
 I did warn you [1] I'd be back!  :-)

 It looks like I will be using Wicket for my next project, but I ran into
 an interesting little issue that I'm not sure how to solve.  How can I
 allow templates that have something like wicket:message's included but
 with my own custom resolver?

 The application will have multiple deployments, and each customer will
 be able to tweak the look and feel of the output.  Most of that will be
 handled by CSS changes and choices of several pre-built HTML templates.
   But there will also be a need for certain sections of the templates to
 be customizable to allow what is essentially free-form data including
 arbitrary name-value pairs.  There will be real logic involved in
 looking up the dynamic value for each name, and I can't simply stick the
 data in properties file.

 Since each installation will only serve one language, i18n will not be
 an issue, so I might be able to do this by replacing the
 WicketMessageResolver with a custom implementation.  Or I could add my
 own IComponentResolver.  But are there extension points that would let
 me do either of these, or will I have to hack up my own version of
 Wicket just for this?

 Or, even better, is there something already in place that would simply
 let me hook in a custom means of resolving either the message key or my
 own construct?

-- Scott

 [1] http://tinyurl.com/2jqy48


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Append custom req paramaters to AjaxLink

2007-05-17 Thread mchack

Johan, thanks for the response. It still appears that I will be instantiating
multiple AjaxLink(s), one for each unique link. In a stateful page these
would be stored in the session. By moving some state to the client it
appears that it might be possible to reduce the number of server side
objects that would be retained in the session. Pardon me if I am missing
something. 

I was looking at this for something like a panel that provided links to say
multiple press releases. When the link was selected it would call common
Ajax on click handler and infer the item to be presented by unique request
parameter. There could be many links and also many concurrent sessions so I
was a bit worried about reducing impact from a session standpoint.

I am new to the framework and am trying to come up to speed as quickly as
possible, but am very favorably impressed.




Johan Compagner wrote:
 
 you can use one anonymous innerclass just fine for multiply ajax links
 just give the seperate instances the state you want on the server side
 why push that to the client?
 
 AjaxLink link1 = AjaxLink(link1, new Model(mystate1))
 AjaxLink link2 = AjaxLink(link2, new Model(mystate2))
 
 onClick()
 {
  State state = getModel()
  // do something
 }
 
 johan
 
 
 
 On 5/17/07, mchack [EMAIL PROTECTED] wrote:


 Would it be possible or reasonable to extend an AjaxLink to include
 additional request parameters. My reason is that I would like to include
 multiple AjaxLinks in a page and would like to only define one anonymous
 inner class to handle the requests, using unique request parameters to
 distinguish between the requests. This would make my page generation more
 efficient and would eliminate the creation of unnecessary server side
 objects.

 Thanks
 --
 View this message in context:
 http://www.nabble.com/Append-custom-req-paramaters-to-AjaxLink-tf3773939.html#a10671020
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 
http://www.nabble.com/Append-custom-req-paramaters-to-AjaxLink-tf3773939.html#a10672578
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Vertical Tabs

2007-05-17 Thread John Krasnay
I tried to explain this in an earlier thread, but I'm afraid I wasn't
too successful. I'll give it another shot. Suppose your outer tabs are
defined on a page like this:

  div wicket:id=outerTabs class=outerTabs/div

When you attached the TabbedPanel component to it, it renders like this:

  div class=outerTabs
div class=tab-row
  ul
lia href=.../li
  /ul
/div
span class=tab-panel...your panel.../span
  /div

You can make them horizontal by doing something like this in CSS:

  div.outerTabs li { display: inline; }

Now, suppose your panel has a set of inner tabs, with this markup:

  div wicket:id=innerTabs class=innerTabs/div

The rendered HTML now looks like this:

  div class=outerTabs
div class=tab-row
  ul
lia href=.../li
  /ul
/div
span class=tab-panel
  div class=innerTabs
div class=tab-row
  ul
lia href=.../li
  /ul
/div
span class=tab-panel
  your inner panel
/span
  /div
/span
  /div

To make the inner ones vertical, you'll want to float the inner tab row
left and render it's li's as blocks:

  div.innerTabs div.tab-row { float: left; }
  div.innerTabs li { display: block; }

You'll have to play a bit with the CSS to get it nice, but that's the
general idea.

The only tricky part is that the inner li elements are styled by both
the (div.outerTabs li) and (div.innerTabs li) elements, so you have to
make sure of the following:

1. put the (div.innerTabs li) later in the stylesheet, so that it's
properties override those from (div.outerTabs li).

2. anything you do in (div.outerTabs li) that you don't want for the
inner tabs, you have to explicitly undo in (div.innerTabs li), for
example:

  div.outerTabs li { font-weight: bold; }

  /* Have to do this, or the inner tabs will be bold too */
  div.innerTabs li { font-weight: normal; }

Does this help?

jk

On Thu, May 17, 2007 at 01:30:24PM -0700, eddmosphere wrote:
 
 How would I do that? Not sure I understood..
 
 Thanks, Edd
 
 
 igor.vaynberg wrote:
  
  if you set a class on the tab panel then you can use that class to scope
  the
  css styles properly
  
  -igor
  
  
  On 2/20/07, burnayev [EMAIL PROTECTED] wrote:
 
 
  Thank you Igor.
 
  I'm trying to implement nested tabs - basic navigation pattern where you
  have horizontal tabs on top and vertical tabs at left within a particular
  tab panel.
 
  I fiddled a little with styling the inner tabs and haven't come to a
  satisfactory result so far. The problem seems to be the fact that both
  tab
  panels internally use the same CSS classes for styling, namely tab-row
  and
  tab-panel.
 
  Is there a way to dynamically change the associated classes?
 
  Thanks,
  Borys
 
 
  igor.vaynberg wrote:
  
   you can style tabbedpanel in extensions
  
   the tabs are just a ul
  
   -igor
  
  
   On 2/19/07, burnayev [EMAIL PROTECTED] wrote:
  
  
   How do I create vertically stacked tabs? Is it possible to style
  and/or
   extend the extensions tab component or do I have to create my own?
   --
  
 
  --
  View this message in context:
  http://www.nabble.com/Vertical-Tabs-tf3254943.html#a9062788
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  Take Surveys. Earn Cash. Influence the Future of IT
  Join SourceForge.net's Techsay panel and you'll get the chance to share
  your
  opinions on IT  business topics through brief surveys-and earn cash
  http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
  
  -
  Take Surveys. Earn Cash. Influence the Future of IT
  Join SourceForge.net's Techsay panel and you'll get the chance to share
  your
  opinions on IT  business topics through brief surveys-and earn cash
  http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
 -- 
 View this message in context: 
 http://www.nabble.com/Vertical-Tabs-tf3254943.html#a10671840
 Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread Julian Klappenbach

I honestly will have to play with it a bit more.  I was originally
interested in simply using Grails for its GORM back end.  Eliminating all
the make work of data access, having the power of hibernate, its caching and
clustering capabilities with almost no upfront cost is appealing.  Also,
there's the components that Grails integrates with, including Compass,
Quartz, even OpenLaslo.  One can integrate these in a standard servlet
environment through time and effort, but Grails just makes it as simple as
the execution of a script.

There was the idea of remaking Wicket in Groovy, ala a Wicket Builder, but I
think after discussion that it was clear that that would be a effort of
folly.  A code base like Wicket is simply too dynamic to attempt
equivalence.  What would emerge is something that looked like Wicket,
perhaps encapsulated it's basic features and functionality, but it would not
be Wicket.  At least, IMHO, there's not enough development interest to keep
a Groovy version synched.

But if Grails is able to take stock Java Wicket components, and weave them
into a presentation layer, then what you have is really the best of both
worlds.  Like Eelco has said, you could start out the project using the RAD
elements of the framework to get something up and running quickly,
leveraging GORM for persistence.  But after a while, more stabilized
development could be conducted in Java.  My guess is that GORM could satisfy
80 - 90% of middle tier needs for projects, and would stand up to most
scalability concerns.  Pepsi is one of the first customers to go live with
the project on a highly visible site.

I'll know more as soon as I've logged a few hours playing with the idea,
which starts tonight.If anyone else decides to take up the quest (ewww,
bad pun), please let me know so efforts can be coordinated.

-jjk

On 5/17/07, Eelco Hillenius [EMAIL PROTECTED] wrote:


 What is in Grails that would make Wicket better for web-app
development?
 Is it just the integration of Groovy or is there something more for a
Wicket
 user?

My uneducated take on this (correct me if I'm wrong, I'm just thinking
out loud): something like Grails should work very well for when you
have to develop/ deliver quickly. Wicket works very well for when you
want to build projects that are maintainable, take advantage of reuse,
easily scale to larger teams etc. This plugin for Grails sounds like
the best of both worlds to me, at least if it is possible to have a
mixed development model. If it is possible to reuse custom components
in Grails (or Gricket) and if you can later switch pages (and
components?) that were build in Grails to 'normal' Wicket when you
want to, that would mean that you can work very rapidly at the start
of projects, and achieve a sort time-to-market, and later when it is
more important to work on robusteness, or e.g. digest custom
components to avoid code duplication etc, switch (parts) to a Wicket
model. Or use Cricket for one project and old-skool Wicket for the
other and still be able to reuse parts/ knowledge between the
projects.

Graeme, Julian, great you've been working on this! Cheers,

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Markup inheritance in the Panel class hierarchy

2007-05-17 Thread Chris Colman
I know and use markup inheritance in classes derived from WebPage with
great benefit. I was wondering if this same markup inheritance works at
the panel level as well. Ie., Can I use markup inheritance in the
markups for classes deriving from Panel class?

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Looking for an example of how to create a component to generate markup

2007-05-17 Thread Alessandro Coelho Ribeiro
Hi,

I want to create 2 components in my wicket application.  The first one 
would be a generic component for embedding any flash (SWF) content.  The 
second component would inherit from the 1st one and would be related to 
a specific flash object we need to embedd in our business application.  
Unfortunately, I cannot just use a Panel or a Include, because the tags 
for the flash object must be dynamically generated.  The application 
needs to pass some dynamic values using flash variables. 

I look forward for a very simple component that can generate markup, but 
I can't find any.  Based on many different examples I've found on the 
Internet, I tried a lot of things: inherit from WebComponent, inherit 
from MarkupContainer, override onComponentTagBody, override on Render.  
All the alternatives produce the same error:

java.lang.NullPointerException

wicket.util.string.PrependingStringBuffer.prepend(PrependingStringBuffer.java:97)
wicket.Component.getPath(Component.java:1085)
wicket.markup.html.debug.PageView$3.component(PageView.java:126)
wicket.MarkupContainer.visitChildren(MarkupContainer.java:744)
wicket.MarkupContainer.visitChildren(MarkupContainer.java:784)
wicket.markup.html.debug.PageView.getComponentData(PageView.java:122)
wicket.markup.html.debug.PageView.init(PageView.java:80)

wicket.markup.html.pages.ExceptionErrorPage.init(ExceptionErrorPage.java:93)

wicket.request.compound.DefaultExceptionResponseStrategy.respond(DefaultExceptionResponseStrategy.java:96)

wicket.request.compound.AbstractCompoundRequestCycleProcessor.respond(AbstractCompoundRequestCycleProcessor.java:76)
wicket.RequestCycle.step(RequestCycle.java:1050)
wicket.RequestCycle.steps(RequestCycle.java:1084)
wicket.RequestCycle.request(RequestCycle.java:454)
wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:219)
javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)

org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
 


Does anyone have a simple example of how you create a simple component 
to generate markup ?  An example that works, I mean... 

Regards,


---
Alessandro Ribeiro
[EMAIL PROTECTED]
Software Architect
Integritas Tecnologia - Open Solutions


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Multiple wicket:child tags in the same page

2007-05-17 Thread Chris Colman
Let's say I have a page which can be almost completely marked up in a
base class markup. There are only two sections of the page that change
in the derived pages/classes. Is it possible to use the wicket:child
tag twice in 
the one page and then have two wicket:extend tags in the derived
pages?

Markup for base page:

body
div id=master

span wicket:id=organizationHeader/

div id=bodywrap

wicket:child
/wicket:child

pThe stuff in here is common to all
pages and so I only want to define it once in this base page markup/p

wicket:child
/wicket:child

  span wicket:id=organizationFooter/

/div

/div
/body

Markup for the derived page:

body
wicket:extend
div id=maincol
span wicket:id=welcomePanel/
/div
/wicket:extend

This text is ignored - only the extend parts will be
used

wicket:extend
h1Hi there!/h1
/wicket:extend
/body

I've tried this and I get the following error message:

WicketMessage: The component [MarkupContainer [Component id = _child,
page = com.sas.av.ui.wicket.HomePage, path =
4:_body:_child.MarkupInheritanceResolver$TransparentWebMarkupContainer
, isVisible = true, isVersioned = true]] has the same wicket:id as
another component already added at the same level

Root cause:

wicket.markup.MarkupException: The component [MarkupContainer [Component
id = _child, page = com.sas.av.ui.wicket.HomePage, path =
4:_body:_child.MarkupInheritanceResolver$TransparentWebMarkupContainer
, isVisible = true, isVersioned = true]] has the same wicket:id as
another component already added at the same level
at wicket.Page.componentRendered(Page.java:936)
at wicket.Component.rendered(Component.java:1755)
at wicket.Component.render(Component.java:1534)
at wicket.MarkupContainer.renderNext(MarkupContainer.java:1334)
at
wicket.MarkupContainer.renderComponentTagBody(MarkupContainer.java:982)
at wicket.MarkupContainer.onComponentTagBody(MarkupContainer.java:917)

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Append custom req paramaters to AjaxLink

2007-05-17 Thread mchack

Thanks for the help. Makes sense. I am trying to come to grips with using
Wicket for a fairly large project and am trying to come up to speed as quick
as possible and at the same time try and figure out where I may get burned.


Johan Compagner wrote:
 
 youre page will be statefull anyway
 and then to try to conserve a few links would seem foolish to me that will
 not save you much anyway.
 
 If there is in the markup 5 links with wicket:id then you need 5 unique
 components (you can reuse it)
 and you need the wicket:id anyway because if you want to change the tag
 (add
 the right onclick attribute)
 then you need a component. So you could have 4 markupcontainers and 1
 ajaxlink and then
 reuse the ajax link onlick behavior somehow for the 4 markupcontainers..
 But
 what would that really gain you
 besides much more complex situation?
 
 johan
 
 
 On 5/17/07, mchack [EMAIL PROTECTED] wrote:


 Johan, thanks for the response. It still appears that I will be
 instantiating
 multiple AjaxLink(s), one for each unique link. In a stateful page these
 would be stored in the session. By moving some state to the client it
 appears that it might be possible to reduce the number of server side
 objects that would be retained in the session. Pardon me if I am missing
 something.

 I was looking at this for something like a panel that provided links to
 say
 multiple press releases. When the link was selected it would call common
 Ajax on click handler and infer the item to be presented by unique
 request
 parameter. There could be many links and also many concurrent sessions so
 I
 was a bit worried about reducing impact from a session standpoint.

 I am new to the framework and am trying to come up to speed as quickly as
 possible, but am very favorably impressed.




 Johan Compagner wrote:
 
  you can use one anonymous innerclass just fine for multiply ajax links
  just give the seperate instances the state you want on the server side
  why push that to the client?
 
  AjaxLink link1 = AjaxLink(link1, new Model(mystate1))
  AjaxLink link2 = AjaxLink(link2, new Model(mystate2))
 
  onClick()
  {
   State state = getModel()
   // do something
  }
 
  johan
 
 
 
  On 5/17/07, mchack [EMAIL PROTECTED] wrote:
 
 
  Would it be possible or reasonable to extend an AjaxLink to include
  additional request parameters. My reason is that I would like to
 include
  multiple AjaxLinks in a page and would like to only define one
 anonymous
  inner class to handle the requests, using unique request parameters to
  distinguish between the requests. This would make my page generation
 more
  efficient and would eliminate the creation of unnecessary server side
  objects.
 
  Thanks
  --
  View this message in context:
 
 http://www.nabble.com/Append-custom-req-paramaters-to-AjaxLink-tf3773939.html#a10671020
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 
 
 -
  This SF.net email is sponsored by DB2 Express
  Download DB2 Express C - the FREE version of DB2 express and take
  control of your XML. No limits. Just data. Click to get it now.
  http://sourceforge.net/powerbar/db2/
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

 --
 View this message in context:
 http://www.nabble.com/Append-custom-req-paramaters-to-AjaxLink-tf3773939.html#a10672578
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user

 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message 

Re: [Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread graemer

No, I still believe it would be quite trivial to write a Wicket builder that
would make creating Wicket component interfaces much simpler in Groovy.
Something like Groovy's current SwingBuilder system:
http://www.oreillynet.com/onjava/blog/2004/10/gdgroovy_basic_swingbuilder.html

It is just about investing the time to build this. As to what you get by
using Grails and Wicket together, well you essentially get an ORM system
built right in that follows a convention-over-configuration approach and
supports dynamic finders and is built on Hibernate (http://grails.org/GORM)

You also get support for Grails' entire plug-in eco-system including things
like Quartz, Compass, XFire, Spring Remoting, Acegi etc. See
http://grails.org/Plugins

My only concern with the current implementation is that it requires a server
restart when you make any changes to the Wicket Application class or
components. This goes against the Grails Way which promotes agile,
iterative development and really ideally we would need to find a way, at
least in development mode, to refresh the Wicket Application instance when
the Groovy classes change so get automatic reloading

PS One correction is that Grails is not part of the RoR family or in anyway
related to Rails or a port of Rails. It is built from the ground up on solid
Java technologies like Spring  Hibernate

Cheers
---
Graeme Rocher
Grails Project Lead



jklappenbach wrote:
 
 http://graemerocher.blogspot.com/2007/05/grails-wicket-wonders-of-grails-plug-in.html
 (SFW)
 
 Graeme pinged me as soon as I got online this morning to tell me about his
 work on integrating Wicket and Groovy, a Rails implementation based on the
 Java scripting language, Groovy.
 
 As you'll read, the integration took him *20 minutes*, and the result was
 the following:
 
1. Wicket classes can be utilized as-is from wicket jars inside a
Groovy environment, meaning that there's no concern of keeping a
Groovy-based mirror of Wicket synchronized.
2. Wicket classes can take advantage of GORM, with dynamic methods
(This is very, very, cool)
3. Developers can take advantage of closures, and all other nice
features of Groovy
 
 Graeme warned me that he hadn't tested much more than a Hello World
 example.  But in getting even those two simple words out, a lot had to be
 going on under the hood.  I'd be surprised if there were issues lurking
 beyond.
 
 If you haven't heard of Grails, or would like to know more, I have a short
 post here at:
 
 http://tapestryofthoughts.blogspot.com/2007/05/grails-rails-gone-groovy.html
 
 For more in-depth, there's the Grails site at:
 
 http://grails.codehaus.org/
 
 -jjk
 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 
http://www.nabble.com/Gricket%3A-The-Love-Child-of-Grails-and-Wicket-tf3772804.html#a10674823
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread Julian Klappenbach

On 5/17/07, graemer [EMAIL PROTECTED] wrote:



No, I still believe it would be quite trivial to write a Wicket builder
that
would make creating Wicket component interfaces much simpler in Groovy.
Something like Groovy's current SwingBuilder system:

http://www.oreillynet.com/onjava/blog/2004/10/gdgroovy_basic_swingbuilder.html



I stand corrected.  I was under the assumption that a builder approach
would require that the Wicket API be rewritten in Groovy, as I thought you
were demonstrating during our initial discussions on a builder approach.

It is just about investing the time to build this. As to what you get by

using Grails and Wicket together, well you essentially get an ORM system
built right in that follows a convention-over-configuration approach and
supports dynamic finders and is built on Hibernate (http://grails.org/GORM
)

You also get support for Grails' entire plug-in eco-system including
things
like Quartz, Compass, XFire, Spring Remoting, Acegi etc. See
http://grails.org/Plugins



Thinking alike, I just posted something on this.

My only concern with the current implementation is that it requires a server

restart when you make any changes to the Wicket Application class or
components. This goes against the Grails Way which promotes agile,
iterative development and really ideally we would need to find a way, at
least in development mode, to refresh the Wicket Application instance when
the Groovy classes change so get automatic reloading

PS One correction is that Grails is not part of the RoR family or in
anyway
related to Rails or a port of Rails. It is built from the ground up on
solid
Java technologies like Spring  Hibernate



[Scratches head]...  OK, fine by me.

-jjk
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Markup inheritance in the Panel class hierarchy

2007-05-17 Thread Timo Rantalaiho
On Fri, 18 May 2007, Chris Colman wrote:
 I know and use markup inheritance in classes derived from WebPage with
 great benefit. I was wondering if this same markup inheritance works at
 the panel level as well. Ie., Can I use markup inheritance in the
 markups for classes deriving from Panel class?

Sure. I think it works with any Component (that has associated
markup).

- Timo

-- 
Timo Rantalaiho   +358-45-6709709
Reaktor Innovations OyURL: http://www.ri.fi/ 

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AjaxSubmitButton IE vs. FF Behavior

2007-05-17 Thread WeaZeLb0y

Here is how I solved the problem.

First I created AbstractOnloadEventBehavior and events.js. This allows me to
execute multiple scripts (behaviors) in the window.onload callback.

Then I created AjaxBindEnterKeyBehavior which just intercepts the enter key
on a form and clicks the ajax submit button instead.

I tested on IE7 and FF2.0

Review my work and if no one sees any apparent problems I'll post it in the
wiki.




import wicket.ajax.markup.html.form.AjaxSubmitButton;
import wicket.markup.html.form.Form;

public class AjaxBindEnterKeyBehavior extends AbstractOnloadEventBehavior {

private AjaxSubmitButton button;

public AjaxBindEnterKeyBehavior(AjaxSubmitButton button) {
this.button = button;
}

@Override
protected String getScript() {
Form form = (Form) button.findParent(Form.class);

return document.getElementById(' + form.getMarkupId()
+ ').onkeydown = function (e) {\n
+ var evt = (e) ? e : window.event; \n
+ var keyCode = evt.keyCode;\n + if (keyCode 
== 13) {\n 
+ document.getElementById(' + 
button.getMarkupId()
+ ').click(); + return false; \n } };
}

}



events.js
---
function addEvent(obj, evType, fn){
  if (obj.addEventListener){
obj.addEventListener(evType, fn, true);
return true;
  } else if (obj.attachEvent){
var r = obj.attachEvent(on+evType, fn);
return r;
  } else {
return false;
  }
}
--

import org.apache.commons.lang.RandomStringUtils;

import wicket.RequestCycle;
import wicket.ResourceReference;
import wicket.Response;
import wicket.behavior.AbstractAjaxBehavior;
import wicket.markup.html.IHeaderContributor;
import wicket.markup.html.resources.CompressedResourceReference;
import wicket.util.string.JavascriptUtils;

abstract public class AbstractOnloadEventBehavior extends
AbstractAjaxBehavior
implements IHeaderContributor {

/** reference to the event javascript file. */
private static final ResourceReference JAVASCRIPT = new
CompressedResourceReference(
AbstractOnloadEventBehavior.class, events.js);

@Override
protected String getImplementationId() {
return events;
}

@Override
public void onRequest() {
}

@Override
protected void onRenderHeadInitContribution(Response response) {
CharSequence url = RequestCycle.get().urlFor(JAVASCRIPT);
JavascriptUtils.writeJavascriptUrl(response, url);
}

@Override
protected void onRenderHeadContribution(Response response) {
String functionName = RandomStringUtils.randomAlphabetic(8);
response.write(script type=\text/javascript\ function 
+ functionName + () { + getScript()
+ } addEvent(window, 'load',  + functionName 
+ );/script);
}

protected abstract String getScript();

}









igor.vaynberg wrote:
 
 you have to catch the enter keypress on every textfield and submit the
 form
 using ajax. you can do that using some javascript magic and some behavior
 that adds this magic to onload event.
 
 so in your basepage or baseform youd do: add(new
 FixIe7EnterKeyBehavior());
 
 -igor
 
 
 On 5/16/07, Joe Toth [EMAIL PROTECTED] wrote:

 Using Wicket 1.2.6

 Using FF 2.0 when I click on the submit button or hit 'enter' on a field
 in the form the ajax call is processed.

 With IE 7.0 when I click on the submit button, the ajax class is
 processed, BUT when I hit 'enter' the form submits normally.

 Any idea what I can do to keep the same behavior all around and make IE 7
 'enter' behave the same as the click?

 Thanks

 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user


 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 

Re: [Wicket-user] Vertical Tabs

2007-05-17 Thread eddmosphere

Thanks John ;) 

that's similar to what I was doing (before I saw your reply). I'll try it
your way, as my seems a bit messier hehe

Edd


John Krasnay wrote:
 
 I tried to explain this in an earlier thread, but I'm afraid I wasn't
 too successful. I'll give it another shot. Suppose your outer tabs are
 defined on a page like this:
 
   div wicket:id=outerTabs class=outerTabs/div
 
 When you attached the TabbedPanel component to it, it renders like this:
 
   div class=outerTabs
 div class=tab-row
   ul
 li .../li 
   /ul
 /div
 ...your panel...
   /div
 
 You can make them horizontal by doing something like this in CSS:
 
   div.outerTabs li { display: inline; }
 
 Now, suppose your panel has a set of inner tabs, with this markup:
 
   div wicket:id=innerTabs class=innerTabs/div
 
 The rendered HTML now looks like this:
 
   div class=outerTabs
 div class=tab-row
   ul
 li .../li 
   /ul
 /div
 
   div class=innerTabs
 div class=tab-row
   ul
 li ... /li
   /ul
 /div
 
   your inner panel
 
   /div
 
   /div
 
 To make the inner ones vertical, you'll want to float the inner tab row
 left and render it's li's as blocks:
 
   div.innerTabs div.tab-row { float: left; }
   div.innerTabs li { display: block; }
 
 You'll have to play a bit with the CSS to get it nice, but that's the
 general idea.
 
 The only tricky part is that the inner li elements are styled by both
 the (div.outerTabs li) and (div.innerTabs li) elements, so you have to
 make sure of the following:
 
 1. put the (div.innerTabs li) later in the stylesheet, so that it's
 properties override those from (div.outerTabs li).
 
 2. anything you do in (div.outerTabs li) that you don't want for the
 inner tabs, you have to explicitly undo in (div.innerTabs li), for
 example:
 
   div.outerTabs li { font-weight: bold; }
 
   /* Have to do this, or the inner tabs will be bold too */
   div.innerTabs li { font-weight: normal; }
 
 Does this help?
 
 jk
 
 On Thu, May 17, 2007 at 01:30:24PM -0700, eddmosphere wrote:
 
 How would I do that? Not sure I understood..
 
 Thanks, Edd
 
 
 igor.vaynberg wrote:
  
  if you set a class on the tab panel then you can use that class to
 scope
  the
  css styles properly
  
  -igor
  
  
  On 2/20/07, burnayev [EMAIL PROTECTED] wrote:
 
 
  Thank you Igor.
 
  I'm trying to implement nested tabs - basic navigation pattern where
 you
  have horizontal tabs on top and vertical tabs at left within a
 particular
  tab panel.
 
  I fiddled a little with styling the inner tabs and haven't come to a
  satisfactory result so far. The problem seems to be the fact that both
  tab
  panels internally use the same CSS classes for styling, namely tab-row
  and
  tab-panel.
 
  Is there a way to dynamically change the associated classes?
 
  Thanks,
  Borys
 
 
  igor.vaynberg wrote:
  
   you can style tabbedpanel in extensions
  
   the tabs are just a ul
  
   -igor
  
  
   On 2/19/07, burnayev [EMAIL PROTECTED] wrote:
  
  
   How do I create vertically stacked tabs? Is it possible to style
  and/or
   extend the extensions tab component or do I have to create my own?
   --
  
 
  --
  View this message in context:
  http://www.nabble.com/Vertical-Tabs-tf3254943.html#a9062788
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 
 -
  Take Surveys. Earn Cash. Influence the Future of IT
  Join SourceForge.net's Techsay panel and you'll get the chance to
 share
  your
  opinions on IT  business topics through brief surveys-and earn cash
 
 http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
 
  
 
 -
  Take Surveys. Earn Cash. Influence the Future of IT
  Join SourceForge.net's Techsay panel and you'll get the chance to share
  your
  opinions on IT  business topics through brief surveys-and earn cash
 
 http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV
  ___
  Wicket-user mailing list
  Wicket-user@lists.sourceforge.net
  https://lists.sourceforge.net/lists/listinfo/wicket-user
  
  
 
 -- 
 View this message in context:
 http://www.nabble.com/Vertical-Tabs-tf3254943.html#a10671840
 Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 

Re: [Wicket-user] Gricket: The Love-Child of Grails and Wicket

2007-05-17 Thread Jonathan Locke


Very interesting.  I'm not that interested for production code, but this
could be really exceptional for prototyping and fast TTM when that matters.


jklappenbach wrote:
 
 http://graemerocher.blogspot.com/2007/05/grails-wicket-wonders-of-grails-plug-in.html
 (SFW)
 
 Graeme pinged me as soon as I got online this morning to tell me about his
 work on integrating Wicket and Groovy, a Rails implementation based on the
 Java scripting language, Groovy.
 
 As you'll read, the integration took him *20 minutes*, and the result was
 the following:
 
1. Wicket classes can be utilized as-is from wicket jars inside a
Groovy environment, meaning that there's no concern of keeping a
Groovy-based mirror of Wicket synchronized.
2. Wicket classes can take advantage of GORM, with dynamic methods
(This is very, very, cool)
3. Developers can take advantage of closures, and all other nice
features of Groovy
 
 Graeme warned me that he hadn't tested much more than a Hello World
 example.  But in getting even those two simple words out, a lot had to be
 going on under the hood.  I'd be surprised if there were issues lurking
 beyond.
 
 If you haven't heard of Grails, or would like to know more, I have a short
 post here at:
 
 http://tapestryofthoughts.blogspot.com/2007/05/grails-rails-gone-groovy.html
 
 For more in-depth, there's the Grails site at:
 
 http://grails.codehaus.org/
 
 -jjk
 
 -
 This SF.net email is sponsored by DB2 Express
 Download DB2 Express C - the FREE version of DB2 express and take
 control of your XML. No limits. Just data. Click to get it now.
 http://sourceforge.net/powerbar/db2/
 ___
 Wicket-user mailing list
 Wicket-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wicket-user
 
 

-- 
View this message in context: 
http://www.nabble.com/Gricket%3A-The-Love-Child-of-Grails-and-Wicket-tf3772804.html#a10676700
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user