Re: Bookmarkable images from db

2009-12-08 Thread Peter Dotchev
xaloon.googlecode.com/svn/trunk/xaloon-wicket-repository/src/main/java/org/xaloon/wicket/component/resource/ImageLink.java >> >> I prefer to do it this way: >> http://pastebin.com/m328e21ff >> >> The first example allow you to use directly an Image component, while the >

Re: ExternalLink takes IModel for label

2009-11-23 Thread Peter Dotchev
https://issues.apache.org/jira/browse/WICKET-2588 igor.vaynberg wrote: > > yep, so we cant fix it in 1.4.x, but add an rfe for 1.5 > > -igor > > On Sun, Nov 22, 2009 at 2:24 PM, Peter Dotchev wrote: >> Hi Wicketeers, >> >> I just noticed that this constr

ExternalLink takes IModel for label

2009-11-22 Thread Peter Dotchev
Hi Wicketeers, I just noticed that this constructor public ExternalLink(final String id, final IModel href, final *IModel* label) takes IModel for label. This is somewhat limiting since the model could hold a number or a date for example. Actually passing a raw IModel with any object insi

Re: Why don't all Link classes support a label like ExternalLink does?

2009-11-22 Thread Peter Dotchev
Hi, I also find myself often in the situation to create two components Link + Label for a link. So, I would appreciate if Link's used their model for the element content. Best regards, Peter Martijn Dashorst wrote: > > Not everybody puts a label inside a link. Not as common as you might > thi

Re: WicketFilter.getLastModified creates a RequestCycle but does not clean it up

2009-11-09 Thread Peter Dotchev
created jira item https://issues.apache.org/jira/browse/WICKET-2566 Regards, Peter igor.vaynberg wrote: > > peter, please open a jira issue. looks like a bug to me. > > -igor > > On Sat, Nov 7, 2009 at 1:52 PM, Peter Dotchev wrote: >> Hi Wicketee

WicketFilter.getLastModified creates a RequestCycle but does not clean it up

2009-11-07 Thread Peter Dotchev
Hi Wicketeers, I noticed that WicketFilter.getLastModified creates a RequestCycle but does not /detach /it, so onEndRequest is not called. I use JCR and open a session to it on first use (lazy init). I store the JCR session in th RequestCycle. I close the JCR session in RequestCycle.onEndReque

Re: Bookmarkable images from db

2009-11-02 Thread Peter Dotchev
there is also a wicket way of do it: > > - Use shared resource, which is stateless and bookmarkable > > If you need more informations about this approach, search on forum or just > ask... and I'll provide you with some examples of how I do it.. > > Alex Objelean >

Bookmarkable images from db

2009-11-01 Thread Peter Dotchev
Hi, My app allows users to upload images and I store them in JCR . I can get InputStream for each one of them. I want to display images in specific pages and I want image URLs to be stable/bookmarkable. Also I don't want these pages

Data validation and form components

2009-04-28 Thread Peter Dotchev
Hi, Setter methods of my business logic classes perform validation and throw exceptions if given parameter is invalid. I don't have separate methods for data validation. In my wicket form I use CompoundPropertyModel which sets user entered values directly in the business object. If the user en

Why is LoadableDetachableModel read-only?

2007-11-02 Thread Peter Dotchev
Hi, setObject() is not supported on LoadableDetachableModel because it extends AbstractReadOnlyModel. What is the reason for this? This way LoadableDetachableModel cannot be used with form controls. In my case I have a DropDownChoice with a list of non-serializable objects. What kind of model

substitute same value in several places

2007-09-27 Thread Peter Dotchev
Hi, I'd like to use the same value in several places of a page, e.g. two labels with same content. Let's say I want to substitute the same property using CompoundPropertyModel. How can I do that in Wicket 1.3? Thanks for your help. Peter -- View this message in context: http://www.nabble.co

Custom page <-> class mapping

2007-08-31 Thread Peter Dotchev
Hello, I'd like to use custom convention for page class names. Something like Home.html <-> HomePage.class How can I do this in wicket 1.3? I don't want to mount each page separately. I guess I should implement IRequestTargetUrlCodingStrategy but would not like to do it from scratch. Any hints?