Bug 131676

Summary: 'mousewheel'-event is not fired inside an iFrame under certain conditions
Product: WebKit Reporter: andreas.parusel
Component: UI EventsAssignee: Nobody <webkit-unassigned>
Status: NEW    
Severity: Normal    
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   

andreas.parusel
Reported 2014-04-15 04:37:45 PDT
Preconditions: A webpage living inside an iFrame contains a <script>-tag in which another script-element is programmatically created and its src-property is set to an external JavaScript-file: <script> var elem = document.createElement("script"); var head = document.getElementsByTagName("head")[0]; head.appendChild(elem); elem.src = "externalScript.js"; </script> Bug: The setting of the script-element's src-property brakes the firing of mousewheel-events inside the iFrame (see attached example, where no 'mouse wheel' logs will appear in the console.) Workaround: If you put the statement window.onmousewheel = function(){}; inside of a script-tag (not in an external JS-file!), then the webpage inside the iFrame reacts to mousewheel-events again. Please find a reduced example demonstrating this bug and the found workaround attached.
Attachments
Note You need to log in before you can comment on or make changes to this bug.