Fix fake-image for audio in CKEditor plugin - refs BT#12748

pull/2487/head
Angel Fernando Quiroz Campos 8 years ago
parent 1ef930f380
commit e38ba5b7cb
  1. 11
      main/inc/lib/javascript/ckeditor/plugins/audio/plugin.js

@ -33,7 +33,7 @@
'background-color:gray;' +
'border: 1px solid #a9a9a9;' +
'width: 80px;' +
'height: 80px;' +
'height: 40px;' +
'}';
},
onLoad: function() {
@ -121,15 +121,10 @@
var fakeElement = editor.createFakeParserElement(realElement, 'cke_audio', 'audio', false),
fakeStyle = fakeElement.attributes.style || '';
var width = realElement.attributes.width,
height = realElement.attributes.height;
var width = realElement.attributes.width;
if (typeof width != 'undefined') {
fakeStyle = fakeElement.attributes.style = fakeStyle + 'width:' + CKEDITOR.tools.cssLength(width) + ';';
}
if (typeof height != 'undefined') {
fakeStyle = fakeElement.attributes.style = fakeStyle + 'height:' + CKEDITOR.tools.cssLength(height) + ';';
fakeElement.attributes.style = fakeStyle + 'width:' + CKEDITOR.tools.cssLength(width) + ';';
}
return fakeElement;

Loading…
Cancel
Save