summaryrefslogtreecommitdiff
path: root/addons/website/static/src/js/website.editor.js
diff options
context:
space:
mode:
authorChristophe Matthieu <chm@openerp.com>2013-09-10 12:03:48 +0200
committerChristophe Matthieu <chm@openerp.com>2013-09-10 12:03:48 +0200
commit4bed245c082129f2086f4544e18a7fc4e33c9d45 (patch)
treeec7901da28006d85b292bb13a108770138e24a23 /addons/website/static/src/js/website.editor.js
parentbf09524def70b72059d5b7bfc1247a52a70ca9e1 (diff)
parent5a16088b0b0477e619b97f203f7af4ec21543418 (diff)
[MERGE] from website-fva: snippets editor and building block
bzr revid: chm@openerp.com-20130910100348-w9kxnxc9tavyanqt
Diffstat (limited to 'addons/website/static/src/js/website.editor.js')
-rw-r--r--addons/website/static/src/js/website.editor.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/addons/website/static/src/js/website.editor.js b/addons/website/static/src/js/website.editor.js
index a98376ae30f..8056998eef9 100644
--- a/addons/website/static/src/js/website.editor.js
+++ b/addons/website/static/src/js/website.editor.js
@@ -275,6 +275,11 @@
// editor.ui.items -> possible commands &al
// editor.applyStyle(new CKEDITOR.style({element: "span",styles: {color: "#(color)"},overrides: [{element: "font",attributes: {color: null}}]}, {color: '#ff0000'}));
+ init: function (EditorBar) {
+ this.EditorBar = EditorBar;
+ this._super.apply(this, arguments);
+ },
+
start_edition: function ($elements) {
var self = this;
$elements
@@ -284,6 +289,7 @@
var $node = $(node);
var editor = CKEDITOR.inline(this, self._config());
editor.on('instanceReady', function () {
+ self.trigger('instanceReady');
observer.observe(node, OBSERVER_CONFIG);
});
$node.one('content_changed', function () {
@@ -511,7 +517,7 @@
this.$('input.pages').val($target.text()).change();
// No #dropdown('close'), and using #dropdown('toggle') sur
// #closest('.dropdown') makes the dropdown not work correctly
- $target.closest('.open').removeClass('open')
+ $target.closest('.open').removeClass('open');
},
/**
* CKEDITOR.plugins.link.getSelectedLink ignores the editor's root,