Even more painful, I just discovered, is that I need to create a
StaticResourceReference for every single URL referenced inside the CSS
file (!!). It would be great if Wicket could automatically scan the CSS
file for "url()" tags and automatically mount those URLs.
Gili
Gili wrote:
Yes, this works. Why is bind() not necessary? If I don't call bind()
who does?
So now my code is down to:
WebMarkupContainer pageCSS = new WebMarkupContainer("pageCSS");
add(pageCSS);
StaticResourceReference pageResource = new
StaticResourceReference(getClass(), "page.css");
pageCSS.add(new AttributeModifier("href", false, new
Model(urlFor(pageResource.getPath()))));
per CSS file. While this works I am disappointed it takes so much
code to do this. My old code making use of Panels was about 1/4 the
amount of code. I wish there was a way for us to refactor this somehow
so it's a bit cleaner. Any ideas?
Gili
Johan Compagner wrote:
is this not possible:
StaticResourceReference pageResource = new
StaticResourceReference(getClass(), "page.css");
pageCSS.add(new AttributeModifier("href", false, new
Model(page.urlFor(pageResource.getPath()))));
that bind call that you do is not needed.
johan
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle
Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing
& QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Wicket-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-develop
--
http://www.desktopbeautifier.com/
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Wicket-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-develop