Re: ModalWindow and jQuery mousedown binding

2014-03-10 Thread Martin Grigorov
Hi,

I don't know what is the reason to stop the event at
https://github.com/apache/wicket/blob/master/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js?source=c#L1186

You can remove that binding with:
jQuery('.wicket-modal .w_content_1')[0].onmousedown = null; // or =
function() {};


 Martin Grigorov
Wicket Training and Consulting


On Fri, Mar 7, 2014 at 6:22 PM, neilbennett wrote:

> Hi,
>
> I am experiencing an issue very similar to Andrew Geery here,
>
> http://apache-wicket.1842946.n4.nabble.com/weird-interaction-between-ModalWindow-and-jQuery-mousedown-binding-td4473055.html
>
> I have a ModalWindow open with a datetimepicker
> (http://www.malot.fr/bootstrap-datetimepicker/) component. On
> non-ModalWindow pages this component closes if open when clicked outside of
> it's area, but the ModalWindow consumes the mousedown event and so
> datetimepicker is not closed when clicking outside of it or even when the
> modal window is closed itself.
>
> Are there any ideas on how to have these ModalWindow mousedown events not
> be
> consumed?
>
> Thanks,
>
> Neil
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/ModalWindow-and-jQuery-mousedown-binding-tp4664859.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Wicket and memory, caching

2014-03-10 Thread Martin Grigorov
Hi,


On Sat, Mar 8, 2014 at 9:24 PM, Brown, Berlin [PRI-1PP] <
berlin.br...@primerica.com> wrote:

> We are running into memory issues and it looks like wicket stores a lot of
> data in heap memory but also a lot of data is stored in session.
>

Some numbers that prove your words would really help here!


>
> We aren't that concerned with page versioning or caching approaches.  E.g.
> we can just turn all of that off.  We thought about using setVersioning to
> false for all components.  Also use the leastevictionstrategy and not use
> the secondlevelsessionstore.
>

What is "leastevictionstrategy" ?!

"secondlevelsessionstore" is DefaultPageStore that by default holds up to
40 pages. Let's say an average size of a page is 500Kb (and this is a
really big/complex page!) then this cache adds 20Mb in total. Not sure
about Wicket 1.4.x but in 1.5+ you can disable it by setting its size to
any non-positive number (see IStoreSettings)


>
> In addition to that, we see one object that seems to eat up a lot of heap:
>
> WicketApplication -> Settings -> MarkupCache$DefaultCacheImplementation
>
> For this object MarkupCache, if we change the caching strategies, will the
> MarkupCache not fill up so much?  Is there any setting that controls the
> MarkupCache?
>

MarkupCache holds the contents of the markup files (the .html templates).
This helps to avoid re-loading the content from the file system again and
again.
How much memory it uses ?


>
> Note: still using an old release 1.4.x (latest)
>
> 
> Berlin Brown
>


Re: Show textfield as plaintext when disabled?

2014-03-10 Thread Entropy
Igor,

This was great.  Exactly what I needed.  I applied this to my TextField and
DropDownChoice with a few tweaks and it's perfect.  But when I went to do
the same to TextArea, I am told that onComponentTagBody is final and cannot
be overridden.

So i tired without that method overidden like so:

public void onComponentTag(ComponentTag tag) { 
super.onComponentTag(tag); 
if (!isEnabledInHierarchy()) { 
tag.setName("label"); 
tag.remove("type"); 
tag.remove("value"); 
tag.remove("disabled");
tag.setType(TagType.OPEN); 
} 
} 

//  public void onComponentTagBody(final MarkupStream markupStream, final
ComponentTag openTag) { 
//  if (!isEnabledInHierarchy()) { 
//  replaceComponentTagBody(markupStream, openTag,
getDefaultModelObjectAsString()); 
//  }
//  } 

And that produced the following exception:
org.apache.wicket.markup.MarkupException: Component [narrative] (path =
[4:oagForm:narrative]) must be applied to a tag of type [textarea], not: 
'' (line 0, column 0)
at
org.apache.wicket.markup.MarkupStream.throwMarkupException(MarkupStream.java:526)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Component.checkComponentTag(Component.java:3550)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.markup.html.form.TextArea.onComponentTagBody(TextArea.java:65)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.markup.html.panel.DefaultMarkupSourcingStrategy.onComponentTagBody(DefaultMarkupSourcingStrategy.java:71)
~[wicket-core-6.12.0.jar:6.12.0]
at 
org.apache.wicket.Component.internalRenderComponent(Component.java:2549)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1493)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Component.internalRender(Component.java:2379)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Component.render(Component.java:2307)
~[wicket-core-6.12.0.jar:6.12.0]
at 
org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1390)
~[wicket-core-6.12.0.jar:6.12.0]
at 
org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1554)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.MarkupContainer.renderComponentTagBody(MarkupContainer.java:1529)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.MarkupContainer.onComponentTagBody(MarkupContainer.java:1484)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.markup.html.form.Form.onComponentTagBody(Form.java:1683)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.markup.html.panel.DefaultMarkupSourcingStrategy.onComponentTagBody(DefaultMarkupSourcingStrategy.java:71)
~[wicket-core-6.12.0.jar:6.12.0]
at 
org.apache.wicket.Component.internalRenderComponent(Component.java:2549)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1493)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Component.internalRender(Component.java:2379)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Component.render(Component.java:2307)
~[wicket-core-6.12.0.jar:6.12.0]
at 
org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1390)
~[wicket-core-6.12.0.jar:6.12.0]
at 
org.apache.wicket.MarkupContainer.renderAll(MarkupContainer.java:1554)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Page.onRender(Page.java:876)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.markup.html.WebPage.onRender(WebPage.java:142)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Component.internalRender(Component.java:2379)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Component.render(Component.java:2307)
~[wicket-core-6.12.0.jar:6.12.0]
at org.apache.wicket.Page.renderPage(Page.java:1010)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.request.handler.render.WebPageRenderer.renderPage(WebPageRenderer.java:121)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.request.handler.render.WebPageRenderer.respond(WebPageRenderer.java:274)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.core.request.handler.RenderPageRequestHandler.respond(RenderPageRequestHandler.java:165)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:861)
~[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.request.RequestHandlerStack.execute(RequestHandlerStack.java:64)
~[wicket-request-6.12.0.jar:6.12.0]
at
org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:261)
[wicket-core-6.12.0.jar:6.12.0]
at
org.apache.wicket.request.cycle.RequestCycle.pr

Add noise to the URL of ResourceLink component

2014-03-10 Thread BenHoit
hi,
i want to add noise to the url of a ResourceLink component (to avoid browser
caching problem) ...
i looked at Image#addAntiCacheParameter and try to put it in onComponentTag
of my ResourceLink 
@Override
protected void onComponentTag(ComponentTag tag) {
super.onComponentTag(tag);
String url = tag.getAttributes().getString("src");
log.debug("URL = "+url);
url = url + (url.contains("?") ? "&" : "?");
url = url + "antiCache=" + System.currentTimeMillis();
tag.put("src", url);
}

but it doesn't work and in my log, url is null ...
Does anybody know how to do this ?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Add noise to the URL of ResourceLink component

2014-03-10 Thread Sven Meier

Links use a "href" attribute instead of "src".

Sven

On 03/10/2014 03:19 PM, BenHoit wrote:

hi,
i want to add noise to the url of a ResourceLink component (to avoid browser
caching problem) ...
i looked at Image#addAntiCacheParameter and try to put it in onComponentTag
of my ResourceLink
@Override
protected void onComponentTag(ComponentTag tag) {
super.onComponentTag(tag);
String url = tag.getAttributes().getString("src");
log.debug("URL = "+url);
url = url + (url.contains("?") ? "&" : "?");
url = url + "antiCache=" + System.currentTimeMillis();
tag.put("src", url);
}

but it doesn't work and in my log, url is null ...
Does anybody know how to do this ?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870.html
Sent from the Users forum mailing list archive at Nabble.com.

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






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



Re: Add noise to the URL of ResourceLink component

2014-03-10 Thread BenHoit
thanks, i modify my onComponentTag
@Override
protected void onComponentTag(ComponentTag tag) {
super.onComponentTag(tag);
String url = tag.getAttributes().getString("href");
log.debug("URL = "+url);
url = url + "antiCache=" + System.currentTimeMillis();
tag.put("href", url);   
log.debug("URL modify =
"+tag.getAttributes().getString("href"));
}

my output is :
URL = #
URL modify = #antiCache=1394463265258

but my url in my browser (opened by the resourceLink) is not modified
(anticache param isn't visible) ... and the content is not the good one ...
(if i clear my browser cache and click on the link, the content is OK).

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870p4664874.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Add noise to the URL of ResourceLink component

2014-03-10 Thread Sven Meier

Are you using popupSettings?

Sven

On 03/10/2014 04:01 PM, BenHoit wrote:

thanks, i modify my onComponentTag
@Override
protected void onComponentTag(ComponentTag tag) {
 super.onComponentTag(tag);
 String url = tag.getAttributes().getString("href");
 log.debug("URL = "+url);
 url = url + "antiCache=" + System.currentTimeMillis();
 tag.put("href", url);
 log.debug("URL modify =
"+tag.getAttributes().getString("href"));
}

my output is :
URL = #
URL modify = #antiCache=1394463265258

but my url in my browser (opened by the resourceLink) is not modified
(anticache param isn't visible) ... and the content is not the good one ...
(if i clear my browser cache and click on the link, the content is OK).

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870p4664874.html
Sent from the Users forum mailing list archive at Nabble.com.

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




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



RE: Wicket and memory, caching

2014-03-10 Thread Brown, Berlin [PRI-1PP]



Berlin Brown – Software Developer Primerica Online
Primerica_Online_-_Java_Development
770-564-6374

-Original Message-
From: Martin Grigorov [mailto:mgrigo...@apache.org] 
Sent: Monday, March 10, 2014 4:03 AM
To: users@wicket.apache.org
Subject: Re: Wicket and memory, caching

Hi,


On Sat, Mar 8, 2014 at 9:24 PM, Brown, Berlin [PRI-1PP] < 
berlin.br...@primerica.com> wrote:

> We are running into memory issues and it looks like wicket stores a 
> lot of data in heap memory but also a lot of data is stored in session.
>

>>Some numbers that prove your words would really help here!

Percenage wise, the numbers are pretty high.  Out of a 1.5 gig heap, we see the 
WicketApplication eating up  1% of the heap.

>
> We aren't that concerned with page versioning or caching approaches.  E.g.
> we can just turn all of that off.  We thought about using 
> setVersioning to false for all components.  Also use the 
> leastevictionstrategy and not use the secondlevelsessionstore.
>

What is "leastevictionstrategy" ?!

Sorry:
package org.apache.wicket.session.pagemap;  
LeastRecentlyAccessedEvictionStrategy

"secondlevelsessionstore" is DefaultPageStore that by default holds up to
40 pages. Let's say an average size of a page is 500Kb (and this is a really 
big/complex page!) then this cache adds 20Mb in total. Not sure about Wicket 
1.4.x but in 1.5+ you can disable it by setting its size to any non-positive 
number (see IStoreSettings)


>
> In addition to that, we see one object that seems to eat up a lot of heap:
>
> WicketApplication -> Settings -> 
> MarkupCache$DefaultCacheImplementation
>
> For this object MarkupCache, if we change the caching strategies, will 
> the MarkupCache not fill up so much?  Is there any setting that 
> controls the MarkupCache?
>

MarkupCache holds the contents of the markup files (the .html templates).
This helps to avoid re-loading the content from the file system again and again.
How much memory it uses ?

The MarkupCache is stored in the Settings object and eventually the 
WicketApplication.  Usually about 1% of a 1.5 gig heap.  Higher than objects.  
Especially since there is only one wicket application.

Is there  way to control the MarkupCache?  Or is that part of the page store 
settings?

>
> Note: still using an old release 1.4.x (latest)
>
> 
> Berlin Brown
>


Re: Add noise to the URL of ResourceLink component

2014-03-10 Thread BenHoit
yes i'm using popupSettings
final String mime="application/xml";
ByteArrayResource res = new ByteArrayResource(mime,dSOBean.getOrder());

ResourceLink resourceL= new
ResourceLink("myF", res) {
@Override
protected void onComponentTag(ComponentTag tag) {
super.onComponentTag(tag);
String url = tag.getAttributes().getString("href");
log.debug("URL = "+url);
url = url + "antiCache=" + System.currentTimeMillis();
tag.put("href", url);   
log.debug("URL = 
"+tag.getAttributes().getString("href"));
}
};

PopupSettings popupSettings = new PopupSettings(
 PopupSettings.RESIZABLE |   
PopupSettings.SCROLLBARS).setHeight(600).setWidth(1000);
resourceLink.setPopupSettings(popupSettings);

listItem.add(resourceLink);


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870p4664877.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Add noise to the URL of ResourceLink component

2014-03-10 Thread Sven Meier

Hi,

take a look at Link#onComponentTag() on why this does not work in your case.

You should override #getURL() instead.

Sven

On 03/10/2014 04:14 PM, BenHoit wrote:

yes i'm using popupSettings
final String mime="application/xml";
ByteArrayResource res = new ByteArrayResource(mime,dSOBean.getOrder());

ResourceLink resourceL= new
ResourceLink("myF", res) {
@Override
protected void onComponentTag(ComponentTag tag) {
super.onComponentTag(tag);
String url = tag.getAttributes().getString("href");
log.debug("URL = "+url);
url = url + "antiCache=" + System.currentTimeMillis();
tag.put("href", url); 
log.debug("URL = 
"+tag.getAttributes().getString("href"));
}
};

PopupSettings popupSettings = new PopupSettings(
 PopupSettings.RESIZABLE |
PopupSettings.SCROLLBARS).setHeight(600).setWidth(1000);
resourceLink.setPopupSettings(popupSettings);

listItem.add(resourceLink);


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870p4664877.html
Sent from the Users forum mailing list archive at Nabble.com.

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




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



Re: Add noise to the URL of ResourceLink component

2014-03-10 Thread BenHoit
unfortunately getUrl is : 
protected final CharSequence getURL()

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870p4664879.html
Sent from the Users forum mailing list archive at Nabble.com.

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



mounting // mapping subdomain HomePage

2014-03-10 Thread Simon B
Hi, 

I want one instance of Wicket to handle different subdomains, so for
example: 

http://mydomain.com/
http://www.mydomain.com/
Map to GeneralHomePage.class

and http://foo.mydomain.com/
Maps to FooHomePage.class

and http://bar.mydomain.com/
Maps to BarHomePage.class

sorry for the unoriginal naming.  

If anyone could suggest the best way to do this I'd be very grateful.

Cheers
Simon

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/mounting-mapping-subdomain-HomePage-tp4664880.html
Sent from the Users forum mailing list archive at Nabble.com.

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



RE: Add noise to the URL of ResourceLink component

2014-03-10 Thread Stijn de Witt
This!

There are so many methods in Wicket final... I often ended up copying a whole 
class just because the method I wanted to override was final...


-Original Message-
From: BenHoit [mailto:benoit.lanoise...@orange.com] 
Sent: maandag 10 maart 2014 16:38
To: users@wicket.apache.org
Subject: Re: Add noise to the URL of ResourceLink component

unfortunately getUrl is : 
protected final CharSequence getURL()

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870p4664879.html
Sent from the Users forum mailing list archive at Nabble.com.

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


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



Re: Add noise to the URL of ResourceLink component

2014-03-10 Thread Martin Grigorov
On Mon, Mar 10, 2014 at 6:20 PM, Stijn de Witt <
stijn.dew...@planonsoftware.com> wrote:

> This!
>
> There are so many methods in Wicket final... I often ended up copying a
> whole class just because the method I wanted to override was final...
>

Next time start a new thread asking to remove some 'final' from the
signature of a method with your use case.
We listen!


>
>
> -Original Message-
> From: BenHoit [mailto:benoit.lanoise...@orange.com]
> Sent: maandag 10 maart 2014 16:38
> To: users@wicket.apache.org
> Subject: Re: Add noise to the URL of ResourceLink component
>
> unfortunately getUrl is :
> protected final CharSequence getURL()
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870p4664879.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: mounting // mapping subdomain HomePage

2014-03-10 Thread Martin Grigorov
Hi,

Create a new IRequestMapper and setup it as a root mapper (see HttpsMapper
and CryptoMapper for example).
If the request's Url has no segments then use the HttpServletRequest
(request.getContainerObjec()) to read the host and from this decide which
page to return (new RenderPageRequestHandler(new
PageProvider(SomePage.class)))

Martin Grigorov
Wicket Training and Consulting


On Mon, Mar 10, 2014 at 5:40 PM, Simon B  wrote:

> Hi,
>
> I want one instance of Wicket to handle different subdomains, so for
> example:
>
> http://mydomain.com/
> http://www.mydomain.com/
> Map to GeneralHomePage.class
>
> and http://foo.mydomain.com/
> Maps to FooHomePage.class
>
> and http://bar.mydomain.com/
> Maps to BarHomePage.class
>
> sorry for the unoriginal naming.
>
> If anyone could suggest the best way to do this I'd be very grateful.
>
> Cheers
> Simon
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/mounting-mapping-subdomain-HomePage-tp4664880.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Add noise to the URL of ResourceLink component

2014-03-10 Thread BenHoit
finally, it works with Sven's solution but tag html has to be   as i can see
in the link class (initially it was  in my html).  
I create a ResourceLinkWithAnticache like this :
public class ResourceLinkWithAnticache extends ResourceLink
{
public ResourceLinkWithAnticache(String id, IResource resource) {
super(id, resource);
}

private static final long serialVersionUID = 1L;

@Override
protected void onComponentTag(ComponentTag tag) {
super.onComponentTag(tag);
String url = tag.getAttributes().getString("href");
url = url + "&antiCache=" + System.currentTimeMillis();
tag.put("href", url);   
}
}

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Add-noise-to-the-URL-of-ResourceLink-component-tp4664870p4664884.html
Sent from the Users forum mailing list archive at Nabble.com.

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



ListView - onComponentTag

2014-03-10 Thread Nick Pratt
Is there any reason why onComponentTag() wouldn't be invoked on a ListView:

ListView users = new ListView( "team-members", usersModel )
 {
@Override
protected void onComponentTag( ComponentTag tag )
 {
super.onComponentTag( tag );
int i = 0;
 }
...


I set a breakpoint on 'int i =0'; but its never hit - either on initial
page render or when the containing Panel is refreshed via Ajax. None of the
child behaviors attached to the ListView are triggered either (no
onComponentTag execution)
Wicket 6.14.0

N


Re: ListView - onComponentTag

2014-03-10 Thread Sven Meier

Hi,

ListView uses its markup tag to render each of its items and is not 
visible in the output by itself - thus it doesn't contribute anything to 
the component tag.


Sven



On 03/10/2014 07:19 PM, Nick Pratt wrote:

Is there any reason why onComponentTag() wouldn't be invoked on a ListView:

ListView users = new ListView( "team-members", usersModel )
  {
@Override
protected void onComponentTag( ComponentTag tag )
  {
super.onComponentTag( tag );
int i = 0;
  }
...


I set a breakpoint on 'int i =0'; but its never hit - either on initial
page render or when the containing Panel is refreshed via Ajax. None of the
child behaviors attached to the ListView are triggered either (no
onComponentTag execution)
Wicket 6.14.0

N




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



Wicket with X-editable

2014-03-10 Thread Jered Myers
Has anybody tried to work with Wicket and X-editable 
(http://vitalets.github.io/x-editable/index.html)?  If so, what was your 
experience (e.g. X-editable stability, difficulty to implement, etc.)?  
I am curious if it would be a good idea to go down the road of making my 
Wicket application run with the X-editable in-line editable fields.


--
Jered Myers



Re: Wicket with X-editable

2014-03-10 Thread Ernesto Reinaldo Barreiro
IMHO this should be very easy to implement/integrate with  Wicket: judging
from the documentation. I haven't used the library myself, so I might be
missing some nuances/caveats...


On Tue, Mar 11, 2014 at 12:03 AM, Jered Myers
wrote:

> Has anybody tried to work with Wicket and X-editable (
> http://vitalets.github.io/x-editable/index.html)?  If so, what was your
> experience (e.g. X-editable stability, difficulty to implement, etc.)?  I
> am curious if it would be a good idea to go down the road of making my
> Wicket application run with the X-editable in-line editable fields.
>
> --
> Jered Myers
>
>


-- 
Regards - Ernesto Reinaldo Barreiro