From e48e597308df75896684583cf04e28e0ebe017cd Mon Sep 17 00:00:00 2001 From: Artur Arseniev Date: Tue, 29 Jan 2019 00:05:56 +0100 Subject: [PATCH] Add multiFrames option (WIP) --- src/canvas/view/CanvasView.js | 2 +- src/editor/config/config.js | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/canvas/view/CanvasView.js b/src/canvas/view/CanvasView.js index d2bfc47c0..688112b71 100644 --- a/src/canvas/view/CanvasView.js +++ b/src/canvas/view/CanvasView.js @@ -64,7 +64,7 @@ module.exports = Backbone.View.extend({ }, onWheel(ev) { - if (ev.ctrlKey || ev.metaKey) { + if ((ev.ctrlKey || ev.metaKey) && this.em.getConfig('multiFrames')) { this.preventDefault(ev); const { model } = this; const delta = Math.max(-1, Math.min(1, ev.wheelDelta || -ev.detail)); diff --git a/src/editor/config/config.js b/src/editor/config/config.js index c49da707f..0f741972d 100644 --- a/src/editor/config/config.js +++ b/src/editor/config/config.js @@ -306,5 +306,8 @@ module.exports = { textViewCode: 'Code', // Keep unused styles within the editor - keepUnusedStyles: 0 + keepUnusedStyles: 0, + + // TODO + multiFrames: 0 };