-
FEATURED COMPONENTS
First time here? Check out the FAQ!
As so far as I know(or, maybe I just forgot)..variable resolver must be declared in zul's directive,
and listener is defined in zk.xml.
Is is possible to have some resolvers and listeners that defined in a jar file's metainfo,
then I only need to do is putting this jar into /lib, and zk will load it automatically (no need to write resolver on each page and zk.xml).
thanks~~cute guys.
/Dennis
I can't find any layer to let you do this in Jar loading, you can post a Feature Request.(Tom said it would be easy~)
Maybe the simplest way is to extends UiFactory, override getPage() and insert your variable-resolver into new page.
But you still need to declare your new UiFactory in zk.xml.
metainfo/zk/config.xml doesn't accept ui-factory-class and many other setting. However, it accepts listener, thus you can specify
<listener> <listener-class>org.zkoss.zkmax.init.WebAppInit</listener-class> </listener> Then, in the WebAppInit implementation: public void init(WebApp wapp) throws Exception { wapp.getConfiguration().setUiFactoryClass(FooUiFactory.class); }
Asked: 2009-10-31 12:45:41 +0800
Seen: 388 times
Last updated: Nov 04 '09