-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=4406327
By: mattedelman
Hello,
I've been using 2.4.1 for a few days now, and it seems to have introduced some troublesome behavior around the Tabbox SelectEvent:
For my test, I have a standard Tabbox component, defined in ZUL. In my backing class, I've attached a listener to the onSelect event of the Tabbox.
The following is the event handling method:
public void handleTabSelection(Event event) {
Component ct = (Component)(((SelectEvent)event).getTarget());
Tab tb;
if (ct instanceof Tabbox) {//in zk 2.3.1 this block executes
tb = (Tab) ((Tabbox) ct).getSelectedTab();
}
else if (ct instanceof Tab) {//in zk 2.4.1 this block executes
tb = ((Tab)((SelectEvent)event).getTarget());
}
System.out.println("the ID of the selected tab is:
"+tb.getId().toString());
}
In version 2.3.1, ct would be an instance of Tabbox
In version 2.4.1, ct is an instance of Tab
Is that intentional?
Thanks,
Matt
P.S. It's not the only problem I'm seeing as a result of the 2.4.1 upgrade.
I'll post to the following thread regarding the problems it's causing with respect to my custom tabbox component set:
http://sourceforge.net/forum/forum.php?thread_id=1760584&forum_id=510209
Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=4407008
By: jebberwocky
Dear Matt
You are right. The getTarget() has been changed from tabbox to tab. The reason behind is to implement the fulfill attribute of tabpanel.
Thank you
Jeff
Asked: 2007-07-10 18:55:00 +0800
Seen: 259 times
Last updated: Mar 21 '12