mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-26 16:48:49 +01:00
WIP image upload via drag into ckeditor 4.5: DO not trigger et2_file uplaod if it is an type image and let CKEditor handles it
This commit is contained in:
parent
9ede2c0b70
commit
a2b96f0c9c
@ -193,9 +193,12 @@ var et2_htmlarea = et2_inputWidget.extend([et2_IResizeable],
|
||||
editor.document.$.body.innerHTML = replaceImgText(editor.document.$.body.innerHTML);
|
||||
},200);
|
||||
}
|
||||
|
||||
|
||||
// Supported file types for dropping on CKEditor imageUpload plugin
|
||||
var supportedTypesByCKEditor = /image\/(jpeg|png|gif)/;
|
||||
|
||||
// Try to pass the image into the first et2_file that will accept it
|
||||
if(e.data.$.dataTransfer)
|
||||
if(e.data.$.dataTransfer && !CKEDITOR.fileTools.isTypeSupported(e.data.$.dataTransfer.files[0],supportedTypesByCKEditor))
|
||||
{
|
||||
self.getRoot().iterateOver(function(widget) {
|
||||
if(widget.options.drop_target)
|
||||
|
Loading…
Reference in New Issue
Block a user