Fix location of _enabled assignment (#818)
This commit is contained in:
parent
9f1753a565
commit
fcb8806717
@ -85,6 +85,8 @@ class TextScanner extends EventDispatcher {
|
|||||||
}
|
}
|
||||||
|
|
||||||
setEnabled(enabled) {
|
setEnabled(enabled) {
|
||||||
|
this._enabled = enabled;
|
||||||
|
|
||||||
const value = enabled && this._isPrepared;
|
const value = enabled && this._isPrepared;
|
||||||
if (this._enabledValue === value) { return; }
|
if (this._enabledValue === value) { return; }
|
||||||
|
|
||||||
@ -95,7 +97,6 @@ class TextScanner extends EventDispatcher {
|
|||||||
this._preventNextClick = false;
|
this._preventNextClick = false;
|
||||||
this._preventScroll = false;
|
this._preventScroll = false;
|
||||||
|
|
||||||
this._enabled = enabled;
|
|
||||||
this._enabledValue = value;
|
this._enabledValue = value;
|
||||||
|
|
||||||
if (value) {
|
if (value) {
|
||||||
|
Loading…
Reference in New Issue
Block a user