-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Only in Internet Explorer 11
I have a <zk forEach> list of <toolbarbutton onClick="win.doSomething(self)" /> There is also a header above the list with toolbarbuttons.
Two things:
if the list is long and you scroll the window down, all hyperlinks give an alert with : For input string : "<some doublevalue>"; if you scroll back sometimes everything works again, but mostly it's definitely broken. A solution is to put the list in a div with it's own scrollbar. It only goes wrong if the body is scrolled. So it is necessary to remove the body scrollbars.
If the window's zoom factor is not 100% you get the same error if you click the hyperlink. It is possible to make it 100% using Ctrl-mousewheel and everything works.
I have no clue why this happens in IE11. It seems like all ZK-bindings are broken.
Is it only a 3.6 issue? Or is Microsoft trying to kill a good framework? Upgrade to version 5,6,7 or 8 is not an option for me, can i expect a bugfix for this?
I fixed this: In ZK 3.6.4 the org.zkoss.zk.au.in.MouseCommand uses Integer.parseInt() to parse mouse data[0] and data[1] ie11 return this data as doubles, so the code throws an Exception.
I changed this to Double d = Double.parseDouble(), then get d.intValue()
if loaded in /classes/ this class is used by tomcat, instead of the one in the /lib/zk*jar
package org.zkoss.zk.au.in;
import org.zkoss.lang.Objects;
import org.zkoss.zk.mesg.MZk;
import org.zkoss.zk.ui.Component;
import org.zkoss.zk.ui.UiException;
import org.zkoss.zk.ui.event.Events;
import org.zkoss.zk.ui.event.MouseEvent;
import org.zkoss.zk.au.AuRequest;
import org.zkoss.zk.au.Command;
/**
* Used only by {@link AuRequest} to implement the {@link MouseEvent}
* relevant command.
* patch to support doubles
* @author huub
* @since 3.0.0
*/
public class MouseCommand extends Command {
public MouseCommand(String evtnm, int flags) {
super(evtnm, flags);
}
//-- super --//
protected void process(AuRequest request) {
final Component comp = request.getComponent();
if (comp == null)
throw new UiException(MZk.ILLEGAL_REQUEST_COMPONENT_REQUIRED, this);
final String[] data = request.getData();
if (data != null && data.length != 1 && data.length != 2 && data.length != 3)
throw new UiException(MZk.ILLEGAL_REQUEST_WRONG_DATA,
new Object[] {Objects.toString(data), this});
MouseEvent event = null;
if(data == null || data.length == 0) {
event = new MouseEvent(getId(), comp);
} //no area, no coord
else if (data.length == 1 ) {
event = new MouseEvent(getId(), comp, data[0]); //by area
}
else {
Double d1 = Double.parseDouble(data[0]);
Double d2 = Double.parseDouble(data[1]);
event = new MouseEvent(getId(), comp, //by coord
d1.intValue() ,d2.intValue(),
data.length < 3 ? 0: Commands.parseKeys(data[2]));
}
Events.postEvent(event);
}
}
Asked: 2014-06-25 14:09:53 +0800
Seen: 9 times
Last updated: Nov 07 '14
Problem binding values to a composite component
How to access static member field of a class in zul without zscript
How can i load a constant in .zul
MVVM Validator: class not found ? [closed]
MVVM tab box - delay @load until tab pane displayed?
mvvm, load or save with after or before for seach command
how to fire an event when a variable value loaded through VM
is there any event trigger from zk component on binding ?
ZK team plans to dispose of Composer EventQueues no longer in scope? [closed]