attempt to fix focus crash issue
This commit is contained in:
parent
62ef9d7bb0
commit
a03961f379
|
@ -256,6 +256,7 @@
|
||||||
this.store.setForCurrentTimeline({ ignoreBlurEvents: true })
|
this.store.setForCurrentTimeline({ ignoreBlurEvents: true })
|
||||||
},
|
},
|
||||||
saveFocus(e) {
|
saveFocus(e) {
|
||||||
|
try {
|
||||||
let instanceName = this.store.get('currentInstance')
|
let instanceName = this.store.get('currentInstance')
|
||||||
let timelineName = this.get('timeline')
|
let timelineName = this.get('timeline')
|
||||||
let lastFocusedElementSelector
|
let lastFocusedElementSelector
|
||||||
|
@ -270,8 +271,12 @@
|
||||||
this.store.setForTimeline(instanceName, timelineName, {
|
this.store.setForTimeline(instanceName, timelineName, {
|
||||||
lastFocusedElementSelector
|
lastFocusedElementSelector
|
||||||
})
|
})
|
||||||
|
} catch (err) {
|
||||||
|
console.error('unable to save focus', err)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
clearFocus() {
|
clearFocus() {
|
||||||
|
try {
|
||||||
if (this.store.get('ignoreBlurEvents')) {
|
if (this.store.get('ignoreBlurEvents')) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -281,6 +286,9 @@
|
||||||
this.store.setForTimeline(instanceName, timelineName, {
|
this.store.setForTimeline(instanceName, timelineName, {
|
||||||
lastFocusedElementSelector: null
|
lastFocusedElementSelector: null
|
||||||
})
|
})
|
||||||
|
} catch (err) {
|
||||||
|
console.error('unable to clear focus', err)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue