diff --git a/www/common/common-ui-elements.js b/www/common/common-ui-elements.js index 6af8db247..e8f653294 100644 --- a/www/common/common-ui-elements.js +++ b/www/common/common-ui-elements.js @@ -575,12 +575,18 @@ define([ } else if (callback) {*/ // Old import button, used in settings - button - .click(common.prepareFeedback(type)) - .click(importContent((data && data.binary) ? 'application/octet-stream' : 'text/plain', callback, { + var importer = importContent((data && data.binary) ? 'application/octet-stream' : 'text/plain', callback, { accept: data ? data.accept : undefined, binary: data ? data.binary : undefined - })); + }); + + var handler = data.first? function () { + data.first(importer); + }: importer; //importContent; + + button + .click(common.prepareFeedback(type)) + .click(handler); //} break; case 'upload': diff --git a/www/common/onlyoffice/inner.js b/www/common/onlyoffice/inner.js index f87cff136..7f8ca6297 100644 --- a/www/common/onlyoffice/inner.js +++ b/www/common/onlyoffice/inner.js @@ -51,6 +51,8 @@ define([ { var saveAs = window.saveAs; var Nacl = window.nacl; +Messages.oo_exportChrome = "Your browser cannot handle conversion to and from Microsoft Office formats. We suggest using a recent version of Firefox or Chrome."; // XXX +Messages.oo_importBin = "Click OK to import CryptPad's internal .bin format."; // XXX var APP = window.APP = { $: $, @@ -74,6 +76,7 @@ define([ }; var supportsXLSX = function () { + //if (true) { return false; } // XXX return !(typeof(Atomics) === "undefined" || typeof (SharedArrayBuffer) === "undefined"); }; @@ -1927,7 +1930,7 @@ define([ if (!supportsXLSX()) { ext = ['.bin']; - warning = '