-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hi all,
is it possible to open/close the south-Area when i click the entire South-Panel same as i click the arrow-button? I use zk-8.
Regards Andi
Hello Andi!
I'd do like this:
<zk>
<window id="win" title="Hello World!!" border="normal" hflex="1" vflex="1" apply="test.SouthTestComposer">
<borderlayout>
<north>Hello North</north>
<center>Hello Center</center>
<south id="mySouth" title="test" collapsible="true" height="200px">
<div>Hello South <button>test</button></div>
</south>
</borderlayout>
</window>
</zk>
and the controller:
public class SouthTestComposer extends SelectorComposer<Window> {
@Wire
private South mySouth;
@Listen("onClick = #mySouth") // this will work for everything apart from the button or any other component which stops the propagation
@Listen("onClick = #mySouth *") // this will work for everything inside the south but not the header bar
public void onSouthClick(Event event) {
if (mySouth.isOpen()) {
mySouth.setOpen(false);
mySouth.invalidate();
}
}
}
Hope it helps Gio
Asked: 2016-03-02 09:11:39 +0800
Seen: 18 times
Last updated: Mar 08 '16
How to control selectAll() feature in a Listbox with multiple=true and checkmark=true
ZK8 Wizard Series: Part 2 now released!
Faster And Lighter, The Performance Test On ZK8
org.zkoss.xel.XelException: Resource not found: http://www.zkoss.org/dsp/web/core
How To Check Dirty Status in ZK8?
Come and join the ''JS'' Hunt!