[jira] Commented: (WICKET-1850) UrlValidator disallow http://user:passw...@host:port/path urls

2008-09-27 Thread Alexey Efimov (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-1850?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12635195#action_12635195
 ] 

Alexey Efimov commented on WICKET-1850:
---

if this help a little:
@Override
protected boolean isValidAuthority(String authority) {
// Cut from URL user:[EMAIL PROTECTED] cos wicket validator not 
allow authorization strings in URL
int atIndex = authority.lastIndexOf('@');
if (atIndex != -1 && atIndex < authority.length() - 1) {
return super.isValidAuthority(authority.substring(atIndex + 1));
}
return super.isValidAuthority(authority);
}


> UrlValidator disallow http://user:[EMAIL PROTECTED]:port/path urls
> --
>
> Key: WICKET-1850
> URL: https://issues.apache.org/jira/browse/WICKET-1850
> Project: Wicket
>  Issue Type: Improvement
>Affects Versions: 1.3.1
>Reporter: Alexey Efimov
>Priority: Trivial
>


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Closed: (WICKET-1816) Wicket 1.3.4 violates servlet standard, Glassfish spews warnings

2008-09-27 Thread Gili (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1816?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Gili closed WICKET-1816.



I verified Johan's fix. It seems to solve the problem on my end.

> Wicket 1.3.4 violates servlet standard, Glassfish spews warnings
> 
>
> Key: WICKET-1816
> URL: https://issues.apache.org/jira/browse/WICKET-1816
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.3.4
>Reporter: Gili
>Assignee: Igor Vaynberg
> Fix For: 1.3.5, 1.4-M4
>
>
> WicketFilter.java line 194 invokes getLastModified() which invokes 
> "request.getParameterMap()" on line 962. Later on in that same request, 
> WicketFilter.java line 222 invokes doGet() which invokes 
> response.setCharacterEncoding() on line 376.
> This is just one case where this problem occurs but I believe others might 
> exist. Whenever Wicket violates the standard Glassfish spews out this warning:
> PWC4011: Unable to set request character encoding to UTF-8 from context 
> , because request parameters have already been read, or 
> ServletRequest.getReader() has already been called
> ... you literally end up with tens of these warnings per request, and 
> supposedly, the wrong behavior :) Glassfish's FAQ discusses this in more 
> detail: 
> http://wiki.glassfish.java.net/Wiki.jsp?page=FaqWebAppUnableToSetRequestCharEncoding

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Closed: (WICKET-1799) wicket-extensions has unused reference to commons-collections.jar

2008-09-27 Thread Peter Ertl (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1799?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Peter Ertl closed WICKET-1799.
--


thanks!

> wicket-extensions has unused reference to commons-collections.jar
> -
>
> Key: WICKET-1799
> URL: https://issues.apache.org/jira/browse/WICKET-1799
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Reporter: Peter Ertl
>Assignee: Igor Vaynberg
> Fix For: 1.3.5, 1.4-M4
>
> Attachments: wicket-1799-wicket-1.3.patch, 
> wicket-1799-wicket-1.4.patch
>
>
> It seems that wicket-extensions (both 1.3 and 1.4) holds an unused reference 
> to common-collections.jar in it's pom.xml. 
>   
> commons-collections
> commons-collections
>   
> I removed that reference and could still compile everything without any 
> error. Could someone double-check that and remove it if it's really not 
> needed. this would save us from another 570 kb :-)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (WICKET-1799) wicket-extensions has unused reference to commons-collections.jar

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1799?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1799.
---

   Resolution: Fixed
Fix Version/s: 1.4-M4

> wicket-extensions has unused reference to commons-collections.jar
> -
>
> Key: WICKET-1799
> URL: https://issues.apache.org/jira/browse/WICKET-1799
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Reporter: Peter Ertl
>Assignee: Igor Vaynberg
> Fix For: 1.3.5, 1.4-M4
>
> Attachments: wicket-1799-wicket-1.3.patch, 
> wicket-1799-wicket-1.4.patch
>
>
> It seems that wicket-extensions (both 1.3 and 1.4) holds an unused reference 
> to common-collections.jar in it's pom.xml. 
>   
> commons-collections
> commons-collections
>   
> I removed that reference and could still compile everything without any 
> error. Could someone double-check that and remove it if it's really not 
> needed. this would save us from another 570 kb :-)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699669 - /wicket/trunk/wicket-extensions/pom.xml

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 08:41:01 2008
New Revision: 699669

URL: http://svn.apache.org/viewvc?rev=699669&view=rev
Log:
WICKET-1799

Modified:
wicket/trunk/wicket-extensions/pom.xml

Modified: wicket/trunk/wicket-extensions/pom.xml
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket-extensions/pom.xml?rev=699669&r1=699668&r2=699669&view=diff
==
--- wicket/trunk/wicket-extensions/pom.xml (original)
+++ wicket/trunk/wicket-extensions/pom.xml Sat Sep 27 08:41:01 2008
@@ -44,9 +44,5 @@
tests
test

-   
-   commons-collections
-   commons-collections
-   

 




[jira] Issue Comment Edited: (WICKET-1799) wicket-extensions has unused reference to commons-collections.jar

2008-09-27 Thread Peter Ertl (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-1799?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12635158#action_12635158
 ] 

pete edited comment on WICKET-1799 at 9/27/08 8:14 AM:
-

for 1.3 the pom.xml is correct, however in 1.4.x the reference is still in 
there.

  was (Author: pete):
for 1.4 the pom.xml is correct, however in 1.3.x the reference is still in 
there.
  
> wicket-extensions has unused reference to commons-collections.jar
> -
>
> Key: WICKET-1799
> URL: https://issues.apache.org/jira/browse/WICKET-1799
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Reporter: Peter Ertl
>Assignee: Igor Vaynberg
> Fix For: 1.3.5
>
> Attachments: wicket-1799-wicket-1.3.patch, 
> wicket-1799-wicket-1.4.patch
>
>
> It seems that wicket-extensions (both 1.3 and 1.4) holds an unused reference 
> to common-collections.jar in it's pom.xml. 
>   
> commons-collections
> commons-collections
>   
> I removed that reference and could still compile everything without any 
> error. Could someone double-check that and remove it if it's really not 
> needed. this would save us from another 570 kb :-)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Reopened: (WICKET-1799) wicket-extensions has unused reference to commons-collections.jar

2008-09-27 Thread Peter Ertl (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1799?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Peter Ertl reopened WICKET-1799:



for 1.4 the pom.xml is correct, however in 1.3.x the reference is still in 
there.

> wicket-extensions has unused reference to commons-collections.jar
> -
>
> Key: WICKET-1799
> URL: https://issues.apache.org/jira/browse/WICKET-1799
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Reporter: Peter Ertl
>Assignee: Igor Vaynberg
> Fix For: 1.3.5
>
> Attachments: wicket-1799-wicket-1.3.patch, 
> wicket-1799-wicket-1.4.patch
>
>
> It seems that wicket-extensions (both 1.3 and 1.4) holds an unused reference 
> to common-collections.jar in it's pom.xml. 
>   
> commons-collections
> commons-collections
>   
> I removed that reference and could still compile everything without any 
> error. Could someone double-check that and remove it if it's really not 
> needed. this would save us from another 570 kb :-)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (WICKET-1786) Adding SVG support detection to ClientProperties

2008-09-27 Thread Federico Fanton (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-1786?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12635126#action_12635126
 ] 

Federico Fanton commented on WICKET-1786:
-

Sorry, I didn't think to check for licenses outside of the code :/

> Adding SVG support detection to ClientProperties
> 
>
> Key: WICKET-1786
> URL: https://issues.apache.org/jira/browse/WICKET-1786
> Project: Wicket
>  Issue Type: Improvement
>  Components: wicket
>Affects Versions: 1.3.4
> Environment: Tested with Ubuntu 8.04 / Firefox 2.0.0.15 and XPsp2 / 
> IE7 (without plugins)
>Reporter: Federico Fanton
>Assignee: Igor Vaynberg
>Priority: Minor
> Fix For: 1.3.5, 1.4-M4
>
> Attachments: detect_svg.patch
>
>
> I'd like to extend BrowserInfoForm to detect if the browser supports SVGs 
> (javascript method here 
> http://thomas.tanrei.ca/modern-script-based-svg-detection/ ), but it looks 
> like it cannot be easily extended.. So I wrote a patch against Wicket 1.3.4 
> (hope it's not too messy ^^; )
> Thanks!

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699605 - in /wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src: main/java/org/apache/wicket/markup/html/pages/ main/java/org/apache/wicket/protocol/http/ test/java/org/apache/wicket/protoco

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 01:33:26 2008
New Revision: 699605

URL: http://svn.apache.org/viewvc?rev=699605&view=rev
Log:
WICKET-861

Removed:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/detectSVG.js
Modified:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java?rev=699605&r1=699604&r2=699605&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
 Sat Sep 27 01:33:26 2008
@@ -49,6 +49,7 @@
 import org.apache.wicket.IRedirectListener;
 import org.apache.wicket.IResourceListener;
 import org.apache.wicket.Page;
+import org.apache.wicket.RequestListenerInterface;
 import org.apache.wicket.WicketRuntimeException;
 import org.apache.wicket.markup.html.form.Form;
 import org.apache.wicket.markup.html.form.FormComponent;
@@ -1204,10 +1205,40 @@
component.getClass());
}
 
+   // manually create the url using default strategy and 
format

parameters.put(WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME, pageMapName + 
':' +
component.getPath() + ':' + (version == 0 ? "" 
: "" + version) + ':' +
Classes.simpleName(clazz) + "::");
 
+   // see if we can replace our manual listener url with a 
properly generated one...
+
+   try
+   {
+   RequestListenerInterface rli = 
(RequestListenerInterface)clazz.getField("INTERFACE")
+   .get(clazz);
+
+   String auto = 
component.getRequestCycle().urlFor(component, rli).toString();
+   int idx = 
auto.indexOf(WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME);
+   if (idx >= 0)
+   {
+   auto = auto.substring(idx +
+   
WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME.length() + 1);
+   }
+   idx = auto.indexOf("&");
+   if (idx >= 0)
+   {
+   auto = auto.substring(0, idx);
+   }
+
+   
parameters.put(WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME, auto);
+
+   }
+   catch (Exception e)
+   {
+   // noop
+   }
+
+
if (component.isStateless() && 
component.getPage().isBookmarkable())
{

parameters.put(WebRequestCodingStrategy.BOOKMARKABLE_PAGE_PARAMETER_NAME,

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java?rev=699605&r1=699604&r2=699605&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java
 Sat Sep 27 01:33:26 2008
@@ -18,7 +18,10 @@
 
 import junit.framework.TestCase;
 
+import org.apache.wicket.Page;
+import org.apache.wicket.PageParameters;
 import org.apache.wicket.request.IRequestCycleProcessor;
+import org.apache.wicket.util.tester.ITestPageSource;
 import org.apache.wicket.util.tester.WicketTester;
 import org.apache.wicket.util.tester.WicketTester.DummyWebApplication;
 
@@ -61,8 +64,8 @@
 */
public void test2()
{
-   // @TODO Johan, why does

[jira] Resolved: (WICKET-861) NumberFormatException with UrlCompressingWebRequestProcessor in WicketTester

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-861?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-861.
--

   Resolution: Fixed
Fix Version/s: 1.4-M4
 Assignee: Igor Vaynberg  (was: Johan Compagner)

> NumberFormatException with UrlCompressingWebRequestProcessor in WicketTester
> 
>
> Key: WICKET-861
> URL: https://issues.apache.org/jira/browse/WICKET-861
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.3.0-beta3
> Environment: Wicket 1.3.0 from Trunk
> JDK 6
>Reporter: Rüdiger Schulz
>Assignee: Igor Vaynberg
>Priority: Minor
> Fix For: 1.3.5, 1.4-M4
>
>
> In my Application I use UrlCompressingWebRequestProcessor. Now I have a JUnit 
> test case with WicketTester and that Application like this:
> tester.startPage(new ITestPageSource() {
>   public Page getTestPage() {
>   PageParameters params = new PageParameters();
>   params.add("0", "param");
>   return new MyPage(params);
>   }
> });
> I get an Exception:
> java.lang.NumberFormatException: For input string: "testPage"
>   at 
> java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
>   at java.lang.Integer.parseInt(Integer.java:447)
>   at java.lang.Integer.parseInt(Integer.java:497)
>   at 
> org.apache.wicket.protocol.http.request.urlcompressing.UrlCompressor.getComponentAndInterfaceForUID(UrlCompressor.java:124)
>   at 
> org.apache.wicket.protocol.http.request.urlcompressing.UrlCompressingWebRequestProcessor.resolveListenerInterfaceTarget(UrlCompressingWebRequestProcessor.java:81)
>   at 
> org.apache.wicket.request.AbstractRequestCycleProcessor.resolveRenderedPage(AbstractRequestCycleProcessor.java:440)
>   at 
> org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:139)
>   at org.apache.wicket.RequestCycle.step(RequestCycle.java:1091)
>   at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1177)
>   at org.apache.wicket.RequestCycle.request(RequestCycle.java:500)
>   at 
> org.apache.wicket.protocol.http.MockWebApplication.processRequestCycle(MockWebApplication.java:381)
>   at 
> org.apache.wicket.protocol.http.MockWebApplication.processRequestCycle(MockWebApplication.java:368)
>   at 
> org.apache.wicket.util.tester.BaseWicketTester.executeListener(BaseWicketTester.java:239)
>   at 
> org.apache.wicket.util.tester.BaseWicketTester.startPage(BaseWicketTester.java:224)
> I could work around this by using WebRequestCycleProcessor for my 
> testing-application.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699604 - in /wicket/trunk/wicket/src: main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressing

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 01:31:04 2008
New Revision: 699604

URL: http://svn.apache.org/viewvc?rev=699604&view=rev
Log:
WICKET-861

Modified:

wicket/trunk/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java

wicket/trunk/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java

Modified: 
wicket/trunk/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java?rev=699604&r1=699603&r2=699604&view=diff
==
--- 
wicket/trunk/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
 (original)
+++ 
wicket/trunk/wicket/src/main/java/org/apache/wicket/protocol/http/MockHttpServletRequest.java
 Sat Sep 27 01:31:04 2008
@@ -49,6 +49,7 @@
 import org.apache.wicket.IRedirectListener;
 import org.apache.wicket.IResourceListener;
 import org.apache.wicket.Page;
+import org.apache.wicket.RequestListenerInterface;
 import org.apache.wicket.WicketRuntimeException;
 import org.apache.wicket.markup.html.form.Form;
 import org.apache.wicket.markup.html.form.FormComponent;
@@ -1210,10 +1211,40 @@
component.getClass());
}
 
+   // manually create the url using default strategy and 
format

parameters.put(WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME, pageMapName + 
':' +
component.getPath() + ':' + (version == 0 ? "" 
: "" + version) + ':' +
Classes.simpleName(clazz) + "::");
 
+   // see if we can replace our manual listener url with a 
properly generated one...
+
+   try
+   {
+   RequestListenerInterface rli = 
(RequestListenerInterface)clazz.getField("INTERFACE")
+   .get(clazz);
+
+   String auto = 
component.getRequestCycle().urlFor(component, rli).toString();
+   int idx = 
auto.indexOf(WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME);
+   if (idx >= 0)
+   {
+   auto = auto.substring(idx +
+   
WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME.length() + 1);
+   }
+   idx = auto.indexOf("&");
+   if (idx >= 0)
+   {
+   auto = auto.substring(0, idx);
+   }
+
+   
parameters.put(WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME, auto);
+
+   }
+   catch (Exception e)
+   {
+   // noop
+   }
+
+
if (component.isStateless() && 
component.getPage().isBookmarkable())
{

parameters.put(WebRequestCodingStrategy.BOOKMARKABLE_PAGE_PARAMETER_NAME,

Modified: 
wicket/trunk/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java?rev=699604&r1=699603&r2=699604&view=diff
==
--- 
wicket/trunk/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java
 (original)
+++ 
wicket/trunk/wicket/src/test/java/org/apache/wicket/protocol/http/request/urlcompressing/UrlCompressingWebRequestProcessorTest.java
 Sat Sep 27 01:31:04 2008
@@ -18,7 +18,10 @@
 
 import junit.framework.TestCase;
 
+import org.apache.wicket.Page;
+import org.apache.wicket.PageParameters;
 import org.apache.wicket.request.IRequestCycleProcessor;
+import org.apache.wicket.util.tester.ITestPageSource;
 import org.apache.wicket.util.tester.WicketTester;
 import org.apache.wicket.util.tester.WicketTester.DummyWebApplication;
 
@@ -32,6 +35,7 @@
/**
 * @see junit.framework.TestCase#setUp()
 */
+   @Override
protected void setUp() throws Exception
{
super.setUp();
@@ -41,6 +45,7 @@
/**
 * Special overwrite to have url compressing for this 
example.
 */
+   @Override
protected IRequestCycleProcessor 
newRequestCyclePr

[jira] Reopened: (WICKET-1786) Adding SVG support detection to ClientProperties

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg reopened WICKET-1786:
---


> Adding SVG support detection to ClientProperties
> 
>
> Key: WICKET-1786
> URL: https://issues.apache.org/jira/browse/WICKET-1786
> Project: Wicket
>  Issue Type: Improvement
>  Components: wicket
>Affects Versions: 1.3.4
> Environment: Tested with Ubuntu 8.04 / Firefox 2.0.0.15 and XPsp2 / 
> IE7 (without plugins)
>Reporter: Federico Fanton
>Assignee: Igor Vaynberg
>Priority: Minor
> Fix For: 1.3.5, 1.4-M4
>
> Attachments: detect_svg.patch
>
>
> I'd like to extend BrowserInfoForm to detect if the browser supports SVGs 
> (javascript method here 
> http://thomas.tanrei.ca/modern-script-based-svg-detection/ ), but it looks 
> like it cannot be easily extended.. So I wrote a patch against Wicket 1.3.4 
> (hope it's not too messy ^^; )
> Thanks!

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (WICKET-1786) Adding SVG support detection to ClientProperties

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1786.
---

Resolution: Won't Fix

had to roll it back, just noticed that the detectSVG.js is licensed under CC 
attribution, which is incompatible with our ASF2

© Copyright 2008 Tanrei Software, Licensed under the CC Attribution License


> Adding SVG support detection to ClientProperties
> 
>
> Key: WICKET-1786
> URL: https://issues.apache.org/jira/browse/WICKET-1786
> Project: Wicket
>  Issue Type: Improvement
>  Components: wicket
>Affects Versions: 1.3.4
> Environment: Tested with Ubuntu 8.04 / Firefox 2.0.0.15 and XPsp2 / 
> IE7 (without plugins)
>Reporter: Federico Fanton
>Assignee: Igor Vaynberg
>Priority: Minor
> Fix For: 1.3.5, 1.4-M4
>
> Attachments: detect_svg.patch
>
>
> I'd like to extend BrowserInfoForm to detect if the browser supports SVGs 
> (javascript method here 
> http://thomas.tanrei.ca/modern-script-based-svg-detection/ ), but it looks 
> like it cannot be easily extended.. So I wrote a patch against Wicket 1.3.4 
> (hope it's not too messy ^^; )
> Thanks!

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699603 - in /wicket/trunk/wicket/src/main/java/org/apache/wicket: markup/html/pages/BrowserInfoForm.html markup/html/pages/BrowserInfoForm.java markup/html/pages/detectSVG.js protocol/htt

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 01:27:58 2008
New Revision: 699603

URL: http://svn.apache.org/viewvc?rev=699603&view=rev
Log:
rollback wicket-1786

Removed:

wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/detectSVG.js
Modified:

wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html

wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java

wicket/trunk/wicket/src/main/java/org/apache/wicket/protocol/http/ClientProperties.java

Modified: 
wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html?rev=699603&r1=699602&r2=699603&view=diff
==
--- 
wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html
 (original)
+++ 
wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html
 Sat Sep 27 01:27:58 2008
@@ -43,17 +43,6 @@
   document.postback.browserWidth.value =  window.innerWidth || 
document.body.offsetWidth;
   document.postback.browserHeight.value =  window.innerHeight || 
document.body.offsetHeight;
 
-  // SVG detection
-  var svginfo = detectSVG();
-  if(svginfo.support){
- var svgstate = null;
- if(svginfo.support=="Builtin")
-  svgstate=svginfo.builtin + ',' + 
svginfo.builtinVersion;
- else
-  svgstate=svginfo.plugin + ',' + 
svginfo.pluginVersion + ',' + svginfo.IID;
- document.postback.SVGsupport.value = svgstate;
-  }
-
  document.postback.submit();
}

@@ -75,7 +64,6 @@



-   


 

Modified: 
wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java?rev=699603&r1=699602&r2=699603&view=diff
==
--- 
wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java
 (original)
+++ 
wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java
 Sat Sep 27 01:27:58 2008
@@ -17,9 +17,6 @@
 package org.apache.wicket.markup.html.pages;
 
 import org.apache.wicket.IClusterable;
-import org.apache.wicket.ResourceReference;
-import org.apache.wicket.markup.html.IHeaderContributor;
-import org.apache.wicket.markup.html.IHeaderResponse;
 import org.apache.wicket.markup.html.form.Form;
 import org.apache.wicket.markup.html.form.TextField;
 import org.apache.wicket.markup.html.panel.Panel;
@@ -35,7 +32,7 @@
 /**
  * Form for posting JavaScript properties.
  */
-public class BrowserInfoForm extends Panel implements IHeaderContributor
+public class BrowserInfoForm extends Panel
 {
/** log. */
private static final Logger log = 
LoggerFactory.getLogger(BrowserInfoForm.class);
@@ -104,7 +101,6 @@
form.add(new TextField("utcDSTOffset"));
form.add(new TextField("browserWidth"));
form.add(new TextField("browserHeight"));
-   form.add(new TextField("SVGsupport"));
add(form);
}
 
@@ -128,11 +124,6 @@
 
}
 
-   public void renderHead(IHeaderResponse response)
-   {
-   response.renderJavascriptReference(new 
ResourceReference(this.getClass(), "detectSVG.js"));
-   }
-
/**
 * Holds properties of the client.
 */
@@ -155,7 +146,6 @@
private String utcDSTOffset;
private String browserWidth;
private String browserHeight;
-   private String SVGsupport;
 
/**
 * Gets browserHeight.
@@ -322,7 +312,6 @@

properties.setScreenColorDepth(getInt(screenColorDepth));
properties.setUtcOffset(utcOffset);
properties.setUtcDSTOffset(utcDSTOffset);
-   properties.setSVGsupport(SVGsupport);
}
 
/**
@@ -514,25 +503,5 @@
return intValue;
}
 
-   /**
-* Sets SVGsupport
-* 
-* @param SVGsupport
-*SVGsupport
-*/
-   public void setSVGsupport(String gsupport)
-   {
-   SVGsupport = gsupport;
-   }
-
-   /**
-* Gets SVGsupport
-* 
- 

svn commit: r699602 - /wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/ClientProperties.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 01:26:17 2008
New Revision: 699602

URL: http://svn.apache.org/viewvc?rev=699602&view=rev
Log:
rollback WICKET-1786

Modified:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/ClientProperties.java

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/ClientProperties.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/ClientProperties.java?rev=699602&r1=699601&r2=699602&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/ClientProperties.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/protocol/http/ClientProperties.java
 Sat Sep 27 01:26:17 2008
@@ -93,7 +93,6 @@
private String utcDSTOffset;
 
private String utcOffset;
-   private String SVGsupport;
 
 
/**
@@ -1052,20 +1051,6 @@
this.utcOffset = utcOffset;
}
 
-   /**
-* @return null if there is no SVG support, otherwise a String like 
"," (e.g. "Gecko,2")
-*/
-   public String getSVGsupport() {
-   return SVGsupport;
-   }
-
-   /**
-* @param svgsupport the SVGsupport to set
-*/
-   public void setSVGsupport(String svgsupport) {
-   SVGsupport = svgsupport;
-   }
-
public String toString()
{
StringBuffer b = new StringBuffer();




svn commit: r699601 - in /wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages: BrowserInfoForm.html BrowserInfoForm.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 01:26:04 2008
New Revision: 699601

URL: http://svn.apache.org/viewvc?rev=699601&view=rev
Log:
rollback WICKET-1786

Modified:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html?rev=699601&r1=699600&r2=699601&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.html
 Sat Sep 27 01:26:04 2008
@@ -43,18 +43,7 @@
   document.postback.browserWidth.value =  window.innerWidth || 
document.body.offsetWidth;
   document.postback.browserHeight.value =  window.innerHeight || 
document.body.offsetHeight;
 
-  // SVG detection
-  var svginfo = detectSVG();
-  if(svginfo.support){
- var svgstate = null;
- if(svginfo.support=="Builtin")
-  svgstate=svginfo.builtin + ',' + 
svginfo.builtinVersion;
- else
-  svgstate=svginfo.plugin + ',' + 
svginfo.pluginVersion + ',' + svginfo.IID;
- document.postback.SVGsupport.value = svgstate;
-  }
-
- document.postback.submit();
+  document.postback.submit();
}



Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java?rev=699601&r1=699600&r2=699601&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/pages/BrowserInfoForm.java
 Sat Sep 27 01:26:04 2008
@@ -17,9 +17,6 @@
 package org.apache.wicket.markup.html.pages;
 
 import org.apache.wicket.IClusterable;
-import org.apache.wicket.ResourceReference;
-import org.apache.wicket.markup.html.IHeaderContributor;
-import org.apache.wicket.markup.html.IHeaderResponse;
 import org.apache.wicket.markup.html.form.Form;
 import org.apache.wicket.markup.html.form.TextField;
 import org.apache.wicket.markup.html.panel.Panel;
@@ -35,7 +32,7 @@
 /**
  * Form for posting JavaScript properties.
  */
-public class BrowserInfoForm extends Panel implements IHeaderContributor
+public class BrowserInfoForm extends Panel
 {
/** log. */
private static final Logger log = 
LoggerFactory.getLogger(BrowserInfoForm.class);
@@ -102,7 +99,6 @@
form.add(new TextField("utcDSTOffset"));
form.add(new TextField("browserWidth"));
form.add(new TextField("browserHeight"));
-   form.add(new TextField("SVGsupport"));
add(form);
}
 
@@ -117,8 +113,8 @@
void warnNotUsingWebClientInfo(ClientInfo clientInfo)
{
log.warn("using " + getClass().getName() + " makes no sense if 
you are not using " +
-   WebClientInfo.class.getName() + " (you are 
using " +
-   clientInfo.getClass().getName() + " instead)");
+   WebClientInfo.class.getName() + " (you are using " + 
clientInfo.getClass().getName() +
+   " instead)");
}
 
protected void afterSubmit()
@@ -126,10 +122,6 @@
 
}
 
-   public void renderHead(IHeaderResponse response) {
-   response.renderJavascriptReference(new 
ResourceReference(this.getClass(), "detectSVG.js"));
-   }
-
/**
 * Holds properties of the client.
 */
@@ -152,7 +144,6 @@
private String utcDSTOffset;
private String browserWidth;
private String browserHeight;
-   private String SVGsupport;
 
/**
 * Gets browserHeight.
@@ -305,10 +296,10 @@
properties.setNavigatorAppName(navigatorAppName);
properties.setNavigatorAppVersion(navigatorAppVersion);

properties.setNavigatorAppCodeName(navigatorAppCodeName);
-   properties.setCookiesEnabl

[jira] Commented: (WICKET-1355) Autocomplete window has wrong position in scrolled context

2008-09-27 Thread Erik van Oosten (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-1355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12635118#action_12635118
 ] 

Erik van Oosten commented on WICKET-1355:
-

Okay. I'll try. I'll be a JAOO so it has to wait till Thursday though.

> Autocomplete window has wrong position in scrolled context
> --
>
> Key: WICKET-1355
> URL: https://issues.apache.org/jira/browse/WICKET-1355
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 1.3.1
>Reporter: Erik van Oosten
>Assignee: Igor Vaynberg
> Fix For: 1.3.5
>
> Attachments: wicket-autocomplete.js
>
>
> When the autocompleted field is located in a scrolled div, the drop-down 
> window is positioned too far down.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699594 - /wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:52:07 2008
New Revision: 699594

URL: http://svn.apache.org/viewvc?rev=699594&view=rev
Log:
forgotten checkin

Modified:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java?rev=699594&r1=699593&r2=699594&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java
 Sat Sep 27 00:52:07 2008
@@ -23,6 +23,7 @@
 import org.apache.wicket.ajax.AjaxRequestTarget;
 import org.apache.wicket.markup.html.IHeaderResponse;
 import org.apache.wicket.markup.html.resources.JavascriptResourceReference;
+import org.apache.wicket.util.string.Strings;
 
 /**
  * @since 1.2
@@ -55,6 +56,8 @@
 
protected final String constructInitJS()
{
+   final String indicatorId = findIndicatorId();
+
StringBuffer sb = new StringBuffer();
sb.append("new Wicket.AutoComplete('")
.append(getComponent().getMarkupId())
@@ -62,21 +65,30 @@
.append(getCallbackUrl())
.append("',")
.append(constructSettingsJS())
-   .append(");");
+   .append(",");
+   if (Strings.isEmpty(indicatorId))
+   {
+   sb.append("null");
+   }
+   else
+   {
+   sb.append("'").append(findIndicatorId()).append("'");
+   }
+   sb.append(");");
return sb.toString();
}
 
protected final String constructSettingsJS()
{
final StringBuffer sb = new StringBuffer();
-sb.append("{preselect: ").append(settings.getPreselect());
-sb.append(",maxHeight: ").append(settings.getMaxHeightInPx());
-sb.append(",adjustInputWidth: ").append(settings.isAdjustInputWidth());
-sb.append(",showListOnEmptyInput: 
").append(settings.getShowListOnEmptyInput());
-sb.append(",showListOnFocusGain: 
").append(settings.getShowListOnFocusGain());
-if(settings.getCssClassName() != null)
-sb.append(",className: 
'").append(settings.getCssClassName()).append('\'');
-sb.append('}');
+   sb.append("{preselect: ").append(settings.getPreselect());
+   sb.append(",maxHeight: ").append(settings.getMaxHeightInPx());
+   sb.append(",adjustInputWidth: 
").append(settings.isAdjustInputWidth());
+   sb.append(",showListOnEmptyInput: 
").append(settings.getShowListOnEmptyInput());
+   sb.append(",showListOnFocusGain: 
").append(settings.getShowListOnFocusGain());
+   if (settings.getCssClassName() != null)
+   sb.append(",className: 
'").append(settings.getCssClassName()).append('\'');
+   sb.append('}');
return sb.toString();
}
 




[jira] Resolved: (WICKET-1161) DiskPageStore should write the sessions index file to disk on destroy (from WicketFilter.destroy())

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1161?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1161.
---

Resolution: Fixed

> DiskPageStore should write the sessions index file to disk on destroy (from 
> WicketFilter.destroy())
> ---
>
> Key: WICKET-1161
> URL: https://issues.apache.org/jira/browse/WICKET-1161
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.3.0-rc1
>Reporter: Johan Compagner
>Assignee: Matej Knopp
> Fix For: 1.3.5
>
>
> We have to save the sessions index to disk from the DiskPageStore when we get 
> a shutdown/destroy from the servlet container
> (I hope that that that event will be called on a servlet container shutdown 
> and on a undeploy/redeploy of the webapp.)
> Then with a destroy we save it. When we are fired up again we read that file 
> and also delete the file immediantly.
> Then when the page store is created and the file isn't there it can delete 
> all the page stores files that are currently on disk
> because the destroy didn't happen so it was a crash or a hard kill and there 
> won't be any sessions anyway.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (WICKET-1719) StringResourceModel may fail to format numbers using MessageFormat

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1719?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1719.
---

   Resolution: Fixed
Fix Version/s: 1.4-M4
 Assignee: Igor Vaynberg

> StringResourceModel may fail to format numbers using MessageFormat
> --
>
> Key: WICKET-1719
> URL: https://issues.apache.org/jira/browse/WICKET-1719
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.3.3
>Reporter: Andrea Aime
>Assignee: Igor Vaynberg
> Fix For: 1.3.5, 1.4-M4
>
>
> StringResourceModel API seems to suggest it's possible to use it without a 
> Component reference using the following approach:
> {code}
> m = new StringResourceModel("key", null, new Model(...), new Object[] {p1, 
> p2, ...});
> m.setLocalizer(xxxApplication.get().getResourceSettings().getLocalizer());
> return m.toString()
> {code}
> Unfortunately the above will fail with an exception if the message uses the 
> MessageFormat approach and one of the parameters
> is a number, since the locale field in StringResourceModel won't be 
> initialized, and will then be passed as null to new MessageFormat(value, 
> locale) at line 514 of StringResourceFormat.
> I'm using the following crude workaround:
> {code}
> StringResourceModel rm = new StringResourceModel(key, null, model, params) {
> @Override
> public void setLocalizer(Localizer localizer) {
> super.setLocalizer(localizer);
> // crude hack to force into the StringResoruceLoader to grab 
> a locale,
> // which is needed to format numbers with the MessageFormat 
> approach
> load();
> }
> };
> 
> rm.setLocalizer(GeoServerApplication.get().getResourceSettings().getLocalizer());
> return rm.getString();
> {code}
> but boy, this looks ugly... Creating a custom subclass that does locale 
> loading in the
> constructor would look better, but still quite ugly...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699593 - /wicket/trunk/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:44:01 2008
New Revision: 699593

URL: http://svn.apache.org/viewvc?rev=699593&view=rev
Log:
WICKET-1719

Modified:

wicket/trunk/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java

Modified: 
wicket/trunk/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java?rev=699593&r1=699592&r2=699593&view=diff
==
--- 
wicket/trunk/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java
 (original)
+++ 
wicket/trunk/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java
 Sat Sep 27 00:44:01 2008
@@ -51,10 +51,9 @@
  * reusable components/containers that are packaged with their own string 
resource bundles it should
  * be the actual component/container rather than the page. For more 
information on this please see
  * [EMAIL PROTECTED] 
org.apache.wicket.resource.loader.ComponentStringResourceLoader}. The relative 
component
- * may actually be null when all resource loading is to be done 
from a global
- * resource loader. However, we recommend that a relative component is still 
supplied even in these
- * cases in order to 'future proof' your application with regards to changing 
resource loading
- * strategies.
+ * may actually be null when all resource loading is to be done 
from a global resource
+ * loader. However, we recommend that a relative component is still supplied 
even in these cases in
+ * order to 'future proof' your application with regards to changing resource 
loading strategies.
  * model - This parameter is mandatory if either the resourceKey, 
the found string
  * resource (see below) or any of the substitution parameters (see below) 
contain property
  * expressions. Where property expressions are present they will all be 
evaluated relative to this
@@ -65,10 +64,10 @@
  * java.text.MessageFormat object. Each parameter may be an 
ordinary Object, in which
  * case it will be processed by the standard formatting rules associated with
  * java.text.MessageFormat. Alternatively, the parameter may be 
an instance of
- * IModel in which case the getObject() method will 
be applied prior
- * to the parameter being passed to the java.text.MessageFormat. 
This allows such
- * features dynamic parameters that are obtained using a 
PropertyModel object or even
- * nested string resource models.
+ * IModel in which case the getObject() method will 
be applied prior to
+ * the parameter being passed to the java.text.MessageFormat. 
This allows such features
+ * dynamic parameters that are obtained using a PropertyModel 
object or even nested
+ * string resource models.
  * 
  * As well as the supplied parameters, the found string resource can contain 
formatting information.
  * It may contain property expressions in which case these are evaluated using 
the model object
@@ -470,6 +469,12 @@
}
}
 
+   // Make sure we have the locale
+   if (locale == null)
+   {
+   locale = Session.get().getLocale();
+   }
+
String value = null;
// Substitute any parameters if necessary
Object[] parameters = getParameters();




svn commit: r699592 - /wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:43:23 2008
New Revision: 699592

URL: http://svn.apache.org/viewvc?rev=699592&view=rev
Log:
WICKET-1719

Modified:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java?rev=699592&r1=699591&r2=699592&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/model/StringResourceModel.java
 Sat Sep 27 00:43:23 2008
@@ -51,10 +51,9 @@
  * reusable components/containers that are packaged with their own string 
resource bundles it should
  * be the actual component/container rather than the page. For more 
information on this please see
  * [EMAIL PROTECTED] 
org.apache.wicket.resource.loader.ComponentStringResourceLoader}. The relative 
component
- * may actually be null when all resource loading is to be done 
from a global
- * resource loader. However, we recommend that a relative component is still 
supplied even in these
- * cases in order to 'future proof' your application with regards to changing 
resource loading
- * strategies.
+ * may actually be null when all resource loading is to be done 
from a global resource
+ * loader. However, we recommend that a relative component is still supplied 
even in these cases in
+ * order to 'future proof' your application with regards to changing resource 
loading strategies.
  * model - This parameter is mandatory if either the resourceKey, 
the found string
  * resource (see below) or any of the substitution parameters (see below) 
contain property
  * expressions. Where property expressions are present they will all be 
evaluated relative to this
@@ -65,10 +64,10 @@
  * java.text.MessageFormat object. Each parameter may be an 
ordinary Object, in which
  * case it will be processed by the standard formatting rules associated with
  * java.text.MessageFormat. Alternatively, the parameter may be 
an instance of
- * IModel in which case the getObject() method will 
be applied prior
- * to the parameter being passed to the java.text.MessageFormat. 
This allows such
- * features dynamic parameters that are obtained using a 
PropertyModel object or even
- * nested string resource models.
+ * IModel in which case the getObject() method will 
be applied prior to
+ * the parameter being passed to the java.text.MessageFormat. 
This allows such features
+ * dynamic parameters that are obtained using a PropertyModel 
object or even nested
+ * string resource models.
  * 
  * As well as the supplied parameters, the found string resource can contain 
formatting information.
  * It may contain property expressions in which case these are evaluated using 
the model object
@@ -226,11 +225,14 @@
 
public Object getObject()
{
-   if (StringResourceModel.this.component != null) {
+   if (StringResourceModel.this.component != null)
+   {
return StringResourceModel.this.getObject();
-   } else {
+   }
+   else
+   {
// TODO: Remove this as soon as we can break 
binary compatibility
-   StringResourceModel.this.component = 
this.component;
+   StringResourceModel.this.component = component;
Object res = 
StringResourceModel.this.getObject();
StringResourceModel.this.component = null;
return res;
@@ -460,6 +462,12 @@
}
}
 
+   // Make sure we have the locale
+   if (locale == null)
+   {
+   locale = Session.get().getLocale();
+   }
+
String value = null;
// Substitute any parameters if necessary
Object[] parameters = getParameters();




[jira] Resolved: (WICKET-1205) Relative path calculations for inline paths in non-bookmarkable pages are incorrect on Tomcat.

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1205?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1205.
---

Resolution: Won't Fix

this is quiet esoteric and we should not be fixing tomcat weirdness

> Relative path calculations for inline paths in non-bookmarkable pages are 
> incorrect on Tomcat.
> --
>
> Key: WICKET-1205
> URL: https://issues.apache.org/jira/browse/WICKET-1205
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.3.0-rc1
> Environment: JBoss 4.2 / Tomcat Embedded
>Reporter: Jeremy Levy
>Assignee: Alastair Maw
> Fix For: 1.3.5
>
> Attachments: CSSIssueQuickStart.tar.gz, OldUrlFilter.java, 
> WICKET-1205.zip
>
>
> When linking from a bookmarked page to a non-bookmarked page the relative 
> link to the CSS page breaks. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (WICKET-1205) Relative path calculations for inline paths in non-bookmarkable pages are incorrect on Tomcat.

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1205?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1205.
---

Resolution: Fixed

> Relative path calculations for inline paths in non-bookmarkable pages are 
> incorrect on Tomcat.
> --
>
> Key: WICKET-1205
> URL: https://issues.apache.org/jira/browse/WICKET-1205
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.3.0-rc1
> Environment: JBoss 4.2 / Tomcat Embedded
>Reporter: Jeremy Levy
>Assignee: Alastair Maw
> Fix For: 1.3.5
>
> Attachments: CSSIssueQuickStart.tar.gz, OldUrlFilter.java, 
> WICKET-1205.zip
>
>
> When linking from a bookmarked page to a non-bookmarked page the relative 
> link to the CSS page breaks. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (WICKET-928) Exception when clicking two times rapidly on the "next" button in a wizard

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-928?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-928.
--

Resolution: Cannot Reproduce
  Assignee: Igor Vaynberg  (was: Eelco Hillenius)

could not reproduce with latest 1.3.x

> Exception when clicking two times rapidly on the "next" button in a wizard
> --
>
> Key: WICKET-928
> URL: https://issues.apache.org/jira/browse/WICKET-928
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 1.3.0-beta2, 1.3.0-beta3
>Reporter: Joël Vimenet
>Assignee: Igor Vaynberg
> Fix For: 1.3.5
>
> Attachments: Apache.tar.gz
>
>
> On a tree steps wizard, the first step contains two fields without any 
> validation. The second one contains only one field that must be an integer. 
> The last step will display the data entered in the two first steps.
> When I am on the first step, and I click two times rapidly on the "next" 
> button, it throws an exception.
> Here is the stack trace : 
> --
> WicketMessage: Method onFormSubmitted of interface 
> org.apache.wicket.markup.html.form.IFormSubmitListener targeted at component 
> [MarkupContainer [Component id = form, page = test.www.factory.TestPage, path 
> = 0:wizard:form.Form, isVisible = true, isVersioned = false]] threw an 
> exception
> Root cause:
> java.lang.NullPointerException
> at 
> org.apache.wicket.util.convert.converters.AbstractConverter.parse(AbstractConverter.java:50)
> at 
> org.apache.wicket.util.convert.converters.AbstractNumberConverter.parse(AbstractNumberConverter.java:71)
> at 
> org.apache.wicket.util.convert.converters.IntegerConverter.convertToObject(IntegerConverter.java:44)
> at 
> org.apache.wicket.markup.html.form.FormComponent.convertInput(FormComponent.java:1159)
> at 
> org.apache.wicket.markup.html.form.FormComponent.validate(FormComponent.java:1027)
> at org.apache.wicket.markup.html.form.Form$15.validate(Form.java:1671)
> at 
> org.apache.wicket.markup.html.form.Form$ValidationVisitor.formComponent(Form.java:160)
> at 
> org.apache.wicket.markup.html.form.FormComponent.visitFormComponentsPostOrderHelper(FormComponent.java:403)
> at 
> org.apache.wicket.markup.html.form.FormComponent.visitFormComponentsPostOrderHelper(FormComponent.java:390)
> at 
> org.apache.wicket.markup.html.form.FormComponent.visitFormComponentsPostOrderHelper(FormComponent.java:390)
> at 
> org.apache.wicket.markup.html.form.FormComponent.visitFormComponentsPostOrderHelper(FormComponent.java:390)
> at 
> org.apache.wicket.markup.html.form.FormComponent.visitFormComponentsPostOrder(FormComponent.java:368)
> at 
> org.apache.wicket.markup.html.form.Form.visitFormComponentsPostOrder(Form.java:1004)
> at org.apache.wicket.markup.html.form.Form.validateComponents(Form.java:1667)
> at org.apache.wicket.markup.html.form.Form.validate(Form.java:1658)
> at org.apache.wicket.markup.html.form.Form.process(Form.java:811)
> at org.apache.wicket.markup.html.form.Form.onFormSubmitted(Form.java:783)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at 
> org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:186)
> at 
> org.apache.wicket.request.target.component.listener.ListenerInterfaceRequestTarget.processEvents(ListenerInterfaceRequestTarget.java:73)
> at 
> org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:90)
> at 
> org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1032)
> at org.apache.wicket.RequestCycle.step(RequestCycle.java:1108)
> at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1177)
> at org.apache.wicket.RequestCycle.request(RequestCycle.java:500)
> at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:261)
> at 
> org.apache.wicket.protocol.http.WicketServlet.doPost(WicketServlet.java:144)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
> at 
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
> at 
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
> at 
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
> at 
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
> at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> at 
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
> at 
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
> at org.apache.catalina.connector.CoyoteAdapte

[jira] Reopened: (WICKET-1205) Relative path calculations for inline paths in non-bookmarkable pages are incorrect on Tomcat.

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1205?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg reopened WICKET-1205:
---


> Relative path calculations for inline paths in non-bookmarkable pages are 
> incorrect on Tomcat.
> --
>
> Key: WICKET-1205
> URL: https://issues.apache.org/jira/browse/WICKET-1205
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.3.0-rc1
> Environment: JBoss 4.2 / Tomcat Embedded
>Reporter: Jeremy Levy
>Assignee: Alastair Maw
> Fix For: 1.3.5
>
> Attachments: CSSIssueQuickStart.tar.gz, OldUrlFilter.java, 
> WICKET-1205.zip
>
>
> When linking from a bookmarked page to a non-bookmarked page the relative 
> link to the CSS page breaks. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Updated: (WICKET-1819) SharedResourceRequestTarget with Custom ResourceStreamLocator throws ClassNotFoundException

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1819?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg updated WICKET-1819:
--

Fix Version/s: (was: 1.3.5)

we need a quickstart that reproduces this...

> SharedResourceRequestTarget with Custom ResourceStreamLocator throws 
> ClassNotFoundException
> ---
>
> Key: WICKET-1819
> URL: https://issues.apache.org/jira/browse/WICKET-1819
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.3.4
> Environment: All
>Reporter: Ritesh Trivedi
>
> Hi,
> Seems like in wicket 1.3.x, if you include a CSS using HeaderContributor and 
> if CSS has background-image style with paths like ../img/whatever.gif, 
> SharedResourceRequestTarget throws exception instead of resource getting 
> loaded through the custom resource stream locator registered in the 
> application.
> resolver below tried to find a class by the name of img from 
> ../img/whatever.gif which of course will fail with classnotfoundexception.
> The block of code that causes the exception is
> SharedResourceRequestTarget.java
> line:143
> // First try to match mounted
> scope = Application.get().getSharedResources().getAliasClass(className);
> // If that fails, resolve it as a fully qualified class
> // name.
> if (scope == null)
> {
>   scope = resolver.resolveClass(className);
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (WICKET-622) Component.toString() is unsafe

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-622?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-622.
--

Resolution: Fixed
  Assignee: Igor Vaynberg  (was: Juergen Donnerstag)

> Component.toString() is unsafe 
> ---
>
> Key: WICKET-622
> URL: https://issues.apache.org/jira/browse/WICKET-622
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.2.2
>Reporter: Nili Adoram
>Assignee: Igor Vaynberg
> Fix For: 1.3.5
>
>
> I add a component to its container when the page is initialized, BEFORE
> it is rendered and before page model finished to initialize.
> if log4j is configured to enable wicket debug, the container toString()
> is called.
> This method invokes isVisible() of the container.
> I have overridden isVisible(), to query the page model before deciding
> whether the component is actually visible.
> I assumed this method is called when the component is rendered, and by
> that time the model is completely initialized.
> However, since it was called before component rendering, my code failed
> and the page failed to be created.
> To sum up, toString() of Component should be safe.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699591 - in /wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket: Component.java MarkupContainer.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:33:09 2008
New Revision: 699591

URL: http://svn.apache.org/viewvc?rev=699591&view=rev
Log:
WICKET-622

Modified:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/Component.java

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/MarkupContainer.java

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/Component.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/Component.java?rev=699591&r1=699590&r2=699591&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/Component.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/Component.java
 Sat Sep 27 00:33:09 2008
@@ -3049,7 +3049,7 @@
 */
public String toString()
{
-   return toString(true);
+   return toString(false);
}
 
/**

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/MarkupContainer.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/MarkupContainer.java?rev=699591&r1=699590&r2=699591&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/MarkupContainer.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/MarkupContainer.java
 Sat Sep 27 00:33:09 2008
@@ -767,7 +767,7 @@
{
final StringBuffer buffer = new StringBuffer();
buffer.append("[MarkupContainer ");
-   buffer.append(super.toString(true));
+   buffer.append(super.toString(detailed));
if (detailed)
{
if (getMarkupStream() != null)




svn commit: r699590 - in /wicket/trunk/wicket/src/main/java/org/apache/wicket: Component.java MarkupContainer.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:32:44 2008
New Revision: 699590

URL: http://svn.apache.org/viewvc?rev=699590&view=rev
Log:
WICKET-622

Modified:
wicket/trunk/wicket/src/main/java/org/apache/wicket/Component.java
wicket/trunk/wicket/src/main/java/org/apache/wicket/MarkupContainer.java

Modified: wicket/trunk/wicket/src/main/java/org/apache/wicket/Component.java
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket/src/main/java/org/apache/wicket/Component.java?rev=699590&r1=699589&r2=699590&view=diff
==
--- wicket/trunk/wicket/src/main/java/org/apache/wicket/Component.java 
(original)
+++ wicket/trunk/wicket/src/main/java/org/apache/wicket/Component.java Sat Sep 
27 00:32:44 2008
@@ -3144,7 +3144,7 @@
@Override
public String toString()
{
-   return toString(true);
+   return toString(false);
}
 
/**

Modified: 
wicket/trunk/wicket/src/main/java/org/apache/wicket/MarkupContainer.java
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket/src/main/java/org/apache/wicket/MarkupContainer.java?rev=699590&r1=699589&r2=699590&view=diff
==
--- wicket/trunk/wicket/src/main/java/org/apache/wicket/MarkupContainer.java 
(original)
+++ wicket/trunk/wicket/src/main/java/org/apache/wicket/MarkupContainer.java 
Sat Sep 27 00:32:44 2008
@@ -787,7 +787,7 @@
{
final StringBuffer buffer = new StringBuffer();
buffer.append("[MarkupContainer ");
-   buffer.append(super.toString(true));
+   buffer.append(super.toString(detailed));
if (detailed)
{
if (getMarkupStream() != null)




[jira] Assigned: (WICKET-1355) Autocomplete window has wrong position in scrolled context

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1355?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg reassigned WICKET-1355:
-

Assignee: Igor Vaynberg  (was: Janne Hietamäki)

> Autocomplete window has wrong position in scrolled context
> --
>
> Key: WICKET-1355
> URL: https://issues.apache.org/jira/browse/WICKET-1355
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 1.3.1
>Reporter: Erik van Oosten
>Assignee: Igor Vaynberg
> Fix For: 1.3.5
>
> Attachments: wicket-autocomplete.js
>
>
> When the autocompleted field is located in a scrolled div, the drop-down 
> window is positioned too far down.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Commented: (WICKET-1355) Autocomplete window has wrong position in scrolled context

2008-09-27 Thread Igor Vaynberg (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-1355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12635112#action_12635112
 ] 

Igor Vaynberg commented on WICKET-1355:
---

erik, can you please attach a patch rather then the file itself, since the file 
has changed it makes it impossible to apply your changes.

> Autocomplete window has wrong position in scrolled context
> --
>
> Key: WICKET-1355
> URL: https://issues.apache.org/jira/browse/WICKET-1355
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 1.3.1
>Reporter: Erik van Oosten
>Assignee: Janne Hietamäki
> Fix For: 1.3.5
>
> Attachments: wicket-autocomplete.js
>
>
> When the autocompleted field is located in a scrolled div, the drop-down 
> window is positioned too far down.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (WICKET-1580) StatelessForm doesn't work if GET method on form is used

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1580?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1580.
---

Resolution: Cannot Reproduce
  Assignee: Igor Vaynberg  (was: Johan Compagner)

tried with the stateless example in wicket-examples and everything worked fine

> StatelessForm doesn't work if GET method on form is used
> 
>
> Key: WICKET-1580
> URL: https://issues.apache.org/jira/browse/WICKET-1580
> Project: Wicket
>  Issue Type: Sub-task
>  Components: wicket
>Affects Versions: 1.3.3
> Environment: Tomcat 6.0.16, JDK 1.5
>Reporter: Doug Donohoe
>Assignee: Igor Vaynberg
> Fix For: 1.3.5
>
>
> As part of my effort to submit a form to a bookmarkable page, I discovered 
> this bug when trying to uses a stateless form with the GET method of a form.  
> I've documented the code that generated this error at:
> http://wiki.donohoedigital.com/wiki/Wiki.jsp?page=Bookmarkable%20Form%20Submission%20in%20Wicket
> The original thread was 
> http://www.nabble.com/submit-form-to-bookmarkable-page-to16912974.html
> Post method seems to work fine.  The error message is: 
> WicketMessage: Internal error parsing wicket:interface = 
> %3A1%3Aform%3A%3AIFormSubmitListener%3A%3A 
> Root cause: 
> org.apache.wicket.WicketRuntimeException: Internal error parsing 
> wicket:interface = %3A1%3Aform%3A%3AIFormSubmitListener%3A%3A 
> at 
> org.apache.wicket.protocol.http.request.WebRequestCodingStrategy.addInterfaceParameters(WebRequestCodingStrategy.java:583)
>  
> at 
> org.apache.wicket.protocol.http.request.WebRequestCodingStrategy.addInterfaceParameters(WebRequestCodingStrategy.java:554)
>  
> at 
> org.apache.wicket.protocol.http.request.WebRequestCodingStrategy.decode(WebRequestCodingStrategy.java:199)
>  
> at org.apache.wicket.Request.getRequestParameters(Request.java:171) 
> at org.apache.wicket.RequestCycle.step(RequestCycle.java:1224) 
> at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1331) 
> at org.apache.wicket.RequestCycle.request(RequestCycle.java:493) 
> at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:363) 
> at 
> org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194) 
> at 
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>  
> at 
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>  
> at 
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
>  
> at 
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
>  
> at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) 
> at 
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) 
> at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568) 
> at 
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>  
> at 
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) 
> at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) 
> at 
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
>  
> at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) 
> at java.lang.Thread.run(Thread.java:613) 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Resolved: (WICKET-1648) AbstractRequestTargetUrlCodingStrategy(line 174) throws confusing exception. It would be better redirect to 404-page in this case.

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1648?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1648.
---

   Resolution: Fixed
Fix Version/s: 1.4-M4
 Assignee: Igor Vaynberg  (was: Timo Rantalaiho)

> AbstractRequestTargetUrlCodingStrategy(line 174) throws confusing exception. 
> It would be better redirect to 404-page in this case. 
> ---
>
> Key: WICKET-1648
> URL: https://issues.apache.org/jira/browse/WICKET-1648
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket
>Affects Versions: 1.4-M1
>Reporter: Andrey Tuzhikov
>Assignee: Igor Vaynberg
> Fix For: 1.3.5, 1.4-M4
>
>   Original Estimate: 48h
>  Remaining Estimate: 48h
>
> Steps to reproduce: 
> When user manually types incorrect URL, this confusing exception will be 
> thrown.
> SEVERE: Internal error for /eshop/profile/p
> java.lang.IllegalStateException: URL fragment has unmatched key/value pair: p
>   at 
> org.apache.wicket.request.target.coding.AbstractRequestTargetUrlCodingStrategy.decodeParameters(AbstractRequestTargetUrlCodingStrategy.java:174)
>   at 
> org.apache.wicket.request.target.coding.BookmarkablePageRequestTargetUrlCodingStrategy.decode(BookmarkablePageRequestTargetUrlCodingStrategy.java:76)
>   at 
> org.apache.wicket.protocol.http.request.WebRequestCodingStrategy.targetForRequest(WebRequestCodingStrategy.java:476)
>   at 
> org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:175)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699585 - /wicket/trunk/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:19:09 2008
New Revision: 699585

URL: http://svn.apache.org/viewvc?rev=699585&view=rev
Log:
WICKET-1648

Modified:

wicket/trunk/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java

Modified: 
wicket/trunk/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java?rev=699585&r1=699584&r2=699585&view=diff
==
--- 
wicket/trunk/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java
 (original)
+++ 
wicket/trunk/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java
 Sat Sep 27 00:19:09 2008
@@ -23,8 +23,9 @@
 import java.util.Map.Entry;
 
 import org.apache.wicket.protocol.http.UnitTestSettings;
-import org.apache.wicket.protocol.http.WicketURLEncoder;
 import org.apache.wicket.protocol.http.WicketURLDecoder;
+import org.apache.wicket.protocol.http.WicketURLEncoder;
+import org.apache.wicket.protocol.http.servlet.AbortWithWebErrorCodeException;
 import org.apache.wicket.util.string.AppendingStringBuffer;
 import org.apache.wicket.util.string.Strings;
 import org.apache.wicket.util.value.ValueMap;
@@ -39,13 +40,12 @@
  * @author Igor Vaynberg (ivaynberg)
  */
 public abstract class AbstractRequestTargetUrlCodingStrategy
-   implements
-   IRequestTargetUrlCodingStrategy,
-   IMountableRequestTargetUrlCodingStrategy
+   implements
+   IRequestTargetUrlCodingStrategy,
+   IMountableRequestTargetUrlCodingStrategy
 {
/** log. */
-   private static final Logger log = LoggerFactory
-   
.getLogger(AbstractRequestTargetUrlCodingStrategy.class);
+   private static final Logger log = 
LoggerFactory.getLogger(AbstractRequestTargetUrlCodingStrategy.class);
 
/** mounted path. */
private final String mountPath;
@@ -168,9 +168,9 @@
// If we don't have an even number of pairs
if (pairs.length % 2 != 0)
{
-   // give up
-   throw new IllegalStateException("URL fragment has 
unmatched key/value " + "pair: " +
-   urlFragment);
+   log.warn("URL fragment has unmatched key/value pairs, 
responding with 404. Fragment: " +
+   urlFragment);
+   throw new AbortWithWebErrorCodeException(404);
}
 
// Loop through pairs
@@ -192,76 +192,78 @@
return parameters;
}
 
-/**
- * Url encodes a string that is mean for a URL path (e.g., between slashes)
- *
- * @param string
- *string to be encoded
- * @return encoded string
- */
-protected String urlEncodePathComponent(String string)
-{
-return WicketURLEncoder.PATH_INSTANCE.encode(string);
-}
+   /**
+* Url encodes a string that is mean for a URL path (e.g., between 
slashes)
+* 
+* @param string
+*string to be encoded
+* @return encoded string
+*/
+   protected String urlEncodePathComponent(String string)
+   {
+   return WicketURLEncoder.PATH_INSTANCE.encode(string);
+   }
 
-/**
+   /**
 * Returns a decoded value of the given value (taken from a URL path 
section)
-*
+* 
 * @param value
 * @return Decodes the value
 */
protected String urlDecodePathComponent(String value)
{
-return WicketURLDecoder.PATH_INSTANCE.decode(value);
+   return WicketURLDecoder.PATH_INSTANCE.decode(value);
}
 
-/**
+   /**
 * Url encodes a string mean for a URL query string
-*
+* 
 * @param string
 *string to be encoded
 * @return encoded string
 */
protected String urlEncodeQueryComponent(String string)
{
-return WicketURLEncoder.QUERY_INSTANCE.encode(string);
+   return WicketURLEncoder.QUERY_INSTANCE.encode(string);
}
 
-/**
- * Returns a decoded value of the given value (taken from a URL query 
string)
- *
- * @param value
- * @return Decodes the value
- */
-protected String urlDecodeQueryComponent(String value)
-{
-return WicketURLDecoder.QUERY_INSTANCE.decode(value);
-}
+   /**
+* Returns a decoded value of the given value (taken from a URL query 
string)
+* 
+* @param value
+* @return Decodes the value
+*/
+   protected

svn commit: r699586 - /wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:19:23 2008
New Revision: 699586

URL: http://svn.apache.org/viewvc?rev=699586&view=rev
Log:
WICKET-1648

Modified:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java?rev=699586&r1=699585&r2=699586&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket/src/main/java/org/apache/wicket/request/target/coding/AbstractRequestTargetUrlCodingStrategy.java
 Sat Sep 27 00:19:23 2008
@@ -23,8 +23,9 @@
 import java.util.Map.Entry;
 
 import org.apache.wicket.protocol.http.UnitTestSettings;
-import org.apache.wicket.protocol.http.WicketURLEncoder;
 import org.apache.wicket.protocol.http.WicketURLDecoder;
+import org.apache.wicket.protocol.http.WicketURLEncoder;
+import org.apache.wicket.protocol.http.servlet.AbortWithWebErrorCodeException;
 import org.apache.wicket.util.string.AppendingStringBuffer;
 import org.apache.wicket.util.string.Strings;
 import org.apache.wicket.util.value.ValueMap;
@@ -39,13 +40,12 @@
  * @author Igor Vaynberg (ivaynberg)
  */
 public abstract class AbstractRequestTargetUrlCodingStrategy
-   implements
-   IRequestTargetUrlCodingStrategy,
-   IMountableRequestTargetUrlCodingStrategy
+   implements
+   IRequestTargetUrlCodingStrategy,
+   IMountableRequestTargetUrlCodingStrategy
 {
/** log. */
-   private static final Logger log = LoggerFactory
-   
.getLogger(AbstractRequestTargetUrlCodingStrategy.class);
+   private static final Logger log = 
LoggerFactory.getLogger(AbstractRequestTargetUrlCodingStrategy.class);
 
/** mounted path. */
private final String mountPath;
@@ -168,9 +168,9 @@
// If we don't have an even number of pairs
if (pairs.length % 2 != 0)
{
-   // give up
-   throw new IllegalStateException("URL fragment has 
unmatched key/value " + "pair: " +
-   urlFragment);
+   log.warn("URL fragment has unmatched key/value pairs, 
responding with 404. Fragment: " +
+   urlFragment);
+   throw new AbortWithWebErrorCodeException(404);
}
 
// Loop through pairs
@@ -192,76 +192,76 @@
return parameters;
}
 
-/**
- * Url encodes a string that is mean for a URL path (e.g., between slashes)
- *
- * @param string
- *string to be encoded
- * @return encoded string
- */
-protected String urlEncodePathComponent(String string)
-{
-return WicketURLEncoder.PATH_INSTANCE.encode(string);
-}
+   /**
+* Url encodes a string that is mean for a URL path (e.g., between 
slashes)
+* 
+* @param string
+*string to be encoded
+* @return encoded string
+*/
+   protected String urlEncodePathComponent(String string)
+   {
+   return WicketURLEncoder.PATH_INSTANCE.encode(string);
+   }
 
-/**
+   /**
 * Returns a decoded value of the given value (taken from a URL path 
section)
-*
+* 
 * @param value
 * @return Decodes the value
 */
protected String urlDecodePathComponent(String value)
{
-return WicketURLDecoder.PATH_INSTANCE.decode(value);
+   return WicketURLDecoder.PATH_INSTANCE.decode(value);
}
 
-/**
+   /**
 * Url encodes a string mean for a URL query string
-*
+* 
 * @param string
 *string to be encoded
 * @return encoded string
 */
protected String urlEncodeQueryComponent(String string)
{
-return WicketURLEncoder.QUERY_INSTANCE.encode(string);
+   return WicketURLEncoder.QUERY_INSTANCE.encode(string);
}
 
-/**
- * Returns a decoded value of the given value (taken from a URL query 
string)
- *
- * @param value
- * @return Decodes the value
- */
-protected String urlDecodeQueryComponent(String value)
-{
-return WicketURLDecoder.QUERY_INSTANCE.decode(value);
-}
+   /**
+* Returns a decoded value of the given value (taken from a U

[jira] Resolved: (WICKET-1839) IAjaxIndicatorAware/WicketAjaxIndicatorAppender with AutoCompleteTextField doesn't work

2008-09-27 Thread Igor Vaynberg (JIRA)

 [ 
https://issues.apache.org/jira/browse/WICKET-1839?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Igor Vaynberg resolved WICKET-1839.
---

   Resolution: Fixed
Fix Version/s: 1.4-M4
 Assignee: Igor Vaynberg

> IAjaxIndicatorAware/WicketAjaxIndicatorAppender with AutoCompleteTextField 
> doesn't work
> ---
>
> Key: WICKET-1839
> URL: https://issues.apache.org/jira/browse/WICKET-1839
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 1.3.4
> Environment: Any
>Reporter: Jan Kriesten
>Assignee: Igor Vaynberg
> Fix For: 1.3.5, 1.4-M4
>
> Attachments: indicator-test.tar.gz
>
>
> When adding IAjaxIndicatorAware/WicketAjaxIndicatorAppender to an 
> AutoCompleteTextField to indicate loading of remote data, the Indicator isn't 
> activated.
> On a side note: AbstractAutoCompleteBehavior#onBind adds another 
> AbstractDefaultAjaxBehavior which is unnecessary since 
> AbstractAutoCompleteBehavior extends that already.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



svn commit: r699584 - in /wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete: AbstractAutoCompleteBehavior.java wicket-autocomplete.js

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:12:10 2008
New Revision: 699584

URL: http://svn.apache.org/viewvc?rev=699584&view=rev
Log:
WICKET-1839

Modified:

wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java

wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js

Modified: 
wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java?rev=699584&r1=699583&r2=699584&view=diff
==
--- 
wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java
 (original)
+++ 
wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/AbstractAutoCompleteBehavior.java
 Sat Sep 27 00:12:10 2008
@@ -23,6 +23,7 @@
 import org.apache.wicket.ajax.AjaxRequestTarget;
 import org.apache.wicket.markup.html.IHeaderResponse;
 import org.apache.wicket.markup.html.resources.JavascriptResourceReference;
+import org.apache.wicket.util.string.Strings;
 
 /**
  * @since 1.2
@@ -49,23 +50,34 @@
super.renderHead(response);
response.renderJavascriptReference(AUTOCOMPLETE_JS);
final String id = getComponent().getMarkupId();
-   String initJS = String.format("new 
Wicket.AutoComplete('%s','%s',%s);", id,
-   getCallbackUrl(), constructSettingsJS());
+
+   String indicatorId = findIndicatorId();
+   if (Strings.isEmpty(indicatorId))
+   {
+   indicatorId = "null";
+   }
+   else
+   {
+   indicatorId = "'" + indicatorId + "'";
+   }
+
+   String initJS = String.format("new 
Wicket.AutoComplete('%s','%s',%s,%s);", id,
+   getCallbackUrl(), constructSettingsJS(), indicatorId);
response.renderOnDomReadyJavascript(initJS);
}
 
protected final String constructSettingsJS()
{
-final StringBuilder sb = new StringBuilder();
-sb.append("{preselect: ").append(settings.getPreselect());
-sb.append(",maxHeight: ").append(settings.getMaxHeightInPx());
-sb.append(",adjustInputWidth: ").append(settings.isAdjustInputWidth());
-sb.append(",showListOnEmptyInput: 
").append(settings.getShowListOnEmptyInput());
-if(settings.getCssClassName() != null)
-sb.append(",className: 
'").append(settings.getCssClassName()).append('\'');
-sb.append('}');
-return sb.toString();
-}
+   final StringBuilder sb = new StringBuilder();
+   sb.append("{preselect: ").append(settings.getPreselect());
+   sb.append(",maxHeight: ").append(settings.getMaxHeightInPx());
+   sb.append(",adjustInputWidth: 
").append(settings.isAdjustInputWidth());
+   sb.append(",showListOnEmptyInput: 
").append(settings.getShowListOnEmptyInput());
+   if (settings.getCssClassName() != null)
+   sb.append(",className: 
'").append(settings.getCssClassName()).append('\'');
+   sb.append('}');
+   return sb.toString();
+   }
 
/**
 * @see org.apache.wicket.ajax.AbstractDefaultAjaxBehavior#onBind()

Modified: 
wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js
URL: 
http://svn.apache.org/viewvc/wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js?rev=699584&r1=699583&r2=699584&view=diff
==
--- 
wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js
 (original)
+++ 
wicket/trunk/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js
 Sat Sep 27 00:12:10 2008
@@ -27,7 +27,7 @@
enterHidesWithNoSelection : false
 };
 
-Wicket.AutoComplete=function(elementId, callbackUrl, cfg){
+Wicket.AutoComplete=function(elementId, callbackUrl, cfg, indicatorId){
 var KEY_TAB=9;
 var KEY_ENTER=13;
 var KEY_ESC=27;
@@ -257,11 +257,24 @@
 
 function actualUpdateChoices()
 {
+   showIndicator();
 var value = wicketGet(elementId).value;
var request = new 
Wicket.Ajax.Request(callbackUrl+"&q="+processValue(value), doUpdateChoices, 
false, true, false,

svn commit: r699583 - /wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js

2008-09-27 Thread ivaynberg
Author: ivaynberg
Date: Sat Sep 27 00:09:38 2008
New Revision: 699583

URL: http://svn.apache.org/viewvc?rev=699583&view=rev
Log:
WICKET-1839

Modified:

wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js

Modified: 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js
URL: 
http://svn.apache.org/viewvc/wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js?rev=699583&r1=699582&r2=699583&view=diff
==
--- 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js
 (original)
+++ 
wicket/branches/wicket-1.3.x/jdk-1.4/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js
 Sat Sep 27 00:09:38 2008
@@ -27,7 +27,7 @@
enterHidesWithNoSelection : false
 };
 
-Wicket.AutoComplete=function(elementId, callbackUrl, cfg){
+Wicket.AutoComplete=function(elementId, callbackUrl, cfg, indicatorId){
 var KEY_TAB=9;
 var KEY_ENTER=13;
 var KEY_ESC=27;
@@ -256,11 +256,24 @@
 
 function actualUpdateChoices()
 {
+   showIndicator();
 var value = wicketGet(elementId).value;
var request = new 
Wicket.Ajax.Request(callbackUrl+"&q="+processValue(value), doUpdateChoices, 
false, true, false, "wicket-autocomplete|d");
request.get();
 }
-
+
+function showIndicator() {
+   if (indicatorId!=null) {
+   Wicket.$(indicatorId).style.display='';
+   }
+}
+
+function hideIndicator() {
+   if (indicatorId!=null) {
+   Wicket.$(indicatorId).style.display='none';
+   }
+}
+
 function processValue(param) {
 return (encodeURIComponent)?encodeURIComponent(param):escape(param);
 }
@@ -352,6 +365,7 @@
 
 Wicket.Log.info("Response processed successfully.");
 Wicket.Ajax.invokePostCallHandlers();
+hideIndicator();
 }
 
 function scheduleEmptyCheck() {