Commit 7597a09d authored by Jérome Perrin's avatar Jérome Perrin

Zelenium: don't trigger events on disabled elements

When we updated Firefox from 52 to 68, the behavior of firefox changed.
With 52, when calling element.dispatchEvent on a disabled element, the
event handlers were not executed, but in 68 they are.
parent 416584d3
......@@ -2522,6 +2522,9 @@ SafariBrowserBot.prototype.modifyWindowToRecordPopUpDialogs = function(windowToM
MozillaBrowserBot.prototype._fireEventOnElement = function(eventType, element, clientX, clientY) {
var win = this.getCurrentWindow();
if (element.disabled) {
LOG.debug("not triggering event " + eventType + " on disabled element " + element);
}
triggerEvent(element, 'focus', false);
// Add an event listener that detects if the default action has been prevented.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment