Re: load page in Wicket and message from web browser
Hi areq10, I tried to recreate your scenario and i came across the same situation you are facing. One query from you : Have you specified WindowClosedCallback for your modalWindow??? If not Specify that using this piece of code : modalWindow.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() { private static final long serialVersionUID = -1991891482338549420L; @Override public void onClose(AjaxRequestTarget target) { System.out.println(Modal window closed); setResponsePage(YOURPAGE.class); } }); Now when your modalWindow is closed the onClose method of above code is called, which renders your page without any alert from browser side. - Regards, Vaibhav Gupta -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/load-page-in-Wicket-and-message-from-web-browser-tp4651042p4651068.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: What exactly is IWrapModel used for?
Hi Sven Thanks for your explanations. I do now see why there's this wrapper. However, the StringResourceModel appears to break its contract since every LoadableDetachableModel should be loaded using its load() method which cannot be used here! I can fix this by just using delegation instead of subclassing but in my opinion this is just plain wrong that implementors need to know which classes may be overriden and which do not. We have several subclasses of StringResourceModel doing some special stuff like reducing all unresolved properties to the empty string or even returning a completely different String if not all expressions were resolved correctly (for cases where the model object itself is null and thus no properties can be resolved at all) etc... This should either be fixed so that load() can be overriden and works as expected or then it should be made final with a notice why it's not supposed to be overridden. Shall I open a JIRA for that? Regards Matt On 06.08.2012 21:41, Sven Meier wrote: Hi Matt, I don't know about your example but the following makes perfect sense: new Label(id, new StringResourceModel(foo)); This way the message is resolved relative to the label. If the StringResourceModel's constructor is given a component argument, it doesn't make sense to pass it to other components as model, since it will be reassigned anyway. AFAIK this variant is meant to be used ad-hoc without passing it to a component. Maybe it would be better for your OurStringResourceModel *not* to extend StringResourceModel? Sven On 08/06/2012 06:38 PM, Matthias Keller wrote: Hi I'm having some trouble porting a 1.4 application to 1.5 since we're using our own subclass of a StringResourceModel implementing load() in a special way. However, in some cases this does not work as our subclass might get wrapped in a AssignmentWrapper and since we do not provide the component instance (since it's not relevant for this model), load() is never called on our model but instead the load() method of the AssignmentWrapper calls the private getString() directly. I don't see why a model should behave so differently whether it knows its component or not, and where's the point to do something like: label = new Label(id); model=new OurStringResourceModel(..., label); label.setDefaultModel(model); just to have load() called on our own model? Could someone with some insight shed some light on it? Thanks Matt - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- matthias.kel...@ergon.ch +41 44 268 83 98 Ergon Informatik AG, Kleinstrasse 15, CH-8008 Zürich http://www.ergon.ch __ e r g o nsmart people - smart software smime.p7s Description: S/MIME Cryptographic Signature
Re: What exactly is IWrapModel used for?
the StringResourceModel appears to break its contract since every LoadableDetachableModel should be loaded using its load() method which cannot be used here Yes, this is inconsistent. This should either be fixed ... load() cannot be overriden as expected, since it can never work relative to the assigned components. Feel free to open a JIRA issue, but please include a suggestion how to improve this. Sven On 08/09/2012 08:21 AM, Matthias Keller wrote: Hi Sven Thanks for your explanations. I do now see why there's this wrapper. However, the StringResourceModel appears to break its contract since every LoadableDetachableModel should be loaded using its load() method which cannot be used here! I can fix this by just using delegation instead of subclassing but in my opinion this is just plain wrong that implementors need to know which classes may be overriden and which do not. We have several subclasses of StringResourceModel doing some special stuff like reducing all unresolved properties to the empty string or even returning a completely different String if not all expressions were resolved correctly (for cases where the model object itself is null and thus no properties can be resolved at all) etc... This should either be fixed so that load() can be overriden and works as expected or then it should be made final with a notice why it's not supposed to be overridden. Shall I open a JIRA for that? Regards Matt On 06.08.2012 21:41, Sven Meier wrote: Hi Matt, I don't know about your example but the following makes perfect sense: new Label(id, new StringResourceModel(foo)); This way the message is resolved relative to the label. If the StringResourceModel's constructor is given a component argument, it doesn't make sense to pass it to other components as model, since it will be reassigned anyway. AFAIK this variant is meant to be used ad-hoc without passing it to a component. Maybe it would be better for your OurStringResourceModel *not* to extend StringResourceModel? Sven On 08/06/2012 06:38 PM, Matthias Keller wrote: Hi I'm having some trouble porting a 1.4 application to 1.5 since we're using our own subclass of a StringResourceModel implementing load() in a special way. However, in some cases this does not work as our subclass might get wrapped in a AssignmentWrapper and since we do not provide the component instance (since it's not relevant for this model), load() is never called on our model but instead the load() method of the AssignmentWrapper calls the private getString() directly. I don't see why a model should behave so differently whether it knows its component or not, and where's the point to do something like: label = new Label(id); model=new OurStringResourceModel(..., label); label.setDefaultModel(model); just to have load() called on our own model? Could someone with some insight shed some light on it? Thanks Matt - 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: What exactly is IWrapModel used for?
I see, you've just created an issue. Thanks Sven On 08/09/2012 09:02 AM, Sven Meier wrote: the StringResourceModel appears to break its contract since every LoadableDetachableModel should be loaded using its load() method which cannot be used here Yes, this is inconsistent. This should either be fixed ... load() cannot be overriden as expected, since it can never work relative to the assigned components. Feel free to open a JIRA issue, but please include a suggestion how to improve this. Sven On 08/09/2012 08:21 AM, Matthias Keller wrote: Hi Sven Thanks for your explanations. I do now see why there's this wrapper. However, the StringResourceModel appears to break its contract since every LoadableDetachableModel should be loaded using its load() method which cannot be used here! I can fix this by just using delegation instead of subclassing but in my opinion this is just plain wrong that implementors need to know which classes may be overriden and which do not. We have several subclasses of StringResourceModel doing some special stuff like reducing all unresolved properties to the empty string or even returning a completely different String if not all expressions were resolved correctly (for cases where the model object itself is null and thus no properties can be resolved at all) etc... This should either be fixed so that load() can be overriden and works as expected or then it should be made final with a notice why it's not supposed to be overridden. Shall I open a JIRA for that? Regards Matt On 06.08.2012 21:41, Sven Meier wrote: Hi Matt, I don't know about your example but the following makes perfect sense: new Label(id, new StringResourceModel(foo)); This way the message is resolved relative to the label. If the StringResourceModel's constructor is given a component argument, it doesn't make sense to pass it to other components as model, since it will be reassigned anyway. AFAIK this variant is meant to be used ad-hoc without passing it to a component. Maybe it would be better for your OurStringResourceModel *not* to extend StringResourceModel? Sven On 08/06/2012 06:38 PM, Matthias Keller wrote: Hi I'm having some trouble porting a 1.4 application to 1.5 since we're using our own subclass of a StringResourceModel implementing load() in a special way. However, in some cases this does not work as our subclass might get wrapped in a AssignmentWrapper and since we do not provide the component instance (since it's not relevant for this model), load() is never called on our model but instead the load() method of the AssignmentWrapper calls the private getString() directly. I don't see why a model should behave so differently whether it knows its component or not, and where's the point to do something like: label = new Label(id); model=new OurStringResourceModel(..., label); label.setDefaultModel(model); just to have load() called on our own model? Could someone with some insight shed some light on it? Thanks Matt - 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 - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: [6.0] wicket-atmosphere
We've noticed this problem as well. It only happens on Tomcat. I'm not sure what is going on, but it all starts with Tomcat loosing query parameters on the ws-request (url/?0-1.IBehaviorListener.0- is changed to url). This makes it impossible for wicket to recognize the call to a behavior, causing a redirect to a new page on the ws-request, which is not allowed. The question is, is this a bug in Tomcat, Atmosphere or wicket-atmosphere. I would say it's a bug in Atmosphere. I've created a ticket for this: https://github.com/Atmosphere/atmosphere/issues/553 For now, using jetty is a work around. Best regards, Emond On Wednesday 08 August 2012 20:59:10 Pierre Goupil wrote: Hello, It looks like a problem with the WebSockets. I've tried to provide a Locale, but no way: class MySession extends WebSession { private static final long serialVersionUID = 1L; public MySession(final Request req) { super(req); } @Override public void setLocale(final Locale locale) { super.setLocale(new Locale(en, GB)); } } and in my WicketApplication: @Override public Session newSession( final Request req, final Response res ) { return new MySession(req); } It all gives me the same error. BUT if I deactivate the WebSockets, it works: init-param param-nameorg.atmosphere.useWebSocket/param-name param-valueFALSE/param-value /init-param in my web.xml. Regards, Pierre On Wed, Aug 8, 2012 at 5:43 PM, Pierre Goupil goupilpie...@gmail.comwrote: Good afternoon, I'm currently trying and have wicket-atmosphere work. I've looked at the examples and I'm unable to post a message because of this exception: INFO - EventBus - registering component for page 0 for session 971E81ED0E61970FA35A1B03E5B218F8: ERROR - DefaultExceptionMapper - Unexpected error occurred java.lang.IllegalStateException: Request#getLocale() cannot return null, request has to have a locale set on it at org.apache.wicket.Session.init(Session.java:211) at org.apache.wicket.protocol.http.WebSession.init(WebSession.java:92) at org.apache.wicket.protocol.http.WebApplication.newSession(WebApplication.j ava:536) at org.apache.wicket.Application.fetchCreateAndSetSession(Application.java:15 57) at org.apache.wicket.Session.get(Session.java:152) at org.apache.wicket.RestartResponseAtInterceptPageException$InterceptData.ge t(RestartResponseAtInterceptPageException.java:146) at org.apache.wicket.RestartResponseAtInterceptPageException$1.matchedData(Re startResponseAtInterceptPageException.java:211) at org.apache.wicket.RestartResponseAtInterceptPageException$1.getCompatibili tyScore(RestartResponseAtInterceptPageException.java:179) at org.apache.wicket.request.mapper.CompoundRequestMapper.mapRequest(Compound RequestMapper.java:134) at org.apache.wicket.request.cycle.RequestCycle.resolveRequestHandler(Request Cycle.java:182) at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.j ava:207) at org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(Reque stCycle.java:281) at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.j ava:188) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:24 5) at org.atmosphere.util.AtmosphereFilterChain.doFilter(AtmosphereFilterChain.j ava:154) at org.atmosphere.util.AtmosphereFilterChain.invokeFilterChain(AtmosphereFilt erChain.java:131) at org.atmosphere.handler.ReflectorServletProcessor$FilterChainServletWrapper .service(ReflectorServletProcessor.java:310) at org.atmosphere.handler.ReflectorServletProcessor.onRequest(ReflectorServle tProcessor.java:168) at org.atmosphere.cpr.AsynchronousProcessor.action(AsynchronousProcessor.java :248) at org.atmosphere.cpr.AsynchronousProcessor.suspended(AsynchronousProcessor.j ava:166) at org.atmosphere.container.TomcatWebSocketUtil.doService(TomcatWebSocketUtil .java:120) at org.atmosphere.container.Tomcat7BIOSupportWithWebSocket.service(Tomcat7BIO SupportWithWebSocket.java:57) at org.atmosphere.cpr.AtmosphereFramework.doCometSupport(AtmosphereFramework. java:1222) at org.atmosphere.websocket.WebSocketProcessor.dispatch(WebSocketProcessor.ja va:187) at org.atmosphere.websocket.WebSocketProcessor.dispatch(WebSocketProcessor.ja va:116) at org.atmosphere.container.TomcatWebSocketHandler.onOpen(TomcatWebSocketHand ler.java:58) at org.apache.catalina.websocket.StreamInbound.onUpgradeComplete(StreamInboun d.java:228) at
Re: [6.0] wicket-atmosphere
Thanks!!! I'll have a close look at your ticket. And yes, I use Tomcat (7.0.29). I know it's all beta code, so no worries. Regards, Pierre On Thu, Aug 9, 2012 at 10:02 AM, Emond Papegaaij emond.papega...@topicus.nl wrote: We've noticed this problem as well. It only happens on Tomcat. I'm not sure what is going on, but it all starts with Tomcat loosing query parameters on the ws-request (url/?0-1.IBehaviorListener.0- is changed to url). This makes it impossible for wicket to recognize the call to a behavior, causing a redirect to a new page on the ws-request, which is not allowed. The question is, is this a bug in Tomcat, Atmosphere or wicket-atmosphere. I would say it's a bug in Atmosphere. I've created a ticket for this: https://github.com/Atmosphere/atmosphere/issues/553 For now, using jetty is a work around. Best regards, Emond On Wednesday 08 August 2012 20:59:10 Pierre Goupil wrote: Hello, It looks like a problem with the WebSockets. I've tried to provide a Locale, but no way: class MySession extends WebSession { private static final long serialVersionUID = 1L; public MySession(final Request req) { super(req); } @Override public void setLocale(final Locale locale) { super.setLocale(new Locale(en, GB)); } } and in my WicketApplication: @Override public Session newSession( final Request req, final Response res ) { return new MySession(req); } It all gives me the same error. BUT if I deactivate the WebSockets, it works: init-param param-nameorg.atmosphere.useWebSocket/param-name param-valueFALSE/param-value /init-param in my web.xml. Regards, Pierre On Wed, Aug 8, 2012 at 5:43 PM, Pierre Goupil goupilpie...@gmail.com wrote: Good afternoon, I'm currently trying and have wicket-atmosphere work. I've looked at the examples and I'm unable to post a message because of this exception: INFO - EventBus - registering component for page 0 for session 971E81ED0E61970FA35A1B03E5B218F8: ERROR - DefaultExceptionMapper - Unexpected error occurred java.lang.IllegalStateException: Request#getLocale() cannot return null, request has to have a locale set on it at org.apache.wicket.Session.init(Session.java:211) at org.apache.wicket.protocol.http.WebSession.init(WebSession.java:92) at org.apache.wicket.protocol.http.WebApplication.newSession(WebApplication.j ava:536) at org.apache.wicket.Application.fetchCreateAndSetSession(Application.java:15 57) at org.apache.wicket.Session.get(Session.java:152) at org.apache.wicket.RestartResponseAtInterceptPageException$InterceptData.ge t(RestartResponseAtInterceptPageException.java:146) at org.apache.wicket.RestartResponseAtInterceptPageException$1.matchedData(Re startResponseAtInterceptPageException.java:211) at org.apache.wicket.RestartResponseAtInterceptPageException$1.getCompatibili tyScore(RestartResponseAtInterceptPageException.java:179) at org.apache.wicket.request.mapper.CompoundRequestMapper.mapRequest(Compound RequestMapper.java:134) at org.apache.wicket.request.cycle.RequestCycle.resolveRequestHandler(Request Cycle.java:182) at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.j ava:207) at org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(Reque stCycle.java:281) at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.j ava:188) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:24 5) at org.atmosphere.util.AtmosphereFilterChain.doFilter(AtmosphereFilterChain.j ava:154) at org.atmosphere.util.AtmosphereFilterChain.invokeFilterChain(AtmosphereFilt erChain.java:131) at org.atmosphere.handler.ReflectorServletProcessor$FilterChainServletWrapper .service(ReflectorServletProcessor.java:310) at org.atmosphere.handler.ReflectorServletProcessor.onRequest(ReflectorServle tProcessor.java:168) at org.atmosphere.cpr.AsynchronousProcessor.action(AsynchronousProcessor.java :248) at org.atmosphere.cpr.AsynchronousProcessor.suspended(AsynchronousProcessor.j ava:166) at org.atmosphere.container.TomcatWebSocketUtil.doService(TomcatWebSocketUtil .java:120) at org.atmosphere.container.Tomcat7BIOSupportWithWebSocket.service(Tomcat7BIO SupportWithWebSocket.java:57) at org.atmosphere.cpr.AtmosphereFramework.doCometSupport(AtmosphereFramework. java:1222) at org.atmosphere.websocket.WebSocketProcessor.dispatch(WebSocketProcessor.ja va:187) at
Re: Key = Value search panel with actf
Hi Igor, Your component looks very impressive :). So just one question. How can I reach your maven repo ? Because thru central repo I can't reach 1.0-SNAPSHOT. dependency groupIdcom.vaynberg.wicket.select2/groupId artifactIdwicket-select2/artifactId version1.0-SNAPSHOT/version /dependency thnx, Sandor -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Key-Value-search-panel-with-actf-tp4651064p4651075.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: Key = Value search panel with actf
http://central.maven.org/maven2/com/vaynberg/wicket/select2/wicket-select2/0.5/ On Thu, Aug 9, 2012 at 11:48 AM, Sandor Feher sfe...@bluesystem.hu wrote: Hi Igor, Your component looks very impressive :). So just one question. How can I reach your maven repo ? Because thru central repo I can't reach 1.0-SNAPSHOT. dependency groupIdcom.vaynberg.wicket.select2/groupId artifactIdwicket-select2/artifactId version1.0-SNAPSHOT/version /dependency thnx, Sandor -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Key-Value-search-panel-with-actf-tp4651064p4651075.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 -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Key = Value search panel with actf
I'm looking for 1.0-SNAPSHOT and not 0.5 :). thnx., S -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Key-Value-search-panel-with-actf-tp4651064p4651077.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
Equivalent of newSessionStore() in wicket 1.5.7
I am migrating my application from wicket 1.4.x to wicket 1.5.7. The newSessionStore method are removed from wicket 1.5.7. What is the equivalent of newSessionstore in wicket 1.5.7?
Re: Equivalent of newSessionStore() in wicket 1.5.7
See org.apache.wicket.Application#setSessionStoreProvider() The default impl is org.apache.wicket.protocol.http.WebApplication.WebSessionStoreProvider and it works with HttpSessionStore Read https://cwiki.apache.org/confluence/display/WICKET/Page+Storage for more info about stores On Thu, Aug 9, 2012 at 12:08 PM, Madasamy Sankarapandian madas...@mcruncher.com wrote: I am migrating my application from wicket 1.4.x to wicket 1.5.7. The newSessionStore method are removed from wicket 1.5.7. What is the equivalent of newSessionstore in wicket 1.5.7? -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Key = Value search panel with actf
Ok. 0.5 would be fine. thanks, Sandor -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Key-Value-search-panel-with-actf-tp4651064p4651081.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: dynamic control of location of panels on page
If everything is in panels, and all panels have proper CSS, wouldn't they automatically wrap properly, no matter what order they were in? So if I added the panels to the container in the order I wanted, isn't it just ensuring the css for those panels is correct and that they will line up properly and wrap properly? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/dynamic-control-of-location-of-panels-on-page-tp4651043p4651085.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: Tabbed Panel error
Thx. After renaming the html files to ElemConfigAdd$TabPanel1.html , ElemConfigAdd$TabPanel2.html and ElemConfigAdd$TabPanel3.html, I still get error eclipse Console output: ERROR - MarkupFactory - Markup not found: Base markup of inherited markup not found. Component class: com.elster.elemconfig.add.ElemConfigAdd. Enable debug messages for org.apache.wicket.util.resource.locator.ResourceStreamLocator to get a list of all filenames tried. org.apache.wicket.markup.MarkupNotFoundException: Base markup of inherited markup not found. Component class: com.elster.elemconfig.add.ElemConfigAdd. Enable debug messages for org.apache.wicket.util.resource.locator.ResourceStreamLocator to get a list of all filenames tried. at org.apache.wicket.markup.loader.InheritedMarkupMarkupLoader.loadMarkup(InheritedMarkupMarkupLoader.java:69) my webpage: (http://localhost:8080/). On browser I see this error: Last cause: Can not determine Markup. Component is not yet connected to a parent. [Page class = com.elster.elemconfig.add.ElemConfigAdd, id = 0, render count = 1] In java side, I add form.add(new AjaxTabbedPanel(tabs, tabs)); and in html side, i use the same id 'tabs' How do i enable debug logs? I see only info, error logs now. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Tabbed-Panel-error-tp4651059p4651091.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: Javascript in HTML body-ta not working when Panel is used within a Wicket ModalWindow
On 08/09/2012 04:20 PM, Michael M wrote: Hmm I really just tried this several times.. how can it be that different people get a different quick-start behavior? I created that quick start form scratch, added the wicket-extensions dependency, my classes, the 'media' folder with all the CSS and JS files and ran it. I'm confused.. 2012/8/9 Michael M generi...@gmail.com The different behavior should be due to a different version of Jetty: inside Eclipse I was using ver 6.1.26 while running your quickstart via Maven it uses ver 7.5 and I get your behavior. That said, I've found a solution replacing all() with highlight() (see here: http://stackoverflow.com/questions/6471526/use-syntax-highlighter-on-ajax-loaded-content). I'm not an expert of Syntax Highlighterlibrary, so I can't say why highlight() works while all() doesn't... - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
wicket-guice and Logger injection
Hi, I'm attempting to use wicket-guice to inject Logger references into my application with logging. So instead of: Logger logger = LoggerFactory.getLogger(HomePage.class); I would rather: @Log Logger logger; I've followed the guice documentation closely and have been frustratingly unable to get these statements working. Does anyone have any experience with this and can provide insight to why it's not (see links below)? All other objects I have provided or binded are getting injected, however, all my logger statements are throwing NPE. See the following two links for the documentation I have been using. I also have a quick-start wicket application that I have prepared if anyone is curious (it's a zipped up eclipse project ... I may have to rename .zippp to get around the corporate firewall) http://code.google.com/p/google-guice/wiki/CustomInjections http://forkbomb-blog.de/2012/slf4j-logger-injection-with-guice I have also tried the Sli4j library, but was getting NPEs as well: http://sli4j.googlecode.com/svn/site/1.0/index.html Does anyone have experience with sli4j? Finally, does anyone have a maven archetype? My coworker is looking into adding logger injection to the 55minutes prototype. Thank you! Sean Lawrence This e-mail and any attachments are intended only for the use of the addressee(s) named herein and may contain proprietary information. If you are not the intended recipient of this e-mail or believe that you received this email in error, please take immediate action to notify the sender of the apparent error by reply e-mail; permanently delete the e-mail and any attachments from your computer; and do not disseminate, distribute, use, or copy this message and any attachments.
RE: How to display a grid with empty cells
Make use of the EmptyPanel class for the null or empty models. You could also simply call setVisible(false) on your component if you can hide it all together. http://wicket.apache.org/apidocs/1.4/org/apache/wicket/markup/html/panel/Emp tyPanel.html ~ Thank you, Paul Bors -Original Message- From: Bertrand Guay-Paquet [mailto:ber...@step.polymtl.ca] Sent: Wednesday, August 08, 2012 11:37 PM To: users@wicket.apache.org Subject: Re: How to display a grid with empty cells Hi, I haven't used the GridView directly so I can't help you with it specifically. However, have you considered modifying your provider to always return 9 records with some having an empty placeholder? It's definitely a hack, but it may be worth a try. Bertrand On 08/08/2012 10:56 PM, Alec Swan wrote: Hello, I am using Wicket 1.4.17 and need to display a 3x3 table with all of its cells, some of which may not have a model and hence blank. So, if my DataProvider returns 0 elements than I want all 9 cells to be shown as blank. I started using GridView and overrode its populateEmptyItem() method to display empty cells. However, contrary to its JavaDoc Add component to an Item for which there is no model anymore and is shown in a cell this method is not being called unless a row has at least one item (see GrdiView#addItems()). What would the easiest way to accomplish what I need without copying the entire code from GridView class? Any other component that can do that? Thanks, Alec - 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 - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Javascript in HTML body-ta not working when Panel is used within a Wicket ModalWindow
That really is working! I don't get it, I've seen that nowhere documented, so I guess it's more a problem of SyntaxHighlighter than Wicket at all (in combination with Ajax). Thanks for your help, I appreciate it! I guess if everything is working as expected with JavaScript inside panels I also won't have trouble with other content. 2012/8/9 Andrea Del Bene an.delb...@gmail.com On 08/09/2012 04:20 PM, Michael M wrote: Hmm I really just tried this several times.. how can it be that different people get a different quick-start behavior? I created that quick start form scratch, added the wicket-extensions dependency, my classes, the 'media' folder with all the CSS and JS files and ran it. I'm confused.. 2012/8/9 Michael M generi...@gmail.com The different behavior should be due to a different version of Jetty: inside Eclipse I was using ver 6.1.26 while running your quickstart via Maven it uses ver 7.5 and I get your behavior. That said, I've found a solution replacing all() with highlight() (see here: http://stackoverflow.com/**questions/6471526/use-syntax-** highlighter-on-ajax-loaded-**contenthttp://stackoverflow.com/questions/6471526/use-syntax-highlighter-on-ajax-loaded-content). I'm not an expert of Syntax Highlighterlibrary, so I can't say why highlight() works while all() doesn't... --**--**- To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.orgusers-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Tabbed Panel error
Please check your usage of wicket:extend, you seem to use it although your super component doesn't provide markup. Sven On 08/09/2012 04:25 PM, technimadhu wrote: Thx. After renaming the html files to ElemConfigAdd$TabPanel1.html , ElemConfigAdd$TabPanel2.html and ElemConfigAdd$TabPanel3.html, I still get error eclipse Console output: ERROR - MarkupFactory - Markup not found: Base markup of inherited markup not found. Component class: com.elster.elemconfig.add.ElemConfigAdd. Enable debug messages for org.apache.wicket.util.resource.locator.ResourceStreamLocator to get a list of all filenames tried. org.apache.wicket.markup.MarkupNotFoundException: Base markup of inherited markup not found. Component class: com.elster.elemconfig.add.ElemConfigAdd. Enable debug messages for org.apache.wicket.util.resource.locator.ResourceStreamLocator to get a list of all filenames tried. at org.apache.wicket.markup.loader.InheritedMarkupMarkupLoader.loadMarkup(InheritedMarkupMarkupLoader.java:69) my webpage: (http://localhost:8080/). On browser I see this error: Last cause: Can not determine Markup. Component is not yet connected to a parent. [Page class = com.elster.elemconfig.add.ElemConfigAdd, id = 0, render count = 1] In java side, I add form.add(new AjaxTabbedPanel(tabs, tabs)); and in html side, i use the same id 'tabs' How do i enable debug logs? I see only info, error logs now. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Tabbed-Panel-error-tp4651059p4651091.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: How to display a grid with empty cells
I tried returning nulls for blank items from data provider but as you said it feels like a hack because now my GridView#populateItem() needs to handle items with null model objects. The way GridView behaves is confusing because it displays the entire row of cells (some potentially blank) if the row has at least one item. If the row has no items, then the row is not displayed. So, GridView pads every row with empty cells but doesn't do this for every column. Should this be filed as a bug? On Wed, Aug 8, 2012 at 9:37 PM, Bertrand Guay-Paquet ber...@step.polymtl.ca wrote: Hi, I haven't used the GridView directly so I can't help you with it specifically. However, have you considered modifying your provider to always return 9 records with some having an empty placeholder? It's definitely a hack, but it may be worth a try. Bertrand On 08/08/2012 10:56 PM, Alec Swan wrote: Hello, I am using Wicket 1.4.17 and need to display a 3x3 table with all of its cells, some of which may not have a model and hence blank. So, if my DataProvider returns 0 elements than I want all 9 cells to be shown as blank. I started using GridView and overrode its populateEmptyItem() method to display empty cells. However, contrary to its JavaDoc Add component to an Item for which there is no model anymore and is shown in a cell this method is not being called unless a row has at least one item (see GrdiView#addItems()). What would the easiest way to accomplish what I need without copying the entire code from GridView class? Any other component that can do that? Thanks, Alec - 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 - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Tabbed Panel error
Thx Sven. That was it. I blindly copied the example, without paying attention to the 'BasePage' being used in the wicket example page, but I don't use the BasePage. So, I removed the wicket:extend tag in my html and its working fine -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Tabbed-Panel-error-tp4651059p4651098.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-guice and Logger injection
Hi Sean, Keep in mind that Guice isn't directly injecting your Wicket components. That happens through org.apache.wicket.guice.GuiceComponentInjector. More specifically, see GuiceFieldValueFactory#supportsField() which only recognizes @Inject annotated fields as requiring injection. HTH, Dan On Thu, Aug 9, 2012 at 7:32 AM, Lawrence, Sean sean.lawre...@mantech.comwrote: Hi, I'm attempting to use wicket-guice to inject Logger references into my application with logging. So instead of: Logger logger = LoggerFactory.getLogger(HomePage.class); I would rather: @Log Logger logger; I've followed the guice documentation closely and have been frustratingly unable to get these statements working. Does anyone have any experience with this and can provide insight to why it's not (see links below)? All other objects I have provided or binded are getting injected, however, all my logger statements are throwing NPE. See the following two links for the documentation I have been using. I also have a quick-start wicket application that I have prepared if anyone is curious (it's a zipped up eclipse project ... I may have to rename .zippp to get around the corporate firewall) http://code.google.com/p/google-guice/wiki/CustomInjections http://forkbomb-blog.de/2012/slf4j-logger-injection-with-guice I have also tried the Sli4j library, but was getting NPEs as well: http://sli4j.googlecode.com/svn/site/1.0/index.html Does anyone have experience with sli4j? Finally, does anyone have a maven archetype? My coworker is looking into adding logger injection to the 55minutes prototype. Thank you! Sean Lawrence This e-mail and any attachments are intended only for the use of the addressee(s) named herein and may contain proprietary information. If you are not the intended recipient of this e-mail or believe that you received this email in error, please take immediate action to notify the sender of the apparent error by reply e-mail; permanently delete the e-mail and any attachments from your computer; and do not disseminate, distribute, use, or copy this message and any attachments.
Re: AutoCompleteTextField + AjaxFormComponentUpdatingBehavior onchange problem on wicket 6.0
I opened a bug report for the issue: https://issues.apache.org/jira/browse/WICKET-4705 On Thu, Aug 9, 2012 at 11:13 AM, Diego Fincatto diego.finca...@gmail.com wrote: I have an AutoCompleteTextField with one AjaxFormComponentUpdatingBehavior added and, on wicket 6.0, it stop working. It was working perfectly on wicket 1.5.7. When I select on value with keyboard, nothing happens. When I click in some option, the event is fired twice. I attached a quickstart with the problem. Changing the wicket version to 1.5.7, everything works ok. Any tips? - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
[Wicketstuff] Google Maps 3 component
Hello, maybe someone might be interested that I have uploaded a component for Google Maps 3 today which can be found at GitHub under https://github.com/wicketstuff/core/tree/master/jdk-1.6-parent/gmap3-parent/gmap3 (I'm not sure when the snapshots are build so it might be necessary to build the project from source still) A (still) very brief overview can be found in the Wiki: https://github.com/wicketstuff/core/wiki/Gmap3 And the examples are under https://github.com/wicketstuff/core/tree/master/jdk-1.6-parent/gmap3-parent/gmap3-examples So, if anyone is in the need of such a component or just want to play a bit with it, I would appreciate to hear any feedback. Joachim Rohde - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
changing number of tabs
All, Newbie here. Using Wicket 1.5.x. How can i change the number of tabs based on dropdown choice in the form? In my initial page contructor, I have just 1 tab. Then if user chooses a particular value in drop down in the form, I want 3 tabs. I tried a) form.render b) form.replace(myAjaxTabbedPanelRef) -- Both these throw error saying can't render after initial render. So my class has these member instances form, atp (which is AjaxTabbedPanel) and tabList(which is ListITab ).. Initially I populate the tabList with only one tab like this If i detect my dropdown change, i do this - tabList.clear() - tabList.add() with 3 AbstractTab in it. - atp = new AjaxTabbedPanel(tabs, tabList) - form.replace(atp) -- throws Cannot modify component hierarchy after render phase Same if i try form.remove() and form.add(atp) How do i make the page refresh with new tabs -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/changing-number-of-tabs-tp4651102.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: changing number of tabs
If i detect my dropdown change What's that in code? Sven On 08/09/2012 09:45 PM, technimadhu wrote: All, Newbie here. Using Wicket 1.5.x. How can i change the number of tabs based on dropdown choice in the form? In my initial page contructor, I have just 1 tab. Then if user chooses a particular value in drop down in the form, I want 3 tabs. I tried a) form.render b) form.replace(myAjaxTabbedPanelRef) -- Both these throw error saying can't render after initial render. So my class has these member instances form, atp (which is AjaxTabbedPanel) and tabList(which is ListITab ).. Initially I populate the tabList with only one tab like this If i detect my dropdown change, i do this - tabList.clear() - tabList.add() with 3 AbstractTab in it. - atp = new AjaxTabbedPanel(tabs, tabList) - form.replace(atp) -- throws Cannot modify component hierarchy after render phase Same if i try form.remove() and form.add(atp) How do i make the page refresh with new tabs -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/changing-number-of-tabs-tp4651102.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: changing number of tabs
My code is like below: ElemConfigAdd.html: ElemConfigAdd.java: -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/changing-number-of-tabs-tp4651102p4651105.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: changing number of tabs
loadTabs() is called by your profToCopy's #getObject(). That's a bad idea because a model's #getObject() might get called multiple times during render, and maybe even when changing the component hierarchy is no longer allowed. You should move the invokation of LoadTabs() into ElemConfigAdd#onBeforeRender(). Hope this helps Sven On 08/09/2012 10:19 PM, technimadhu wrote: My code is like below: ElemConfigAdd.html: ElemConfigAdd.java: -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/changing-number-of-tabs-tp4651102p4651105.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
enabling and disabling the components
Hi, I am newbie to Wicket,My requirement is to show some components based on the conditions. I have written on WebMarkUpContainer and in that I am add the components based on the conditions, but on html i have added that wicket:id. It is throwing MarkupException Unable to find component with id . Please advise how to handle my requirement. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/enabling-and-disabling-the-components-tp4651107.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: enabling and disabling the components
I was reading about setEnable(false), will that will be sufficient for my requirement ? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/enabling-and-disabling-the-components-tp4651107p4651108.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: enabling and disabling the components
Hi, Yes, you have to add the component anyway, and you can controls its rendering by using #setEnable based on your condition. Note that if you need to not render severals components in the same time, you can have a look at wicket:enclosure. Finally, if you need to control its/their rendering afterward, using ajax, you will weed to set setOutputMarkupId(true), or even setOutputMarkupPlaceholderTag(true) if the components starts un-rendered Hope this helps, Sebastien. On Thu, Aug 9, 2012 at 10:53 PM, wicket user samd...@live.com wrote: I was reading about setEnable(false), will that will be sufficient for my requirement ? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/enabling-and-disabling-the-components-tp4651107p4651108.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
Searching for new experience with wicket
I am intermediate java developer (~2 years of commercial JEE experience). I am searching for some open source (maybe commercial) project based on wicket where I could improve my skills. I work on: -java 6 -wicket 6 (could be earlier) -JPA 2.0 -basic knowledge of jQuery and Js -intermediate VCS Samples of me code: https://github.com/procrastinativedeveloper Please look on jcrop integration, syntax highlighter is still in production. What I want to achieve -increase my wicket and java knowledge -improve my English What I could offer: -fresh look into project :) -8h-16h of my time per week I need: -guidelines and mentor support -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Searching-for-new-experience-with-wicket-tp465.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: enabling and disabling the components
Hi, I tried this . public class MyContainer extends WebMarkupContainer{ public MyContainer(String id, MyVO myVO) { super(id); if(myVO.getName()!=null) add( new Label(fName, myVO.getName())); else add( new Label(fName, )).setVisible(false); } public MyContainer(String id){ super(id); add(new Label(message, Testing Label); } } Calling from my Class add( new MyContainer(test)); add( new MyContainer(test1, VO); In html div wicket:id=test /div div wicket:id=test1 /div But the problem is I am getting the first markup which is test and not the test1 even though the getName is not null. PLease advise -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/enabling-and-disabling-the-components-tp4651107p4651112.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: Equivalent of newSessionStore() in wicket 1.5.7
Thanks martin, I will try this