Commit 89a78702 authored by mkhamash's avatar mkhamash Committed by olstjos

Issue #2148641 by drupal_was_my_past, mkhamash, gmclelland: WYSIWYG-inserted...

Issue #2148641 by drupal_was_my_past, mkhamash, gmclelland: WYSIWYG-inserted images lose ckeditor styles
parent 197152a8
......@@ -213,6 +213,7 @@ Drupal.media.popups.mediaStyleSelector = function (mediaFile, onSelect, options)
dialogOptions.buttons[ok] = function () {
// Find the current file selection.
var formattedMedia = this.contentWindow.Drupal.media.formatForm.getFormattedMedia();
formattedMedia.options = $.extend({}, mediaFile.attributes, formattedMedia.options);
// Alert the user if a selection has yet to be made.
if (!formattedMedia) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment