From bea33efd63daaa705947e25443769336fbe9c63e Mon Sep 17 00:00:00 2001 From: Jermolene Date: Mon, 20 Mar 2017 22:03:28 +0000 Subject: [PATCH] Fix problem with dragging text snippets --- core/modules/utils/dom/datatransfer.js | 24 ++++++------------------ 1 file changed, 6 insertions(+), 18 deletions(-) diff --git a/core/modules/utils/dom/datatransfer.js b/core/modules/utils/dom/datatransfer.js index 75ee410f2..de8dac46a 100644 --- a/core/modules/utils/dom/datatransfer.js +++ b/core/modules/utils/dom/datatransfer.js @@ -42,9 +42,7 @@ var importDataTypes = [ if(match) { return parseJSONTiddlers(match[1],fallbackTitle); } else { - return { // As URL string - text: data - }; + return [{text: data}]; // As URL string } }}, {type: "text/x-moz-url", IECompatible: false, toTiddlerFieldsArray: function(data,fallbackTitle) { @@ -53,30 +51,20 @@ var importDataTypes = [ if(match) { return parseJSONTiddlers(match[1],fallbackTitle); } else { - return { // As URL string - text: data - }; + return [{text: data}]; // As URL string } }}, {type: "text/html", IECompatible: false, toTiddlerFieldsArray: function(data,fallbackTitle) { - return { - text: data - }; + return [{text: data}]; }}, {type: "text/plain", IECompatible: false, toTiddlerFieldsArray: function(data,fallbackTitle) { - return { - text: data - }; + return [{text: data}]; }}, {type: "Text", IECompatible: true, toTiddlerFieldsArray: function(data,fallbackTitle) { - return { - text: data - }; + return [{text: data}]; }}, {type: "text/uri-list", IECompatible: false, toTiddlerFieldsArray: function(data,fallbackTitle) { - return { - text: data - }; + return [{text: data}]; }} ];