- actions: [
- createSwitchAction({name: 'switchToHeader', from: {tagName: 'div', klass: 'p'}, to: {tagName: 'header', klass: '', name: gettext('header')}}),
- createSwitchAction({name: 'switchToParagraph', from: {tagName: 'header'}, to: {tagName: 'div', klass: 'p', name: gettext('paragraf')}})
- ]
+ actions: [headerAction, paragraphAction],
+ canvasActionHandler: {
+ handles: [headerAction, paragraphAction],
+ // handle: function(canvas, action, ret) {
+ // var params = {},
+ // f;
+ // if(ret && ret.node2) {
+ // f = ret.oldFragment;
+ // if(f && f instanceof f.CaretFragment) {
+ // params.caretTo = f.offset;
+ // }
+ // canvas.setCurrentElement(ret.node2, params);
+ // }
+ // }
+ }