Arie,

This is possible out-of-the-box using Session.setStyle();

Setting a style will make wicket consider resource files and property files
with the style you've specified.

The following is from the Component javadoc:

Style - The style ("skin") for a component is available through getStyle(),
which is equivalent to getSession().getStyle(). Styles are intended to give
a particular look to a Component or Resource that is independent of its
Locale. For example, a style might be a set of resources, including images
and markup files, which gives the design look of "ocean" to the user. If the
Session's style is set to "ocean" and these resources are given names
suffixed with "_ocean", Wicket's resource management logic will prefer these
resources to other resources, such as default resources, which are not as
good of a match. 

Bas


Arie Fishler-2 wrote:
> 
> Hello,
> 
> The normal way wicket goes over resource files is based on locale and
> different component names, application name etc.
> 
> What's the best practice for a situation in which I would like my
> application to find the resource file based on a "skin".
> This means that for the same classes set (same wicket application) and
> same
> local I still need to have different texts for a certain resource key.
> 
> It is like I need another selection mechanism for resource file which is
> not
> the locale but something that is specific to the logic of my application.
> 
> Is there some way to implement that? Like making wicket look for resource
> files the same way it does but add a prefix for every resource file
> name....
> 
> Thanks,
> Arie
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Controlling-the-order-of-resource-files-tp25002679p25002802.html
Sent from the Wicket - User 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

Reply via email to