From 992852d3c0aab94044e4a850f598bed38dbc2579 Mon Sep 17 00:00:00 2001 From: Alex Yatskov Date: Wed, 24 May 2017 20:42:54 -0700 Subject: make form search be always enabled --- ext/fg/js/driver.js | 2 +- ext/fg/js/util.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'ext/fg') diff --git a/ext/fg/js/driver.js b/ext/fg/js/driver.js index e11b5014..bdcc01b3 100644 --- a/ext/fg/js/driver.js +++ b/ext/fg/js/driver.js @@ -142,7 +142,7 @@ window.driver = new class { return; } - const textSource = docRangeFromPoint(point, this.options.scanning.imposter); + const textSource = docRangeFromPoint(point); if (!textSource || !textSource.containsPoint(point)) { docImposterDestroy(); return; diff --git a/ext/fg/js/util.js b/ext/fg/js/util.js index 88d160cc..a9e67976 100644 --- a/ext/fg/js/util.js +++ b/ext/fg/js/util.js @@ -112,12 +112,12 @@ function docImposterDestroy() { } } -function docRangeFromPoint(point, imposter) { +function docRangeFromPoint(point) { const element = document.elementFromPoint(point.x, point.y); if (element !== null) { if (element.nodeName === 'IMG' || element.nodeName === 'BUTTON') { return new TextSourceElement(element); - } else if (imposter && (element.nodeName === 'INPUT' || element.nodeName === 'TEXTAREA')) { + } else if (element.nodeName === 'INPUT' || element.nodeName === 'TEXTAREA') { docImposterCreate(element); } } -- cgit v1.2.3