Special-case "." selector in uiEvents.

This commit is contained in:
Tony Garnock-Jones 2016-06-05 15:53:28 -04:00
parent 56324db6f6
commit dd28b667e8
1 changed files with 5 additions and 1 deletions

View File

@ -609,7 +609,11 @@ function cleanEventType(eventType) {
function selectorMatch(n, selector) {
if (n && typeof n === 'object' && 'querySelectorAll' in n) {
return Array.prototype.slice.call(n.querySelectorAll(selector));
if (selector === '.') {
return [n];
} else {
return Array.prototype.slice.call(n.querySelectorAll(selector));
}
} else {
return [];
}