|
|
@ -84,8 +84,11 @@ export default { |
|
|
methods[method](window, 'resize', this.onFrameUpdated); |
|
|
methods[method](window, 'resize', this.onFrameUpdated); |
|
|
em[method]('component:toggled', this.onSelect, this); |
|
|
em[method]('component:toggled', this.onSelect, this); |
|
|
em[method]('change:componentHovered', this.onHovered, this); |
|
|
em[method]('change:componentHovered', this.onHovered, this); |
|
|
em[method]('component:update', this.onComponentUpdate, this); |
|
|
em[method]( |
|
|
em[method]('component:resize', this.updateGlobalPos, this); |
|
|
'component:resize component:styleUpdate', |
|
|
|
|
|
this.updateGlobalPos, |
|
|
|
|
|
this |
|
|
|
|
|
); |
|
|
em[method]('change:canvasOffset', this.updateAttached, this); |
|
|
em[method]('change:canvasOffset', this.updateAttached, this); |
|
|
em[method]('frame:updated', this.onFrameUpdated, this); |
|
|
em[method]('frame:updated', this.onFrameUpdated, this); |
|
|
em.get('Canvas') |
|
|
em.get('Canvas') |
|
|
@ -173,15 +176,6 @@ export default { |
|
|
this.updateToolsGlobal(); |
|
|
this.updateToolsGlobal(); |
|
|
// This will hide some elements from the select component
|
|
|
// This will hide some elements from the select component
|
|
|
this.updateToolsLocal(result); |
|
|
this.updateToolsLocal(result); |
|
|
|
|
|
|
|
|
// if (el) {
|
|
|
|
|
|
// this.showFixedElementOffset(el);
|
|
|
|
|
|
// this.hideElementOffset();
|
|
|
|
|
|
// this.hideHighlighter();
|
|
|
|
|
|
// this.initResize(el);
|
|
|
|
|
|
// } else {
|
|
|
|
|
|
// this.editor.stopCommand('resize');
|
|
|
|
|
|
// }
|
|
|
|
|
|
}), |
|
|
}), |
|
|
|
|
|
|
|
|
updateGlobalPos() { |
|
|
updateGlobalPos() { |
|
|
@ -735,10 +729,6 @@ export default { |
|
|
this.updateToolsGlobal(); |
|
|
this.updateToolsGlobal(); |
|
|
}), |
|
|
}), |
|
|
|
|
|
|
|
|
onComponentUpdate: debounce(function() { |
|
|
|
|
|
this.onSelect(); |
|
|
|
|
|
}), |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* Returns element's data info |
|
|
* Returns element's data info |
|
|
* @param {HTMLElement} el |
|
|
* @param {HTMLElement} el |
|
|
|