Skip to content
Prev Previous commit
Next Next commit
Use event target doc as getActiveElement context
  • Loading branch information
acusti committed Dec 2, 2016
commit f95ff15a265bdfdc773f688dd66b126476838503
3 changes: 2 additions & 1 deletion src/renderers/dom/shared/eventPlugins/SelectEventPlugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,10 @@ function constructSelectEvent(nativeEvent, nativeEventTarget) {
// selection (this matches native `select` event behavior). In HTML5, select
// fires only on input and textarea thus if there's no focused element we
// won't dispatch.
var doc = nativeEventTarget.ownerDocument || nativeEventTarget.document || nativeEventTarget;
if (mouseDown ||
activeElement == null ||
activeElement !== getActiveElement()) {
activeElement !== getActiveElement(doc)) {
return null;
}

Expand Down