From dfc680f3a19d1b9ed434beaf330f554bcc1f66d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tautvidas=20Sipavi=C4=8Dius?= Date: Tue, 23 Feb 2016 18:39:45 +0200 Subject: [PATCH] Do not rerender header and footer blocks on content change --- assets/js/src/newsletter_editor/blocks/footer.js | 2 +- assets/js/src/newsletter_editor/blocks/header.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/js/src/newsletter_editor/blocks/footer.js b/assets/js/src/newsletter_editor/blocks/footer.js index 2885d17175..52deaa5e60 100644 --- a/assets/js/src/newsletter_editor/blocks/footer.js +++ b/assets/js/src/newsletter_editor/blocks/footer.js @@ -41,7 +41,7 @@ define([ getTemplate: function() { return templates.footerBlock; }, modelEvents: _.extend({ 'change:styles.block.backgroundColor change:styles.text.fontColor change:styles.text.fontFamily change:styles.text.fontSize change:styles.text.textAlign change:styles.link.fontColor change:styles.link.textDecoration': 'render', - }, base.BlockView.prototype.modelEvents), + }, _.omit(base.BlockView.prototype.modelEvents, 'change')), onDragSubstituteBy: function() { return Module.FooterWidgetView; }, onRender: function() { this.toolsView = new Module.FooterBlockToolsView({ model: this.model }); diff --git a/assets/js/src/newsletter_editor/blocks/header.js b/assets/js/src/newsletter_editor/blocks/header.js index 4ec82d43f6..7349a51f63 100644 --- a/assets/js/src/newsletter_editor/blocks/header.js +++ b/assets/js/src/newsletter_editor/blocks/header.js @@ -41,7 +41,7 @@ define([ getTemplate: function() { return templates.headerBlock; }, modelEvents: _.extend({ 'change:styles.block.backgroundColor change:styles.text.fontColor change:styles.text.fontFamily change:styles.text.fontSize change:styles.text.textAlign change:styles.link.fontColor change:styles.link.textDecoration': 'render', - }, base.BlockView.prototype.modelEvents), + }, _.omit(base.BlockView.prototype.modelEvents, 'change')), onDragSubstituteBy: function() { return Module.HeaderWidgetView; }, onRender: function() { this.toolsView = new Module.HeaderBlockToolsView({ model: this.model });