editor: change capture flag name and remove tab hack (handling editor's select in capture phase makes it useless)
This commit is contained in:
parent
709d0a7f25
commit
1a02c80496
4 changed files with 5 additions and 10 deletions
|
|
@ -132,7 +132,8 @@ var handleClick = function(event) {
|
|||
if (!widget.container.classList.contains('editing')) {
|
||||
// add a flag to the original event to prevent draginit
|
||||
// and prevent any further fast-click (ie input focus)
|
||||
eventData.preventInterraction = true
|
||||
eventData.capturedByEditor = true
|
||||
event.capturedByEditor = true
|
||||
}
|
||||
|
||||
editor.select(widget)
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ var targets = {},
|
|||
|
||||
function pointerDownHandler(event) {
|
||||
|
||||
if (event.preventInterraction === true) return
|
||||
if (event.capturedByEditor === true) return
|
||||
|
||||
if (!event.multitouch) {
|
||||
for (var i in targets) {
|
||||
|
|
|
|||
|
|
@ -90,6 +90,7 @@ module.exports = class Modal extends Panel {
|
|||
})
|
||||
} else {
|
||||
this.light.addEventListener('fast-click',(e)=>{
|
||||
if (e.capturedByEditor === true) return
|
||||
this.setValue(1, {sync:true, send:true})
|
||||
})
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,11 +1,5 @@
|
|||
var Panel = require('./panel'),
|
||||
resize = require('../../events/resize'),
|
||||
editor
|
||||
|
||||
setTimeout(()=>{
|
||||
editor = require('../../editor/')
|
||||
})
|
||||
|
||||
resize = require('../../events/resize')
|
||||
|
||||
module.exports = class Tab extends Panel {
|
||||
|
||||
|
|
@ -60,7 +54,6 @@ module.exports = class Tab extends Panel {
|
|||
|
||||
hide() {
|
||||
if (this.detached) return
|
||||
if (EDITING) editor.unselect()
|
||||
this.container.removeChild(this.widget)
|
||||
this.container.classList.remove('show')
|
||||
this.detached = true
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue