diff --git a/CHANGELOG.md b/CHANGELOG.md index 3f3b4274c..dfa69006a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,33 @@ +# Smilodon's revenge (3.18.1) + +Our next major release (3.19.0) is still a few weeks away. +In the meantime we've been working on some minor improvements and bug fixes that we wanted to ship as soon as possible. + +New features: + +* Rich text pads can now be exported to .doc format. A few features don't translate well to the exported format (some fonts, embedded videos and pdfs), but for the most part your documents should work +* Items in the "Recent pads" section of your drive can now be dragged to other folders via the filesystem tree UI +* The user admin menu (found in the top-right corner) now includes an option to display the current version of the CryptPad instance you're using. We plan to add some more information here in the near future. +* The kanban app now offers better support for editing markdown within cards with autocompleted parentheses. We've also added support for embedded media, allowing users to drag images and other content into the card content editor. + +Bug fixes: + +* Account deletion via the settings page works once again +* Some small layout and usability issues in the drive have been addressed + * dropdown menus flow in the appropriate direction when space is limited + * changing the sorting criteria no longer causes the browser to jump to the top of the page +* Hitting enter or escape in the kanban's card tag field while it's empty now closes the modal (instead of doing nothing) +* Language preferences (as configured via the settings page) are applied when you log in (previously it would reset to English or your browser's settings) +* A performance issue triggered by hiding a closed support ticket from the admin panel has been optimized. Previously it would lock up the shared worker in cases when there were many unclosed tickets. +* We've updated the parameters of the XLSX import/export functionality to prevent an "out of memory" error that primarily affected large spreadsheets. It should now allocate more memory instead of failing silently. +* Finally, members of a team can now directly share or transfer ownership of a document owned by their team to their own account without having to go through the additional steps of offering it to themself and accepting the offer. + +Updating from 3.18.0 to 3.18.1 is pretty standard: + +1. Stop your server +2. Get the latest code with git +3. Restart your server + # Smilodon release (3.18.0) ## Goals diff --git a/customize.dist/login.js b/customize.dist/login.js index 0e46981ea..35121f113 100644 --- a/customize.dist/login.js +++ b/customize.dist/login.js @@ -341,6 +341,11 @@ define([ if (shouldImport) { setMergeAnonDrive(); } + var l = Util.find(rt.proxy, ['settings', 'general', 'language']); + var LS_LANG = "CRYPTPAD_LANG"; + if (l) { + localStorage.setItem(LS_LANG, l); + } return void LocalStore.login(userHash, uname, function () { cb(void 0, res); }); diff --git a/customize.dist/pages.js b/customize.dist/pages.js index 1ba7991f3..6bc19e10a 100644 --- a/customize.dist/pages.js +++ b/customize.dist/pages.js @@ -61,6 +61,9 @@ define([ var imprintUrl = AppConfig.imprint && (typeof(AppConfig.imprint) === "boolean" ? '/imprint.html' : AppConfig.imprint); + + Pages.versionString = "CryptPad v3.18.1 (Smilodon's revenge)"; + Pages.infopageFooter = function () { return h('footer', [ h('div.container', [ @@ -107,7 +110,7 @@ define([ ])*/ ]) ]), - h('div.cp-version-footer', "CryptPad v3.18.0 (Smilodon)") + h('div.cp-version-footer', Pages.versionString) ]); }; diff --git a/customize.dist/src/less2/include/drive.less b/customize.dist/src/less2/include/drive.less index 7c428a3de..0eb400587 100644 --- a/customize.dist/src/less2/include/drive.less +++ b/customize.dist/src/less2/include/drive.less @@ -716,6 +716,9 @@ } } } + .cp-app-drive-element-state { + display: none !important; + } } } .cp-app-drive-element { @@ -729,6 +732,9 @@ .cp-app-drive-element-type, .cp-app-drive-element-filler { display: none !important; } + .cp-app-drive-element-sort { + display: block !important; + } } @media screen and (max-width: 740px) { @@ -744,9 +750,6 @@ .cp-app-drive-element-header .cp-app-drive-element-state { display: none !important; } - .cp-app-drive-element-sort { - display: block !important; - } } } @@ -902,126 +905,6 @@ } } - /* Toolbar */ - - // XXX remove, preserve drive path? - #cp-app-drive-toolbar { - background: @colortheme_drive-bg-light; - color: @colortheme_drive-color; - //height: 30px; - //display: flex; - //flex-flow: row; - z-index: 100; - box-sizing: border-box; - height: @variables_bar-height; - padding: 0; - display: flex; - flex-flow: row; - - * { - outline-width: 0; - &:focus { - outline-width: 0; - } - } - - .cp-toolbar-icon-history { - float: right; - &.active { - background-color: rgba(0, 0, 255, 0.2); - } - .cp-toolbar-drawer-element { - display: none; - } - } - - .cp-app-drive-toolbar-rightside, .cp-app-drive-toolbar-leftside { - display: inline-block; - margin: 0; - padding: 0; - .fa, .cptools { - margin: 0; - vertical-align: top; - } - button { - height: @variables_bar-height !important; - padding: 0 10px; - border: none; - border-radius: 0; - box-sizing: border-box; - background: transparent; - font-size: @colortheme_app-font-size; - color: @colortheme_drive-color; - transition: all 0.15s; - display: inline-flex; - align-items: center; - .drawer { - display: none; - } - .fa, .cptools, span { - font-size: @colortheme_app-font-size; - } - &:hover { - background: @colortheme_drive-bg-active; - } - &.cp-app-drive-toolbar-active { - display: none; - } - } - } - .cp-app-drive-toolbar-rightside { - float: right; - flex-shrink: 0; - & > * { - float: right; - } - #cp-app-drive-toolbar-contextbuttons { - display: inline-block; - height: 100%; - } - padding-left: 10px; - } - .cp-app-drive-toolbar-leftside { - flex-shrink: 0; - & > span { - height: 100%; - margin: 0; - } - button { - padding: 0 10px; - .fa, .cptools { - margin-right: 5px; - } - .cp-dropdown-button-title { - display: inline-flex; - height: @variables_bar-height; - align-items: center; - span:not(.fa):not(.cptools) { - line-height: 23px; - } - } - } - } - - button { - font: @colortheme_app-font; - span { - font: @colortheme_app-font; - } - .fa, &.fa { - font-family: FontAwesome; - } - .cptools, &.cptools { - font-family: cptools; - } - } - - - .cp-app-drive-toolbar-filler { - flex: 1; - } - } - #cp-app-drive-edition-state { height: @variables_bar-height; display: flex; diff --git a/customize.dist/src/less2/include/toolbar.less b/customize.dist/src/less2/include/toolbar.less index 0c26c0e3b..985f6bd83 100644 --- a/customize.dist/src/less2/include/toolbar.less +++ b/customize.dist/src/less2/include/toolbar.less @@ -949,10 +949,6 @@ } } - .cp-dropdown-content { - margin-top: -1px; - } - & > span { height: @toolbar_line-height; } diff --git a/package-lock.json b/package-lock.json index c6c2c1219..9840bd099 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "cryptpad", - "version": "3.18.0", + "version": "3.18.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index a08f0ea29..56e512b22 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "cryptpad", "description": "realtime collaborative visual editor with zero knowlege server", - "version": "3.18.0", + "version": "3.18.1", "license": "AGPL-3.0+", "repository": { "type": "git", diff --git a/www/admin/inner.js b/www/admin/inner.js index 9fab8020a..2ff62cf1f 100644 --- a/www/admin/inner.js +++ b/www/admin/inner.js @@ -255,17 +255,27 @@ define([ if (msg.type !== 'TICKET') { return; } if (!$ticket.length) { - $ticket = APP.support.makeTicket($div, content, function () { + $ticket = APP.support.makeTicket($div, content, function (hideButton) { + // the ticket will still be displayed until the worker confirms its deletion + // so make it unclickable in the meantime + hideButton.setAttribute('disabled', true); var error = false; - hashesById[id].forEach(function (d) { - common.mailbox.dismiss(d, function (err) { - if (err) { - error = true; - console.error(err); - } + nThen(function (w) { + hashesById[id].forEach(function (d) { + common.mailbox.dismiss(d, w(function (err) { + if (err) { + error = true; + console.error(err); + } + })); }); + }).nThen(function () { + if (!error) { return void $ticket.remove(); } + // if deletion failed then reactivate the button and warn + hideButton.removeAttribute('disabled'); + // and show a generic error message + UI.alert(Messages.error); }); - if (!error) { $ticket.remove(); } }); } $ticket.append(APP.support.makeMessage(content, hash)); diff --git a/www/code/markers.js b/www/code/markers.js index fb67736a6..b070e68fc 100644 --- a/www/code/markers.js +++ b/www/code/markers.js @@ -622,30 +622,9 @@ define([ }); }; - var authorUid = function (existing) { - if (!Array.isArray(existing)) { existing = []; } - var n; - var i = 0; - while (!n || existing.indexOf(n) !== -1 && i++ < 1000) { - n = Math.floor(Math.random() * 1000000); - } - // If we can't find a valid number in 1000 iterations, use 0... - if (existing.indexOf(n) !== -1) { n = 0; } - return n; - }; var getAuthorId = function (Env) { - var existing = Object.keys(Env.authormarks.authors || {}).map(Number); - if (!Env.common.isLoggedIn()) { return authorUid(existing); } - var userData = Env.common.getMetadataMgr().getUserData(); - var uid; - existing.some(function (id) { - var author = Env.authormarks.authors[id] || {}; - if (author.curvePublic !== userData.curvePublic) { return; } - uid = Number(id); - return true; - }); - return uid || authorUid(existing); + return Env.common.getAuthorId(Env.authormarks.authors, userData.curvePublic); }; var ready = function (Env) { Env.ready = true; diff --git a/www/common/common-thumbnail.js b/www/common/common-thumbnail.js index 3f359d425..8c78d9d6d 100644 --- a/www/common/common-thumbnail.js +++ b/www/common/common-thumbnail.js @@ -200,7 +200,6 @@ define([ // The blob is already in memory, it should be super-fast to make a thumbnail // ==> 1s timeout setTimeout(function () { - console.error("Thumbnail timeout"); cb('TIMEOUT'); }, 1000); try { diff --git a/www/common/common-ui-elements.js b/www/common/common-ui-elements.js index 5d9f38077..0caa39c92 100644 --- a/www/common/common-ui-elements.js +++ b/www/common/common-ui-elements.js @@ -2116,7 +2116,11 @@ define([ config.options.forEach(function (o) { if (!isValidOption(o)) { return; } if (isElement(o)) { return $innerblock.append($(o)); } - $('<' + o.tag + '>', o.attributes || {}).html(o.content || '').appendTo($innerblock); + var $el = $('<' + o.tag + '>', o.attributes || {}).html(o.content || ''); + $el.appendTo($innerblock); + if (typeof(o.action) === 'function') { + $el.click(o.action); + } }); $container.append($button).append($innerblock); @@ -2141,8 +2145,17 @@ define([ var show = function () { var wh = $(window).height(); - var topPos = $container[0].getBoundingClientRect().bottom; - $innerblock.css('max-height', Math.floor(wh - topPos - 1)+'px'); + var button = $button[0].getBoundingClientRect(); + var topPos = button.bottom; + $innerblock.css('bottom', ''); + if (config.noscroll) { + var h = $innerblock.outerHeight(); + if ((topPos + h) > wh) { + $innerblock.css('bottom', button.height+'px'); + } + } else { + $innerblock.css('max-height', Math.floor(wh - topPos - 1)+'px'); + } $innerblock.show(); $innerblock.find('.cp-dropdown-element-active').removeClass('cp-dropdown-element-active'); if (config.isSelect && value) { @@ -2157,6 +2170,11 @@ define([ e.stopPropagation(); var state = $innerblock.is(':visible'); $('.cp-dropdown-content').hide(); + + var $c = $container.closest('.cp-toolbar-drawer-content'); + $c.removeClass('cp-dropdown-visible'); + if (!state) { $c.addClass('cp-dropdown-visible'); } + try { $('iframe').each(function (idx, ifrw) { $(ifrw).contents().find('.cp-dropdown-content').hide(); @@ -2324,14 +2342,28 @@ define([ options.push({ tag: 'a', attributes: {'class': 'cp-toolbar-menu-profile fa fa-user-circle'}, - content: h('span', Messages.profileButton) + content: h('span', Messages.profileButton), + action: function () { + if (padType) { + window.open(origin+'/profile/'); + } else { + window.parent.location = origin+'/profile/'; + } + }, }); } if (padType !== 'settings') { options.push({ tag: 'a', attributes: {'class': 'cp-toolbar-menu-settings fa fa-cog'}, - content: h('span', Messages.settingsButton) + content: h('span', Messages.settingsButton), + action: function () { + if (padType) { + window.open(origin+'/settings/'); + } else { + window.parent.location = origin+'/settings/'; + } + }, }); } options.push({ tag: 'hr' }); @@ -2340,14 +2372,28 @@ define([ options.push({ tag: 'a', attributes: {'class': 'cp-toolbar-menu-admin fa fa-cogs'}, - content: h('span', Messages.adminPage || 'Admin') + content: h('span', Messages.adminPage || 'Admin'), + action: function () { + if (padType) { + window.open(origin+'/admin/'); + } else { + window.parent.location = origin+'/admin/'; + } + }, }); } if (padType !== 'support' && accountName && Config.supportMailbox) { options.push({ tag: 'a', attributes: {'class': 'cp-toolbar-menu-support fa fa-life-ring'}, - content: h('span', Messages.supportPage || 'Support') + content: h('span', Messages.supportPage || 'Support'), + action: function () { + if (padType) { + window.open(origin+'/support/'); + } else { + window.parent.location = origin+'/support/'; + } + }, }); } options.push({ tag: 'hr' }); @@ -2383,9 +2429,27 @@ define([ 'href': AppConfig.surveyURL, 'class': 'cp-toolbar-survey fa fa-graduation-cap' }, - content: h('span', Messages.survey) + content: h('span', Messages.survey), + action: function () { + Feedback.send('SURVEY_CLICKED'); + }, + }); + } + if (Pages.versionString) { + Messages.user_about = Messages.about; // XXX "About CryptPad" + options.push({ + tag: 'a', + attributes: { + 'class': 'cp-toolbar-about fa fa-info', + }, + content: h('span', Messages.user_about), + action: function () { + // XXX UIElements.createHelpButton + UI.alert(Pages.versionString); + }, }); } + options.push({ tag: 'hr' }); // Add login or logout button depending on the current status if (priv.loggedIn) { @@ -2394,23 +2458,43 @@ define([ attributes: { 'class': 'cp-toolbar-menu-logout-everywhere fa fa-plug', }, - content: h('span', Messages.logoutEverywhere) + content: h('span', Messages.logoutEverywhere), + action: function () { + Common.getSframeChannel().query('Q_LOGOUT_EVERYWHERE', null, function () { + window.parent.location = origin + '/'; + }); + }, }); options.push({ tag: 'a', attributes: {'class': 'cp-toolbar-menu-logout fa fa-sign-out'}, - content: h('span', Messages.logoutButton) + content: h('span', Messages.logoutButton), + action: function () { + Common.logout(function () { + window.parent.location = origin+'/'; + }); + }, }); } else { options.push({ tag: 'a', attributes: {'class': 'cp-toolbar-menu-login fa fa-sign-in'}, - content: h('span', Messages.login_login) + content: h('span', Messages.login_login), + action: function () { + Common.setLoginRedirect(function () { + window.parent.location = origin+'/login/'; + }); + }, }); options.push({ tag: 'a', attributes: {'class': 'cp-toolbar-menu-register fa fa-user-plus'}, - content: h('span', Messages.login_register) + content: h('span', Messages.login_register), + action: function () { + Common.setLoginRedirect(function () { + window.parent.location = origin+'/register/'; + }); + }, }); } var $icon = $('', {'class': 'fa fa-user-secret'}); @@ -2477,59 +2561,6 @@ define([ metadataMgr.onChange(updateButton); updateButton(); - $userAdmin.find('a.cp-toolbar-menu-logout').click(function () { - Common.logout(function () { - window.parent.location = origin+'/'; - }); - }); - - $userAdmin.find('a.cp-toolbar-menu-logout-everywhere').click(function () { - Common.getSframeChannel().query('Q_LOGOUT_EVERYWHERE', null, function () { - window.parent.location = origin + '/'; - }); - }); - $userAdmin.find('a.cp-toolbar-menu-settings').click(function () { - if (padType) { - window.open(origin+'/settings/'); - } else { - window.parent.location = origin+'/settings/'; - } - }); - $userAdmin.find('a.cp-toolbar-menu-support').click(function () { - if (padType) { - window.open(origin+'/support/'); - } else { - window.parent.location = origin+'/support/'; - } - }); - $userAdmin.find('a.cp-toolbar-menu-admin').click(function () { - if (padType) { - window.open(origin+'/admin/'); - } else { - window.parent.location = origin+'/admin/'; - } - }); - $userAdmin.find('a.cp-toolbar-survey').click(function () { - Feedback.send('SURVEY_CLICKED'); - }); - $userAdmin.find('a.cp-toolbar-menu-profile').click(function () { - if (padType) { - window.open(origin+'/profile/'); - } else { - window.parent.location = origin+'/profile/'; - } - }); - $userAdmin.find('a.cp-toolbar-menu-login').click(function () { - Common.setLoginRedirect(function () { - window.parent.location = origin+'/login/'; - }); - }); - $userAdmin.find('a.cp-toolbar-menu-register').click(function () { - Common.setLoginRedirect(function () { - window.parent.location = origin+'/register/'; - }); - }); - return $userAdmin; }; diff --git a/www/common/cryptpad-common.js b/www/common/cryptpad-common.js index 1204e3e27..19faf940b 100644 --- a/www/common/cryptpad-common.js +++ b/www/common/cryptpad-common.js @@ -63,7 +63,10 @@ define([ common.setLanguage = function (l, cb) { var LS_LANG = "CRYPTPAD_LANG"; localStorage.setItem(LS_LANG, l); - cb(); + postMessage("SET_ATTRIBUTE", { + attr: ['general', 'language'], + value: l + }, cb); }; common.makeNetwork = function (cb) { diff --git a/www/common/drive-ui.js b/www/common/drive-ui.js index 991fe5cc4..a92e383d1 100644 --- a/www/common/drive-ui.js +++ b/www/common/drive-ui.js @@ -1207,9 +1207,6 @@ define([ if ($element.is('.cp-app-drive-element-notrash')) { // We can't delete elements in virtual categories hide.push('delete'); - } else { - // We can only open parent in virtual categories - hide.push('openparent'); } if (!$element.is('.cp-border-color-file')) { //hide.push('download'); @@ -1310,6 +1307,10 @@ define([ hide.push('open'); } + if (!APP.loggedIn) { + hide.push('openparent'); + } + filter = function ($el, className) { if (hide.indexOf(className) !== -1) { return true; } }; @@ -1325,7 +1326,7 @@ define([ 'deleteowned', 'removesf', 'access', 'properties', 'hashtag']; break; case 'default': - show = ['open', 'openro', 'preview', 'share', 'openparent', 'delete', 'deleteowned', 'properties', 'access', 'hashtag', 'makeacopy']; + show = ['open', 'openro', 'preview', 'openincode', 'share', 'download', 'openparent', 'delete', 'deleteowned', 'properties', 'access', 'hashtag', 'makeacopy', 'savelocal', 'rename']; break; case 'trashtree': { show = ['empty']; @@ -2117,7 +2118,7 @@ define([ onElementClick(e, $element); }); if (!isTrash) { - $element.contextmenu(openContextMenu('tree')); + $element.on('contextmenu', openContextMenu('tree')); $element.data('context', 'tree'); } else { $element.contextmenu(openContextMenu('trash')); @@ -2747,21 +2748,22 @@ define([ var options = [{ tag: 'a', attributes: {'class': 'cp-app-drive-element-type'}, - content: Messages.fm_type + content: '' + Messages.fm_type },{ tag: 'a', attributes: {'class': 'cp-app-drive-element-atime'}, - content: Messages.fm_lastAccess + content: '' + Messages.fm_lastAccess },{ tag: 'a', attributes: {'class': 'cp-app-drive-element-ctime'}, - content: Messages.fm_creation + content: '' + Messages.fm_creation }]; var dropdownConfig = { text: '', // Button initial text options: options, // Entries displayed in the menu container: $fhSort, left: true, + noscroll: true, common: common }; var $sortBlock = UIElements.createDropdown(dropdownConfig); @@ -2804,7 +2806,7 @@ define([ if (APP.store[SORT_FILE_BY] === '') { classSorted = 'cp-app-drive-sort-filename'; } else if (APP.store[SORT_FILE_BY]) { classSorted = 'cp-app-drive-element-' + APP.store[SORT_FILE_BY]; } if (classSorted) { - $list.find('.' + classSorted).addClass('cp-app-drive-sort-active').prepend($icon); + $list.find('.' + classSorted).addClass('cp-app-drive-sort-active').prepend($icon).find('i').hide(); } }; var getFileListHeader = function (clickable) { @@ -3312,6 +3314,7 @@ define([ } // Display the pad + /* var $icon = getFileIcon(id); var ro = manager.isReadOnlyFile(id); // ro undefined means it's an old hash which doesn't support read-only @@ -3319,21 +3322,13 @@ define([ ro ? ' cp-app-drive-element-readonly' : ''; var $element = $('
  • ', { 'class': 'cp-app-drive-element cp-app-drive-element-notrash cp-app-drive-element-file cp-app-drive-element-row' + roClass, - }); - $element.prepend($icon).dblclick(function () { - openFile(id); - }); - addFileData(id, $element); - $element.data('path', path); - $element.click(function(e) { - e.stopPropagation(); - onElementClick(e, $element); - }); - $element.contextmenu(openContextMenu('default')); + });*/ + var parentPath = path.slice(); + var key = parentPath.pop(); + var root = manager.find(parentPath); + var $element = createElement(parentPath, key, root); + $element.off('contextmenu').contextmenu(openContextMenu('default')); $element.data('context', 'default'); - /*if (draggable) { - addDragAndDropHandlers($element, path, false, false); - }*/ $list.append($element); i++; }); diff --git a/www/common/inner/access.js b/www/common/inner/access.js index b2705208f..55a4dbbe9 100644 --- a/www/common/inner/access.js +++ b/www/common/inner/access.js @@ -205,10 +205,14 @@ define([ var $sel = $div.find('.cp-usergrid-user.cp-selected'); var sel = $sel.toArray(); if (!sel.length) { return; } + var addMe = false; var toAdd = sel.map(function (el) { var curve = $(el).attr('data-curve'); - // If the pad is woned by a team, we can transfer ownership to ourselves - if (curve === user.curvePublic && teamOwner) { return priv.edPublic; } + // If the pad is owned by a team, we can transfer ownership to ourselves + if (curve === user.curvePublic && teamOwner) { + addMe = true; + return; + } var friend = friends[curve]; if (!friend) { return; } return friend.edPublic; @@ -282,10 +286,31 @@ define([ } })); } + }).nThen(function (waitFor) { + // Offer ownership to a friend + if (addMe) { + // Send the command + sframeChan.query('Q_SET_PAD_METADATA', { + channel: channel, + command: 'ADD_OWNERS', + value: [priv.edPublic], + teamId: teamOwner + }, waitFor(function (err, res) { + err = err || (res && res.error); + if (err) { + waitFor.abort(); + redrawAll(true); + var text = err === "INSUFFICIENT_PERMISSIONS" ? Messages.fm_forbidden + : Messages.error; + return void UI.warn(text); + } + })); + } }).nThen(function (waitFor) { sel.forEach(function (el) { var curve = $(el).attr('data-curve'); - var friend = curve === user.curvePublic ? user : friends[curve]; + if (curve === user.curvePublic) { return; } + var friend = friends[curve]; if (!friend) { return; } common.mailbox.sendTo("ADD_OWNER", { channel: channel, diff --git a/www/common/onlyoffice/app-oo.less b/www/common/onlyoffice/app-oo.less index 2971165a0..08b64df91 100644 --- a/www/common/onlyoffice/app-oo.less +++ b/www/common/onlyoffice/app-oo.less @@ -63,6 +63,9 @@ body.cp-app-sheet, body.cp-app-oodoc, body.cp-app-ooslide { display: flex; flex-flow: column; position: relative; + iframe { + flex: 1; + } } #cp-app-oo-offline { position: absolute; diff --git a/www/common/onlyoffice/inner.js b/www/common/onlyoffice/inner.js index 262581c2f..19adc46b2 100644 --- a/www/common/onlyoffice/inner.js +++ b/www/common/onlyoffice/inner.js @@ -1606,13 +1606,13 @@ define([ if (typeof(Atomics) === "undefined") { accept = ['.bin']; } - var $importXLSX = common.createButton('import', true, { - accept: accept, - binary : ["ods", "xlsx", "odt", "docx", "odp", "pptx"] - }, importXLSXFile); - $importXLSX.appendTo(toolbar.$drawer); if (common.isLoggedIn()) { + var $importXLSX = common.createButton('import', true, { + accept: accept, + binary : ["ods", "xlsx", "odt", "docx", "odp", "pptx"] + }, importXLSXFile); + $importXLSX.appendTo(toolbar.$drawer); common.createButton('hashtag', true).appendTo(toolbar.$drawer); } diff --git a/www/common/onlyoffice/x2t/x2t.js b/www/common/onlyoffice/x2t/x2t.js index 1bfa08870..c87f65922 100644 --- a/www/common/onlyoffice/x2t/x2t.js +++ b/www/common/onlyoffice/x2t/x2t.js @@ -1,1581 +1,1180 @@ -// Copyright 2010 The Emscripten Authors. All rights reserved. -// Emscripten is available under two separate licenses, the MIT license and the -// University of Illinois/NCSA Open Source License. Both these licenses can be -// found in the LICENSE file. +// Support for growable heap + pthreads, where the buffer may change, so JS views +// must be updated. +function GROWABLE_HEAP_STORE_I8(ptr, value) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + HEAP8[ptr] = value; +} +function GROWABLE_HEAP_STORE_I16(ptr, value) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + HEAP16[ptr >> 1] = value; +} +function GROWABLE_HEAP_STORE_I32(ptr, value) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + HEAP32[ptr >> 2] = value; +} +function GROWABLE_HEAP_STORE_F32(ptr, value) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + HEAPF32[ptr >> 2] = value; +} +function GROWABLE_HEAP_STORE_F64(ptr, value) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + HEAPF64[ptr >> 3] = value; +} -// The Module object: Our interface to the outside world. We import -// and export values on it. There are various ways Module can be used: -// 1. Not defined. We create it here -// 2. A function parameter, function(Module) { ..generated code.. } -// 3. pre-run appended it, var Module = {}; ..generated code.. -// 4. External script tag defines var Module. -// We need to check if Module already exists (e.g. case 3 above). -// Substitution will be replaced with actual code on later stage of the build, -// this way Closure Compiler will not mangle it (e.g. case 4. above). -// Note that if you want to run closure, and also to use Module -// after the generated code, you will need to define var Module = {}; -// before the code. Then that object will be used in the code, and you -// can continue to use Module afterwards as well. -var Module = typeof Module !== 'undefined' ? Module : {}; +function GROWABLE_HEAP_LOAD_I8(ptr) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + return HEAP8[ptr]; +} +function GROWABLE_HEAP_LOAD_U8(ptr) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + return HEAPU8[ptr]; +} +function GROWABLE_HEAP_LOAD_I16(ptr) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + return HEAP16[ptr >> 1]; +} +function GROWABLE_HEAP_LOAD_U16(ptr) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + return HEAPU16[ptr >> 1]; +} +function GROWABLE_HEAP_LOAD_I32(ptr) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + return HEAP32[ptr >> 2]; +} +function GROWABLE_HEAP_LOAD_U32(ptr) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + return HEAPU32[ptr >> 2]; +} +function GROWABLE_HEAP_LOAD_F32(ptr) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + return HEAPF32[ptr >> 2]; +} +function GROWABLE_HEAP_LOAD_F64(ptr) { + if (wasmMemory.buffer != buffer) { + updateGlobalBufferAndViews(wasmMemory.buffer); + } + return HEAPF64[ptr >> 3]; +} +function GROWABLE_HEAP_VIEW_I8(start, end) { + return new Int8Array(wasmMemory.buffer, start, end - start); +} +function GROWABLE_HEAP_VIEW_U8(start, end) { + return new Uint8Array(wasmMemory.buffer, start, end - start); +} +function GROWABLE_HEAP_VIEW_I16(start, end) { + return new Int16Array(wasmMemory.buffer, start >> 1, end - start >> 1); +} +function GROWABLE_HEAP_VIEW_U16(start, end) { + return new Uint16Array(wasmMemory.buffer, start >> 1, end - start >> 1); +} +function GROWABLE_HEAP_VIEW_I32(start, end) { + return new Int32Array(wasmMemory.buffer, start >> 2, end - start >> 2); +} +function GROWABLE_HEAP_VIEW_U32(start, end) { + return new Uint32Array(wasmMemory.buffer, start >> 2, end - start >> 2); +} +function GROWABLE_HEAP_VIEW_F32(start, end) { + return new Float32Array(wasmMemory.buffer, start >> 2, end - start >> 2); +} +function GROWABLE_HEAP_VIEW_F64(start, end) { + return new Float64Array(wasmMemory.buffer, start >> 3, end - start >> 3); +} -// --pre-jses are emitted after the Module integration code, so that they can -// refer to Module (if they choose; they can also define Module) -// {{PRE_JSES}} -// Sometimes an existing Module object exists with properties -// meant to overwrite the default module functionality. Here -// we collect those properties and reapply _after_ we configure -// the current environment's defaults to avoid having to be so -// defensive during initialization. +var Module = typeof Module !== "undefined" ? Module : {}; var moduleOverrides = {}; var key; for (key in Module) { - if (Module.hasOwnProperty(key)) { - moduleOverrides[key] = Module[key]; - } + if (Module.hasOwnProperty(key)) { + moduleOverrides[key] = Module[key]; + } } - var arguments_ = []; -var thisProgram = './this.program'; -var quit_ = function(status, toThrow) { - throw toThrow; -}; - -// Determine the runtime environment we are in. You can customize this by -// setting the ENVIRONMENT setting at compile time (see settings.js). - +var thisProgram = "./this.program"; +var quit_ = (function(status, toThrow) { + throw toThrow; +}); var ENVIRONMENT_IS_WEB = false; var ENVIRONMENT_IS_WORKER = false; var ENVIRONMENT_IS_NODE = false; var ENVIRONMENT_HAS_NODE = false; var ENVIRONMENT_IS_SHELL = false; -ENVIRONMENT_IS_WEB = typeof window === 'object'; -ENVIRONMENT_IS_WORKER = typeof importScripts === 'function'; -// A web environment like Electron.js can have Node enabled, so we must -// distinguish between Node-enabled environments and Node environments per se. -// This will allow the former to do things like mount NODEFS. -// Extended check using process.versions fixes issue #8816. -// (Also makes redundant the original check that 'require' is a function.) -ENVIRONMENT_HAS_NODE = typeof process === 'object' && typeof process.versions === 'object' && typeof process.versions.node === 'string'; +ENVIRONMENT_IS_WEB = typeof window === "object"; +ENVIRONMENT_IS_WORKER = typeof importScripts === "function"; +ENVIRONMENT_HAS_NODE = typeof process === "object" && typeof process.versions === "object" && typeof process.versions.node === "string"; ENVIRONMENT_IS_NODE = ENVIRONMENT_HAS_NODE && !ENVIRONMENT_IS_WEB && !ENVIRONMENT_IS_WORKER; ENVIRONMENT_IS_SHELL = !ENVIRONMENT_IS_WEB && !ENVIRONMENT_IS_NODE && !ENVIRONMENT_IS_WORKER; - -if (Module['ENVIRONMENT']) { - throw new Error('Module.ENVIRONMENT has been deprecated. To force the environment, use the ENVIRONMENT compile-time option (for example, -s ENVIRONMENT=web or -s ENVIRONMENT=node)'); +if (Module["ENVIRONMENT"]) { + throw new Error("Module.ENVIRONMENT has been deprecated. To force the environment, use the ENVIRONMENT compile-time option (for example, -s ENVIRONMENT=web or -s ENVIRONMENT=node)"); } - - -// Three configurations we can be running in: -// 1) We could be the application main() thread running in the main JS UI thread. (ENVIRONMENT_IS_WORKER == false and ENVIRONMENT_IS_PTHREAD == false) -// 2) We could be the application main() thread proxied to worker. (with Emscripten -s PROXY_TO_WORKER=1) (ENVIRONMENT_IS_WORKER == true, ENVIRONMENT_IS_PTHREAD == false) -// 3) We could be an application pthread running in a worker. (ENVIRONMENT_IS_WORKER == true and ENVIRONMENT_IS_PTHREAD == true) - -// ENVIRONMENT_IS_PTHREAD=true will have been preset in worker.js. Make it false in the main runtime thread. -var ENVIRONMENT_IS_PTHREAD = Module['ENVIRONMENT_IS_PTHREAD'] || false; +var ENVIRONMENT_IS_PTHREAD = Module["ENVIRONMENT_IS_PTHREAD"] || false; if (ENVIRONMENT_IS_PTHREAD) { - // Grab imports from the pthread to local scope. - buffer = Module['buffer']; - tempDoublePtr = Module['tempDoublePtr']; - DYNAMIC_BASE = Module['DYNAMIC_BASE']; - DYNAMICTOP_PTR = Module['DYNAMICTOP_PTR']; - // Note that not all runtime fields are imported above. Values for STACK_BASE, STACKTOP and STACK_MAX are not yet known at worker.js load time. - // These will be filled in at pthread startup time (the 'run' message for a pthread - pthread start establishes the stack frame) + buffer = Module["buffer"]; + tempDoublePtr = Module["tempDoublePtr"]; + DYNAMIC_BASE = Module["DYNAMIC_BASE"]; + DYNAMICTOP_PTR = Module["DYNAMICTOP_PTR"]; } - - - - -// In MODULARIZE mode _scriptDir needs to be captured already at the very top of the page immediately when the page is parsed, so it is generated there -// before the page load. In non-MODULARIZE modes generate it here. -var _scriptDir = (typeof document !== 'undefined' && document.currentScript) ? document.currentScript.src : undefined; - +var _scriptDir = typeof document !== "undefined" && document.currentScript ? document.currentScript.src : undefined; if (ENVIRONMENT_IS_NODE) { - _scriptDir = __filename; + _scriptDir = __filename; } - -// `/` should be present at the end if `scriptDirectory` is not empty -var scriptDirectory = ''; +var scriptDirectory = ""; function locateFile(path) { - if (Module['locateFile']) { - return Module['locateFile'](path, scriptDirectory); - } - return scriptDirectory + path; + if (Module["locateFile"]) { + return Module["locateFile"](path, scriptDirectory); + } + return scriptDirectory + path; } - -// Hooks that are implemented differently in different runtime environments. -var read_, - readAsync, - readBinary, - setWindowTitle; - +var read_, readAsync, readBinary, setWindowTitle; var nodeFS; var nodePath; - if (ENVIRONMENT_IS_NODE) { - scriptDirectory = __dirname + '/'; - - - read_ = function shell_read(filename, binary) { - if (!nodeFS) nodeFS = require('fs'); - if (!nodePath) nodePath = require('path'); - filename = nodePath['normalize'](filename); - return nodeFS['readFileSync'](filename, binary ? null : 'utf8'); - }; - - readBinary = function readBinary(filename) { - var ret = read_(filename, true); - if (!ret.buffer) { - ret = new Uint8Array(ret); - } - assert(ret.buffer); - return ret; + scriptDirectory = __dirname + "/"; + read_ = function shell_read(filename, binary) { + if (!nodeFS) nodeFS = require("fs"); + if (!nodePath) nodePath = require("path"); + filename = nodePath["normalize"](filename); + return nodeFS["readFileSync"](filename, binary ? null : "utf8"); + }; + readBinary = function readBinary(filename) { + var ret = read_(filename, true); + if (!ret.buffer) { + ret = new Uint8Array(ret); + } + assert(ret.buffer); + return ret; + }; + if (process["argv"].length > 1) { + thisProgram = process["argv"][1].replace(/\\/g, "/"); + } + arguments_ = process["argv"].slice(2); + if (typeof module !== "undefined") { + module["exports"] = Module; + } + process["on"]("uncaughtException", (function(ex) { + if (!(ex instanceof ExitStatus)) { + throw ex; + } + })); + process["on"]("unhandledRejection", abort); + quit_ = (function(status) { + process["exit"](status); + }); + Module["inspect"] = (function() { + return "[Emscripten Module object]"; + }); + var nodeWorkerThreads; + try { + nodeWorkerThreads = require("worker_threads"); + } catch (e) { + console.error('The "worker_threads" module is not supported in this node.js build - perhaps a newer version is needed?'); + throw e; + } + Worker = nodeWorkerThreads.Worker; +} else if (ENVIRONMENT_IS_SHELL) { + if (typeof read != "undefined") { + read_ = function shell_read(f) { + return read(f); }; - - - - - if (process['argv'].length > 1) { - thisProgram = process['argv'][1].replace(/\\/g, '/'); - } - - arguments_ = process['argv'].slice(2); - - if (typeof module !== 'undefined') { - module['exports'] = Module; - } - - process['on']('uncaughtException', function(ex) { - // suppress ExitStatus exceptions from showing an error - if (!(ex instanceof ExitStatus)) { - throw ex; - } + } + readBinary = function readBinary(f) { + var data; + if (typeof readbuffer === "function") { + return new Uint8Array(readbuffer(f)); + } + data = read(f, "binary"); + assert(typeof data === "object"); + return data; + }; + if (typeof scriptArgs != "undefined") { + arguments_ = scriptArgs; + } else if (typeof arguments != "undefined") { + arguments_ = arguments; + } + if (typeof quit === "function") { + quit_ = (function(status) { + quit(status); }); - - process['on']('unhandledRejection', abort); - - quit_ = function(status) { - process['exit'](status); - }; - - Module['inspect'] = function () { return '[Emscripten Module object]'; }; - - var nodeWorkerThreads; - try { - nodeWorkerThreads = require('worker_threads'); - } catch (e) { - console.error('The "worker_threads" module is not supported in this node.js build - perhaps a newer version is needed?'); - throw e; - } - Worker = nodeWorkerThreads.Worker; - -} else -if (ENVIRONMENT_IS_SHELL) { - - - if (typeof read != 'undefined') { - read_ = function shell_read(f) { - return read(f); - }; - } - - readBinary = function readBinary(f) { - var data; - if (typeof readbuffer === 'function') { - return new Uint8Array(readbuffer(f)); - } - data = read(f, 'binary'); - assert(typeof data === 'object'); - return data; - }; - - if (typeof scriptArgs != 'undefined') { - arguments_ = scriptArgs; - } else if (typeof arguments != 'undefined') { - arguments_ = arguments; - } - - if (typeof quit === 'function') { - quit_ = function(status) { - quit(status); - }; - } - - if (typeof print !== 'undefined') { - // Prefer to use print/printErr where they exist, as they usually work better. - if (typeof console === 'undefined') console = {}; - console.log = print; - console.warn = console.error = typeof printErr !== 'undefined' ? printErr : print; - } -} else - -// Note that this includes Node.js workers when relevant (pthreads is enabled). -// Node.js workers are detected as a combination of ENVIRONMENT_IS_WORKER and -// ENVIRONMENT_HAS_NODE. -if (ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER) { - if (ENVIRONMENT_IS_WORKER) { // Check worker, not web, since window could be polyfilled - scriptDirectory = self.location.href; - } else if (document.currentScript) { // web - scriptDirectory = document.currentScript.src; - } - // blob urls look like blob:http://site.com/etc/etc and we cannot infer anything from them. - // otherwise, slice off the final part of the url to find the script directory. - // if scriptDirectory does not contain a slash, lastIndexOf will return -1, - // and scriptDirectory will correctly be replaced with an empty string. - if (scriptDirectory.indexOf('blob:') !== 0) { - scriptDirectory = scriptDirectory.substr(0, scriptDirectory.lastIndexOf('/')+1); - } else { - scriptDirectory = ''; - } - - - // Differentiate the Web Worker from the Node Worker case, as reading must - // be done differently. - if (ENVIRONMENT_HAS_NODE) { - - + } + if (typeof print !== "undefined") { + if (typeof console === "undefined") console = {}; + console.log = print; + console.warn = console.error = typeof printErr !== "undefined" ? printErr : print; + } +} else if (ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER) { + if (ENVIRONMENT_IS_WORKER) { + scriptDirectory = self.location.href; + } else if (document.currentScript) { + scriptDirectory = document.currentScript.src; + } + if (scriptDirectory.indexOf("blob:") !== 0) { + scriptDirectory = scriptDirectory.substr(0, scriptDirectory.lastIndexOf("/") + 1); + } else { + scriptDirectory = ""; + } + if (ENVIRONMENT_HAS_NODE) { read_ = function shell_read(filename, binary) { - if (!nodeFS) nodeFS = require('fs'); - if (!nodePath) nodePath = require('path'); - filename = nodePath['normalize'](filename); - return nodeFS['readFileSync'](filename, binary ? null : 'utf8'); + if (!nodeFS) nodeFS = require("fs"); + if (!nodePath) nodePath = require("path"); + filename = nodePath["normalize"](filename); + return nodeFS["readFileSync"](filename, binary ? null : "utf8"); }; - readBinary = function readBinary(filename) { - var ret = read_(filename, true); - if (!ret.buffer) { - ret = new Uint8Array(ret); - } - assert(ret.buffer); - return ret; + var ret = read_(filename, true); + if (!ret.buffer) { + ret = new Uint8Array(ret); + } + assert(ret.buffer); + return ret; }; - - - - - } else - { - - + } else { read_ = function shell_read(url) { - var xhr = new XMLHttpRequest(); - xhr.open('GET', url, false); - xhr.send(null); - return xhr.responseText; + var xhr = new XMLHttpRequest; + xhr.open("GET", url, false); + xhr.send(null); + return xhr.responseText; }; - if (ENVIRONMENT_IS_WORKER) { - readBinary = function readBinary(url) { - var xhr = new XMLHttpRequest(); - xhr.open('GET', url, false); - xhr.responseType = 'arraybuffer'; - xhr.send(null); - return new Uint8Array(xhr.response); - }; + readBinary = function readBinary(url) { + var xhr = new XMLHttpRequest; + xhr.open("GET", url, false); + xhr.responseType = "arraybuffer"; + xhr.send(null); + return new Uint8Array(xhr.response); + }; } - readAsync = function readAsync(url, onload, onerror) { - var xhr = new XMLHttpRequest(); - xhr.open('GET', url, true); - xhr.responseType = 'arraybuffer'; - xhr.onload = function xhr_onload() { - if (xhr.status == 200 || (xhr.status == 0 && xhr.response)) { // file URLs can return 0 - onload(xhr.response); - return; - } - onerror(); - }; - xhr.onerror = onerror; - xhr.send(null); + var xhr = new XMLHttpRequest; + xhr.open("GET", url, true); + xhr.responseType = "arraybuffer"; + xhr.onload = function xhr_onload() { + if (xhr.status == 200 || xhr.status == 0 && xhr.response) { + onload(xhr.response); + return; + } + onerror(); + }; + xhr.onerror = onerror; + xhr.send(null); }; - - - - - } - - setWindowTitle = function(title) { document.title = title }; -} else -{ - throw new Error('environment detection error'); + } + setWindowTitle = (function(title) { + document.title = title; + }); +} else { + throw new Error("environment detection error"); } - if (ENVIRONMENT_HAS_NODE) { - // Polyfill the performance object, which emscripten pthreads support - // depends on for good timing. - if (typeof performance === 'undefined') { - performance = require('perf_hooks').performance; - } + if (typeof performance === "undefined") { + performance = require("perf_hooks").performance; + } } - -// Set up the out() and err() hooks, which are how we can print to stdout or -// stderr, respectively. -var out = Module['print'] || console.log.bind(console); -var err = Module['printErr'] || console.warn.bind(console); - -// Merge back in the overrides +var out = Module["print"] || console.log.bind(console); +var err = Module["printErr"] || console.warn.bind(console); for (key in moduleOverrides) { - if (moduleOverrides.hasOwnProperty(key)) { - Module[key] = moduleOverrides[key]; - } + if (moduleOverrides.hasOwnProperty(key)) { + Module[key] = moduleOverrides[key]; + } } -// Free the object hierarchy contained in the overrides, this lets the GC -// reclaim data used e.g. in memoryInitializerRequest, which is a large typed array. moduleOverrides = null; - -// Emit code to handle expected values on the Module object. This applies Module.x -// to the proper local x. This has two benefits: first, we only emit it if it is -// expected to arrive, and second, by using a local everywhere else that can be -// minified. -if (Module['arguments']) arguments_ = Module['arguments'];if (!Object.getOwnPropertyDescriptor(Module, 'arguments')) Object.defineProperty(Module, 'arguments', { configurable: true, get: function() { abort('Module.arguments has been replaced with plain arguments_') } }); -if (Module['thisProgram']) thisProgram = Module['thisProgram'];if (!Object.getOwnPropertyDescriptor(Module, 'thisProgram')) Object.defineProperty(Module, 'thisProgram', { configurable: true, get: function() { abort('Module.thisProgram has been replaced with plain thisProgram') } }); -if (Module['quit']) quit_ = Module['quit'];if (!Object.getOwnPropertyDescriptor(Module, 'quit')) Object.defineProperty(Module, 'quit', { configurable: true, get: function() { abort('Module.quit has been replaced with plain quit_') } }); - -// perform assertions in shell.js after we set up out() and err(), as otherwise if an assertion fails it cannot print the message -// Assertions on removed incoming Module JS APIs. -assert(typeof Module['memoryInitializerPrefixURL'] === 'undefined', 'Module.memoryInitializerPrefixURL option was removed, use Module.locateFile instead'); -assert(typeof Module['pthreadMainPrefixURL'] === 'undefined', 'Module.pthreadMainPrefixURL option was removed, use Module.locateFile instead'); -assert(typeof Module['cdInitializerPrefixURL'] === 'undefined', 'Module.cdInitializerPrefixURL option was removed, use Module.locateFile instead'); -assert(typeof Module['filePackagePrefixURL'] === 'undefined', 'Module.filePackagePrefixURL option was removed, use Module.locateFile instead'); -assert(typeof Module['read'] === 'undefined', 'Module.read option was removed (modify read_ in JS)'); -assert(typeof Module['readAsync'] === 'undefined', 'Module.readAsync option was removed (modify readAsync in JS)'); -assert(typeof Module['readBinary'] === 'undefined', 'Module.readBinary option was removed (modify readBinary in JS)'); -assert(typeof Module['setWindowTitle'] === 'undefined', 'Module.setWindowTitle option was removed (modify setWindowTitle in JS)'); -if (!Object.getOwnPropertyDescriptor(Module, 'read')) Object.defineProperty(Module, 'read', { configurable: true, get: function() { abort('Module.read has been replaced with plain read_') } }); -if (!Object.getOwnPropertyDescriptor(Module, 'readAsync')) Object.defineProperty(Module, 'readAsync', { configurable: true, get: function() { abort('Module.readAsync has been replaced with plain readAsync') } }); -if (!Object.getOwnPropertyDescriptor(Module, 'readBinary')) Object.defineProperty(Module, 'readBinary', { configurable: true, get: function() { abort('Module.readBinary has been replaced with plain readBinary') } }); -// TODO: add when SDL2 is fixed if (!Object.getOwnPropertyDescriptor(Module, 'setWindowTitle')) Object.defineProperty(Module, 'setWindowTitle', { configurable: true, get: function() { abort('Module.setWindowTitle has been replaced with plain setWindowTitle') } }); -var IDBFS = 'IDBFS is no longer included by default; build with -lidbfs.js'; -var PROXYFS = 'PROXYFS is no longer included by default; build with -lproxyfs.js'; -var WORKERFS = 'WORKERFS is no longer included by default; build with -lworkerfs.js'; - - -assert(ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER || ENVIRONMENT_IS_NODE, 'Pthreads do not work in this environment yet (need Web Workers, or an alternative to them)'); - -// TODO remove when SDL2 is fixed (also see above) - - - -// Copyright 2017 The Emscripten Authors. All rights reserved. -// Emscripten is available under two separate licenses, the MIT license and the -// University of Illinois/NCSA Open Source License. Both these licenses can be -// found in the LICENSE file. - -// {{PREAMBLE_ADDITIONS}} - +if (Module["arguments"]) arguments_ = Module["arguments"]; +if (!Object.getOwnPropertyDescriptor(Module, "arguments")) Object.defineProperty(Module, "arguments", { + configurable: true, + get: (function() { + abort("Module.arguments has been replaced with plain arguments_"); + }) +}); +if (Module["thisProgram"]) thisProgram = Module["thisProgram"]; +if (!Object.getOwnPropertyDescriptor(Module, "thisProgram")) Object.defineProperty(Module, "thisProgram", { + configurable: true, + get: (function() { + abort("Module.thisProgram has been replaced with plain thisProgram"); + }) +}); +if (Module["quit"]) quit_ = Module["quit"]; +if (!Object.getOwnPropertyDescriptor(Module, "quit")) Object.defineProperty(Module, "quit", { + configurable: true, + get: (function() { + abort("Module.quit has been replaced with plain quit_"); + }) +}); +assert(typeof Module["memoryInitializerPrefixURL"] === "undefined", "Module.memoryInitializerPrefixURL option was removed, use Module.locateFile instead"); +assert(typeof Module["pthreadMainPrefixURL"] === "undefined", "Module.pthreadMainPrefixURL option was removed, use Module.locateFile instead"); +assert(typeof Module["cdInitializerPrefixURL"] === "undefined", "Module.cdInitializerPrefixURL option was removed, use Module.locateFile instead"); +assert(typeof Module["filePackagePrefixURL"] === "undefined", "Module.filePackagePrefixURL option was removed, use Module.locateFile instead"); +assert(typeof Module["read"] === "undefined", "Module.read option was removed (modify read_ in JS)"); +assert(typeof Module["readAsync"] === "undefined", "Module.readAsync option was removed (modify readAsync in JS)"); +assert(typeof Module["readBinary"] === "undefined", "Module.readBinary option was removed (modify readBinary in JS)"); +assert(typeof Module["setWindowTitle"] === "undefined", "Module.setWindowTitle option was removed (modify setWindowTitle in JS)"); +if (!Object.getOwnPropertyDescriptor(Module, "read")) Object.defineProperty(Module, "read", { + configurable: true, + get: (function() { + abort("Module.read has been replaced with plain read_"); + }) +}); +if (!Object.getOwnPropertyDescriptor(Module, "readAsync")) Object.defineProperty(Module, "readAsync", { + configurable: true, + get: (function() { + abort("Module.readAsync has been replaced with plain readAsync"); + }) +}); +if (!Object.getOwnPropertyDescriptor(Module, "readBinary")) Object.defineProperty(Module, "readBinary", { + configurable: true, + get: (function() { + abort("Module.readBinary has been replaced with plain readBinary"); + }) +}); +var IDBFS = "IDBFS is no longer included by default; build with -lidbfs.js"; +var PROXYFS = "PROXYFS is no longer included by default; build with -lproxyfs.js"; +var WORKERFS = "WORKERFS is no longer included by default; build with -lworkerfs.js"; +assert(ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER || ENVIRONMENT_IS_NODE, "Pthreads do not work in this environment yet (need Web Workers, or an alternative to them)"); var STACK_ALIGN = 16; - -// stack management, and other functionality that is provided by the compiled code, -// should not be used before it is ready -stackSave = stackRestore = stackAlloc = function() { - abort('cannot use the stack before compiled code is ready to run, and has provided stack access'); -}; - +stackSave = stackRestore = stackAlloc = (function() { + abort("cannot use the stack before compiled code is ready to run, and has provided stack access"); +}); function staticAlloc(size) { - abort('staticAlloc is no longer available at runtime; instead, perform static allocations at compile time (using makeStaticAlloc)'); + abort("staticAlloc is no longer available at runtime; instead, perform static allocations at compile time (using makeStaticAlloc)"); } - function dynamicAlloc(size) { - assert(DYNAMICTOP_PTR); - assert(!ENVIRONMENT_IS_PTHREAD); // this function is not thread-safe - var ret = HEAP32[DYNAMICTOP_PTR>>2]; - var end = (ret + size + 15) & -16; - if (end > _emscripten_get_heap_size()) { - abort('failure to dynamicAlloc - memory growth etc. is not supported there, call malloc/sbrk directly'); - } - HEAP32[DYNAMICTOP_PTR>>2] = end; - return ret; + assert(DYNAMICTOP_PTR); + assert(!ENVIRONMENT_IS_PTHREAD); + var ret = GROWABLE_HEAP_LOAD_I32(DYNAMICTOP_PTR | 0); + var end = ret + size + 15 & -16; + if (end > _emscripten_get_heap_size()) { + abort("failure to dynamicAlloc - memory growth etc. is not supported there, call malloc/sbrk directly"); + } + GROWABLE_HEAP_STORE_I32(DYNAMICTOP_PTR | 0, end); + return ret; } - function alignMemory(size, factor) { - if (!factor) factor = STACK_ALIGN; // stack alignment (16-byte) by default - return Math.ceil(size / factor) * factor; + if (!factor) factor = STACK_ALIGN; + return Math.ceil(size / factor) * factor; } - function getNativeTypeSize(type) { - switch (type) { - case 'i1': case 'i8': return 1; - case 'i16': return 2; - case 'i32': return 4; - case 'i64': return 8; - case 'float': return 4; - case 'double': return 8; - default: { - if (type[type.length-1] === '*') { - return 4; // A pointer - } else if (type[0] === 'i') { - var bits = parseInt(type.substr(1)); - assert(bits % 8 === 0, 'getNativeTypeSize invalid bits ' + bits + ', type ' + type); - return bits / 8; - } else { - return 0; - } - } + switch (type) { + case "i1": + case "i8": + return 1; + case "i16": + return 2; + case "i32": + return 4; + case "i64": + return 8; + case "float": + return 4; + case "double": + return 8; + default: + { + if (type[type.length - 1] === "*") { + return 4; + } else if (type[0] === "i") { + var bits = parseInt(type.substr(1)); + assert(bits % 8 === 0, "getNativeTypeSize invalid bits " + bits + ", type " + type); + return bits / 8; + } else { + return 0; + } } + } } - function warnOnce(text) { - if (!warnOnce.shown) warnOnce.shown = {}; - if (!warnOnce.shown[text]) { - warnOnce.shown[text] = 1; - err(text); - } + if (!warnOnce.shown) warnOnce.shown = {}; + if (!warnOnce.shown[text]) { + warnOnce.shown[text] = 1; + err(text); + } } - -var asm2wasmImports = { // special asm2wasm imports - "f64-rem": function(x, y) { - return x % y; - }, - "debugger": function() { - debugger; - } +var asm2wasmImports = { + "f64-rem": (function(x, y) { + return x % y; + }), + "debugger": (function() { + debugger; + }) }; - - - - -// Wraps a JS function as a wasm function with a given signature. function convertJsFunctionToWasm(func, sig) { - - // If the type reflection proposal is available, use the new - // "WebAssembly.Function" constructor. - // Otherwise, construct a minimal wasm module importing the JS function and - // re-exporting it. - if (typeof WebAssembly.Function === "function") { - var typeNames = { - 'i': 'i32', - 'j': 'i64', - 'f': 'f32', - 'd': 'f64' - }; - var type = { - parameters: [], - results: sig[0] == 'v' ? [] : [typeNames[sig[0]]] - }; - for (var i = 1; i < sig.length; ++i) { - type.parameters.push(typeNames[sig[i]]); - } - return new WebAssembly.Function(type, func); - } - - // The module is static, with the exception of the type section, which is - // generated based on the signature passed in. - var typeSection = [ - 0x01, // id: section, - 0x00, // length: 0 (placeholder) - 0x01, // count: 1 - 0x60, // form: func - ]; - var sigRet = sig.slice(0, 1); - var sigParam = sig.slice(1); - var typeCodes = { - 'i': 0x7f, // i32 - 'j': 0x7e, // i64 - 'f': 0x7d, // f32 - 'd': 0x7c, // f64 + if (typeof WebAssembly.Function === "function") { + var typeNames = { + "i": "i32", + "j": "i64", + "f": "f32", + "d": "f64" }; - - // Parameters, length + signatures - typeSection.push(sigParam.length); - for (var i = 0; i < sigParam.length; ++i) { - typeSection.push(typeCodes[sigParam[i]]); - } - - // Return values, length + signatures - // With no multi-return in MVP, either 0 (void) or 1 (anything else) - if (sigRet == 'v') { - typeSection.push(0x00); - } else { - typeSection = typeSection.concat([0x01, typeCodes[sigRet]]); - } - - // Write the overall length of the type section back into the section header - // (excepting the 2 bytes for the section id and length) - typeSection[1] = typeSection.length - 2; - - // Rest of the module is static - var bytes = new Uint8Array([ - 0x00, 0x61, 0x73, 0x6d, // magic ("\0asm") - 0x01, 0x00, 0x00, 0x00, // version: 1 - ].concat(typeSection, [ - 0x02, 0x07, // import section - // (import "e" "f" (func 0 (type 0))) - 0x01, 0x01, 0x65, 0x01, 0x66, 0x00, 0x00, - 0x07, 0x05, // export section - // (export "f" (func 0 (type 0))) - 0x01, 0x01, 0x66, 0x00, 0x00, - ])); - - // We can compile this wasm module synchronously because it is very small. - // This accepts an import (at "e.f"), that it reroutes to an export (at "f") - var module = new WebAssembly.Module(bytes); - var instance = new WebAssembly.Instance(module, { - 'e': { - 'f': func - } - }); - var wrappedFunc = instance.exports['f']; - return wrappedFunc; + var type = { + parameters: [], + results: sig[0] == "v" ? [] : [ typeNames[sig[0]] ] + }; + for (var i = 1; i < sig.length; ++i) { + type.parameters.push(typeNames[sig[i]]); + } + return new WebAssembly.Function(type, func); + } + var typeSection = [ 1, 0, 1, 96 ]; + var sigRet = sig.slice(0, 1); + var sigParam = sig.slice(1); + var typeCodes = { + "i": 127, + "j": 126, + "f": 125, + "d": 124 + }; + typeSection.push(sigParam.length); + for (var i = 0; i < sigParam.length; ++i) { + typeSection.push(typeCodes[sigParam[i]]); + } + if (sigRet == "v") { + typeSection.push(0); + } else { + typeSection = typeSection.concat([ 1, typeCodes[sigRet] ]); + } + typeSection[1] = typeSection.length - 2; + var bytes = new Uint8Array([ 0, 97, 115, 109, 1, 0, 0, 0 ].concat(typeSection, [ 2, 7, 1, 1, 101, 1, 102, 0, 0, 7, 5, 1, 1, 102, 0, 0 ])); + var module = new WebAssembly.Module(bytes); + var instance = new WebAssembly.Instance(module, { + "e": { + "f": func + } + }); + var wrappedFunc = instance.exports["f"]; + return wrappedFunc; } - -// Add a wasm function to the table. function addFunctionWasm(func, sig) { - var table = wasmTable; - var ret = table.length; - - // Grow the table - try { - table.grow(1); - } catch (err) { - if (!err instanceof RangeError) { - throw err; - } - throw 'Unable to grow wasm table. Use a higher value for RESERVED_FUNCTION_POINTERS or set ALLOW_TABLE_GROWTH.'; - } - - // Insert new element - try { - // Attempting to call this with JS function will cause of table.set() to fail - table.set(ret, func); - } catch (err) { - if (!err instanceof TypeError) { - throw err; - } - assert(typeof sig !== 'undefined', 'Missing signature argument to addFunction'); - var wrapped = convertJsFunctionToWasm(func, sig); - table.set(ret, wrapped); - } - - return ret; -} - -function removeFunctionWasm(index) { - // TODO(sbc): Look into implementing this to allow re-using of table slots + var table = wasmTable; + var ret = table.length; + try { + table.grow(1); + } catch (err) { + if (!err instanceof RangeError) { + throw err; + } + throw "Unable to grow wasm table. Use a higher value for RESERVED_FUNCTION_POINTERS or set ALLOW_TABLE_GROWTH."; + } + try { + table.set(ret, func); + } catch (err) { + if (!err instanceof TypeError) { + throw err; + } + assert(typeof sig !== "undefined", "Missing signature argument to addFunction"); + var wrapped = convertJsFunctionToWasm(func, sig); + table.set(ret, wrapped); + } + return ret; } - -// 'sig' parameter is required for the llvm backend but only when func is not -// already a WebAssembly function. +function removeFunctionWasm(index) {} function addFunction(func, sig) { - assert(typeof func !== 'undefined'); - - return addFunctionWasm(func, sig); + assert(typeof func !== "undefined"); + return addFunctionWasm(func, sig); } - function removeFunction(index) { - removeFunctionWasm(index); + removeFunctionWasm(index); } - var funcWrappers = {}; - function getFuncWrapper(func, sig) { - if (!func) return; // on null pointer, return undefined - assert(sig); - if (!funcWrappers[sig]) { - funcWrappers[sig] = {}; - } - var sigCache = funcWrappers[sig]; - if (!sigCache[func]) { - // optimize away arguments usage in common cases - if (sig.length === 1) { - sigCache[func] = function dynCall_wrapper() { - return dynCall(sig, func); - }; - } else if (sig.length === 2) { - sigCache[func] = function dynCall_wrapper(arg) { - return dynCall(sig, func, [arg]); - }; - } else { - // general case - sigCache[func] = function dynCall_wrapper() { - return dynCall(sig, func, Array.prototype.slice.call(arguments)); - }; - } + if (!func) return; + assert(sig); + if (!funcWrappers[sig]) { + funcWrappers[sig] = {}; + } + var sigCache = funcWrappers[sig]; + if (!sigCache[func]) { + if (sig.length === 1) { + sigCache[func] = function dynCall_wrapper() { + return dynCall(sig, func); + }; + } else if (sig.length === 2) { + sigCache[func] = function dynCall_wrapper(arg) { + return dynCall(sig, func, [ arg ]); + }; + } else { + sigCache[func] = function dynCall_wrapper() { + return dynCall(sig, func, Array.prototype.slice.call(arguments)); + }; } - return sigCache[func]; + } + return sigCache[func]; } - - function makeBigInt(low, high, unsigned) { - return unsigned ? ((+((low>>>0)))+((+((high>>>0)))*4294967296.0)) : ((+((low>>>0)))+((+((high|0)))*4294967296.0)); + return unsigned ? +(low >>> 0) + +(high >>> 0) * 4294967296 : +(low >>> 0) + +(high | 0) * 4294967296; } - function dynCall(sig, ptr, args) { - if (args && args.length) { - assert(args.length == sig.length-1); - assert(('dynCall_' + sig) in Module, 'bad function pointer type - no table for sig \'' + sig + '\''); - return Module['dynCall_' + sig].apply(null, [ptr].concat(args)); - } else { - assert(sig.length == 1); - assert(('dynCall_' + sig) in Module, 'bad function pointer type - no table for sig \'' + sig + '\''); - return Module['dynCall_' + sig].call(null, ptr); - } + if (args && args.length) { + assert(args.length == sig.length - 1); + assert("dynCall_" + sig in Module, "bad function pointer type - no table for sig '" + sig + "'"); + return Module["dynCall_" + sig].apply(null, [ ptr ].concat(args)); + } else { + assert(sig.length == 1); + assert("dynCall_" + sig in Module, "bad function pointer type - no table for sig '" + sig + "'"); + return Module["dynCall_" + sig].call(null, ptr); + } } - var tempRet0 = 0; - -var setTempRet0 = function(value) { - tempRet0 = value; -}; - -var getTempRet0 = function() { - return tempRet0; -}; - +var setTempRet0 = (function(value) { + tempRet0 = value; +}); +var getTempRet0 = (function() { + return tempRet0; +}); function getCompilerSetting(name) { - throw 'You must build with -s RETAIN_COMPILER_SETTINGS=1 for getCompilerSetting or emscripten_get_compiler_setting to work'; + throw "You must build with -s RETAIN_COMPILER_SETTINGS=1 for getCompilerSetting or emscripten_get_compiler_setting to work"; } - var Runtime = { - // helpful errors - getTempRet0: function() { abort('getTempRet0() is now a top-level function, after removing the Runtime object. Remove "Runtime."') }, - staticAlloc: function() { abort('staticAlloc() is now a top-level function, after removing the Runtime object. Remove "Runtime."') }, - stackAlloc: function() { abort('stackAlloc() is now a top-level function, after removing the Runtime object. Remove "Runtime."') }, + getTempRet0: (function() { + abort('getTempRet0() is now a top-level function, after removing the Runtime object. Remove "Runtime."'); + }), + staticAlloc: (function() { + abort('staticAlloc() is now a top-level function, after removing the Runtime object. Remove "Runtime."'); + }), + stackAlloc: (function() { + abort('stackAlloc() is now a top-level function, after removing the Runtime object. Remove "Runtime."'); + }) }; - -// The address globals begin at. Very low in memory, for code size and optimization opportunities. -// Above 0 is static memory, starting with globals. -// Then the stack. -// Then 'dynamic' memory for sbrk. var GLOBAL_BASE = 1024; - - -// The wasm backend path does not have a way to set the stack max, so we can -// just implement this function in a trivial way function establishStackSpace(base, max) { - stackRestore(max); + stackRestore(max); } - -// JS library code refers to Atomics in the manner used from asm.js, provide -// the same API here. var Atomics_load = Atomics.load; var Atomics_store = Atomics.store; var Atomics_compareExchange = Atomics.compareExchange; - - -// === Preamble library stuff === - -// Documentation for the public APIs defined in this file must be updated in: -// site/source/docs/api_reference/preamble.js.rst -// A prebuilt local version of the documentation is available at: -// site/build/text/docs/api_reference/preamble.js.txt -// You can also build docs locally as HTML or other formats in site/ -// An online HTML version (which may be of a different version of Emscripten) -// is up at http://kripken.github.io/emscripten-site/docs/api_reference/preamble.js.html - - -var wasmBinary;if (Module['wasmBinary']) wasmBinary = Module['wasmBinary'];if (!Object.getOwnPropertyDescriptor(Module, 'wasmBinary')) Object.defineProperty(Module, 'wasmBinary', { configurable: true, get: function() { abort('Module.wasmBinary has been replaced with plain wasmBinary') } }); -var noExitRuntime;if (Module['noExitRuntime']) noExitRuntime = Module['noExitRuntime'];if (!Object.getOwnPropertyDescriptor(Module, 'noExitRuntime')) Object.defineProperty(Module, 'noExitRuntime', { configurable: true, get: function() { abort('Module.noExitRuntime has been replaced with plain noExitRuntime') } }); - - -if (typeof WebAssembly !== 'object') { - abort('No WebAssembly support found. Build with -s WASM=0 to target JavaScript instead.'); +var wasmBinary; +if (Module["wasmBinary"]) wasmBinary = Module["wasmBinary"]; +if (!Object.getOwnPropertyDescriptor(Module, "wasmBinary")) Object.defineProperty(Module, "wasmBinary", { + configurable: true, + get: (function() { + abort("Module.wasmBinary has been replaced with plain wasmBinary"); + }) +}); +var noExitRuntime; +if (Module["noExitRuntime"]) noExitRuntime = Module["noExitRuntime"]; +if (!Object.getOwnPropertyDescriptor(Module, "noExitRuntime")) Object.defineProperty(Module, "noExitRuntime", { + configurable: true, + get: (function() { + abort("Module.noExitRuntime has been replaced with plain noExitRuntime"); + }) +}); +if (typeof WebAssembly !== "object") { + abort("No WebAssembly support found. Build with -s WASM=0 to target JavaScript instead."); } - - -// In MINIMAL_RUNTIME, setValue() and getValue() are only available when building with safe heap enabled, for heap safety checking. -// In traditional runtime, setValue() and getValue() are always available (although their use is highly discouraged due to perf penalties) - -/** @type {function(number, number, string, boolean=)} */ function setValue(ptr, value, type, noSafe) { - type = type || 'i8'; - if (type.charAt(type.length-1) === '*') type = 'i32'; // pointers are 32-bit - switch(type) { - case 'i1': HEAP8[((ptr)>>0)]=value; break; - case 'i8': HEAP8[((ptr)>>0)]=value; break; - case 'i16': HEAP16[((ptr)>>1)]=value; break; - case 'i32': HEAP32[((ptr)>>2)]=value; break; - case 'i64': (tempI64 = [value>>>0,(tempDouble=value,(+(Math_abs(tempDouble))) >= 1.0 ? (tempDouble > 0.0 ? ((Math_min((+(Math_floor((tempDouble)/4294967296.0))), 4294967295.0))|0)>>>0 : (~~((+(Math_ceil((tempDouble - +(((~~(tempDouble)))>>>0))/4294967296.0)))))>>>0) : 0)],HEAP32[((ptr)>>2)]=tempI64[0],HEAP32[(((ptr)+(4))>>2)]=tempI64[1]); break; - case 'float': HEAPF32[((ptr)>>2)]=value; break; - case 'double': HEAPF64[((ptr)>>3)]=value; break; - default: abort('invalid type for setValue: ' + type); - } + type = type || "i8"; + if (type.charAt(type.length - 1) === "*") type = "i32"; + switch (type) { + case "i1": + GROWABLE_HEAP_STORE_I8(ptr >> 0 | 0, value); + break; + case "i8": + GROWABLE_HEAP_STORE_I8(ptr >> 0 | 0, value); + break; + case "i16": + GROWABLE_HEAP_STORE_I16(ptr | 0, value); + break; + case "i32": + GROWABLE_HEAP_STORE_I32(ptr | 0, value); + break; + case "i64": + tempI64 = [ value >>> 0, (tempDouble = value, +Math_abs(tempDouble) >= 1 ? tempDouble > 0 ? (Math_min(+Math_floor(tempDouble / 4294967296), 4294967295) | 0) >>> 0 : ~~+Math_ceil((tempDouble - +(~~tempDouble >>> 0)) / 4294967296) >>> 0 : 0) ], GROWABLE_HEAP_STORE_I32(ptr | 0, tempI64[0]), GROWABLE_HEAP_STORE_I32(ptr + 4 | 0, tempI64[1]); + break; + case "float": + GROWABLE_HEAP_STORE_F32(ptr | 0, value); + break; + case "double": + GROWABLE_HEAP_STORE_F64(ptr | 0, value); + break; + default: + abort("invalid type for setValue: " + type); + } } - -/** @type {function(number, string, boolean=)} */ function getValue(ptr, type, noSafe) { - type = type || 'i8'; - if (type.charAt(type.length-1) === '*') type = 'i32'; // pointers are 32-bit - switch(type) { - case 'i1': return HEAP8[((ptr)>>0)]; - case 'i8': return HEAP8[((ptr)>>0)]; - case 'i16': return HEAP16[((ptr)>>1)]; - case 'i32': return HEAP32[((ptr)>>2)]; - case 'i64': return HEAP32[((ptr)>>2)]; - case 'float': return HEAPF32[((ptr)>>2)]; - case 'double': return HEAPF64[((ptr)>>3)]; - default: abort('invalid type for getValue: ' + type); - } - return null; + type = type || "i8"; + if (type.charAt(type.length - 1) === "*") type = "i32"; + switch (type) { + case "i1": + return GROWABLE_HEAP_LOAD_I8(ptr >> 0 | 0); + case "i8": + return GROWABLE_HEAP_LOAD_I8(ptr >> 0 | 0); + case "i16": + return GROWABLE_HEAP_LOAD_I16(ptr | 0); + case "i32": + return GROWABLE_HEAP_LOAD_I32(ptr | 0); + case "i64": + return GROWABLE_HEAP_LOAD_I32(ptr | 0); + case "float": + return GROWABLE_HEAP_LOAD_F32(ptr | 0); + case "double": + return GROWABLE_HEAP_LOAD_F64(ptr | 0); + default: + abort("invalid type for getValue: " + type); + } + return null; } - - - - - -// Wasm globals - var wasmMemory; - -// In fastcomp asm.js, we don't need a wasm Table at all. -// In the wasm backend, we polyfill the WebAssembly object, -// so this creates a (non-native-wasm) table for us. var wasmTable = new WebAssembly.Table({ - 'initial': 63857, - 'maximum': 63857 + 0, - 'element': 'anyfunc' + "initial": 63857, + "maximum": 63857 + 0, + "element": "anyfunc" }); - -// For sending to workers. var wasmModule; -// Only workers actually use these field, but we refer to them from -// library_pthread (which exists on all threads) so this definition is useful -// to avoid accessing the global scope. var threadInfoStruct = 0; var selfThreadId = 0; var __performance_now_clock_drift = 0; var tempDoublePtr = 0; - -//======================================== -// Runtime essentials -//======================================== - -// whether we are quitting the application. no code should run after this. -// set in exit() and abort() var ABORT = false; - -// set by exit() and abort(). Passed to 'onExit' handler. -// NOTE: This is also used as the process return code code in shell environments -// but only when noExitRuntime is false. var EXITSTATUS = 0; - -/** @type {function(*, string=)} */ function assert(condition, text) { - if (!condition) { - abort('Assertion failed: ' + text); - } + if (!condition) { + abort("Assertion failed: " + text); + } } - -// Returns the C function with a specified identifier (for C++, you need to do manual name mangling) function getCFunc(ident) { - var func = Module['_' + ident]; // closure exported function - assert(func, 'Cannot call unknown function ' + ident + ', make sure it is exported'); - return func; + var func = Module["_" + ident]; + assert(func, "Cannot call unknown function " + ident + ", make sure it is exported"); + return func; } - -// C calling interface. function ccall(ident, returnType, argTypes, args, opts) { - // For fast lookup of conversion functions - var toC = { - 'string': function(str) { - var ret = 0; - if (str !== null && str !== undefined && str !== 0) { // null string - // at most 4 bytes per UTF-8 code point, +1 for the trailing '\0' - var len = (str.length << 2) + 1; - ret = stackAlloc(len); - stringToUTF8(str, ret, len); - } - return ret; - }, - 'array': function(arr) { - var ret = stackAlloc(arr.length); - writeArrayToMemory(arr, ret); - return ret; - } - }; - - function convertReturnValue(ret) { - if (returnType === 'string') return UTF8ToString(ret); - if (returnType === 'boolean') return Boolean(ret); - return ret; - } - - var func = getCFunc(ident); - var cArgs = []; - var stack = 0; - assert(returnType !== 'array', 'Return type should not be "array".'); - if (args) { - for (var i = 0; i < args.length; i++) { - var converter = toC[argTypes[i]]; - if (converter) { - if (stack === 0) stack = stackSave(); - cArgs[i] = converter(args[i]); - } else { - cArgs[i] = args[i]; - } - } - } - var ret = func.apply(null, cArgs); - - ret = convertReturnValue(ret); - if (stack !== 0) stackRestore(stack); + var toC = { + "string": (function(str) { + var ret = 0; + if (str !== null && str !== undefined && str !== 0) { + var len = (str.length << 2) + 1; + ret = stackAlloc(len); + stringToUTF8(str, ret, len); + } + return ret; + }), + "array": (function(arr) { + var ret = stackAlloc(arr.length); + writeArrayToMemory(arr, ret); + return ret; + }) + }; + function convertReturnValue(ret) { + if (returnType === "string") return UTF8ToString(ret); + if (returnType === "boolean") return Boolean(ret); return ret; + } + var func = getCFunc(ident); + var cArgs = []; + var stack = 0; + assert(returnType !== "array", 'Return type should not be "array".'); + if (args) { + for (var i = 0; i < args.length; i++) { + var converter = toC[argTypes[i]]; + if (converter) { + if (stack === 0) stack = stackSave(); + cArgs[i] = converter(args[i]); + } else { + cArgs[i] = args[i]; + } + } + } + var ret = func.apply(null, cArgs); + ret = convertReturnValue(ret); + if (stack !== 0) stackRestore(stack); + return ret; } - function cwrap(ident, returnType, argTypes, opts) { - return function() { - return ccall(ident, returnType, argTypes, arguments, opts); - } + return (function() { + return ccall(ident, returnType, argTypes, arguments, opts); + }); } - -var ALLOC_NORMAL = 0; // Tries to use _malloc() -var ALLOC_STACK = 1; // Lives for the duration of the current function call -var ALLOC_DYNAMIC = 2; // Cannot be freed except through sbrk -var ALLOC_NONE = 3; // Do not allocate - -// allocate(): This is for internal use. You can use it yourself as well, but the interface -// is a little tricky (see docs right below). The reason is that it is optimized -// for multiple syntaxes to save space in generated code. So you should -// normally not use allocate(), and instead allocate memory using _malloc(), -// initialize it with setValue(), and so forth. -// @slab: An array of data, or a number. If a number, then the size of the block to allocate, -// in *bytes* (note that this is sometimes confusing: the next parameter does not -// affect this!) -// @types: Either an array of types, one for each byte (or 0 if no type at that position), -// or a single type which is used for the entire block. This only matters if there -// is initial data - if @slab is a number, then this does not matter at all and is -// ignored. -// @allocator: How to allocate memory, see ALLOC_* -/** @type {function((TypedArray|Array|number), string, number, number=)} */ +var ALLOC_NORMAL = 0; +var ALLOC_STACK = 1; +var ALLOC_DYNAMIC = 2; +var ALLOC_NONE = 3; function allocate(slab, types, allocator, ptr) { - var zeroinit, size; - if (typeof slab === 'number') { - zeroinit = true; - size = slab; - } else { - zeroinit = false; - size = slab.length; + var zeroinit, size; + if (typeof slab === "number") { + zeroinit = true; + size = slab; + } else { + zeroinit = false; + size = slab.length; + } + var singleType = typeof types === "string" ? types : null; + var ret; + if (allocator == ALLOC_NONE) { + ret = ptr; + } else { + ret = [ _malloc, stackAlloc, dynamicAlloc ][allocator](Math.max(size, singleType ? 1 : types.length)); + } + if (zeroinit) { + var stop; + ptr = ret; + assert((ret & 3) == 0); + stop = ret + (size & ~3); + for (; ptr < stop; ptr += 4) { + GROWABLE_HEAP_STORE_I32(ptr | 0, 0); + } + stop = ret + size; + while (ptr < stop) { + GROWABLE_HEAP_STORE_I8(ptr++ >> 0 | 0, 0); } - - var singleType = typeof types === 'string' ? types : null; - - var ret; - if (allocator == ALLOC_NONE) { - ret = ptr; + return ret; + } + if (singleType === "i8") { + if (slab.subarray || slab.slice) { + HEAPU8.set(slab, ret); } else { - ret = [_malloc, - stackAlloc, - dynamicAlloc][allocator](Math.max(size, singleType ? 1 : types.length)); - } - - if (zeroinit) { - var stop; - ptr = ret; - assert((ret & 3) == 0); - stop = ret + (size & ~3); - for (; ptr < stop; ptr += 4) { - HEAP32[((ptr)>>2)]=0; - } - stop = ret + size; - while (ptr < stop) { - HEAP8[((ptr++)>>0)]=0; - } - return ret; - } - - if (singleType === 'i8') { - if (slab.subarray || slab.slice) { - HEAPU8.set(/** @type {!Uint8Array} */ (slab), ret); - } else { - HEAPU8.set(new Uint8Array(slab), ret); - } - return ret; - } - - var i = 0, type, typeSize, previousType; - while (i < size) { - var curr = slab[i]; - - type = singleType || types[i]; - if (type === 0) { - i++; - continue; - } - assert(type, 'Must know what type to store in allocate!'); - - if (type == 'i64') type = 'i32'; // special case: we have one i32 here, and one i32 later - - setValue(ret+i, curr, type); - - // no need to look up size unless type changes, so cache it - if (previousType !== type) { - typeSize = getNativeTypeSize(type); - previousType = type; - } - i += typeSize; + HEAPU8.set(new Uint8Array(slab), ret); } - return ret; + } + var i = 0, type, typeSize, previousType; + while (i < size) { + var curr = slab[i]; + type = singleType || types[i]; + if (type === 0) { + i++; + continue; + } + assert(type, "Must know what type to store in allocate!"); + if (type == "i64") type = "i32"; + setValue(ret + i, curr, type); + if (previousType !== type) { + typeSize = getNativeTypeSize(type); + previousType = type; + } + i += typeSize; + } + return ret; } - -// Allocate memory during any stage of startup - static memory early on, dynamic memory later, malloc when ready function getMemory(size) { - if (!runtimeInitialized) return dynamicAlloc(size); - return _malloc(size); + if (!runtimeInitialized) return dynamicAlloc(size); + return _malloc(size); } - - - - -/** @type {function(number, number=)} */ function Pointer_stringify(ptr, length) { - abort("this function has been removed - you should use UTF8ToString(ptr, maxBytesToRead) instead!"); + abort("this function has been removed - you should use UTF8ToString(ptr, maxBytesToRead) instead!"); } - -// Given a pointer 'ptr' to a null-terminated ASCII-encoded string in the emscripten HEAP, returns -// a copy of that string as a Javascript String object. - function AsciiToString(ptr) { - var str = ''; - while (1) { - var ch = HEAPU8[((ptr++)>>0)]; - if (!ch) return str; - str += String.fromCharCode(ch); - } + var str = ""; + while (1) { + var ch = GROWABLE_HEAP_LOAD_U8(ptr++ >> 0 | 0); + if (!ch) return str; + str += String.fromCharCode(ch); + } } - -// Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr', -// null-terminated and encoded in ASCII form. The copy will require at most str.length+1 bytes of space in the HEAP. - function stringToAscii(str, outPtr) { - return writeAsciiToMemory(str, outPtr, false); + return writeAsciiToMemory(str, outPtr, false); } - - -// Given a pointer 'ptr' to a null-terminated UTF8-encoded string in the given array that contains uint8 values, returns -// a copy of that string as a Javascript String object. - - -/** - * @param {number} idx - * @param {number=} maxBytesToRead - * @return {string} - */ function UTF8ArrayToString(u8Array, idx, maxBytesToRead) { - var endIdx = idx + maxBytesToRead; - - var str = ''; - while (!(idx >= endIdx)) { - // For UTF8 byte structure, see: - // http://en.wikipedia.org/wiki/UTF-8#Description - // https://www.ietf.org/rfc/rfc2279.txt - // https://tools.ietf.org/html/rfc3629 - var u0 = u8Array[idx++]; - // If not building with TextDecoder enabled, we don't know the string length, so scan for \0 byte. - // If building with TextDecoder, we know exactly at what byte index the string ends, so checking for nulls here would be redundant. - if (!u0) return str; - if (!(u0 & 0x80)) { str += String.fromCharCode(u0); continue; } - var u1 = u8Array[idx++] & 63; - if ((u0 & 0xE0) == 0xC0) { str += String.fromCharCode(((u0 & 31) << 6) | u1); continue; } - var u2 = u8Array[idx++] & 63; - if ((u0 & 0xF0) == 0xE0) { - u0 = ((u0 & 15) << 12) | (u1 << 6) | u2; - } else { - if ((u0 & 0xF8) != 0xF0) warnOnce('Invalid UTF-8 leading byte 0x' + u0.toString(16) + ' encountered when deserializing a UTF-8 string on the asm.js/wasm heap to a JS string!'); - u0 = ((u0 & 7) << 18) | (u1 << 12) | (u2 << 6) | (u8Array[idx++] & 63); - } - - if (u0 < 0x10000) { - str += String.fromCharCode(u0); - } else { - var ch = u0 - 0x10000; - str += String.fromCharCode(0xD800 | (ch >> 10), 0xDC00 | (ch & 0x3FF)); - } - } - return str; + var endIdx = idx + maxBytesToRead; + var str = ""; + while (!(idx >= endIdx)) { + var u0 = u8Array[idx++]; + if (!u0) return str; + if (!(u0 & 128)) { + str += String.fromCharCode(u0); + continue; + } + var u1 = u8Array[idx++] & 63; + if ((u0 & 224) == 192) { + str += String.fromCharCode((u0 & 31) << 6 | u1); + continue; + } + var u2 = u8Array[idx++] & 63; + if ((u0 & 240) == 224) { + u0 = (u0 & 15) << 12 | u1 << 6 | u2; + } else { + if ((u0 & 248) != 240) warnOnce("Invalid UTF-8 leading byte 0x" + u0.toString(16) + " encountered when deserializing a UTF-8 string on the asm.js/wasm heap to a JS string!"); + u0 = (u0 & 7) << 18 | u1 << 12 | u2 << 6 | u8Array[idx++] & 63; + } + if (u0 < 65536) { + str += String.fromCharCode(u0); + } else { + var ch = u0 - 65536; + str += String.fromCharCode(55296 | ch >> 10, 56320 | ch & 1023); + } + } + return str; } - -// Given a pointer 'ptr' to a null-terminated UTF8-encoded string in the emscripten HEAP, returns a -// copy of that string as a Javascript String object. -// maxBytesToRead: an optional length that specifies the maximum number of bytes to read. You can omit -// this parameter to scan the string until the first \0 byte. If maxBytesToRead is -// passed, and the string at [ptr, ptr+maxBytesToReadr[ contains a null byte in the -// middle, then the string will cut short at that byte index (i.e. maxBytesToRead will -// not produce a string of exact length [ptr, ptr+maxBytesToRead[) -// N.B. mixing frequent uses of UTF8ToString() with and without maxBytesToRead may -// throw JS JIT optimizations off, so it is worth to consider consistently using one -// style or the other. -/** - * @param {number} ptr - * @param {number=} maxBytesToRead - * @return {string} - */ function UTF8ToString(ptr, maxBytesToRead) { - return ptr ? UTF8ArrayToString(HEAPU8, ptr, maxBytesToRead) : ''; + return ptr ? UTF8ArrayToString(HEAPU8, ptr, maxBytesToRead) : ""; } - -// Copies the given Javascript String object 'str' to the given byte array at address 'outIdx', -// encoded in UTF8 form and null-terminated. The copy will require at most str.length*4+1 bytes of space in the HEAP. -// Use the function lengthBytesUTF8 to compute the exact number of bytes (excluding null terminator) that this function will write. -// Parameters: -// str: the Javascript string to copy. -// outU8Array: the array to copy to. Each index in this array is assumed to be one 8-byte element. -// outIdx: The starting offset in the array to begin the copying. -// maxBytesToWrite: The maximum number of bytes this function can write to the array. -// This count should include the null terminator, -// i.e. if maxBytesToWrite=1, only the null terminator will be written and nothing else. -// maxBytesToWrite=0 does not write any bytes to the output, not even the null terminator. -// Returns the number of bytes written, EXCLUDING the null terminator. - function stringToUTF8Array(str, outU8Array, outIdx, maxBytesToWrite) { - if (!(maxBytesToWrite > 0)) // Parameter maxBytesToWrite is not optional. Negative values, 0, null, undefined and false each don't write out any bytes. - return 0; - - var startIdx = outIdx; - var endIdx = outIdx + maxBytesToWrite - 1; // -1 for string null terminator. - for (var i = 0; i < str.length; ++i) { - // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code unit, not a Unicode code point of the character! So decode UTF16->UTF32->UTF8. - // See http://unicode.org/faq/utf_bom.html#utf16-3 - // For UTF8 byte structure, see http://en.wikipedia.org/wiki/UTF-8#Description and https://www.ietf.org/rfc/rfc2279.txt and https://tools.ietf.org/html/rfc3629 - var u = str.charCodeAt(i); // possibly a lead surrogate - if (u >= 0xD800 && u <= 0xDFFF) { - var u1 = str.charCodeAt(++i); - u = 0x10000 + ((u & 0x3FF) << 10) | (u1 & 0x3FF); - } - if (u <= 0x7F) { - if (outIdx >= endIdx) break; - outU8Array[outIdx++] = u; - } else if (u <= 0x7FF) { - if (outIdx + 1 >= endIdx) break; - outU8Array[outIdx++] = 0xC0 | (u >> 6); - outU8Array[outIdx++] = 0x80 | (u & 63); - } else if (u <= 0xFFFF) { - if (outIdx + 2 >= endIdx) break; - outU8Array[outIdx++] = 0xE0 | (u >> 12); - outU8Array[outIdx++] = 0x80 | ((u >> 6) & 63); - outU8Array[outIdx++] = 0x80 | (u & 63); - } else { - if (outIdx + 3 >= endIdx) break; - if (u >= 0x200000) warnOnce('Invalid Unicode code point 0x' + u.toString(16) + ' encountered when serializing a JS string to an UTF-8 string on the asm.js/wasm heap! (Valid unicode code points should be in range 0-0x1FFFFF).'); - outU8Array[outIdx++] = 0xF0 | (u >> 18); - outU8Array[outIdx++] = 0x80 | ((u >> 12) & 63); - outU8Array[outIdx++] = 0x80 | ((u >> 6) & 63); - outU8Array[outIdx++] = 0x80 | (u & 63); - } - } - // Null-terminate the pointer to the buffer. - outU8Array[outIdx] = 0; - return outIdx - startIdx; + if (!(maxBytesToWrite > 0)) return 0; + var startIdx = outIdx; + var endIdx = outIdx + maxBytesToWrite - 1; + for (var i = 0; i < str.length; ++i) { + var u = str.charCodeAt(i); + if (u >= 55296 && u <= 57343) { + var u1 = str.charCodeAt(++i); + u = 65536 + ((u & 1023) << 10) | u1 & 1023; + } + if (u <= 127) { + if (outIdx >= endIdx) break; + outU8Array[outIdx++] = u; + } else if (u <= 2047) { + if (outIdx + 1 >= endIdx) break; + outU8Array[outIdx++] = 192 | u >> 6; + outU8Array[outIdx++] = 128 | u & 63; + } else if (u <= 65535) { + if (outIdx + 2 >= endIdx) break; + outU8Array[outIdx++] = 224 | u >> 12; + outU8Array[outIdx++] = 128 | u >> 6 & 63; + outU8Array[outIdx++] = 128 | u & 63; + } else { + if (outIdx + 3 >= endIdx) break; + if (u >= 2097152) warnOnce("Invalid Unicode code point 0x" + u.toString(16) + " encountered when serializing a JS string to an UTF-8 string on the asm.js/wasm heap! (Valid unicode code points should be in range 0-0x1FFFFF)."); + outU8Array[outIdx++] = 240 | u >> 18; + outU8Array[outIdx++] = 128 | u >> 12 & 63; + outU8Array[outIdx++] = 128 | u >> 6 & 63; + outU8Array[outIdx++] = 128 | u & 63; + } + } + outU8Array[outIdx] = 0; + return outIdx - startIdx; } - -// Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr', -// null-terminated and encoded in UTF8 form. The copy will require at most str.length*4+1 bytes of space in the HEAP. -// Use the function lengthBytesUTF8 to compute the exact number of bytes (excluding null terminator) that this function will write. -// Returns the number of bytes written, EXCLUDING the null terminator. - function stringToUTF8(str, outPtr, maxBytesToWrite) { - assert(typeof maxBytesToWrite == 'number', 'stringToUTF8(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!'); - return stringToUTF8Array(str, HEAPU8,outPtr, maxBytesToWrite); + assert(typeof maxBytesToWrite == "number", "stringToUTF8(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!"); + return stringToUTF8Array(str, HEAPU8, outPtr, maxBytesToWrite); } - -// Returns the number of bytes the given Javascript string takes if encoded as a UTF8 byte array, EXCLUDING the null terminator byte. function lengthBytesUTF8(str) { - var len = 0; - for (var i = 0; i < str.length; ++i) { - // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code unit, not a Unicode code point of the character! So decode UTF16->UTF32->UTF8. - // See http://unicode.org/faq/utf_bom.html#utf16-3 - var u = str.charCodeAt(i); // possibly a lead surrogate - if (u >= 0xD800 && u <= 0xDFFF) u = 0x10000 + ((u & 0x3FF) << 10) | (str.charCodeAt(++i) & 0x3FF); - if (u <= 0x7F) ++len; - else if (u <= 0x7FF) len += 2; - else if (u <= 0xFFFF) len += 3; - else len += 4; - } - return len; + var len = 0; + for (var i = 0; i < str.length; ++i) { + var u = str.charCodeAt(i); + if (u >= 55296 && u <= 57343) u = 65536 + ((u & 1023) << 10) | str.charCodeAt(++i) & 1023; + if (u <= 127) ++len; else if (u <= 2047) len += 2; else if (u <= 65535) len += 3; else len += 4; + } + return len; } - - -// Given a pointer 'ptr' to a null-terminated UTF16LE-encoded string in the emscripten HEAP, returns -// a copy of that string as a Javascript String object. - function UTF16ToString(ptr) { - assert(ptr % 2 == 0, 'Pointer passed to UTF16ToString must be aligned to two bytes!'); - var i = 0; - - var str = ''; - while (1) { - var codeUnit = HEAP16[(((ptr)+(i*2))>>1)]; - if (codeUnit == 0) return str; - ++i; - // fromCharCode constructs a character from a UTF-16 code unit, so we can pass the UTF16 string right through. - str += String.fromCharCode(codeUnit); - } + assert(ptr % 2 == 0, "Pointer passed to UTF16ToString must be aligned to two bytes!"); + var i = 0; + var str = ""; + while (1) { + var codeUnit = GROWABLE_HEAP_LOAD_I16(ptr + i * 2 | 0); + if (codeUnit == 0) return str; + ++i; + str += String.fromCharCode(codeUnit); + } } - -// Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr', -// null-terminated and encoded in UTF16 form. The copy will require at most str.length*4+2 bytes of space in the HEAP. -// Use the function lengthBytesUTF16() to compute the exact number of bytes (excluding null terminator) that this function will write. -// Parameters: -// str: the Javascript string to copy. -// outPtr: Byte address in Emscripten HEAP where to write the string to. -// maxBytesToWrite: The maximum number of bytes this function can write to the array. This count should include the null -// terminator, i.e. if maxBytesToWrite=2, only the null terminator will be written and nothing else. -// maxBytesToWrite<2 does not write any bytes to the output, not even the null terminator. -// Returns the number of bytes written, EXCLUDING the null terminator. - function stringToUTF16(str, outPtr, maxBytesToWrite) { - assert(outPtr % 2 == 0, 'Pointer passed to stringToUTF16 must be aligned to two bytes!'); - assert(typeof maxBytesToWrite == 'number', 'stringToUTF16(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!'); - // Backwards compatibility: if max bytes is not specified, assume unsafe unbounded write is allowed. - if (maxBytesToWrite === undefined) { - maxBytesToWrite = 0x7FFFFFFF; - } - if (maxBytesToWrite < 2) return 0; - maxBytesToWrite -= 2; // Null terminator. - var startPtr = outPtr; - var numCharsToWrite = (maxBytesToWrite < str.length*2) ? (maxBytesToWrite / 2) : str.length; - for (var i = 0; i < numCharsToWrite; ++i) { - // charCodeAt returns a UTF-16 encoded code unit, so it can be directly written to the HEAP. - var codeUnit = str.charCodeAt(i); // possibly a lead surrogate - HEAP16[((outPtr)>>1)]=codeUnit; - outPtr += 2; - } - // Null-terminate the pointer to the HEAP. - HEAP16[((outPtr)>>1)]=0; - return outPtr - startPtr; + assert(outPtr % 2 == 0, "Pointer passed to stringToUTF16 must be aligned to two bytes!"); + assert(typeof maxBytesToWrite == "number", "stringToUTF16(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!"); + if (maxBytesToWrite === undefined) { + maxBytesToWrite = 2147483647; + } + if (maxBytesToWrite < 2) return 0; + maxBytesToWrite -= 2; + var startPtr = outPtr; + var numCharsToWrite = maxBytesToWrite < str.length * 2 ? maxBytesToWrite / 2 : str.length; + for (var i = 0; i < numCharsToWrite; ++i) { + var codeUnit = str.charCodeAt(i); + GROWABLE_HEAP_STORE_I16(outPtr | 0, codeUnit); + outPtr += 2; + } + GROWABLE_HEAP_STORE_I16(outPtr | 0, 0); + return outPtr - startPtr; } - -// Returns the number of bytes the given Javascript string takes if encoded as a UTF16 byte array, EXCLUDING the null terminator byte. - function lengthBytesUTF16(str) { - return str.length*2; + return str.length * 2; } - function UTF32ToString(ptr) { - assert(ptr % 4 == 0, 'Pointer passed to UTF32ToString must be aligned to four bytes!'); - var i = 0; - - var str = ''; - while (1) { - var utf32 = HEAP32[(((ptr)+(i*4))>>2)]; - if (utf32 == 0) - return str; - ++i; - // Gotcha: fromCharCode constructs a character from a UTF-16 encoded code (pair), not from a Unicode code point! So encode the code point to UTF-16 for constructing. - // See http://unicode.org/faq/utf_bom.html#utf16-3 - if (utf32 >= 0x10000) { - var ch = utf32 - 0x10000; - str += String.fromCharCode(0xD800 | (ch >> 10), 0xDC00 | (ch & 0x3FF)); - } else { - str += String.fromCharCode(utf32); - } + assert(ptr % 4 == 0, "Pointer passed to UTF32ToString must be aligned to four bytes!"); + var i = 0; + var str = ""; + while (1) { + var utf32 = GROWABLE_HEAP_LOAD_I32(ptr + i * 4 | 0); + if (utf32 == 0) return str; + ++i; + if (utf32 >= 65536) { + var ch = utf32 - 65536; + str += String.fromCharCode(55296 | ch >> 10, 56320 | ch & 1023); + } else { + str += String.fromCharCode(utf32); } + } } - -// Copies the given Javascript String object 'str' to the emscripten HEAP at address 'outPtr', -// null-terminated and encoded in UTF32 form. The copy will require at most str.length*4+4 bytes of space in the HEAP. -// Use the function lengthBytesUTF32() to compute the exact number of bytes (excluding null terminator) that this function will write. -// Parameters: -// str: the Javascript string to copy. -// outPtr: Byte address in Emscripten HEAP where to write the string to. -// maxBytesToWrite: The maximum number of bytes this function can write to the array. This count should include the null -// terminator, i.e. if maxBytesToWrite=4, only the null terminator will be written and nothing else. -// maxBytesToWrite<4 does not write any bytes to the output, not even the null terminator. -// Returns the number of bytes written, EXCLUDING the null terminator. - function stringToUTF32(str, outPtr, maxBytesToWrite) { - assert(outPtr % 4 == 0, 'Pointer passed to stringToUTF32 must be aligned to four bytes!'); - assert(typeof maxBytesToWrite == 'number', 'stringToUTF32(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!'); - // Backwards compatibility: if max bytes is not specified, assume unsafe unbounded write is allowed. - if (maxBytesToWrite === undefined) { - maxBytesToWrite = 0x7FFFFFFF; - } - if (maxBytesToWrite < 4) return 0; - var startPtr = outPtr; - var endPtr = startPtr + maxBytesToWrite - 4; - for (var i = 0; i < str.length; ++i) { - // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code unit, not a Unicode code point of the character! We must decode the string to UTF-32 to the heap. - // See http://unicode.org/faq/utf_bom.html#utf16-3 - var codeUnit = str.charCodeAt(i); // possibly a lead surrogate - if (codeUnit >= 0xD800 && codeUnit <= 0xDFFF) { - var trailSurrogate = str.charCodeAt(++i); - codeUnit = 0x10000 + ((codeUnit & 0x3FF) << 10) | (trailSurrogate & 0x3FF); - } - HEAP32[((outPtr)>>2)]=codeUnit; - outPtr += 4; - if (outPtr + 4 > endPtr) break; - } - // Null-terminate the pointer to the HEAP. - HEAP32[((outPtr)>>2)]=0; - return outPtr - startPtr; + assert(outPtr % 4 == 0, "Pointer passed to stringToUTF32 must be aligned to four bytes!"); + assert(typeof maxBytesToWrite == "number", "stringToUTF32(str, outPtr, maxBytesToWrite) is missing the third parameter that specifies the length of the output buffer!"); + if (maxBytesToWrite === undefined) { + maxBytesToWrite = 2147483647; + } + if (maxBytesToWrite < 4) return 0; + var startPtr = outPtr; + var endPtr = startPtr + maxBytesToWrite - 4; + for (var i = 0; i < str.length; ++i) { + var codeUnit = str.charCodeAt(i); + if (codeUnit >= 55296 && codeUnit <= 57343) { + var trailSurrogate = str.charCodeAt(++i); + codeUnit = 65536 + ((codeUnit & 1023) << 10) | trailSurrogate & 1023; + } + GROWABLE_HEAP_STORE_I32(outPtr | 0, codeUnit); + outPtr += 4; + if (outPtr + 4 > endPtr) break; + } + GROWABLE_HEAP_STORE_I32(outPtr | 0, 0); + return outPtr - startPtr; } - -// Returns the number of bytes the given Javascript string takes if encoded as a UTF16 byte array, EXCLUDING the null terminator byte. - function lengthBytesUTF32(str) { - var len = 0; - for (var i = 0; i < str.length; ++i) { - // Gotcha: charCodeAt returns a 16-bit word that is a UTF-16 encoded code unit, not a Unicode code point of the character! We must decode the string to UTF-32 to the heap. - // See http://unicode.org/faq/utf_bom.html#utf16-3 - var codeUnit = str.charCodeAt(i); - if (codeUnit >= 0xD800 && codeUnit <= 0xDFFF) ++i; // possibly a lead surrogate, so skip over the tail surrogate. - len += 4; - } - - return len; + var len = 0; + for (var i = 0; i < str.length; ++i) { + var codeUnit = str.charCodeAt(i); + if (codeUnit >= 55296 && codeUnit <= 57343) ++i; + len += 4; + } + return len; } - -// Allocate heap space for a JS string, and write it there. -// It is the responsibility of the caller to free() that memory. function allocateUTF8(str) { - var size = lengthBytesUTF8(str) + 1; - var ret = _malloc(size); - if (ret) stringToUTF8Array(str, HEAP8, ret, size); - return ret; + var size = lengthBytesUTF8(str) + 1; + var ret = _malloc(size); + if (ret) stringToUTF8Array(str, HEAP8, ret, size); + return ret; } - -// Allocate stack space for a JS string, and write it there. function allocateUTF8OnStack(str) { - var size = lengthBytesUTF8(str) + 1; - var ret = stackAlloc(size); - stringToUTF8Array(str, HEAP8, ret, size); - return ret; + var size = lengthBytesUTF8(str) + 1; + var ret = stackAlloc(size); + stringToUTF8Array(str, HEAP8, ret, size); + return ret; } - -// Deprecated: This function should not be called because it is unsafe and does not provide -// a maximum length limit of how many bytes it is allowed to write. Prefer calling the -// function stringToUTF8Array() instead, which takes in a maximum length that can be used -// to be secure from out of bounds writes. -/** @deprecated */ function writeStringToMemory(string, buffer, dontAddNull) { - warnOnce('writeStringToMemory is deprecated and should not be called! Use stringToUTF8() instead!'); - - var /** @type {number} */ lastChar, /** @type {number} */ end; - if (dontAddNull) { - // stringToUTF8Array always appends null. If we don't want to do that, remember the - // character that existed at the location where the null will be placed, and restore - // that after the write (below). - end = buffer + lengthBytesUTF8(string); - lastChar = HEAP8[end]; - } - stringToUTF8(string, buffer, Infinity); - if (dontAddNull) HEAP8[end] = lastChar; // Restore the value under the null character. + warnOnce("writeStringToMemory is deprecated and should not be called! Use stringToUTF8() instead!"); + var lastChar, end; + if (dontAddNull) { + end = buffer + lengthBytesUTF8(string); + lastChar = GROWABLE_HEAP_LOAD_I8(end | 0); + } + stringToUTF8(string, buffer, Infinity); + if (dontAddNull) GROWABLE_HEAP_STORE_I8(end | 0, lastChar); } - function writeArrayToMemory(array, buffer) { - assert(array.length >= 0, 'writeArrayToMemory array must have a length (should be an array or typed array)') - HEAP8.set(array, buffer); + assert(array.length >= 0, "writeArrayToMemory array must have a length (should be an array or typed array)"); + HEAP8.set(array, buffer); } - function writeAsciiToMemory(str, buffer, dontAddNull) { - for (var i = 0; i < str.length; ++i) { - assert(str.charCodeAt(i) === str.charCodeAt(i)&0xff); - HEAP8[((buffer++)>>0)]=str.charCodeAt(i); - } - // Null-terminate the pointer to the HEAP. - if (!dontAddNull) HEAP8[((buffer)>>0)]=0; + for (var i = 0; i < str.length; ++i) { + assert(str.charCodeAt(i) === str.charCodeAt(i) & 255); + GROWABLE_HEAP_STORE_I8(buffer++ >> 0 | 0, str.charCodeAt(i)); + } + if (!dontAddNull) GROWABLE_HEAP_STORE_I8(buffer >> 0 | 0, 0); } - - - - -// Memory management - var PAGE_SIZE = 16384; var WASM_PAGE_SIZE = 65536; var ASMJS_PAGE_SIZE = 16777216; - function alignUp(x, multiple) { - if (x % multiple > 0) { - x += multiple - (x % multiple); - } - return x; + if (x % multiple > 0) { + x += multiple - x % multiple; + } + return x; } - -var HEAP, -/** @type {ArrayBuffer} */ - buffer, -/** @type {Int8Array} */ - HEAP8, -/** @type {Uint8Array} */ - HEAPU8, -/** @type {Int16Array} */ - HEAP16, -/** @type {Uint16Array} */ - HEAPU16, -/** @type {Int32Array} */ - HEAP32, -/** @type {Uint32Array} */ - HEAPU32, -/** @type {Float32Array} */ - HEAPF32, -/** @type {Float64Array} */ - HEAPF64; - +var HEAP, buffer, HEAP8, HEAPU8, HEAP16, HEAPU16, HEAP32, HEAPU32, HEAPF32, HEAPF64; function updateGlobalBufferAndViews(buf) { - buffer = buf; - Module['HEAP8'] = HEAP8 = new Int8Array(buf); - Module['HEAP16'] = HEAP16 = new Int16Array(buf); - Module['HEAP32'] = HEAP32 = new Int32Array(buf); - Module['HEAPU8'] = HEAPU8 = new Uint8Array(buf); - Module['HEAPU16'] = HEAPU16 = new Uint16Array(buf); - Module['HEAPU32'] = HEAPU32 = new Uint32Array(buf); - Module['HEAPF32'] = HEAPF32 = new Float32Array(buf); - Module['HEAPF64'] = HEAPF64 = new Float64Array(buf); + buffer = buf; + Module["HEAP8"] = HEAP8 = new Int8Array(buf); + Module["HEAP16"] = HEAP16 = new Int16Array(buf); + Module["HEAP32"] = HEAP32 = new Int32Array(buf); + Module["HEAPU8"] = HEAPU8 = new Uint8Array(buf); + Module["HEAPU16"] = HEAPU16 = new Uint16Array(buf); + Module["HEAPU32"] = HEAPU32 = new Uint32Array(buf); + Module["HEAPF32"] = HEAPF32 = new Float32Array(buf); + Module["HEAPF64"] = HEAPF64 = new Float64Array(buf); } - -var STATIC_BASE = 1024, - STACK_BASE = 17838800, - STACKTOP = STACK_BASE, - STACK_MAX = 12595920, - DYNAMIC_BASE = 17838800, - DYNAMICTOP_PTR = 12594960; - -assert(STACK_BASE % 16 === 0, 'stack must start aligned'); -assert(DYNAMIC_BASE % 16 === 0, 'heap must start aligned'); - +var STATIC_BASE = 1024, STACK_BASE = 17838800, STACKTOP = STACK_BASE, STACK_MAX = 12595920, DYNAMIC_BASE = 17838800, DYNAMICTOP_PTR = 12594960; +assert(STACK_BASE % 16 === 0, "stack must start aligned"); +assert(DYNAMIC_BASE % 16 === 0, "heap must start aligned"); if (ENVIRONMENT_IS_PTHREAD) { - - // At the 'load' stage of Worker startup, we are just loading this script - // but not ready to run yet. At 'run' we receive proper values for the stack - // etc. and can launch a pthread. Set some fake values there meanwhile to - // catch bugs, then set the real values in applyStackValues later. - STACK_MAX = STACKTOP = STACK_MAX = 0x7FFFFFFF; - - Module['applyStackValues'] = function(stackBase, stackTop, stackMax) { - STACK_BASE = stackBase; - STACKTOP = stackTop; - STACK_MAX = stackMax; - }; - - // TODO DYNAMIC_BASE = Module['DYNAMIC_BASE']; - // TODO DYNAMICTOP_PTR = Module['DYNAMICTOP_PTR']; - // TODO tempDoublePtr = Module['tempDoublePtr']; + STACK_MAX = STACKTOP = STACK_MAX = 2147483647; + Module["applyStackValues"] = (function(stackBase, stackTop, stackMax) { + STACK_BASE = stackBase; + STACKTOP = stackTop; + STACK_MAX = stackMax; + }); } - - var TOTAL_STACK = 5242880; -if (Module['TOTAL_STACK']) assert(TOTAL_STACK === Module['TOTAL_STACK'], 'the stack size can no longer be determined at runtime') - -var INITIAL_TOTAL_MEMORY = Module['TOTAL_MEMORY'] || 149880832;if (!Object.getOwnPropertyDescriptor(Module, 'TOTAL_MEMORY')) Object.defineProperty(Module, 'TOTAL_MEMORY', { configurable: true, get: function() { abort('Module.TOTAL_MEMORY has been replaced with plain INITIAL_TOTAL_MEMORY') } }); - -assert(INITIAL_TOTAL_MEMORY >= TOTAL_STACK, 'TOTAL_MEMORY should be larger than TOTAL_STACK, was ' + INITIAL_TOTAL_MEMORY + '! (TOTAL_STACK=' + TOTAL_STACK + ')'); - -// check for full engine support (use string 'subarray' to avoid closure compiler confusion) -assert(typeof Int32Array !== 'undefined' && typeof Float64Array !== 'undefined' && Int32Array.prototype.subarray !== undefined && Int32Array.prototype.set !== undefined, - 'JS engine does not provide full typed array support'); - - - - - - -// In standalone mode, the wasm creates the memory, and the user can't provide it. -// In non-standalone/normal mode, we create the memory here. - -// Create the main memory. (Note: this isn't used in STANDALONE_WASM mode since the wasm -// memory is created in the wasm, not in JS.) +if (Module["TOTAL_STACK"]) assert(TOTAL_STACK === Module["TOTAL_STACK"], "the stack size can no longer be determined at runtime"); +var INITIAL_TOTAL_MEMORY = Module["TOTAL_MEMORY"] || 268435456; +if (!Object.getOwnPropertyDescriptor(Module, "TOTAL_MEMORY")) Object.defineProperty(Module, "TOTAL_MEMORY", { + configurable: true, + get: (function() { + abort("Module.TOTAL_MEMORY has been replaced with plain INITIAL_TOTAL_MEMORY"); + }) +}); +assert(INITIAL_TOTAL_MEMORY >= TOTAL_STACK, "TOTAL_MEMORY should be larger than TOTAL_STACK, was " + INITIAL_TOTAL_MEMORY + "! (TOTAL_STACK=" + TOTAL_STACK + ")"); +assert(typeof Int32Array !== "undefined" && typeof Float64Array !== "undefined" && Int32Array.prototype.subarray !== undefined && Int32Array.prototype.set !== undefined, "JS engine does not provide full typed array support"); if (ENVIRONMENT_IS_PTHREAD) { - wasmMemory = Module['wasmMemory']; - buffer = Module['buffer']; + wasmMemory = Module["wasmMemory"]; + buffer = Module["buffer"]; } else { - - if (Module['wasmMemory']) { - wasmMemory = Module['wasmMemory']; - } else - { - wasmMemory = new WebAssembly.Memory({ - 'initial': INITIAL_TOTAL_MEMORY / WASM_PAGE_SIZE - , - 'maximum': INITIAL_TOTAL_MEMORY / WASM_PAGE_SIZE - , - 'shared': true - }); - if (!(wasmMemory.buffer instanceof SharedArrayBuffer)) { - err('requested a shared WebAssembly.Memory but the returned buffer is not a SharedArrayBuffer, indicating that while the browser has SharedArrayBuffer it does not have WebAssembly threads support - you may need to set a flag'); - if (ENVIRONMENT_HAS_NODE) { - console.log('(on node you may need: --experimental-wasm-threads --experimental-wasm-bulk-memory and also use a recent version)'); - } - throw Error('bad memory'); - } - } - + if (Module["wasmMemory"]) { + wasmMemory = Module["wasmMemory"]; + } else { + wasmMemory = new WebAssembly.Memory({ + "initial": INITIAL_TOTAL_MEMORY / WASM_PAGE_SIZE, + "maximum": 1073741824 / WASM_PAGE_SIZE, + "shared": true + }); + if (!(wasmMemory.buffer instanceof SharedArrayBuffer)) { + err("requested a shared WebAssembly.Memory but the returned buffer is not a SharedArrayBuffer, indicating that while the browser has SharedArrayBuffer it does not have WebAssembly threads support - you may need to set a flag"); + if (ENVIRONMENT_HAS_NODE) { + console.log("(on node you may need: --experimental-wasm-threads --experimental-wasm-bulk-memory and also use a recent version)"); + } + throw Error("bad memory"); + } + } } - if (wasmMemory) { - buffer = wasmMemory.buffer; + buffer = wasmMemory.buffer; } - -// If the user provides an incorrect length, just use that length instead rather than providing the user to -// specifically provide the memory length with Module['TOTAL_MEMORY']. INITIAL_TOTAL_MEMORY = buffer.byteLength; assert(INITIAL_TOTAL_MEMORY % WASM_PAGE_SIZE === 0); +assert(65536 % WASM_PAGE_SIZE === 0); updateGlobalBufferAndViews(buffer); - -if (!ENVIRONMENT_IS_PTHREAD) { // Pthreads have already initialized these variables in src/worker.js, where they were passed to the thread worker at startup time -HEAP32[DYNAMICTOP_PTR>>2] = DYNAMIC_BASE; +if (!ENVIRONMENT_IS_PTHREAD) { + GROWABLE_HEAP_STORE_I32(DYNAMICTOP_PTR | 0, DYNAMIC_BASE); } - - - - -// Initializes the stack cookie. Called at the startup of main and at the startup of each thread in pthreads mode. function writeStackCookie() { - assert((STACK_MAX & 3) == 0); - // The stack grows downwards - HEAPU32[(STACK_MAX >> 2)+1] = 0x02135467; - HEAPU32[(STACK_MAX >> 2)+2] = 0x89BACDFE; - // Also test the global address 0 for integrity. - // We don't do this with ASan because ASan does its own checks for this. - HEAP32[0] = 0x63736d65; /* 'emsc' */ + assert((STACK_MAX & 3) == 0); + GROWABLE_HEAP_STORE_I32(((STACK_MAX >> 2) + 1) * 4 | 0, 34821223); + GROWABLE_HEAP_STORE_I32(((STACK_MAX >> 2) + 2) * 4 | 0, 2310721022); + GROWABLE_HEAP_STORE_I32(0 * 4 | 0, 1668509029); } - function checkStackCookie() { - var cookie1 = HEAPU32[(STACK_MAX >> 2)+1]; - var cookie2 = HEAPU32[(STACK_MAX >> 2)+2]; - if (cookie1 != 0x02135467 || cookie2 != 0x89BACDFE) { - abort('Stack overflow! Stack cookie has been overwritten, expected hex dwords 0x89BACDFE and 0x02135467, but received 0x' + cookie2.toString(16) + ' ' + cookie1.toString(16)); - } - // Also test the global address 0 for integrity. - // We don't do this with ASan because ASan does its own checks for this. - if (HEAP32[0] !== 0x63736d65 /* 'emsc' */) abort('Runtime error: The application has corrupted its heap memory area (address zero)!'); + var cookie1 = GROWABLE_HEAP_LOAD_U32(((STACK_MAX >> 2) + 1) * 4 | 0); + var cookie2 = GROWABLE_HEAP_LOAD_U32(((STACK_MAX >> 2) + 2) * 4 | 0); + if (cookie1 != 34821223 || cookie2 != 2310721022) { + abort("Stack overflow! Stack cookie has been overwritten, expected hex dwords 0x89BACDFE and 0x02135467, but received 0x" + cookie2.toString(16) + " " + cookie1.toString(16)); + } + if (GROWABLE_HEAP_LOAD_I32(0 * 4 | 0) !== 1668509029) abort("Runtime error: The application has corrupted its heap memory area (address zero)!"); } - function abortStackOverflow(allocSize) { - abort('Stack overflow! Attempted to allocate ' + allocSize + ' bytes on the stack, but stack has only ' + (STACK_MAX - stackSave() + allocSize) + ' bytes available!'); + abort("Stack overflow! Attempted to allocate " + allocSize + " bytes on the stack, but stack has only " + (STACK_MAX - stackSave() + allocSize) + " bytes available!"); } - - - - -// Endianness check (note: assumes compiler arch was little-endian) -(function() { - var h16 = new Int16Array(1); - var h8 = new Int8Array(h16.buffer); - h16[0] = 0x6373; - if (h8[0] !== 0x73 || h8[1] !== 0x63) throw 'Runtime error: expected the system to be little-endian!'; -})(); - +((function() { + var h16 = new Int16Array(1); + var h8 = new Int8Array(h16.buffer); + h16[0] = 25459; + if (h8[0] !== 115 || h8[1] !== 99) throw "Runtime error: expected the system to be little-endian!"; +}))(); function abortFnPtrError(ptr, sig) { - abort("Invalid function pointer " + ptr + " called with signature '" + sig + "'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this). Build with ASSERTIONS=2 for more info."); + abort("Invalid function pointer " + ptr + " called with signature '" + sig + "'. Perhaps this is an invalid value (e.g. caused by calling a virtual method on a NULL pointer)? Or calling a function with an incorrect type, which will fail? (it is worth building your source files with -Werror (warnings are errors), as warnings can indicate undefined behavior which can cause this). Build with ASSERTIONS=2 for more info."); } - - - function callRuntimeCallbacks(callbacks) { - while(callbacks.length > 0) { - var callback = callbacks.shift(); - if (typeof callback == 'function') { - callback(); - continue; - } - var func = callback.func; - if (typeof func === 'number') { - if (callback.arg === undefined) { - Module['dynCall_v'](func); - } else { - Module['dynCall_vi'](func, callback.arg); - } - } else { - func(callback.arg === undefined ? null : callback.arg); - } + while (callbacks.length > 0) { + var callback = callbacks.shift(); + if (typeof callback == "function") { + callback(); + continue; + } + var func = callback.func; + if (typeof func === "number") { + if (callback.arg === undefined) { + Module["dynCall_v"](func); + } else { + Module["dynCall_vi"](func, callback.arg); + } + } else { + func(callback.arg === undefined ? null : callback.arg); } + } } - -var __ATPRERUN__ = []; // functions called before the runtime is initialized -var __ATINIT__ = []; // functions called during startup -var __ATMAIN__ = []; // functions called when main() is to be run -var __ATEXIT__ = []; // functions called during shutdown -var __ATPOSTRUN__ = []; // functions called after the main() is called - +var __ATPRERUN__ = []; +var __ATINIT__ = []; +var __ATMAIN__ = []; +var __ATEXIT__ = []; +var __ATPOSTRUN__ = []; var runtimeInitialized = false; var runtimeExited = false; - -if (ENVIRONMENT_IS_PTHREAD) runtimeInitialized = true; // The runtime is hosted in the main thread, and bits shared to pthreads via SharedArrayBuffer. No need to init again in pthread. - +if (ENVIRONMENT_IS_PTHREAD) runtimeInitialized = true; function preRun() { - if (ENVIRONMENT_IS_PTHREAD) return; // PThreads reuse the runtime from the main thread. - - if (Module['preRun']) { - if (typeof Module['preRun'] == 'function') Module['preRun'] = [Module['preRun']]; - while (Module['preRun'].length) { - addOnPreRun(Module['preRun'].shift()); - } - } - - callRuntimeCallbacks(__ATPRERUN__); + if (ENVIRONMENT_IS_PTHREAD) return; + if (Module["preRun"]) { + if (typeof Module["preRun"] == "function") Module["preRun"] = [ Module["preRun"] ]; + while (Module["preRun"].length) { + addOnPreRun(Module["preRun"].shift()); + } + } + callRuntimeCallbacks(__ATPRERUN__); } - function initRuntime() { - checkStackCookie(); - assert(!runtimeInitialized); - runtimeInitialized = true; - if (!Module["noFSInit"] && !FS.init.initialized) FS.init(); -TTY.init(); - callRuntimeCallbacks(__ATINIT__); + checkStackCookie(); + assert(!runtimeInitialized); + runtimeInitialized = true; + if (!Module["noFSInit"] && !FS.init.initialized) FS.init(); + TTY.init(); + callRuntimeCallbacks(__ATINIT__); } - function preMain() { - checkStackCookie(); - if (ENVIRONMENT_IS_PTHREAD) return; // PThreads reuse the runtime from the main thread. - FS.ignorePermissions = false; - callRuntimeCallbacks(__ATMAIN__); + checkStackCookie(); + if (ENVIRONMENT_IS_PTHREAD) return; + FS.ignorePermissions = false; + callRuntimeCallbacks(__ATMAIN__); } - function exitRuntime() { - checkStackCookie(); - if (ENVIRONMENT_IS_PTHREAD) return; // PThreads reuse the runtime from the main thread. - runtimeExited = true; + checkStackCookie(); + if (ENVIRONMENT_IS_PTHREAD) return; + runtimeExited = true; } - function postRun() { - checkStackCookie(); - if (ENVIRONMENT_IS_PTHREAD) return; // PThreads reuse the runtime from the main thread. - - if (Module['postRun']) { - if (typeof Module['postRun'] == 'function') Module['postRun'] = [Module['postRun']]; - while (Module['postRun'].length) { - addOnPostRun(Module['postRun'].shift()); - } - } - - callRuntimeCallbacks(__ATPOSTRUN__); + checkStackCookie(); + if (ENVIRONMENT_IS_PTHREAD) return; + if (Module["postRun"]) { + if (typeof Module["postRun"] == "function") Module["postRun"] = [ Module["postRun"] ]; + while (Module["postRun"].length) { + addOnPostRun(Module["postRun"].shift()); + } + } + callRuntimeCallbacks(__ATPOSTRUN__); } - function addOnPreRun(cb) { - __ATPRERUN__.unshift(cb); + __ATPRERUN__.unshift(cb); } - function addOnInit(cb) { - __ATINIT__.unshift(cb); + __ATINIT__.unshift(cb); } - function addOnPreMain(cb) { - __ATMAIN__.unshift(cb); -} - -function addOnExit(cb) { + __ATMAIN__.unshift(cb); } - +function addOnExit(cb) {} function addOnPostRun(cb) { - __ATPOSTRUN__.unshift(cb); + __ATPOSTRUN__.unshift(cb); } - function unSign(value, bits, ignore) { - if (value >= 0) { - return value; - } - return bits <= 32 ? 2*Math.abs(1 << (bits-1)) + value // Need some trickery, since if bits == 32, we are right at the limit of the bits JS uses in bitshifts - : Math.pow(2, bits) + value; + if (value >= 0) { + return value; + } + return bits <= 32 ? 2 * Math.abs(1 << bits - 1) + value : Math.pow(2, bits) + value; } function reSign(value, bits, ignore) { - if (value <= 0) { - return value; - } - var half = bits <= 32 ? Math.abs(1 << (bits-1)) // abs is needed if bits == 32 - : Math.pow(2, bits-1); - if (value >= half && (bits <= 32 || value > half)) { // for huge values, we can hit the precision limit and always get true here. so don't do that - // but, in general there is no perfect solution here. With 64-bit ints, we get rounding and errors - // TODO: In i64 mode 1, resign the two parts separately and safely - value = -2*half + value; // Cannot bitshift half, as it may be at the limit of the bits JS uses in bitshifts - } + if (value <= 0) { return value; + } + var half = bits <= 32 ? Math.abs(1 << bits - 1) : Math.pow(2, bits - 1); + if (value >= half && (bits <= 32 || value > half)) { + value = -2 * half + value; + } + return value; } - - -assert(Math.imul, 'This browser does not support Math.imul(), build with LEGACY_VM_SUPPORT or POLYFILL_OLD_MATH_FUNCTIONS to add in a polyfill'); -assert(Math.fround, 'This browser does not support Math.fround(), build with LEGACY_VM_SUPPORT or POLYFILL_OLD_MATH_FUNCTIONS to add in a polyfill'); -assert(Math.clz32, 'This browser does not support Math.clz32(), build with LEGACY_VM_SUPPORT or POLYFILL_OLD_MATH_FUNCTIONS to add in a polyfill'); -assert(Math.trunc, 'This browser does not support Math.trunc(), build with LEGACY_VM_SUPPORT or POLYFILL_OLD_MATH_FUNCTIONS to add in a polyfill'); - +assert(Math.imul, "This browser does not support Math.imul(), build with LEGACY_VM_SUPPORT or POLYFILL_OLD_MATH_FUNCTIONS to add in a polyfill"); +assert(Math.fround, "This browser does not support Math.fround(), build with LEGACY_VM_SUPPORT or POLYFILL_OLD_MATH_FUNCTIONS to add in a polyfill"); +assert(Math.clz32, "This browser does not support Math.clz32(), build with LEGACY_VM_SUPPORT or POLYFILL_OLD_MATH_FUNCTIONS to add in a polyfill"); +assert(Math.trunc, "This browser does not support Math.trunc(), build with LEGACY_VM_SUPPORT or POLYFILL_OLD_MATH_FUNCTIONS to add in a polyfill"); var Math_abs = Math.abs; var Math_cos = Math.cos; var Math_sin = Math.sin; @@ -1597,7625 +1196,7562 @@ var Math_min = Math.min; var Math_max = Math.max; var Math_clz32 = Math.clz32; var Math_trunc = Math.trunc; - - - -// A counter of dependencies for calling run(). If we need to -// do asynchronous work before running, increment this and -// decrement it. Incrementing must happen in a place like -// Module.preRun (used by emcc to add file preloading). -// Note that you can add dependencies in preRun, even though -// it happens right before run - run will be postponed until -// the dependencies are met. var runDependencies = 0; var runDependencyWatcher = null; -var dependenciesFulfilled = null; // overridden to take different actions when all run dependencies are fulfilled +var dependenciesFulfilled = null; var runDependencyTracking = {}; - function getUniqueRunDependency(id) { - var orig = id; - while (1) { - if (!runDependencyTracking[id]) return id; - id = orig + Math.random(); - } - return id; + var orig = id; + while (1) { + if (!runDependencyTracking[id]) return id; + id = orig + Math.random(); + } + return id; } - function addRunDependency(id) { - // We should never get here in pthreads (could no-op this out if called in pthreads, but that might indicate a bug in caller side, - // so good to be very explicit) - assert(!ENVIRONMENT_IS_PTHREAD, "addRunDependency cannot be used in a pthread worker"); - runDependencies++; - - if (Module['monitorRunDependencies']) { - Module['monitorRunDependencies'](runDependencies); - } - - if (id) { - assert(!runDependencyTracking[id]); - runDependencyTracking[id] = 1; - if (runDependencyWatcher === null && typeof setInterval !== 'undefined') { - // Check for missing dependencies every few seconds - runDependencyWatcher = setInterval(function() { - if (ABORT) { - clearInterval(runDependencyWatcher); - runDependencyWatcher = null; - return; - } - var shown = false; - for (var dep in runDependencyTracking) { - if (!shown) { - shown = true; - err('still waiting on run dependencies:'); - } - err('dependency: ' + dep); - } - if (shown) { - err('(end of list)'); - } - }, 10000); + assert(!ENVIRONMENT_IS_PTHREAD, "addRunDependency cannot be used in a pthread worker"); + runDependencies++; + if (Module["monitorRunDependencies"]) { + Module["monitorRunDependencies"](runDependencies); + } + if (id) { + assert(!runDependencyTracking[id]); + runDependencyTracking[id] = 1; + if (runDependencyWatcher === null && typeof setInterval !== "undefined") { + runDependencyWatcher = setInterval((function() { + if (ABORT) { + clearInterval(runDependencyWatcher); + runDependencyWatcher = null; + return; } - } else { - err('warning: run dependency added without ID'); - } -} - -function removeRunDependency(id) { - runDependencies--; - - if (Module['monitorRunDependencies']) { - Module['monitorRunDependencies'](runDependencies); - } - - if (id) { - assert(runDependencyTracking[id]); - delete runDependencyTracking[id]; - } else { - err('warning: run dependency removed without ID'); - } - if (runDependencies == 0) { - if (runDependencyWatcher !== null) { - clearInterval(runDependencyWatcher); - runDependencyWatcher = null; + var shown = false; + for (var dep in runDependencyTracking) { + if (!shown) { + shown = true; + err("still waiting on run dependencies:"); + } + err("dependency: " + dep); } - if (dependenciesFulfilled) { - var callback = dependenciesFulfilled; - dependenciesFulfilled = null; - callback(); // can add another dependenciesFulfilled + if (shown) { + err("(end of list)"); } + }), 1e4); } + } else { + err("warning: run dependency added without ID"); + } } - -Module["preloadedImages"] = {}; // maps url to image data -Module["preloadedAudios"] = {}; // maps url to audio data - - +function removeRunDependency(id) { + runDependencies--; + if (Module["monitorRunDependencies"]) { + Module["monitorRunDependencies"](runDependencies); + } + if (id) { + assert(runDependencyTracking[id]); + delete runDependencyTracking[id]; + } else { + err("warning: run dependency removed without ID"); + } + if (runDependencies == 0) { + if (runDependencyWatcher !== null) { + clearInterval(runDependencyWatcher); + runDependencyWatcher = null; + } + if (dependenciesFulfilled) { + var callback = dependenciesFulfilled; + dependenciesFulfilled = null; + callback(); + } + } +} +Module["preloadedImages"] = {}; +Module["preloadedAudios"] = {}; function abort(what) { - if (Module['onAbort']) { - Module['onAbort'](what); - } - - if (ENVIRONMENT_IS_PTHREAD) console.error('Pthread aborting at ' + new Error().stack); - what += ''; - out(what); - err(what); - - ABORT = true; - EXITSTATUS = 1; - - var output = 'abort(' + what + ') at ' + stackTrace(); - what = output; - - // Throw a wasm runtime error, because a JS error might be seen as a foreign - // exception, which means we'd run destructors on it. We need the error to - // simply make the program stop. - throw new WebAssembly.RuntimeError(what); + if (Module["onAbort"]) { + Module["onAbort"](what); + } + if (ENVIRONMENT_IS_PTHREAD) console.error("Pthread aborting at " + (new Error).stack); + what += ""; + out(what); + err(what); + ABORT = true; + EXITSTATUS = 1; + var output = "abort(" + what + ") at " + stackTrace(); + what = output; + throw new WebAssembly.RuntimeError(what); } - - var memoryInitializer = null; - - - - - - - -// Copyright 2017 The Emscripten Authors. All rights reserved. -// Emscripten is available under two separate licenses, the MIT license and the -// University of Illinois/NCSA Open Source License. Both these licenses can be -// found in the LICENSE file. - -// Prefix of data URIs emitted by SINGLE_FILE and related options. -var dataURIPrefix = 'data:application/octet-stream;base64,'; - -// Indicates whether filename is a base64 data URI. +var dataURIPrefix = "data:application/octet-stream;base64,"; function isDataURI(filename) { - return String.prototype.startsWith ? - filename.startsWith(dataURIPrefix) : - filename.indexOf(dataURIPrefix) === 0; + return String.prototype.startsWith ? filename.startsWith(dataURIPrefix) : filename.indexOf(dataURIPrefix) === 0; } - - - - -var wasmBinaryFile = 'x2t.wasm'; +var wasmBinaryFile = "x2t.wasm"; if (!isDataURI(wasmBinaryFile)) { - wasmBinaryFile = locateFile(wasmBinaryFile); + wasmBinaryFile = locateFile(wasmBinaryFile); } - function getBinary() { - try { - if (wasmBinary) { - return new Uint8Array(wasmBinary); - } - - if (readBinary) { - return readBinary(wasmBinaryFile); - } else { - throw "both async and sync fetching of the wasm failed"; - } + try { + if (wasmBinary) { + return new Uint8Array(wasmBinary); } - catch (err) { - abort(err); + if (readBinary) { + return readBinary(wasmBinaryFile); + } else { + throw "both async and sync fetching of the wasm failed"; } + } catch (err) { + abort(err); + } } - function getBinaryPromise() { - // if we don't have the binary yet, and have the Fetch api, use that - // in some environments, like Electron's render process, Fetch api may be present, but have a different context than expected, let's only use it on the Web - if (!wasmBinary && (ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER) && typeof fetch === 'function') { - return fetch(wasmBinaryFile, { credentials: 'same-origin' }).then(function(response) { - if (!response['ok']) { - throw "failed to load wasm binary file at '" + wasmBinaryFile + "'"; - } - return response['arrayBuffer'](); - }).catch(function () { - return getBinary(); - }); - } - // Otherwise, getBinary should be able to get it synchronously - return new Promise(function(resolve, reject) { - resolve(getBinary()); - }); + if (!wasmBinary && (ENVIRONMENT_IS_WEB || ENVIRONMENT_IS_WORKER) && typeof fetch === "function") { + return fetch(wasmBinaryFile, { + credentials: "same-origin" + }).then((function(response) { + if (!response["ok"]) { + throw "failed to load wasm binary file at '" + wasmBinaryFile + "'"; + } + return response["arrayBuffer"](); + })).catch((function() { + return getBinary(); + })); + } + return new Promise((function(resolve, reject) { + resolve(getBinary()); + })); } - - - -// Create the wasm instance. -// Receives the wasm imports, returns the exports. function createWasm() { - // prepare imports - var info = { - 'env': asmLibraryArg, - 'wasi_unstable': asmLibraryArg - }; - // Load the wasm module and create an instance of using native support in the JS engine. - // handle a generated wasm instance, receiving its exports and - // performing other necessary setup - function receiveInstance(instance, module) { - var exports = instance.exports; - Module['asm'] = exports; - // Keep a reference to the compiled module so we can post it to the workers. - wasmModule = module; - // Instantiation is synchronous in pthreads and we assert on run dependencies. - if (!ENVIRONMENT_IS_PTHREAD) removeRunDependency('wasm-instantiate'); - } - // we can't run yet (except in a pthread, where we have a custom sync instantiator) - if (!ENVIRONMENT_IS_PTHREAD) { addRunDependency('wasm-instantiate'); } - - - // Async compilation can be confusing when an error on the page overwrites Module - // (for example, if the order of elements is wrong, and the one defining Module is - // later), so we save Module and check it later. - var trueModule = Module; - function receiveInstantiatedSource(output) { - // 'output' is a WebAssemblyInstantiatedSource object which has both the module and instance. - // receiveInstance() will swap in the exports (to Module.asm) so they can be called - assert(Module === trueModule, 'the Module object should not be replaced during async compilation - perhaps the order of HTML elements is wrong?'); - trueModule = null; - receiveInstance(output['instance'], output['module']); - } - - - function instantiateArrayBuffer(receiver) { - return getBinaryPromise().then(function(binary) { - return WebAssembly.instantiate(binary, info); - }).then(receiver, function(reason) { - err('failed to asynchronously prepare wasm: ' + reason); - abort(reason); - }); - } - - // Prefer streaming instantiation if available. - function instantiateAsync() { - if (!wasmBinary && - typeof WebAssembly.instantiateStreaming === 'function' && - !isDataURI(wasmBinaryFile) && - typeof fetch === 'function') { - fetch(wasmBinaryFile, { credentials: 'same-origin' }).then(function (response) { - var result = WebAssembly.instantiateStreaming(response, info); - return result.then(receiveInstantiatedSource, function(reason) { - // We expect the most common failure cause to be a bad MIME type for the binary, - // in which case falling back to ArrayBuffer instantiation should work. - err('wasm streaming compile failed: ' + reason); - err('falling back to ArrayBuffer instantiation'); - instantiateArrayBuffer(receiveInstantiatedSource); - }); - }); - } else { - return instantiateArrayBuffer(receiveInstantiatedSource); - } + var info = { + "env": asmLibraryArg, + "wasi_unstable": asmLibraryArg + }; + function receiveInstance(instance, module) { + var exports = instance.exports; + Module["asm"] = exports; + wasmModule = module; + if (!ENVIRONMENT_IS_PTHREAD) removeRunDependency("wasm-instantiate"); + } + if (!ENVIRONMENT_IS_PTHREAD) { + addRunDependency("wasm-instantiate"); + } + var trueModule = Module; + function receiveInstantiatedSource(output) { + assert(Module === trueModule, "the Module object should not be replaced during async compilation - perhaps the order of HTML elements is wrong?"); + trueModule = null; + receiveInstance(output["instance"], output["module"]); + } + function instantiateArrayBuffer(receiver) { + return getBinaryPromise().then((function(binary) { + return WebAssembly.instantiate(binary, info); + })).then(receiver, (function(reason) { + err("failed to asynchronously prepare wasm: " + reason); + abort(reason); + })); + } + function instantiateAsync() { + if (!wasmBinary && typeof WebAssembly.instantiateStreaming === "function" && !isDataURI(wasmBinaryFile) && typeof fetch === "function") { + fetch(wasmBinaryFile, { + credentials: "same-origin" + }).then((function(response) { + var result = WebAssembly.instantiateStreaming(response, info); + return result.then(receiveInstantiatedSource, (function(reason) { + err("wasm streaming compile failed: " + reason); + err("falling back to ArrayBuffer instantiation"); + instantiateArrayBuffer(receiveInstantiatedSource); + })); + })); + } else { + return instantiateArrayBuffer(receiveInstantiatedSource); } - // User shell pages can write their own Module.instantiateWasm = function(imports, successCallback) callback - // to manually instantiate the Wasm module themselves. This allows pages to run the instantiation parallel - // to any other async startup actions they are performing. - if (Module['instantiateWasm']) { - try { - var exports = Module['instantiateWasm'](info, receiveInstance); - return exports; - } catch(e) { - err('Module.instantiateWasm callback failed with error: ' + e); - return false; - } + } + if (Module["instantiateWasm"]) { + try { + var exports = Module["instantiateWasm"](info, receiveInstance); + return exports; + } catch (e) { + err("Module.instantiateWasm callback failed with error: " + e); + return false; } - - instantiateAsync(); - return {}; // no exports yet; we'll fill them in later + } + instantiateAsync(); + return {}; } - - -// Globals used by JS i64 conversions var tempDouble; var tempI64; - -// === Body === - var ASM_CONSTS = { - 55680: function() {FS.mkdir('/working'); FS.mount(NODEFS, { root: '.' }, '/working');}, - 10774936: function() {throw 'Canceled!'}, - 10775075: function() {postMessage({cmd : 'processQueuedMainThreadWork'})}, - 10775126: function($0) {if (!ENVIRONMENT_IS_PTHREAD) { if (!PThread.pthreads[$0] || !PThread.pthreads[$0].worker) { return 0; } PThread.pthreads[$0].worker.postMessage({cmd : 'processThreadQueue'}); } else { postMessage({targetThread : $0, cmd : 'processThreadQueue'}); } return 1;}, - 10775494: function() {return !!(Module['canvas'])}, - 10775530: function() {noExitRuntime = true} + 55680: (function() { + FS.mkdir("/working"); + FS.mount(NODEFS, { + root: "." + }, "/working"); + }), + 10774952: (function() { + throw "Canceled!"; + }), + 10775091: (function() { + postMessage({ + cmd: "processQueuedMainThreadWork" + }); + }), + 10775142: (function($0) { + if (!ENVIRONMENT_IS_PTHREAD) { + if (!PThread.pthreads[$0] || !PThread.pthreads[$0].worker) { + return 0; + } + PThread.pthreads[$0].worker.postMessage({ + cmd: "processThreadQueue" + }); + } else { + postMessage({ + targetThread: $0, + cmd: "processThreadQueue" + }); + } + return 1; + }), + 10775510: (function() { + return !!Module["canvas"]; + }), + 10775546: (function() { + noExitRuntime = true; + }) }; - -// Avoid creating a new array var _readAsmConstArgsArray = []; - function readAsmConstArgs(sigPtr, buf) { - var args = _readAsmConstArgsArray; - args.length = 0; - while (1) { - var ch = HEAPU8[sigPtr++]; - if (!ch) return args; - if (ch === 'd'.charCodeAt(0) || ch === 'f'.charCodeAt(0)) { - buf = alignMemory(buf, 8); - args.push(HEAPF64[(buf >> 3)]); - buf += 8; - } else if (ch === 'i'.charCodeAt(0)) { - buf = alignMemory(buf, 4); - args.push(HEAP32[(buf >> 2)]); - buf += 4; - } else abort("unexpected char in asm const signature " + ch); - } + var args = _readAsmConstArgsArray; + args.length = 0; + while (1) { + var ch = GROWABLE_HEAP_LOAD_U8(sigPtr++ | 0); + if (!ch) return args; + if (ch === "d".charCodeAt(0) || ch === "f".charCodeAt(0)) { + buf = alignMemory(buf, 8); + args.push(GROWABLE_HEAP_LOAD_F64(buf | 0)); + buf += 8; + } else if (ch === "i".charCodeAt(0)) { + buf = alignMemory(buf, 4); + args.push(GROWABLE_HEAP_LOAD_I32(buf | 0)); + buf += 4; + } else abort("unexpected char in asm const signature " + ch); + } } - - function _emscripten_asm_const_iii(code, sigPtr, argbuf) { - var args = readAsmConstArgs(sigPtr, argbuf); - return ASM_CONSTS[code].apply(null, args); -}function initPthreadsJS(){ PThread.initRuntime(); } - - - -// STATICTOP = STATIC_BASE + 12594896; -/* global initializers */ if (!ENVIRONMENT_IS_PTHREAD) __ATINIT__.push({ func: function() { ___wasm_call_ctors() } }); - - - -/* no memory initializer */ -// {{PRE_LIBRARY}} - - - function demangle(func) { - warnOnce('warning: build with -s DEMANGLE_SUPPORT=1 to link in libcxxabi demangling'); - return func; + var args = readAsmConstArgs(sigPtr, argbuf); + return ASM_CONSTS[code].apply(null, args); +} +function initPthreadsJS() { + PThread.initRuntime(); +} +if (!ENVIRONMENT_IS_PTHREAD) __ATINIT__.push({ + func: (function() { + ___wasm_call_ctors(); + }) +}); +function demangle(func) { + warnOnce("warning: build with -s DEMANGLE_SUPPORT=1 to link in libcxxabi demangling"); + return func; +} +Module["demangle"] = demangle; +function demangleAll(text) { + var regex = /\b_Z[\w\d_]+/g; + return text.replace(regex, (function(x) { + var y = demangle(x); + return x === y ? x : y + " [" + x + "]"; + })); +} +Module["demangleAll"] = demangleAll; +function jsStackTrace() { + var err = new Error; + if (!err.stack) { + try { + throw new Error(0); + } catch (e) { + err = e; + } + if (!err.stack) { + return "(no stack trace available)"; + } + } + return err.stack.toString(); +} +Module["jsStackTrace"] = jsStackTrace; +function stackTrace() { + var js = jsStackTrace(); + if (Module["extraStackTrace"]) js += "\n" + Module["extraStackTrace"](); + return demangleAll(js); +} +Module["stackTrace"] = stackTrace; +function __ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE() { + err("missing function: _ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"); + abort(-1); +} +Module["__ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; +function __ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE() { + err("missing function: _ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"); + abort(-1); +} +Module["__ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; +function __ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE() { + err("missing function: _ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"); + abort(-1); +} +Module["__ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; +function __ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE() { + err("missing function: _ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"); + abort(-1); +} +Module["__ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; +function __ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE() { + err("missing function: _ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"); + abort(-1); +} +Module["__ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; +function __ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb() { + err("missing function: _ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb"); + abort(-1); +} +Module["__ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb"] = __ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb; +function __ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb() { + err("missing function: _ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb"); + abort(-1); +} +Module["__ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb"] = __ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb; +function __ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb() { + err("missing function: _ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb"); + abort(-1); +} +Module["__ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb"] = __ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb; +function __ZN12CPdfRendererD1Ev() { + err("missing function: _ZN12CPdfRendererD1Ev"); + abort(-1); +} +Module["__ZN12CPdfRendererD1Ev"] = __ZN12CPdfRendererD1Ev; +function __ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv() { + err("missing function: _ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv"); + abort(-1); +} +Module["__ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv"] = __ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv; +function __ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_() { + err("missing function: _ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_"); + abort(-1); +} +Module["__ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_"] = __ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_; +function __ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE() { + err("missing function: _ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE"); + abort(-1); +} +Module["__ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE"] = __ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE; +function __ZN14NSDoctRenderer13CDoctrendererD1Ev() { + err("missing function: _ZN14NSDoctRenderer13CDoctrendererD1Ev"); + abort(-1); +} +Module["__ZN14NSDoctRenderer13CDoctrendererD1Ev"] = __ZN14NSDoctRenderer13CDoctrendererD1Ev; +function __ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_() { + err("missing function: _ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_"); + abort(-1); +} +Module["__ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_"] = __ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_; +function __ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb() { + err("missing function: _ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb"); + abort(-1); +} +Module["__ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb"] = __ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb; +function __ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev() { + err("missing function: _ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev"); + abort(-1); +} +Module["__ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev"] = __ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev; +function __ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev() { + err("missing function: _ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev"); + abort(-1); +} +Module["__ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev"] = __ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev; +function __ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb() { + err("missing function: _ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb"); + abort(-1); +} +Module["__ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb"] = __ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb; +function __ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE() { + err("missing function: _ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE"); + abort(-1); +} +Module["__ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE"] = __ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE; +function __ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE() { + err("missing function: _ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE"); + abort(-1); +} +Module["__ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE"] = __ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE; +function __ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_() { + err("missing function: _ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_"); + abort(-1); +} +Module["__ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_"] = __ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_; +function __ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_() { + err("missing function: _ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_"); + abort(-1); +} +Module["__ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_"] = __ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_; +function __ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_() { + err("missing function: _ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_"); + abort(-1); +} +Module["__ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_"] = __ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_; +function __ZN9CHtmlFileC1Ev() { + err("missing function: _ZN9CHtmlFileC1Ev"); + abort(-1); +} +Module["__ZN9CHtmlFileC1Ev"] = __ZN9CHtmlFileC1Ev; +function __ZN9CHtmlFileD1Ev() { + err("missing function: _ZN9CHtmlFileD1Ev"); + abort(-1); +} +Module["__ZN9CHtmlFileD1Ev"] = __ZN9CHtmlFileD1Ev; +function __ZN9PdfReader10CPdfReader8GetErrorEv() { + err("missing function: _ZN9PdfReader10CPdfReader8GetErrorEv"); + abort(-1); +} +Module["__ZN9PdfReader10CPdfReader8GetErrorEv"] = __ZN9PdfReader10CPdfReader8GetErrorEv; +function __ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE() { + err("missing function: _ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE"); + abort(-1); +} +Module["__ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE"] = __ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE; +function ___assert_fail(condition, filename, line, func) { + abort("Assertion failed: " + UTF8ToString(condition) + ", at: " + [ filename ? UTF8ToString(filename) : "unknown filename", line, func ? UTF8ToString(func) : "unknown function" ]); +} +Module["___assert_fail"] = ___assert_fail; +var PROCINFO = { + ppid: 1, + pid: 42, + sid: 42, + pgid: 42 +}; +Module["PROCINFO"] = PROCINFO; +var __pthread_ptr = 0; +Module["__pthread_ptr"] = __pthread_ptr; +var __pthread_is_main_runtime_thread = 0; +Module["__pthread_is_main_runtime_thread"] = __pthread_is_main_runtime_thread; +var __pthread_is_main_browser_thread = 0; +Module["__pthread_is_main_browser_thread"] = __pthread_is_main_browser_thread; +function __register_pthread_ptr(pthreadPtr, isMainBrowserThread, isMainRuntimeThread) { + pthreadPtr = pthreadPtr | 0; + isMainBrowserThread = isMainBrowserThread | 0; + isMainRuntimeThread = isMainRuntimeThread | 0; + __pthread_ptr = pthreadPtr; + __pthread_is_main_browser_thread = isMainBrowserThread; + __pthread_is_main_runtime_thread = isMainRuntimeThread; +} +Module["__register_pthread_ptr"] = __register_pthread_ptr; +var ERRNO_CODES = { + EPERM: 63, + ENOENT: 44, + ESRCH: 71, + EINTR: 27, + EIO: 29, + ENXIO: 60, + E2BIG: 1, + ENOEXEC: 45, + EBADF: 8, + ECHILD: 12, + EAGAIN: 6, + EWOULDBLOCK: 6, + ENOMEM: 48, + EACCES: 2, + EFAULT: 21, + ENOTBLK: 105, + EBUSY: 10, + EEXIST: 20, + EXDEV: 75, + ENODEV: 43, + ENOTDIR: 54, + EISDIR: 31, + EINVAL: 28, + ENFILE: 41, + EMFILE: 33, + ENOTTY: 59, + ETXTBSY: 74, + EFBIG: 22, + ENOSPC: 51, + ESPIPE: 70, + EROFS: 69, + EMLINK: 34, + EPIPE: 64, + EDOM: 18, + ERANGE: 68, + ENOMSG: 49, + EIDRM: 24, + ECHRNG: 106, + EL2NSYNC: 156, + EL3HLT: 107, + EL3RST: 108, + ELNRNG: 109, + EUNATCH: 110, + ENOCSI: 111, + EL2HLT: 112, + EDEADLK: 16, + ENOLCK: 46, + EBADE: 113, + EBADR: 114, + EXFULL: 115, + ENOANO: 104, + EBADRQC: 103, + EBADSLT: 102, + EDEADLOCK: 16, + EBFONT: 101, + ENOSTR: 100, + ENODATA: 116, + ETIME: 117, + ENOSR: 118, + ENONET: 119, + ENOPKG: 120, + EREMOTE: 121, + ENOLINK: 47, + EADV: 122, + ESRMNT: 123, + ECOMM: 124, + EPROTO: 65, + EMULTIHOP: 36, + EDOTDOT: 125, + EBADMSG: 9, + ENOTUNIQ: 126, + EBADFD: 127, + EREMCHG: 128, + ELIBACC: 129, + ELIBBAD: 130, + ELIBSCN: 131, + ELIBMAX: 132, + ELIBEXEC: 133, + ENOSYS: 52, + ENOTEMPTY: 55, + ENAMETOOLONG: 37, + ELOOP: 32, + EOPNOTSUPP: 138, + EPFNOSUPPORT: 139, + ECONNRESET: 15, + ENOBUFS: 42, + EAFNOSUPPORT: 5, + EPROTOTYPE: 67, + ENOTSOCK: 57, + ENOPROTOOPT: 50, + ESHUTDOWN: 140, + ECONNREFUSED: 14, + EADDRINUSE: 3, + ECONNABORTED: 13, + ENETUNREACH: 40, + ENETDOWN: 38, + ETIMEDOUT: 73, + EHOSTDOWN: 142, + EHOSTUNREACH: 23, + EINPROGRESS: 26, + EALREADY: 7, + EDESTADDRREQ: 17, + EMSGSIZE: 35, + EPROTONOSUPPORT: 66, + ESOCKTNOSUPPORT: 137, + EADDRNOTAVAIL: 4, + ENETRESET: 39, + EISCONN: 30, + ENOTCONN: 53, + ETOOMANYREFS: 141, + EUSERS: 136, + EDQUOT: 19, + ESTALE: 72, + ENOTSUP: 138, + ENOMEDIUM: 148, + EILSEQ: 25, + EOVERFLOW: 61, + ECANCELED: 11, + ENOTRECOVERABLE: 56, + EOWNERDEAD: 62, + ESTRPIPE: 135 +}; +Module["ERRNO_CODES"] = ERRNO_CODES; +var __main_thread_futex_wait_address = 12595904; +Module["__main_thread_futex_wait_address"] = __main_thread_futex_wait_address; +function _emscripten_futex_wake(addr, count) { + if (addr <= 0 || addr > HEAP8.length || addr & 3 != 0 || count < 0) return -28; + if (count == 0) return 0; + if (count >= 2147483647) count = Infinity; + var mainThreadWaitAddress = Atomics.load(HEAP32, __main_thread_futex_wait_address >> 2); + var mainThreadWoken = 0; + if (mainThreadWaitAddress == addr) { + var loadedAddr = Atomics.compareExchange(HEAP32, __main_thread_futex_wait_address >> 2, mainThreadWaitAddress, 0); + if (loadedAddr == mainThreadWaitAddress) { + --count; + mainThreadWoken = 1; + if (count <= 0) return 1; + } + } + var ret = Atomics.notify(HEAP32, addr >> 2, count); + if (ret >= 0) return ret + mainThreadWoken; + throw "Atomics.notify returned an unexpected value " + ret; +} +Module["_emscripten_futex_wake"] = _emscripten_futex_wake; +function __kill_thread(pthread_ptr) { + if (ENVIRONMENT_IS_PTHREAD) throw "Internal Error! _kill_thread() can only ever be called from main application thread!"; + if (!pthread_ptr) throw "Internal Error! Null pthread_ptr in _kill_thread!"; + GROWABLE_HEAP_STORE_I32(pthread_ptr + 24 | 0, 0); + var pthread = PThread.pthreads[pthread_ptr]; + pthread.worker.terminate(); + PThread.freeThreadData(pthread); + PThread.runningWorkers.splice(PThread.runningWorkers.indexOf(pthread.worker), 1); + pthread.worker.pthread = undefined; +} +Module["__kill_thread"] = __kill_thread; +function __cancel_thread(pthread_ptr) { + if (ENVIRONMENT_IS_PTHREAD) throw "Internal Error! _cancel_thread() can only ever be called from main application thread!"; + if (!pthread_ptr) throw "Internal Error! Null pthread_ptr in _cancel_thread!"; + var pthread = PThread.pthreads[pthread_ptr]; + pthread.worker.postMessage({ + "cmd": "cancel" + }); +} +Module["__cancel_thread"] = __cancel_thread; +function __cleanup_thread(pthread_ptr) { + if (ENVIRONMENT_IS_PTHREAD) throw "Internal Error! _cleanup_thread() can only ever be called from main application thread!"; + if (!pthread_ptr) throw "Internal Error! Null pthread_ptr in _cleanup_thread!"; + GROWABLE_HEAP_STORE_I32(pthread_ptr + 24 | 0, 0); + var pthread = PThread.pthreads[pthread_ptr]; + if (pthread) { + var worker = pthread.worker; + PThread.returnWorkerToPool(worker); + } +} +Module["__cleanup_thread"] = __cleanup_thread; +var PThread = { + MAIN_THREAD_ID: 1, + mainThreadInfo: { + schedPolicy: 0, + schedPrio: 0 + }, + preallocatedWorkers: [], + unusedWorkers: [], + runningWorkers: [], + initRuntime: (function() { + __register_pthread_ptr(PThread.mainThreadBlock, !ENVIRONMENT_IS_WORKER, 1); + _emscripten_register_main_browser_thread_id(PThread.mainThreadBlock); + }), + initMainThreadBlock: (function() { + if (ENVIRONMENT_IS_PTHREAD) return undefined; + PThread.mainThreadBlock = 12595120; + for (var i = 0; i < 244 / 4; ++i) GROWABLE_HEAP_STORE_I32((PThread.mainThreadBlock / 4 + i) * 4 | 0, 0); + GROWABLE_HEAP_STORE_I32(PThread.mainThreadBlock + 24 | 0, PThread.mainThreadBlock); + var headPtr = PThread.mainThreadBlock + 168; + GROWABLE_HEAP_STORE_I32(headPtr | 0, headPtr); + var tlsMemory = 12595376; + for (var i = 0; i < 128; ++i) GROWABLE_HEAP_STORE_I32((tlsMemory / 4 + i) * 4 | 0, 0); + Atomics.store(HEAPU32, PThread.mainThreadBlock + 116 >> 2, tlsMemory); + Atomics.store(HEAPU32, PThread.mainThreadBlock + 52 >> 2, PThread.mainThreadBlock); + Atomics.store(HEAPU32, PThread.mainThreadBlock + 56 >> 2, PROCINFO.pid); + }), + initWorker: (function() {}), + pthreads: {}, + exitHandlers: null, + setThreadStatus: (function() {}), + runExitHandlers: (function() { + if (PThread.exitHandlers !== null) { + while (PThread.exitHandlers.length > 0) { + PThread.exitHandlers.pop()(); + } + PThread.exitHandlers = null; + } + if (ENVIRONMENT_IS_PTHREAD && threadInfoStruct) ___pthread_tsd_run_dtors(); + }), + threadExit: (function(exitCode) { + var tb = _pthread_self(); + if (tb) { + Atomics.store(HEAPU32, tb + 4 >> 2, exitCode); + Atomics.store(HEAPU32, tb + 0 >> 2, 1); + Atomics.store(HEAPU32, tb + 72 >> 2, 1); + Atomics.store(HEAPU32, tb + 76 >> 2, 0); + PThread.runExitHandlers(); + _emscripten_futex_wake(tb + 0, 2147483647); + __register_pthread_ptr(0, 0, 0); + threadInfoStruct = 0; + if (ENVIRONMENT_IS_PTHREAD) { + postMessage({ + "cmd": "exit" + }); + } + } + }), + threadCancel: (function() { + PThread.runExitHandlers(); + Atomics.store(HEAPU32, threadInfoStruct + 4 >> 2, -1); + Atomics.store(HEAPU32, threadInfoStruct + 0 >> 2, 1); + _emscripten_futex_wake(threadInfoStruct + 0, 2147483647); + threadInfoStruct = selfThreadId = 0; + __register_pthread_ptr(0, 0, 0); + postMessage({ + "cmd": "cancelDone" + }); + }), + terminateAllThreads: (function() { + for (var t in PThread.pthreads) { + var pthread = PThread.pthreads[t]; + if (pthread && pthread.worker) { + PThread.returnWorkerToPool(pthread.worker); + } + } + PThread.pthreads = {}; + for (var i = 0; i < PThread.preallocatedWorkers.length; ++i) { + var worker = PThread.preallocatedWorkers[i]; + assert(!worker.pthread); + worker.terminate(); + } + PThread.preallocatedWorkers = []; + for (var i = 0; i < PThread.unusedWorkers.length; ++i) { + var worker = PThread.unusedWorkers[i]; + assert(!worker.pthread); + worker.terminate(); + } + PThread.unusedWorkers = []; + for (var i = 0; i < PThread.runningWorkers.length; ++i) { + var worker = PThread.runningWorkers[i]; + var pthread = worker.pthread; + assert(pthread, "This Worker should have a pthread it is executing"); + PThread.freeThreadData(pthread); + worker.terminate(); + } + PThread.runningWorkers = []; + }), + freeThreadData: (function(pthread) { + if (!pthread) return; + if (pthread.threadInfoStruct) { + var tlsMemory = GROWABLE_HEAP_LOAD_I32(pthread.threadInfoStruct + 116 | 0); + GROWABLE_HEAP_STORE_I32(pthread.threadInfoStruct + 116 | 0, 0); + _free(tlsMemory); + _free(pthread.threadInfoStruct); + } + pthread.threadInfoStruct = 0; + if (pthread.allocatedOwnStack && pthread.stackBase) _free(pthread.stackBase); + pthread.stackBase = 0; + if (pthread.worker) pthread.worker.pthread = null; + }), + returnWorkerToPool: (function(worker) { + delete PThread.pthreads[worker.pthread.thread]; + PThread.unusedWorkers.push(worker); + PThread.runningWorkers.splice(PThread.runningWorkers.indexOf(worker), 1); + PThread.freeThreadData(worker.pthread); + worker.pthread = undefined; + }), + receiveObjectTransfer: (function(data) {}), + allocateUnusedWorkers: (function(numWorkers, onFinishedLoading) { + if (typeof SharedArrayBuffer === "undefined") return; + var workers = []; + var numWorkersToCreate = numWorkers; + if (PThread.preallocatedWorkers.length > 0) { + var workersUsed = Math.min(PThread.preallocatedWorkers.length, numWorkers); + workers = workers.concat(PThread.preallocatedWorkers.splice(0, workersUsed)); + numWorkersToCreate -= workersUsed; + } + if (numWorkersToCreate > 0) { + workers = workers.concat(PThread.createNewWorkers(numWorkersToCreate)); + } + PThread.attachListenerToWorkers(workers, onFinishedLoading); + for (var i = 0; i < numWorkers; ++i) { + var worker = workers[i]; + worker.postMessage({ + "cmd": "load", + "urlOrBlob": Module["mainScriptUrlOrBlob"] || _scriptDir, + "wasmMemory": wasmMemory, + "wasmModule": wasmModule, + "DYNAMIC_BASE": DYNAMIC_BASE, + "DYNAMICTOP_PTR": DYNAMICTOP_PTR + }); + PThread.unusedWorkers.push(worker); + } + }), + attachListenerToWorkers: (function(workers, onFinishedLoading) { + var numWorkersLoaded = 0; + var numWorkers = workers.length; + for (var i = 0; i < numWorkers; ++i) { + var worker = workers[i]; + ((function(worker) { + worker.onmessage = (function(e) { + var d = e["data"]; + var cmd = d["cmd"]; + if (worker.pthread) PThread.currentProxiedOperationCallerThread = worker.pthread.threadInfoStruct; + if (d["targetThread"] && d["targetThread"] != _pthread_self()) { + var thread = PThread.pthreads[d.targetThread]; + if (thread) { + thread.worker.postMessage(e.data, d["transferList"]); + } else { + console.error('Internal error! Worker sent a message "' + cmd + '" to target pthread ' + d["targetThread"] + ", but that thread no longer exists!"); + } + PThread.currentProxiedOperationCallerThread = undefined; + return; + } + if (cmd === "processQueuedMainThreadWork") { + _emscripten_main_thread_process_queued_calls(); + } else if (cmd === "spawnThread") { + __spawn_thread(e.data); + } else if (cmd === "cleanupThread") { + __cleanup_thread(d["thread"]); + } else if (cmd === "killThread") { + __kill_thread(d["thread"]); + } else if (cmd === "cancelThread") { + __cancel_thread(d["thread"]); + } else if (cmd === "loaded") { + worker.loaded = true; + if (worker.runPthread) { + worker.runPthread(); + delete worker.runPthread; + } + ++numWorkersLoaded; + if (numWorkersLoaded === numWorkers && onFinishedLoading) { + onFinishedLoading(); + } + } else if (cmd === "print") { + out("Thread " + d["threadId"] + ": " + d["text"]); + } else if (cmd === "printErr") { + err("Thread " + d["threadId"] + ": " + d["text"]); + } else if (cmd === "alert") { + alert("Thread " + d["threadId"] + ": " + d["text"]); + } else if (cmd === "exit") { + var detached = worker.pthread && Atomics.load(HEAPU32, worker.pthread.thread + 80 >> 2); + if (detached) { + PThread.returnWorkerToPool(worker); + } + } else if (cmd === "exitProcess") { + noExitRuntime = false; + try { + exit(d["returnCode"]); + } catch (e) { + if (e instanceof ExitStatus) return; + throw e; + } + } else if (cmd === "cancelDone") { + PThread.returnWorkerToPool(worker); + } else if (cmd === "objectTransfer") { + PThread.receiveObjectTransfer(e.data); + } else if (e.data.target === "setimmediate") { + worker.postMessage(e.data); + } else { + err("worker sent an unknown command " + cmd); + } + PThread.currentProxiedOperationCallerThread = undefined; + }); + worker.onerror = (function(e) { + err("pthread sent an error! " + e.filename + ":" + e.lineno + ": " + e.message); + }); + if (ENVIRONMENT_HAS_NODE) { + worker.on("message", (function(data) { + worker.onmessage({ + data: data + }); + })); + worker.on("error", (function(data) { + worker.onerror(data); + })); + worker.on("exit", (function(data) { + console.log("worker exited - TODO: update the worker queue?"); + })); } - Module["demangle"] = demangle; - - function demangleAll(text) { - var regex = - /\b_Z[\w\d_]+/g; - return text.replace(regex, - function(x) { - var y = demangle(x); - return x === y ? x : (y + ' [' + x + ']'); - }); + }))(worker); + } + }), + createNewWorkers: (function(numWorkers) { + if (typeof SharedArrayBuffer === "undefined") return []; + var pthreadMainJs = "x2t.worker.js"; + pthreadMainJs = locateFile(pthreadMainJs); + var newWorkers = []; + for (var i = 0; i < numWorkers; ++i) { + newWorkers.push(new Worker(pthreadMainJs)); + } + return newWorkers; + }), + getNewWorker: (function() { + if (PThread.unusedWorkers.length == 0) PThread.allocateUnusedWorkers(1); + if (PThread.unusedWorkers.length > 0) return PThread.unusedWorkers.pop(); else return null; + }), + busySpinWait: (function(msecs) { + var t = performance.now() + msecs; + while (performance.now() < t) { + } + }) +}; +Module["PThread"] = PThread; +function ___call_main(argc, argv) { + var returnCode = _main(argc, argv); + if (!noExitRuntime) postMessage({ + "cmd": "exitProcess", + "returnCode": returnCode + }); + return returnCode; +} +Module["___call_main"] = ___call_main; +function _emscripten_get_now() { + abort(); +} +Module["_emscripten_get_now"] = _emscripten_get_now; +function _emscripten_get_now_is_monotonic() { + return 0 || ENVIRONMENT_IS_NODE || typeof dateNow !== "undefined" || typeof performance === "object" && performance && typeof performance["now"] === "function"; +} +Module["_emscripten_get_now_is_monotonic"] = _emscripten_get_now_is_monotonic; +function ___setErrNo(value) { + if (Module["___errno_location"]) GROWABLE_HEAP_STORE_I32(Module["___errno_location"]() | 0, value); else err("failed to set errno from JS"); + return value; +} +Module["___setErrNo"] = ___setErrNo; +function _clock_gettime(clk_id, tp) { + var now; + if (clk_id === 0) { + now = Date.now(); + } else if (clk_id === 1 && _emscripten_get_now_is_monotonic()) { + now = _emscripten_get_now(); + } else { + ___setErrNo(28); + return -1; + } + GROWABLE_HEAP_STORE_I32(tp | 0, now / 1e3 | 0); + GROWABLE_HEAP_STORE_I32(tp + 4 | 0, now % 1e3 * 1e3 * 1e3 | 0); + return 0; +} +Module["_clock_gettime"] = _clock_gettime; +function ___clock_gettime(a0, a1) { + return _clock_gettime(a0, a1); +} +Module["___clock_gettime"] = ___clock_gettime; +function ___cxa_allocate_exception(size) { + return _malloc(size); +} +Module["___cxa_allocate_exception"] = ___cxa_allocate_exception; +function _atexit(func, arg) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(1, 1, func, arg); + warnOnce("atexit() called, but EXIT_RUNTIME is not set, so atexits() will not be called. set EXIT_RUNTIME to 1 (see the FAQ)"); + __ATEXIT__.unshift({ + func: func, + arg: arg + }); +} +Module["_atexit"] = _atexit; +function ___cxa_atexit() { + return _atexit.apply(null, arguments); +} +Module["___cxa_atexit"] = ___cxa_atexit; +var ___exception_caught = []; +Module["___exception_caught"] = ___exception_caught; +var ___exception_infos = {}; +Module["___exception_infos"] = ___exception_infos; +function ___exception_deAdjust(adjusted) { + if (!adjusted || ___exception_infos[adjusted]) return adjusted; + for (var key in ___exception_infos) { + var ptr = +key; + var adj = ___exception_infos[ptr].adjusted; + var len = adj.length; + for (var i = 0; i < len; i++) { + if (adj[i] === adjusted) { + return ptr; + } + } + } + return adjusted; +} +Module["___exception_deAdjust"] = ___exception_deAdjust; +var ___exception_last = 0; +Module["___exception_last"] = ___exception_last; +function ___cxa_rethrow() { + var ptr = ___exception_caught.pop(); + ptr = ___exception_deAdjust(ptr); + if (!___exception_infos[ptr].rethrown) { + ___exception_caught.push(ptr); + ___exception_infos[ptr].rethrown = true; + } + ___exception_last = ptr; + throw ptr + " - Exception catching is disabled, this exception cannot be caught. Compile with -s DISABLE_EXCEPTION_CATCHING=0 or DISABLE_EXCEPTION_CATCHING=2 to catch."; +} +Module["___cxa_rethrow"] = ___cxa_rethrow; +function ___cxa_throw(ptr, type, destructor) { + ___exception_infos[ptr] = { + ptr: ptr, + adjusted: [ ptr ], + type: type, + destructor: destructor, + refcount: 0, + caught: false, + rethrown: false + }; + ___exception_last = ptr; + if (!("uncaught_exception" in __ZSt18uncaught_exceptionv)) { + __ZSt18uncaught_exceptionv.uncaught_exceptions = 1; + } else { + __ZSt18uncaught_exceptionv.uncaught_exceptions++; + } + throw ptr + " - Exception catching is disabled, this exception cannot be caught. Compile with -s DISABLE_EXCEPTION_CATCHING=0 or DISABLE_EXCEPTION_CATCHING=2 to catch."; +} +Module["___cxa_throw"] = ___cxa_throw; +function ___lock() {} +Module["___lock"] = ___lock; +function ___map_file(pathname, size) { + ___setErrNo(63); + return -1; +} +Module["___map_file"] = ___map_file; +var PATH = { + splitPath: (function(filename) { + var splitPathRe = /^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/; + return splitPathRe.exec(filename).slice(1); + }), + normalizeArray: (function(parts, allowAboveRoot) { + var up = 0; + for (var i = parts.length - 1; i >= 0; i--) { + var last = parts[i]; + if (last === ".") { + parts.splice(i, 1); + } else if (last === "..") { + parts.splice(i, 1); + up++; + } else if (up) { + parts.splice(i, 1); + up--; + } + } + if (allowAboveRoot) { + for (; up; up--) { + parts.unshift(".."); + } + } + return parts; + }), + normalize: (function(path) { + var isAbsolute = path.charAt(0) === "/", trailingSlash = path.substr(-1) === "/"; + path = PATH.normalizeArray(path.split("/").filter((function(p) { + return !!p; + })), !isAbsolute).join("/"); + if (!path && !isAbsolute) { + path = "."; + } + if (path && trailingSlash) { + path += "/"; + } + return (isAbsolute ? "/" : "") + path; + }), + dirname: (function(path) { + var result = PATH.splitPath(path), root = result[0], dir = result[1]; + if (!root && !dir) { + return "."; + } + if (dir) { + dir = dir.substr(0, dir.length - 1); + } + return root + dir; + }), + basename: (function(path) { + if (path === "/") return "/"; + var lastSlash = path.lastIndexOf("/"); + if (lastSlash === -1) return path; + return path.substr(lastSlash + 1); + }), + extname: (function(path) { + return PATH.splitPath(path)[3]; + }), + join: (function() { + var paths = Array.prototype.slice.call(arguments, 0); + return PATH.normalize(paths.join("/")); + }), + join2: (function(l, r) { + return PATH.normalize(l + "/" + r); + }) +}; +Module["PATH"] = PATH; +var PATH_FS = { + resolve: (function() { + var resolvedPath = "", resolvedAbsolute = false; + for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) { + var path = i >= 0 ? arguments[i] : FS.cwd(); + if (typeof path !== "string") { + throw new TypeError("Arguments to path.resolve must be strings"); + } else if (!path) { + return ""; + } + resolvedPath = path + "/" + resolvedPath; + resolvedAbsolute = path.charAt(0) === "/"; + } + resolvedPath = PATH.normalizeArray(resolvedPath.split("/").filter((function(p) { + return !!p; + })), !resolvedAbsolute).join("/"); + return (resolvedAbsolute ? "/" : "") + resolvedPath || "."; + }), + relative: (function(from, to) { + from = PATH_FS.resolve(from).substr(1); + to = PATH_FS.resolve(to).substr(1); + function trim(arr) { + var start = 0; + for (; start < arr.length; start++) { + if (arr[start] !== "") break; + } + var end = arr.length - 1; + for (; end >= 0; end--) { + if (arr[end] !== "") break; + } + if (start > end) return []; + return arr.slice(start, end - start + 1); + } + var fromParts = trim(from.split("/")); + var toParts = trim(to.split("/")); + var length = Math.min(fromParts.length, toParts.length); + var samePartsLength = length; + for (var i = 0; i < length; i++) { + if (fromParts[i] !== toParts[i]) { + samePartsLength = i; + break; + } + } + var outputParts = []; + for (var i = samePartsLength; i < fromParts.length; i++) { + outputParts.push(".."); + } + outputParts = outputParts.concat(toParts.slice(samePartsLength)); + return outputParts.join("/"); + }) +}; +Module["PATH_FS"] = PATH_FS; +var TTY = { + ttys: [], + init: (function() {}), + shutdown: (function() {}), + register: (function(dev, ops) { + TTY.ttys[dev] = { + input: [], + output: [], + ops: ops + }; + FS.registerDevice(dev, TTY.stream_ops); + }), + stream_ops: { + open: (function(stream) { + var tty = TTY.ttys[stream.node.rdev]; + if (!tty) { + throw new FS.ErrnoError(43); + } + stream.tty = tty; + stream.seekable = false; + }), + close: (function(stream) { + stream.tty.ops.flush(stream.tty); + }), + flush: (function(stream) { + stream.tty.ops.flush(stream.tty); + }), + read: (function(stream, buffer, offset, length, pos) { + if (!stream.tty || !stream.tty.ops.get_char) { + throw new FS.ErrnoError(60); + } + var bytesRead = 0; + for (var i = 0; i < length; i++) { + var result; + try { + result = stream.tty.ops.get_char(stream.tty); + } catch (e) { + throw new FS.ErrnoError(29); } - Module["demangleAll"] = demangleAll; - - function jsStackTrace() { - var err = new Error(); - if (!err.stack) { - // IE10+ special cases: It does have callstack info, but it is only populated if an Error object is thrown, - // so try that as a special-case. - try { - throw new Error(0); - } catch(e) { - err = e; - } - if (!err.stack) { - return '(no stack trace available)'; - } - } - return err.stack.toString(); + if (result === undefined && bytesRead === 0) { + throw new FS.ErrnoError(6); } - Module["jsStackTrace"] = jsStackTrace; - - function stackTrace() { - var js = jsStackTrace(); - if (Module['extraStackTrace']) js += '\n' + Module['extraStackTrace'](); - return demangleAll(js); + if (result === null || result === undefined) break; + bytesRead++; + buffer[offset + i] = result; + } + if (bytesRead) { + stream.node.timestamp = Date.now(); + } + return bytesRead; + }), + write: (function(stream, buffer, offset, length, pos) { + if (!stream.tty || !stream.tty.ops.put_char) { + throw new FS.ErrnoError(60); + } + try { + for (var i = 0; i < length; i++) { + stream.tty.ops.put_char(stream.tty, buffer[offset + i]); } - Module["stackTrace"] = stackTrace; - - function __ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE( - ) { - err('missing function: _ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE'); abort(-1); + } catch (e) { + throw new FS.ErrnoError(29); + } + if (length) { + stream.node.timestamp = Date.now(); + } + return i; + }) + }, + default_tty_ops: { + get_char: (function(tty) { + if (!tty.input.length) { + var result = null; + if (ENVIRONMENT_IS_NODE) { + var BUFSIZE = 256; + var buf = Buffer.alloc ? Buffer.alloc(BUFSIZE) : new Buffer(BUFSIZE); + var bytesRead = 0; + try { + bytesRead = nodeFS.readSync(process.stdin.fd, buf, 0, BUFSIZE, null); + } catch (e) { + if (e.toString().indexOf("EOF") != -1) bytesRead = 0; else throw e; + } + if (bytesRead > 0) { + result = buf.slice(0, bytesRead).toString("utf-8"); + } else { + result = null; + } + } else if (typeof window != "undefined" && typeof window.prompt == "function") { + result = window.prompt("Input: "); + if (result !== null) { + result += "\n"; + } + } else if (typeof readline == "function") { + result = readline(); + if (result !== null) { + result += "\n"; + } + } + if (!result) { + return null; + } + tty.input = intArrayFromString(result, true); + } + return tty.input.shift(); + }), + put_char: (function(tty, val) { + if (val === null || val === 10) { + out(UTF8ArrayToString(tty.output, 0)); + tty.output = []; + } else { + if (val != 0) tty.output.push(val); + } + }), + flush: (function(tty) { + if (tty.output && tty.output.length > 0) { + out(UTF8ArrayToString(tty.output, 0)); + tty.output = []; + } + }) + }, + default_tty1_ops: { + put_char: (function(tty, val) { + if (val === null || val === 10) { + err(UTF8ArrayToString(tty.output, 0)); + tty.output = []; + } else { + if (val != 0) tty.output.push(val); + } + }), + flush: (function(tty) { + if (tty.output && tty.output.length > 0) { + err(UTF8ArrayToString(tty.output, 0)); + tty.output = []; + } + }) + } +}; +Module["TTY"] = TTY; +var MEMFS = { + ops_table: null, + mount: (function(mount) { + return MEMFS.createNode(null, "/", 16384 | 511, 0); + }), + createNode: (function(parent, name, mode, dev) { + if (FS.isBlkdev(mode) || FS.isFIFO(mode)) { + throw new FS.ErrnoError(63); + } + if (!MEMFS.ops_table) { + MEMFS.ops_table = { + dir: { + node: { + getattr: MEMFS.node_ops.getattr, + setattr: MEMFS.node_ops.setattr, + lookup: MEMFS.node_ops.lookup, + mknod: MEMFS.node_ops.mknod, + rename: MEMFS.node_ops.rename, + unlink: MEMFS.node_ops.unlink, + rmdir: MEMFS.node_ops.rmdir, + readdir: MEMFS.node_ops.readdir, + symlink: MEMFS.node_ops.symlink + }, + stream: { + llseek: MEMFS.stream_ops.llseek + } + }, + file: { + node: { + getattr: MEMFS.node_ops.getattr, + setattr: MEMFS.node_ops.setattr + }, + stream: { + llseek: MEMFS.stream_ops.llseek, + read: MEMFS.stream_ops.read, + write: MEMFS.stream_ops.write, + allocate: MEMFS.stream_ops.allocate, + mmap: MEMFS.stream_ops.mmap, + msync: MEMFS.stream_ops.msync + } + }, + link: { + node: { + getattr: MEMFS.node_ops.getattr, + setattr: MEMFS.node_ops.setattr, + readlink: MEMFS.node_ops.readlink + }, + stream: {} + }, + chrdev: { + node: { + getattr: MEMFS.node_ops.getattr, + setattr: MEMFS.node_ops.setattr + }, + stream: FS.chrdev_stream_ops + } + }; + } + var node = FS.createNode(parent, name, mode, dev); + if (FS.isDir(node.mode)) { + node.node_ops = MEMFS.ops_table.dir.node; + node.stream_ops = MEMFS.ops_table.dir.stream; + node.contents = {}; + } else if (FS.isFile(node.mode)) { + node.node_ops = MEMFS.ops_table.file.node; + node.stream_ops = MEMFS.ops_table.file.stream; + node.usedBytes = 0; + node.contents = null; + } else if (FS.isLink(node.mode)) { + node.node_ops = MEMFS.ops_table.link.node; + node.stream_ops = MEMFS.ops_table.link.stream; + } else if (FS.isChrdev(node.mode)) { + node.node_ops = MEMFS.ops_table.chrdev.node; + node.stream_ops = MEMFS.ops_table.chrdev.stream; + } + node.timestamp = Date.now(); + if (parent) { + parent.contents[name] = node; + } + return node; + }), + getFileDataAsRegularArray: (function(node) { + if (node.contents && node.contents.subarray) { + var arr = []; + for (var i = 0; i < node.usedBytes; ++i) arr.push(node.contents[i]); + return arr; + } + return node.contents; + }), + getFileDataAsTypedArray: (function(node) { + if (!node.contents) return new Uint8Array; + if (node.contents.subarray) return node.contents.subarray(0, node.usedBytes); + return new Uint8Array(node.contents); + }), + expandFileStorage: (function(node, newCapacity) { + var prevCapacity = node.contents ? node.contents.length : 0; + if (prevCapacity >= newCapacity) return; + var CAPACITY_DOUBLING_MAX = 1024 * 1024; + newCapacity = Math.max(newCapacity, prevCapacity * (prevCapacity < CAPACITY_DOUBLING_MAX ? 2 : 1.125) | 0); + if (prevCapacity != 0) newCapacity = Math.max(newCapacity, 256); + var oldContents = node.contents; + node.contents = new Uint8Array(newCapacity); + if (node.usedBytes > 0) node.contents.set(oldContents.subarray(0, node.usedBytes), 0); + return; + }), + resizeFileStorage: (function(node, newSize) { + if (node.usedBytes == newSize) return; + if (newSize == 0) { + node.contents = null; + node.usedBytes = 0; + return; + } + if (!node.contents || node.contents.subarray) { + var oldContents = node.contents; + node.contents = new Uint8Array(new ArrayBuffer(newSize)); + if (oldContents) { + node.contents.set(oldContents.subarray(0, Math.min(newSize, node.usedBytes))); + } + node.usedBytes = newSize; + return; + } + if (!node.contents) node.contents = []; + if (node.contents.length > newSize) node.contents.length = newSize; else while (node.contents.length < newSize) node.contents.push(0); + node.usedBytes = newSize; + }), + node_ops: { + getattr: (function(node) { + var attr = {}; + attr.dev = FS.isChrdev(node.mode) ? node.id : 1; + attr.ino = node.id; + attr.mode = node.mode; + attr.nlink = 1; + attr.uid = 0; + attr.gid = 0; + attr.rdev = node.rdev; + if (FS.isDir(node.mode)) { + attr.size = 4096; + } else if (FS.isFile(node.mode)) { + attr.size = node.usedBytes; + } else if (FS.isLink(node.mode)) { + attr.size = node.link.length; + } else { + attr.size = 0; + } + attr.atime = new Date(node.timestamp); + attr.mtime = new Date(node.timestamp); + attr.ctime = new Date(node.timestamp); + attr.blksize = 4096; + attr.blocks = Math.ceil(attr.size / attr.blksize); + return attr; + }), + setattr: (function(node, attr) { + if (attr.mode !== undefined) { + node.mode = attr.mode; + } + if (attr.timestamp !== undefined) { + node.timestamp = attr.timestamp; + } + if (attr.size !== undefined) { + MEMFS.resizeFileStorage(node, attr.size); + } + }), + lookup: (function(parent, name) { + throw FS.genericErrors[44]; + }), + mknod: (function(parent, name, mode, dev) { + return MEMFS.createNode(parent, name, mode, dev); + }), + rename: (function(old_node, new_dir, new_name) { + if (FS.isDir(old_node.mode)) { + var new_node; + try { + new_node = FS.lookupNode(new_dir, new_name); + } catch (e) {} + if (new_node) { + for (var i in new_node.contents) { + throw new FS.ErrnoError(55); + } + } + } + delete old_node.parent.contents[old_node.name]; + old_node.name = new_name; + new_dir.contents[new_name] = old_node; + old_node.parent = new_dir; + }), + unlink: (function(parent, name) { + delete parent.contents[name]; + }), + rmdir: (function(parent, name) { + var node = FS.lookupNode(parent, name); + for (var i in node.contents) { + throw new FS.ErrnoError(55); + } + delete parent.contents[name]; + }), + readdir: (function(node) { + var entries = [ ".", ".." ]; + for (var key in node.contents) { + if (!node.contents.hasOwnProperty(key)) { + continue; + } + entries.push(key); + } + return entries; + }), + symlink: (function(parent, newname, oldpath) { + var node = MEMFS.createNode(parent, newname, 511 | 40960, 0); + node.link = oldpath; + return node; + }), + readlink: (function(node) { + if (!FS.isLink(node.mode)) { + throw new FS.ErrnoError(28); + } + return node.link; + }) + }, + stream_ops: { + read: (function(stream, buffer, offset, length, position) { + var contents = stream.node.contents; + if (position >= stream.node.usedBytes) return 0; + var size = Math.min(stream.node.usedBytes - position, length); + assert(size >= 0); + if (size > 8 && contents.subarray) { + buffer.set(contents.subarray(position, position + size), offset); + } else { + for (var i = 0; i < size; i++) buffer[offset + i] = contents[position + i]; + } + return size; + }), + write: (function(stream, buffer, offset, length, position, canOwn) { + assert(!(buffer instanceof ArrayBuffer)); + if (buffer.buffer === HEAP8.buffer) { + if (canOwn) { + warnOnce("file packager has copied file data into memory, but in memory growth we are forced to copy it again (see --no-heap-copy)"); + } + canOwn = false; + } + if (!length) return 0; + var node = stream.node; + node.timestamp = Date.now(); + if (buffer.subarray && (!node.contents || node.contents.subarray)) { + if (canOwn) { + assert(position === 0, "canOwn must imply no weird position inside the file"); + node.contents = buffer.subarray(offset, offset + length); + node.usedBytes = length; + return length; + } else if (node.usedBytes === 0 && position === 0) { + node.contents = new Uint8Array(buffer.subarray(offset, offset + length)); + node.usedBytes = length; + return length; + } else if (position + length <= node.usedBytes) { + node.contents.set(buffer.subarray(offset, offset + length), position); + return length; + } + } + MEMFS.expandFileStorage(node, position + length); + if (node.contents.subarray && buffer.subarray) node.contents.set(buffer.subarray(offset, offset + length), position); else { + for (var i = 0; i < length; i++) { + node.contents[position + i] = buffer[offset + i]; + } + } + node.usedBytes = Math.max(node.usedBytes, position + length); + return length; + }), + llseek: (function(stream, offset, whence) { + var position = offset; + if (whence === 1) { + position += stream.position; + } else if (whence === 2) { + if (FS.isFile(stream.node.mode)) { + position += stream.node.usedBytes; + } + } + if (position < 0) { + throw new FS.ErrnoError(28); + } + return position; + }), + allocate: (function(stream, offset, length) { + MEMFS.expandFileStorage(stream.node, offset + length); + stream.node.usedBytes = Math.max(stream.node.usedBytes, offset + length); + }), + mmap: (function(stream, buffer, offset, length, position, prot, flags) { + assert(!(buffer instanceof ArrayBuffer)); + if (!FS.isFile(stream.node.mode)) { + throw new FS.ErrnoError(43); + } + var ptr; + var allocated; + var contents = stream.node.contents; + if (!(flags & 2) && contents.buffer === buffer.buffer) { + allocated = false; + ptr = contents.byteOffset; + } else { + if (position > 0 || position + length < stream.node.usedBytes) { + if (contents.subarray) { + contents = contents.subarray(position, position + length); + } else { + contents = Array.prototype.slice.call(contents, position, position + length); + } + } + allocated = true; + var fromHeap = buffer.buffer == HEAP8.buffer; + ptr = _malloc(length); + if (!ptr) { + throw new FS.ErrnoError(48); + } + (fromHeap ? HEAP8 : buffer).set(contents, ptr); + } + return { + ptr: ptr, + allocated: allocated + }; + }), + msync: (function(stream, buffer, offset, length, mmapFlags) { + if (!FS.isFile(stream.node.mode)) { + throw new FS.ErrnoError(43); + } + if (mmapFlags & 2) { + return 0; + } + var bytesWritten = MEMFS.stream_ops.write(stream, buffer, 0, length, offset, false); + return 0; + }) + } +}; +Module["MEMFS"] = MEMFS; +var NODEFS = { + isWindows: false, + staticInit: (function() { + NODEFS.isWindows = !!process.platform.match(/^win/); + var flags = process["binding"]("constants"); + if (flags["fs"]) { + flags = flags["fs"]; + } + NODEFS.flagsForNodeMap = { + "1024": flags["O_APPEND"], + "64": flags["O_CREAT"], + "128": flags["O_EXCL"], + "0": flags["O_RDONLY"], + "2": flags["O_RDWR"], + "4096": flags["O_SYNC"], + "512": flags["O_TRUNC"], + "1": flags["O_WRONLY"] + }; + }), + bufferFrom: (function(arrayBuffer) { + return Buffer["alloc"] ? Buffer.from(arrayBuffer) : new Buffer(arrayBuffer); + }), + convertNodeCode: (function(e) { + var code = e.code; + assert(code in ERRNO_CODES); + return ERRNO_CODES[code]; + }), + mount: (function(mount) { + assert(ENVIRONMENT_HAS_NODE); + return NODEFS.createNode(null, "/", NODEFS.getMode(mount.opts.root), 0); + }), + createNode: (function(parent, name, mode, dev) { + if (!FS.isDir(mode) && !FS.isFile(mode) && !FS.isLink(mode)) { + throw new FS.ErrnoError(28); + } + var node = FS.createNode(parent, name, mode); + node.node_ops = NODEFS.node_ops; + node.stream_ops = NODEFS.stream_ops; + return node; + }), + getMode: (function(path) { + var stat; + try { + stat = fs.lstatSync(path); + if (NODEFS.isWindows) { + stat.mode = stat.mode | (stat.mode & 292) >> 2; + } + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + return stat.mode; + }), + realPath: (function(node) { + var parts = []; + while (node.parent !== node) { + parts.push(node.name); + node = node.parent; + } + parts.push(node.mount.opts.root); + parts.reverse(); + return PATH.join.apply(null, parts); + }), + flagsForNode: (function(flags) { + flags &= ~2097152; + flags &= ~2048; + flags &= ~32768; + flags &= ~524288; + var newFlags = 0; + for (var k in NODEFS.flagsForNodeMap) { + if (flags & k) { + newFlags |= NODEFS.flagsForNodeMap[k]; + flags ^= k; + } + } + if (!flags) { + return newFlags; + } else { + throw new FS.ErrnoError(28); + } + }), + node_ops: { + getattr: (function(node) { + var path = NODEFS.realPath(node); + var stat; + try { + stat = fs.lstatSync(path); + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + if (NODEFS.isWindows && !stat.blksize) { + stat.blksize = 4096; + } + if (NODEFS.isWindows && !stat.blocks) { + stat.blocks = (stat.size + stat.blksize - 1) / stat.blksize | 0; + } + return { + dev: stat.dev, + ino: stat.ino, + mode: stat.mode, + nlink: stat.nlink, + uid: stat.uid, + gid: stat.gid, + rdev: stat.rdev, + size: stat.size, + atime: stat.atime, + mtime: stat.mtime, + ctime: stat.ctime, + blksize: stat.blksize, + blocks: stat.blocks + }; + }), + setattr: (function(node, attr) { + var path = NODEFS.realPath(node); + try { + if (attr.mode !== undefined) { + fs.chmodSync(path, attr.mode); + node.mode = attr.mode; + } + if (attr.timestamp !== undefined) { + var date = new Date(attr.timestamp); + fs.utimesSync(path, date, date); + } + if (attr.size !== undefined) { + fs.truncateSync(path, attr.size); + } + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + lookup: (function(parent, name) { + var path = PATH.join2(NODEFS.realPath(parent), name); + var mode = NODEFS.getMode(path); + return NODEFS.createNode(parent, name, mode); + }), + mknod: (function(parent, name, mode, dev) { + var node = NODEFS.createNode(parent, name, mode, dev); + var path = NODEFS.realPath(node); + try { + if (FS.isDir(node.mode)) { + fs.mkdirSync(path, node.mode); + } else { + fs.writeFileSync(path, "", { + mode: node.mode + }); + } + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + return node; + }), + rename: (function(oldNode, newDir, newName) { + var oldPath = NODEFS.realPath(oldNode); + var newPath = PATH.join2(NODEFS.realPath(newDir), newName); + try { + fs.renameSync(oldPath, newPath); + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + unlink: (function(parent, name) { + var path = PATH.join2(NODEFS.realPath(parent), name); + try { + fs.unlinkSync(path); + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + rmdir: (function(parent, name) { + var path = PATH.join2(NODEFS.realPath(parent), name); + try { + fs.rmdirSync(path); + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + readdir: (function(node) { + var path = NODEFS.realPath(node); + try { + return fs.readdirSync(path); + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + symlink: (function(parent, newName, oldPath) { + var newPath = PATH.join2(NODEFS.realPath(parent), newName); + try { + fs.symlinkSync(oldPath, newPath); + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + readlink: (function(node) { + var path = NODEFS.realPath(node); + try { + path = fs.readlinkSync(path); + path = NODEJS_PATH.relative(NODEJS_PATH.resolve(node.mount.opts.root), path); + return path; + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }) + }, + stream_ops: { + open: (function(stream) { + var path = NODEFS.realPath(stream.node); + try { + if (FS.isFile(stream.node.mode)) { + stream.nfd = fs.openSync(path, NODEFS.flagsForNode(stream.flags)); + } + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + close: (function(stream) { + try { + if (FS.isFile(stream.node.mode) && stream.nfd) { + fs.closeSync(stream.nfd); + } + } catch (e) { + if (!e.code) throw e; + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + read: (function(stream, buffer, offset, length, position) { + if (length === 0) return 0; + try { + return fs.readSync(stream.nfd, NODEFS.bufferFrom(buffer.buffer), offset, length, position); + } catch (e) { + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + write: (function(stream, buffer, offset, length, position) { + try { + return fs.writeSync(stream.nfd, NODEFS.bufferFrom(buffer.buffer), offset, length, position); + } catch (e) { + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + }), + llseek: (function(stream, offset, whence) { + var position = offset; + if (whence === 1) { + position += stream.position; + } else if (whence === 2) { + if (FS.isFile(stream.node.mode)) { + try { + var stat = fs.fstatSync(stream.nfd); + position += stat.size; + } catch (e) { + throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); + } + } + } + if (position < 0) { + throw new FS.ErrnoError(28); + } + return position; + }) + } +}; +Module["NODEFS"] = NODEFS; +var ERRNO_MESSAGES = { + 0: "Success", + 1: "Arg list too long", + 2: "Permission denied", + 3: "Address already in use", + 4: "Address not available", + 5: "Address family not supported by protocol family", + 6: "No more processes", + 7: "Socket already connected", + 8: "Bad file number", + 9: "Trying to read unreadable message", + 10: "Mount device busy", + 11: "Operation canceled", + 12: "No children", + 13: "Connection aborted", + 14: "Connection refused", + 15: "Connection reset by peer", + 16: "File locking deadlock error", + 17: "Destination address required", + 18: "Math arg out of domain of func", + 19: "Quota exceeded", + 20: "File exists", + 21: "Bad address", + 22: "File too large", + 23: "Host is unreachable", + 24: "Identifier removed", + 25: "Illegal byte sequence", + 26: "Connection already in progress", + 27: "Interrupted system call", + 28: "Invalid argument", + 29: "I/O error", + 30: "Socket is already connected", + 31: "Is a directory", + 32: "Too many symbolic links", + 33: "Too many open files", + 34: "Too many links", + 35: "Message too long", + 36: "Multihop attempted", + 37: "File or path name too long", + 38: "Network interface is not configured", + 39: "Connection reset by network", + 40: "Network is unreachable", + 41: "Too many open files in system", + 42: "No buffer space available", + 43: "No such device", + 44: "No such file or directory", + 45: "Exec format error", + 46: "No record locks available", + 47: "The link has been severed", + 48: "Not enough core", + 49: "No message of desired type", + 50: "Protocol not available", + 51: "No space left on device", + 52: "Function not implemented", + 53: "Socket is not connected", + 54: "Not a directory", + 55: "Directory not empty", + 56: "State not recoverable", + 57: "Socket operation on non-socket", + 59: "Not a typewriter", + 60: "No such device or address", + 61: "Value too large for defined data type", + 62: "Previous owner died", + 63: "Not super-user", + 64: "Broken pipe", + 65: "Protocol error", + 66: "Unknown protocol", + 67: "Protocol wrong type for socket", + 68: "Math result not representable", + 69: "Read only file system", + 70: "Illegal seek", + 71: "No such process", + 72: "Stale file handle", + 73: "Connection timed out", + 74: "Text file busy", + 75: "Cross-device link", + 100: "Device not a stream", + 101: "Bad font file fmt", + 102: "Invalid slot", + 103: "Invalid request code", + 104: "No anode", + 105: "Block device required", + 106: "Channel number out of range", + 107: "Level 3 halted", + 108: "Level 3 reset", + 109: "Link number out of range", + 110: "Protocol driver not attached", + 111: "No CSI structure available", + 112: "Level 2 halted", + 113: "Invalid exchange", + 114: "Invalid request descriptor", + 115: "Exchange full", + 116: "No data (for no delay io)", + 117: "Timer expired", + 118: "Out of streams resources", + 119: "Machine is not on the network", + 120: "Package not installed", + 121: "The object is remote", + 122: "Advertise error", + 123: "Srmount error", + 124: "Communication error on send", + 125: "Cross mount point (not really error)", + 126: "Given log. name not unique", + 127: "f.d. invalid for this operation", + 128: "Remote address changed", + 129: "Can access a needed shared lib", + 130: "Accessing a corrupted shared lib", + 131: ".lib section in a.out corrupted", + 132: "Attempting to link in too many libs", + 133: "Attempting to exec a shared library", + 135: "Streams pipe error", + 136: "Too many users", + 137: "Socket type not supported", + 138: "Not supported", + 139: "Protocol family not supported", + 140: "Can't send after socket shutdown", + 141: "Too many references", + 142: "Host is down", + 148: "No medium (in tape drive)", + 156: "Level 2 not synchronized" +}; +Module["ERRNO_MESSAGES"] = ERRNO_MESSAGES; +var FS = { + root: null, + mounts: [], + devices: {}, + streams: [], + nextInode: 1, + nameTable: null, + currentPath: "/", + initialized: false, + ignorePermissions: true, + trackingDelegate: {}, + tracking: { + openFlags: { + READ: 1, + WRITE: 2 + } + }, + ErrnoError: null, + genericErrors: {}, + filesystems: null, + syncFSRequests: 0, + handleFSError: (function(e) { + if (!(e instanceof FS.ErrnoError)) throw e + " : " + stackTrace(); + return ___setErrNo(e.errno); + }), + lookupPath: (function(path, opts) { + path = PATH_FS.resolve(FS.cwd(), path); + opts = opts || {}; + if (!path) return { + path: "", + node: null + }; + var defaults = { + follow_mount: true, + recurse_count: 0 + }; + for (var key in defaults) { + if (opts[key] === undefined) { + opts[key] = defaults[key]; + } + } + if (opts.recurse_count > 8) { + throw new FS.ErrnoError(32); + } + var parts = PATH.normalizeArray(path.split("/").filter((function(p) { + return !!p; + })), false); + var current = FS.root; + var current_path = "/"; + for (var i = 0; i < parts.length; i++) { + var islast = i === parts.length - 1; + if (islast && opts.parent) { + break; + } + current = FS.lookupNode(current, parts[i]); + current_path = PATH.join2(current_path, parts[i]); + if (FS.isMountpoint(current)) { + if (!islast || islast && opts.follow_mount) { + current = current.mounted.root; + } + } + if (!islast || opts.follow) { + var count = 0; + while (FS.isLink(current.mode)) { + var link = FS.readlink(current_path); + current_path = PATH_FS.resolve(PATH.dirname(current_path), link); + var lookup = FS.lookupPath(current_path, { + recurse_count: opts.recurse_count + }); + current = lookup.node; + if (count++ > 40) { + throw new FS.ErrnoError(32); + } + } + } } - Module["__ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; - - function __ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE( - ) { - err('missing function: _ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE'); abort(-1); + return { + path: current_path, + node: current + }; + }), + getPath: (function(node) { + var path; + while (true) { + if (FS.isRoot(node)) { + var mount = node.mount.mountpoint; + if (!path) return mount; + return mount[mount.length - 1] !== "/" ? mount + "/" + path : mount + path; + } + path = path ? node.name + "/" + path : node.name; + node = node.parent; + } + }), + hashName: (function(parentid, name) { + var hash = 0; + for (var i = 0; i < name.length; i++) { + hash = (hash << 5) - hash + name.charCodeAt(i) | 0; + } + return (parentid + hash >>> 0) % FS.nameTable.length; + }), + hashAddNode: (function(node) { + var hash = FS.hashName(node.parent.id, node.name); + node.name_next = FS.nameTable[hash]; + FS.nameTable[hash] = node; + }), + hashRemoveNode: (function(node) { + var hash = FS.hashName(node.parent.id, node.name); + if (FS.nameTable[hash] === node) { + FS.nameTable[hash] = node.name_next; + } else { + var current = FS.nameTable[hash]; + while (current) { + if (current.name_next === node) { + current.name_next = node.name_next; + break; + } + current = current.name_next; + } + } + }), + lookupNode: (function(parent, name) { + var err = FS.mayLookup(parent); + if (err) { + throw new FS.ErrnoError(err, parent); + } + var hash = FS.hashName(parent.id, name); + for (var node = FS.nameTable[hash]; node; node = node.name_next) { + var nodeName = node.name; + if (node.parent.id === parent.id && nodeName === name) { + return node; + } + } + return FS.lookup(parent, name); + }), + createNode: (function(parent, name, mode, rdev) { + if (!FS.FSNode) { + FS.FSNode = (function(parent, name, mode, rdev) { + if (!parent) { + parent = this; + } + this.parent = parent; + this.mount = parent.mount; + this.mounted = null; + this.id = FS.nextInode++; + this.name = name; + this.mode = mode; + this.node_ops = {}; + this.stream_ops = {}; + this.rdev = rdev; + }); + FS.FSNode.prototype = {}; + var readMode = 292 | 73; + var writeMode = 146; + Object.defineProperties(FS.FSNode.prototype, { + read: { + get: (function() { + return (this.mode & readMode) === readMode; + }), + set: (function(val) { + val ? this.mode |= readMode : this.mode &= ~readMode; + }) + }, + write: { + get: (function() { + return (this.mode & writeMode) === writeMode; + }), + set: (function(val) { + val ? this.mode |= writeMode : this.mode &= ~writeMode; + }) + }, + isFolder: { + get: (function() { + return FS.isDir(this.mode); + }) + }, + isDevice: { + get: (function() { + return FS.isChrdev(this.mode); + }) + } + }); + } + var node = new FS.FSNode(parent, name, mode, rdev); + FS.hashAddNode(node); + return node; + }), + destroyNode: (function(node) { + FS.hashRemoveNode(node); + }), + isRoot: (function(node) { + return node === node.parent; + }), + isMountpoint: (function(node) { + return !!node.mounted; + }), + isFile: (function(mode) { + return (mode & 61440) === 32768; + }), + isDir: (function(mode) { + return (mode & 61440) === 16384; + }), + isLink: (function(mode) { + return (mode & 61440) === 40960; + }), + isChrdev: (function(mode) { + return (mode & 61440) === 8192; + }), + isBlkdev: (function(mode) { + return (mode & 61440) === 24576; + }), + isFIFO: (function(mode) { + return (mode & 61440) === 4096; + }), + isSocket: (function(mode) { + return (mode & 49152) === 49152; + }), + flagModes: { + "r": 0, + "rs": 1052672, + "r+": 2, + "w": 577, + "wx": 705, + "xw": 705, + "w+": 578, + "wx+": 706, + "xw+": 706, + "a": 1089, + "ax": 1217, + "xa": 1217, + "a+": 1090, + "ax+": 1218, + "xa+": 1218 + }, + modeStringToFlags: (function(str) { + var flags = FS.flagModes[str]; + if (typeof flags === "undefined") { + throw new Error("Unknown file open mode: " + str); + } + return flags; + }), + flagsToPermissionString: (function(flag) { + var perms = [ "r", "w", "rw" ][flag & 3]; + if (flag & 512) { + perms += "w"; + } + return perms; + }), + nodePermissions: (function(node, perms) { + if (FS.ignorePermissions) { + return 0; + } + if (perms.indexOf("r") !== -1 && !(node.mode & 292)) { + return 2; + } else if (perms.indexOf("w") !== -1 && !(node.mode & 146)) { + return 2; + } else if (perms.indexOf("x") !== -1 && !(node.mode & 73)) { + return 2; + } + return 0; + }), + mayLookup: (function(dir) { + var err = FS.nodePermissions(dir, "x"); + if (err) return err; + if (!dir.node_ops.lookup) return 2; + return 0; + }), + mayCreate: (function(dir, name) { + try { + var node = FS.lookupNode(dir, name); + return 20; + } catch (e) {} + return FS.nodePermissions(dir, "wx"); + }), + mayDelete: (function(dir, name, isdir) { + var node; + try { + node = FS.lookupNode(dir, name); + } catch (e) { + return e.errno; + } + var err = FS.nodePermissions(dir, "wx"); + if (err) { + return err; + } + if (isdir) { + if (!FS.isDir(node.mode)) { + return 54; + } + if (FS.isRoot(node) || FS.getPath(node) === FS.cwd()) { + return 10; + } + } else { + if (FS.isDir(node.mode)) { + return 31; + } + } + return 0; + }), + mayOpen: (function(node, flags) { + if (!node) { + return 44; + } + if (FS.isLink(node.mode)) { + return 32; + } else if (FS.isDir(node.mode)) { + if (FS.flagsToPermissionString(flags) !== "r" || flags & 512) { + return 31; + } + } + return FS.nodePermissions(node, FS.flagsToPermissionString(flags)); + }), + MAX_OPEN_FDS: 4096, + nextfd: (function(fd_start, fd_end) { + fd_start = fd_start || 0; + fd_end = fd_end || FS.MAX_OPEN_FDS; + for (var fd = fd_start; fd <= fd_end; fd++) { + if (!FS.streams[fd]) { + return fd; + } + } + throw new FS.ErrnoError(33); + }), + getStream: (function(fd) { + return FS.streams[fd]; + }), + createStream: (function(stream, fd_start, fd_end) { + if (!FS.FSStream) { + FS.FSStream = (function() {}); + FS.FSStream.prototype = {}; + Object.defineProperties(FS.FSStream.prototype, { + object: { + get: (function() { + return this.node; + }), + set: (function(val) { + this.node = val; + }) + }, + isRead: { + get: (function() { + return (this.flags & 2097155) !== 1; + }) + }, + isWrite: { + get: (function() { + return (this.flags & 2097155) !== 0; + }) + }, + isAppend: { + get: (function() { + return this.flags & 1024; + }) + } + }); + } + var newStream = new FS.FSStream; + for (var p in stream) { + newStream[p] = stream[p]; + } + stream = newStream; + var fd = FS.nextfd(fd_start, fd_end); + stream.fd = fd; + FS.streams[fd] = stream; + return stream; + }), + closeStream: (function(fd) { + FS.streams[fd] = null; + }), + chrdev_stream_ops: { + open: (function(stream) { + var device = FS.getDevice(stream.node.rdev); + stream.stream_ops = device.stream_ops; + if (stream.stream_ops.open) { + stream.stream_ops.open(stream); + } + }), + llseek: (function() { + throw new FS.ErrnoError(70); + }) + }, + major: (function(dev) { + return dev >> 8; + }), + minor: (function(dev) { + return dev & 255; + }), + makedev: (function(ma, mi) { + return ma << 8 | mi; + }), + registerDevice: (function(dev, ops) { + FS.devices[dev] = { + stream_ops: ops + }; + }), + getDevice: (function(dev) { + return FS.devices[dev]; + }), + getMounts: (function(mount) { + var mounts = []; + var check = [ mount ]; + while (check.length) { + var m = check.pop(); + mounts.push(m); + check.push.apply(check, m.mounts); + } + return mounts; + }), + syncfs: (function(populate, callback) { + if (typeof populate === "function") { + callback = populate; + populate = false; + } + FS.syncFSRequests++; + if (FS.syncFSRequests > 1) { + console.log("warning: " + FS.syncFSRequests + " FS.syncfs operations in flight at once, probably just doing extra work"); + } + var mounts = FS.getMounts(FS.root.mount); + var completed = 0; + function doCallback(err) { + assert(FS.syncFSRequests > 0); + FS.syncFSRequests--; + return callback(err); + } + function done(err) { + if (err) { + if (!done.errored) { + done.errored = true; + return doCallback(err); + } + return; + } + if (++completed >= mounts.length) { + doCallback(null); + } + } + mounts.forEach((function(mount) { + if (!mount.type.syncfs) { + return done(null); + } + mount.type.syncfs(mount, populate, done); + })); + }), + mount: (function(type, opts, mountpoint) { + if (typeof type === "string") { + throw type; + } + var root = mountpoint === "/"; + var pseudo = !mountpoint; + var node; + if (root && FS.root) { + throw new FS.ErrnoError(10); + } else if (!root && !pseudo) { + var lookup = FS.lookupPath(mountpoint, { + follow_mount: false + }); + mountpoint = lookup.path; + node = lookup.node; + if (FS.isMountpoint(node)) { + throw new FS.ErrnoError(10); + } + if (!FS.isDir(node.mode)) { + throw new FS.ErrnoError(54); + } + } + var mount = { + type: type, + opts: opts, + mountpoint: mountpoint, + mounts: [] + }; + var mountRoot = type.mount(mount); + mountRoot.mount = mount; + mount.root = mountRoot; + if (root) { + FS.root = mountRoot; + } else if (node) { + node.mounted = mount; + if (node.mount) { + node.mount.mounts.push(mount); + } + } + return mountRoot; + }), + unmount: (function(mountpoint) { + var lookup = FS.lookupPath(mountpoint, { + follow_mount: false + }); + if (!FS.isMountpoint(lookup.node)) { + throw new FS.ErrnoError(28); + } + var node = lookup.node; + var mount = node.mounted; + var mounts = FS.getMounts(mount); + Object.keys(FS.nameTable).forEach((function(hash) { + var current = FS.nameTable[hash]; + while (current) { + var next = current.name_next; + if (mounts.indexOf(current.mount) !== -1) { + FS.destroyNode(current); + } + current = next; + } + })); + node.mounted = null; + var idx = node.mount.mounts.indexOf(mount); + assert(idx !== -1); + node.mount.mounts.splice(idx, 1); + }), + lookup: (function(parent, name) { + return parent.node_ops.lookup(parent, name); + }), + mknod: (function(path, mode, dev) { + var lookup = FS.lookupPath(path, { + parent: true + }); + var parent = lookup.node; + var name = PATH.basename(path); + if (!name || name === "." || name === "..") { + throw new FS.ErrnoError(28); + } + var err = FS.mayCreate(parent, name); + if (err) { + throw new FS.ErrnoError(err); + } + if (!parent.node_ops.mknod) { + throw new FS.ErrnoError(63); + } + return parent.node_ops.mknod(parent, name, mode, dev); + }), + create: (function(path, mode) { + mode = mode !== undefined ? mode : 438; + mode &= 4095; + mode |= 32768; + return FS.mknod(path, mode, 0); + }), + mkdir: (function(path, mode) { + mode = mode !== undefined ? mode : 511; + mode &= 511 | 512; + mode |= 16384; + return FS.mknod(path, mode, 0); + }), + mkdirTree: (function(path, mode) { + var dirs = path.split("/"); + var d = ""; + for (var i = 0; i < dirs.length; ++i) { + if (!dirs[i]) continue; + d += "/" + dirs[i]; + try { + FS.mkdir(d, mode); + } catch (e) { + if (e.errno != 20) throw e; + } + } + }), + mkdev: (function(path, mode, dev) { + if (typeof dev === "undefined") { + dev = mode; + mode = 438; + } + mode |= 8192; + return FS.mknod(path, mode, dev); + }), + symlink: (function(oldpath, newpath) { + if (!PATH_FS.resolve(oldpath)) { + throw new FS.ErrnoError(44); + } + var lookup = FS.lookupPath(newpath, { + parent: true + }); + var parent = lookup.node; + if (!parent) { + throw new FS.ErrnoError(44); + } + var newname = PATH.basename(newpath); + var err = FS.mayCreate(parent, newname); + if (err) { + throw new FS.ErrnoError(err); + } + if (!parent.node_ops.symlink) { + throw new FS.ErrnoError(63); + } + return parent.node_ops.symlink(parent, newname, oldpath); + }), + rename: (function(old_path, new_path) { + var old_dirname = PATH.dirname(old_path); + var new_dirname = PATH.dirname(new_path); + var old_name = PATH.basename(old_path); + var new_name = PATH.basename(new_path); + var lookup, old_dir, new_dir; + try { + lookup = FS.lookupPath(old_path, { + parent: true + }); + old_dir = lookup.node; + lookup = FS.lookupPath(new_path, { + parent: true + }); + new_dir = lookup.node; + } catch (e) { + throw new FS.ErrnoError(10); } - Module["__ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; - - function __ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE( - ) { - err('missing function: _ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE'); abort(-1); + if (!old_dir || !new_dir) throw new FS.ErrnoError(44); + if (old_dir.mount !== new_dir.mount) { + throw new FS.ErrnoError(75); } - Module["__ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; - - function __ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE( - ) { - err('missing function: _ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE'); abort(-1); + var old_node = FS.lookupNode(old_dir, old_name); + var relative = PATH_FS.relative(old_path, new_dirname); + if (relative.charAt(0) !== ".") { + throw new FS.ErrnoError(28); } - Module["__ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; - - function __ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE( - ) { - err('missing function: _ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE'); abort(-1); + relative = PATH_FS.relative(new_path, old_dirname); + if (relative.charAt(0) !== ".") { + throw new FS.ErrnoError(55); } - Module["__ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE"] = __ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE; - - function __ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb( - ) { - err('missing function: _ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb'); abort(-1); + var new_node; + try { + new_node = FS.lookupNode(new_dir, new_name); + } catch (e) {} + if (old_node === new_node) { + return; } - Module["__ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb"] = __ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb; - - function __ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb( - ) { - err('missing function: _ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb'); abort(-1); + var isdir = FS.isDir(old_node.mode); + var err = FS.mayDelete(old_dir, old_name, isdir); + if (err) { + throw new FS.ErrnoError(err); } - Module["__ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb"] = __ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb; - - function __ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb( - ) { - err('missing function: _ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb'); abort(-1); + err = new_node ? FS.mayDelete(new_dir, new_name, isdir) : FS.mayCreate(new_dir, new_name); + if (err) { + throw new FS.ErrnoError(err); } - Module["__ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb"] = __ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb; - - function __ZN12CPdfRendererD1Ev( - ) { - err('missing function: _ZN12CPdfRendererD1Ev'); abort(-1); + if (!old_dir.node_ops.rename) { + throw new FS.ErrnoError(63); } - Module["__ZN12CPdfRendererD1Ev"] = __ZN12CPdfRendererD1Ev; - - function __ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv( - ) { - err('missing function: _ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv'); abort(-1); + if (FS.isMountpoint(old_node) || new_node && FS.isMountpoint(new_node)) { + throw new FS.ErrnoError(10); } - Module["__ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv"] = __ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv; - - function __ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_( - ) { - err('missing function: _ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_'); abort(-1); + if (new_dir !== old_dir) { + err = FS.nodePermissions(old_dir, "w"); + if (err) { + throw new FS.ErrnoError(err); + } } - Module["__ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_"] = __ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_; - - function __ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE( - ) { - err('missing function: _ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE'); abort(-1); + try { + if (FS.trackingDelegate["willMovePath"]) { + FS.trackingDelegate["willMovePath"](old_path, new_path); + } + } catch (e) { + console.log("FS.trackingDelegate['willMovePath']('" + old_path + "', '" + new_path + "') threw an exception: " + e.message); } - Module["__ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE"] = __ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE; - - function __ZN14NSDoctRenderer13CDoctrendererD1Ev( - ) { - err('missing function: _ZN14NSDoctRenderer13CDoctrendererD1Ev'); abort(-1); + FS.hashRemoveNode(old_node); + try { + old_dir.node_ops.rename(old_node, new_dir, new_name); + } catch (e) { + throw e; + } finally { + FS.hashAddNode(old_node); } - Module["__ZN14NSDoctRenderer13CDoctrendererD1Ev"] = __ZN14NSDoctRenderer13CDoctrendererD1Ev; - - function __ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_( - ) { - err('missing function: _ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_'); abort(-1); + try { + if (FS.trackingDelegate["onMovePath"]) FS.trackingDelegate["onMovePath"](old_path, new_path); + } catch (e) { + console.log("FS.trackingDelegate['onMovePath']('" + old_path + "', '" + new_path + "') threw an exception: " + e.message); } - Module["__ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_"] = __ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_; - - function __ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb( - ) { - err('missing function: _ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb'); abort(-1); + }), + rmdir: (function(path) { + var lookup = FS.lookupPath(path, { + parent: true + }); + var parent = lookup.node; + var name = PATH.basename(path); + var node = FS.lookupNode(parent, name); + var err = FS.mayDelete(parent, name, true); + if (err) { + throw new FS.ErrnoError(err); } - Module["__ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb"] = __ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb; - - function __ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev( - ) { - err('missing function: _ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev'); abort(-1); + if (!parent.node_ops.rmdir) { + throw new FS.ErrnoError(63); } - Module["__ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev"] = __ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev; - - function __ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev( - ) { - err('missing function: _ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev'); abort(-1); + if (FS.isMountpoint(node)) { + throw new FS.ErrnoError(10); } - Module["__ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev"] = __ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev; - - function __ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb( - ) { - err('missing function: _ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb'); abort(-1); + try { + if (FS.trackingDelegate["willDeletePath"]) { + FS.trackingDelegate["willDeletePath"](path); + } + } catch (e) { + console.log("FS.trackingDelegate['willDeletePath']('" + path + "') threw an exception: " + e.message); } - Module["__ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb"] = __ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb; - - function __ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE( - ) { - err('missing function: _ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE'); abort(-1); + parent.node_ops.rmdir(parent, name); + FS.destroyNode(node); + try { + if (FS.trackingDelegate["onDeletePath"]) FS.trackingDelegate["onDeletePath"](path); + } catch (e) { + console.log("FS.trackingDelegate['onDeletePath']('" + path + "') threw an exception: " + e.message); } - Module["__ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE"] = __ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE; - - function __ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE( - ) { - err('missing function: _ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE'); abort(-1); + }), + readdir: (function(path) { + var lookup = FS.lookupPath(path, { + follow: true + }); + var node = lookup.node; + if (!node.node_ops.readdir) { + throw new FS.ErrnoError(54); + } + return node.node_ops.readdir(node); + }), + unlink: (function(path) { + var lookup = FS.lookupPath(path, { + parent: true + }); + var parent = lookup.node; + var name = PATH.basename(path); + var node = FS.lookupNode(parent, name); + var err = FS.mayDelete(parent, name, false); + if (err) { + throw new FS.ErrnoError(err); } - Module["__ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE"] = __ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE; - - function __ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_( - ) { - err('missing function: _ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_'); abort(-1); + if (!parent.node_ops.unlink) { + throw new FS.ErrnoError(63); } - Module["__ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_"] = __ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_; - - function __ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_( - ) { - err('missing function: _ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_'); abort(-1); + if (FS.isMountpoint(node)) { + throw new FS.ErrnoError(10); } - Module["__ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_"] = __ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_; - - function __ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_( - ) { - err('missing function: _ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_'); abort(-1); + try { + if (FS.trackingDelegate["willDeletePath"]) { + FS.trackingDelegate["willDeletePath"](path); + } + } catch (e) { + console.log("FS.trackingDelegate['willDeletePath']('" + path + "') threw an exception: " + e.message); } - Module["__ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_"] = __ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_; - - function __ZN9CHtmlFileC1Ev( - ) { - err('missing function: _ZN9CHtmlFileC1Ev'); abort(-1); + parent.node_ops.unlink(parent, name); + FS.destroyNode(node); + try { + if (FS.trackingDelegate["onDeletePath"]) FS.trackingDelegate["onDeletePath"](path); + } catch (e) { + console.log("FS.trackingDelegate['onDeletePath']('" + path + "') threw an exception: " + e.message); + } + }), + readlink: (function(path) { + var lookup = FS.lookupPath(path); + var link = lookup.node; + if (!link) { + throw new FS.ErrnoError(44); + } + if (!link.node_ops.readlink) { + throw new FS.ErrnoError(28); + } + return PATH_FS.resolve(FS.getPath(link.parent), link.node_ops.readlink(link)); + }), + stat: (function(path, dontFollow) { + var lookup = FS.lookupPath(path, { + follow: !dontFollow + }); + var node = lookup.node; + if (!node) { + throw new FS.ErrnoError(44); + } + if (!node.node_ops.getattr) { + throw new FS.ErrnoError(63); + } + return node.node_ops.getattr(node); + }), + lstat: (function(path) { + return FS.stat(path, true); + }), + chmod: (function(path, mode, dontFollow) { + var node; + if (typeof path === "string") { + var lookup = FS.lookupPath(path, { + follow: !dontFollow + }); + node = lookup.node; + } else { + node = path; } - Module["__ZN9CHtmlFileC1Ev"] = __ZN9CHtmlFileC1Ev; - - function __ZN9CHtmlFileD1Ev( - ) { - err('missing function: _ZN9CHtmlFileD1Ev'); abort(-1); + if (!node.node_ops.setattr) { + throw new FS.ErrnoError(63); } - Module["__ZN9CHtmlFileD1Ev"] = __ZN9CHtmlFileD1Ev; - - function __ZN9PdfReader10CPdfReader8GetErrorEv( - ) { - err('missing function: _ZN9PdfReader10CPdfReader8GetErrorEv'); abort(-1); + node.node_ops.setattr(node, { + mode: mode & 4095 | node.mode & ~4095, + timestamp: Date.now() + }); + }), + lchmod: (function(path, mode) { + FS.chmod(path, mode, true); + }), + fchmod: (function(fd, mode) { + var stream = FS.getStream(fd); + if (!stream) { + throw new FS.ErrnoError(8); + } + FS.chmod(stream.node, mode); + }), + chown: (function(path, uid, gid, dontFollow) { + var node; + if (typeof path === "string") { + var lookup = FS.lookupPath(path, { + follow: !dontFollow + }); + node = lookup.node; + } else { + node = path; } - Module["__ZN9PdfReader10CPdfReader8GetErrorEv"] = __ZN9PdfReader10CPdfReader8GetErrorEv; - - function __ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE( - ) { - err('missing function: _ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE'); abort(-1); + if (!node.node_ops.setattr) { + throw new FS.ErrnoError(63); } - Module["__ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE"] = __ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE; - - function ___assert_fail(condition, filename, line, func) { - abort('Assertion failed: ' + UTF8ToString(condition) + ', at: ' + [filename ? UTF8ToString(filename) : 'unknown filename', line, func ? UTF8ToString(func) : 'unknown function']); + node.node_ops.setattr(node, { + timestamp: Date.now() + }); + }), + lchown: (function(path, uid, gid) { + FS.chown(path, uid, gid, true); + }), + fchown: (function(fd, uid, gid) { + var stream = FS.getStream(fd); + if (!stream) { + throw new FS.ErrnoError(8); + } + FS.chown(stream.node, uid, gid); + }), + truncate: (function(path, len) { + if (len < 0) { + throw new FS.ErrnoError(28); + } + var node; + if (typeof path === "string") { + var lookup = FS.lookupPath(path, { + follow: true + }); + node = lookup.node; + } else { + node = path; + } + if (!node.node_ops.setattr) { + throw new FS.ErrnoError(63); + } + if (FS.isDir(node.mode)) { + throw new FS.ErrnoError(31); + } + if (!FS.isFile(node.mode)) { + throw new FS.ErrnoError(28); + } + var err = FS.nodePermissions(node, "w"); + if (err) { + throw new FS.ErrnoError(err); + } + node.node_ops.setattr(node, { + size: len, + timestamp: Date.now() + }); + }), + ftruncate: (function(fd, len) { + var stream = FS.getStream(fd); + if (!stream) { + throw new FS.ErrnoError(8); + } + if ((stream.flags & 2097155) === 0) { + throw new FS.ErrnoError(28); + } + FS.truncate(stream.node, len); + }), + utime: (function(path, atime, mtime) { + var lookup = FS.lookupPath(path, { + follow: true + }); + var node = lookup.node; + node.node_ops.setattr(node, { + timestamp: Math.max(atime, mtime) + }); + }), + open: (function(path, flags, mode, fd_start, fd_end) { + if (path === "") { + throw new FS.ErrnoError(44); + } + flags = typeof flags === "string" ? FS.modeStringToFlags(flags) : flags; + mode = typeof mode === "undefined" ? 438 : mode; + if (flags & 64) { + mode = mode & 4095 | 32768; + } else { + mode = 0; + } + var node; + if (typeof path === "object") { + node = path; + } else { + path = PATH.normalize(path); + try { + var lookup = FS.lookupPath(path, { + follow: !(flags & 131072) + }); + node = lookup.node; + } catch (e) {} + } + var created = false; + if (flags & 64) { + if (node) { + if (flags & 128) { + throw new FS.ErrnoError(20); } - Module["___assert_fail"] = ___assert_fail; - - - - var PROCINFO={ppid:1,pid:42,sid:42,pgid:42}; - Module["PROCINFO"] = PROCINFO; - - - var __pthread_ptr=0; - Module["__pthread_ptr"] = __pthread_ptr; - - var __pthread_is_main_runtime_thread=0; - Module["__pthread_is_main_runtime_thread"] = __pthread_is_main_runtime_thread; - - var __pthread_is_main_browser_thread=0; - Module["__pthread_is_main_browser_thread"] = __pthread_is_main_browser_thread;function __register_pthread_ptr(pthreadPtr, isMainBrowserThread, isMainRuntimeThread) { - pthreadPtr = pthreadPtr|0; - isMainBrowserThread = isMainBrowserThread|0; - isMainRuntimeThread = isMainRuntimeThread|0; - __pthread_ptr = pthreadPtr; - __pthread_is_main_browser_thread = isMainBrowserThread; - __pthread_is_main_runtime_thread = isMainRuntimeThread; + } else { + node = FS.mknod(path, mode, 0); + created = true; + } + } + if (!node) { + throw new FS.ErrnoError(44); + } + if (FS.isChrdev(node.mode)) { + flags &= ~512; + } + if (flags & 65536 && !FS.isDir(node.mode)) { + throw new FS.ErrnoError(54); + } + if (!created) { + var err = FS.mayOpen(node, flags); + if (err) { + throw new FS.ErrnoError(err); + } + } + if (flags & 512) { + FS.truncate(node, 0); + } + flags &= ~(128 | 512); + var stream = FS.createStream({ + node: node, + path: FS.getPath(node), + flags: flags, + seekable: true, + position: 0, + stream_ops: node.stream_ops, + ungotten: [], + error: false + }, fd_start, fd_end); + if (stream.stream_ops.open) { + stream.stream_ops.open(stream); + } + if (Module["logReadFiles"] && !(flags & 1)) { + if (!FS.readFiles) FS.readFiles = {}; + if (!(path in FS.readFiles)) { + FS.readFiles[path] = 1; + console.log("FS.trackingDelegate error on read file: " + path); + } + } + try { + if (FS.trackingDelegate["onOpenFile"]) { + var trackingFlags = 0; + if ((flags & 2097155) !== 1) { + trackingFlags |= FS.tracking.openFlags.READ; } - Module["__register_pthread_ptr"] = __register_pthread_ptr; - - var ERRNO_CODES={EPERM:63,ENOENT:44,ESRCH:71,EINTR:27,EIO:29,ENXIO:60,E2BIG:1,ENOEXEC:45,EBADF:8,ECHILD:12,EAGAIN:6,EWOULDBLOCK:6,ENOMEM:48,EACCES:2,EFAULT:21,ENOTBLK:105,EBUSY:10,EEXIST:20,EXDEV:75,ENODEV:43,ENOTDIR:54,EISDIR:31,EINVAL:28,ENFILE:41,EMFILE:33,ENOTTY:59,ETXTBSY:74,EFBIG:22,ENOSPC:51,ESPIPE:70,EROFS:69,EMLINK:34,EPIPE:64,EDOM:18,ERANGE:68,ENOMSG:49,EIDRM:24,ECHRNG:106,EL2NSYNC:156,EL3HLT:107,EL3RST:108,ELNRNG:109,EUNATCH:110,ENOCSI:111,EL2HLT:112,EDEADLK:16,ENOLCK:46,EBADE:113,EBADR:114,EXFULL:115,ENOANO:104,EBADRQC:103,EBADSLT:102,EDEADLOCK:16,EBFONT:101,ENOSTR:100,ENODATA:116,ETIME:117,ENOSR:118,ENONET:119,ENOPKG:120,EREMOTE:121,ENOLINK:47,EADV:122,ESRMNT:123,ECOMM:124,EPROTO:65,EMULTIHOP:36,EDOTDOT:125,EBADMSG:9,ENOTUNIQ:126,EBADFD:127,EREMCHG:128,ELIBACC:129,ELIBBAD:130,ELIBSCN:131,ELIBMAX:132,ELIBEXEC:133,ENOSYS:52,ENOTEMPTY:55,ENAMETOOLONG:37,ELOOP:32,EOPNOTSUPP:138,EPFNOSUPPORT:139,ECONNRESET:15,ENOBUFS:42,EAFNOSUPPORT:5,EPROTOTYPE:67,ENOTSOCK:57,ENOPROTOOPT:50,ESHUTDOWN:140,ECONNREFUSED:14,EADDRINUSE:3,ECONNABORTED:13,ENETUNREACH:40,ENETDOWN:38,ETIMEDOUT:73,EHOSTDOWN:142,EHOSTUNREACH:23,EINPROGRESS:26,EALREADY:7,EDESTADDRREQ:17,EMSGSIZE:35,EPROTONOSUPPORT:66,ESOCKTNOSUPPORT:137,EADDRNOTAVAIL:4,ENETRESET:39,EISCONN:30,ENOTCONN:53,ETOOMANYREFS:141,EUSERS:136,EDQUOT:19,ESTALE:72,ENOTSUP:138,ENOMEDIUM:148,EILSEQ:25,EOVERFLOW:61,ECANCELED:11,ENOTRECOVERABLE:56,EOWNERDEAD:62,ESTRPIPE:135}; - Module["ERRNO_CODES"] = ERRNO_CODES; - - - var __main_thread_futex_wait_address=12595904; - Module["__main_thread_futex_wait_address"] = __main_thread_futex_wait_address;function _emscripten_futex_wake(addr, count) { - if (addr <= 0 || addr > HEAP8.length || addr&3 != 0 || count < 0) return -28; - if (count == 0) return 0; - // Waking (at least) INT_MAX waiters is defined to mean wake all callers. - // For Atomics.notify() API Infinity is to be passed in that case. - if (count >= 2147483647) count = Infinity; - // dump('futex_wake addr:' + addr + ' by thread: ' + _pthread_self() + (ENVIRONMENT_IS_PTHREAD?'(pthread)':'') + '\n'); - - // See if main thread is waiting on this address? If so, wake it up by resetting its wake location to zero. - // Note that this is not a fair procedure, since we always wake main thread first before any workers, so - // this scheme does not adhere to real queue-based waiting. - var mainThreadWaitAddress = Atomics.load(HEAP32, __main_thread_futex_wait_address >> 2); - var mainThreadWoken = 0; - if (mainThreadWaitAddress == addr) { - var loadedAddr = Atomics.compareExchange(HEAP32, __main_thread_futex_wait_address >> 2, mainThreadWaitAddress, 0); - if (loadedAddr == mainThreadWaitAddress) { - --count; - mainThreadWoken = 1; - if (count <= 0) return 1; - } - } - - // Wake any workers waiting on this address. - var ret = Atomics.notify(HEAP32, addr >> 2, count); - if (ret >= 0) return ret + mainThreadWoken; - throw 'Atomics.notify returned an unexpected value ' + ret; - } - Module["_emscripten_futex_wake"] = _emscripten_futex_wake; - - function __kill_thread(pthread_ptr) { - if (ENVIRONMENT_IS_PTHREAD) throw 'Internal Error! _kill_thread() can only ever be called from main application thread!'; - if (!pthread_ptr) throw 'Internal Error! Null pthread_ptr in _kill_thread!'; - HEAP32[(((pthread_ptr)+(24))>>2)]=0; - var pthread = PThread.pthreads[pthread_ptr]; - pthread.worker.terminate(); - PThread.freeThreadData(pthread); - // The worker was completely nuked (not just the pthread execution it was hosting), so remove it from running workers - // but don't put it back to the pool. - PThread.runningWorkers.splice(PThread.runningWorkers.indexOf(pthread.worker), 1); // Not a running Worker anymore. - pthread.worker.pthread = undefined; - } - Module["__kill_thread"] = __kill_thread; - - function __cancel_thread(pthread_ptr) { - if (ENVIRONMENT_IS_PTHREAD) throw 'Internal Error! _cancel_thread() can only ever be called from main application thread!'; - if (!pthread_ptr) throw 'Internal Error! Null pthread_ptr in _cancel_thread!'; - var pthread = PThread.pthreads[pthread_ptr]; - pthread.worker.postMessage({ 'cmd': 'cancel' }); - } - Module["__cancel_thread"] = __cancel_thread; - - function __cleanup_thread(pthread_ptr) { - if (ENVIRONMENT_IS_PTHREAD) throw 'Internal Error! _cleanup_thread() can only ever be called from main application thread!'; - if (!pthread_ptr) throw 'Internal Error! Null pthread_ptr in _cleanup_thread!'; - HEAP32[(((pthread_ptr)+(24))>>2)]=0; - var pthread = PThread.pthreads[pthread_ptr]; - if (pthread) { - var worker = pthread.worker; - PThread.returnWorkerToPool(worker); - } - } - Module["__cleanup_thread"] = __cleanup_thread;var PThread={MAIN_THREAD_ID:1,mainThreadInfo:{schedPolicy:0,schedPrio:0},preallocatedWorkers:[],unusedWorkers:[],runningWorkers:[],initRuntime:function() { - // Pass the thread address inside the asm.js scope to store it for fast access that avoids the need for a FFI out. - // Global constructors trying to access this value will read the wrong value, but that is UB anyway. - __register_pthread_ptr(PThread.mainThreadBlock, /*isMainBrowserThread=*/!ENVIRONMENT_IS_WORKER, /*isMainRuntimeThread=*/1); - _emscripten_register_main_browser_thread_id(PThread.mainThreadBlock); - },initMainThreadBlock:function() { - if (ENVIRONMENT_IS_PTHREAD) return undefined; - - - PThread.mainThreadBlock = 12595120; - - for (var i = 0; i < 244/4; ++i) HEAPU32[PThread.mainThreadBlock/4+i] = 0; - - // The pthread struct has a field that points to itself - this is used as a magic ID to detect whether the pthread_t - // structure is 'alive'. - HEAP32[(((PThread.mainThreadBlock)+(24))>>2)]=PThread.mainThreadBlock; - - // pthread struct robust_list head should point to itself. - var headPtr = PThread.mainThreadBlock + 168; - HEAP32[((headPtr)>>2)]=headPtr; - - // Allocate memory for thread-local storage. - var tlsMemory = 12595376; - for (var i = 0; i < 128; ++i) HEAPU32[tlsMemory/4+i] = 0; - Atomics.store(HEAPU32, (PThread.mainThreadBlock + 116 ) >> 2, tlsMemory); // Init thread-local-storage memory array. - Atomics.store(HEAPU32, (PThread.mainThreadBlock + 52 ) >> 2, PThread.mainThreadBlock); // Main thread ID. - Atomics.store(HEAPU32, (PThread.mainThreadBlock + 56 ) >> 2, PROCINFO.pid); // Process ID. - - },initWorker:function() { - },pthreads:{},exitHandlers:null,setThreadStatus:function() {},runExitHandlers:function() { - if (PThread.exitHandlers !== null) { - while (PThread.exitHandlers.length > 0) { - PThread.exitHandlers.pop()(); - } - PThread.exitHandlers = null; - } - - // Call into the musl function that runs destructors of all thread-specific data. - if (ENVIRONMENT_IS_PTHREAD && threadInfoStruct) ___pthread_tsd_run_dtors(); - },threadExit:function(exitCode) { - var tb = _pthread_self(); - if (tb) { // If we haven't yet exited? - Atomics.store(HEAPU32, (tb + 4 ) >> 2, exitCode); - // When we publish this, the main thread is free to deallocate the thread object and we are done. - // Therefore set threadInfoStruct = 0; above to 'release' the object in this worker thread. - Atomics.store(HEAPU32, (tb + 0 ) >> 2, 1); - - // Disable all cancellation so that executing the cleanup handlers won't trigger another JS - // canceled exception to be thrown. - Atomics.store(HEAPU32, (tb + 72 ) >> 2, 1/*PTHREAD_CANCEL_DISABLE*/); - Atomics.store(HEAPU32, (tb + 76 ) >> 2, 0/*PTHREAD_CANCEL_DEFERRED*/); - PThread.runExitHandlers(); - - _emscripten_futex_wake(tb + 0, 2147483647); - __register_pthread_ptr(0, 0, 0); // Unregister the thread block also inside the asm.js scope. - threadInfoStruct = 0; - if (ENVIRONMENT_IS_PTHREAD) { - // Note: in theory we would like to return any offscreen canvases back to the main thread, - // but if we ever fetched a rendering context for them that would not be valid, so we don't try. - postMessage({ 'cmd': 'exit' }); - } - } - },threadCancel:function() { - PThread.runExitHandlers(); - Atomics.store(HEAPU32, (threadInfoStruct + 4 ) >> 2, -1/*PTHREAD_CANCELED*/); - Atomics.store(HEAPU32, (threadInfoStruct + 0 ) >> 2, 1); // Mark the thread as no longer running. - _emscripten_futex_wake(threadInfoStruct + 0, 2147483647); // wake all threads - threadInfoStruct = selfThreadId = 0; // Not hosting a pthread anymore in this worker, reset the info structures to null. - __register_pthread_ptr(0, 0, 0); // Unregister the thread block also inside the asm.js scope. - postMessage({ 'cmd': 'cancelDone' }); - },terminateAllThreads:function() { - for (var t in PThread.pthreads) { - var pthread = PThread.pthreads[t]; - if (pthread && pthread.worker) { - PThread.returnWorkerToPool(pthread.worker); - } - } - PThread.pthreads = {}; - - for (var i = 0; i < PThread.preallocatedWorkers.length; ++i) { - var worker = PThread.preallocatedWorkers[i]; - assert(!worker.pthread); // This Worker should not be hosting a pthread at this time. - worker.terminate(); - } - PThread.preallocatedWorkers = []; - - for (var i = 0; i < PThread.unusedWorkers.length; ++i) { - var worker = PThread.unusedWorkers[i]; - assert(!worker.pthread); // This Worker should not be hosting a pthread at this time. - worker.terminate(); - } - PThread.unusedWorkers = []; - - for (var i = 0; i < PThread.runningWorkers.length; ++i) { - var worker = PThread.runningWorkers[i]; - var pthread = worker.pthread; - assert(pthread, 'This Worker should have a pthread it is executing'); - PThread.freeThreadData(pthread); - worker.terminate(); - } - PThread.runningWorkers = []; - },freeThreadData:function(pthread) { - if (!pthread) return; - if (pthread.threadInfoStruct) { - var tlsMemory = HEAP32[(((pthread.threadInfoStruct)+(116))>>2)]; - HEAP32[(((pthread.threadInfoStruct)+(116))>>2)]=0; - _free(tlsMemory); - _free(pthread.threadInfoStruct); - } - pthread.threadInfoStruct = 0; - if (pthread.allocatedOwnStack && pthread.stackBase) _free(pthread.stackBase); - pthread.stackBase = 0; - if (pthread.worker) pthread.worker.pthread = null; - },returnWorkerToPool:function(worker) { - delete PThread.pthreads[worker.pthread.thread]; - //Note: worker is intentionally not terminated so the pool can dynamically grow. - PThread.unusedWorkers.push(worker); - PThread.runningWorkers.splice(PThread.runningWorkers.indexOf(worker), 1); // Not a running Worker anymore - PThread.freeThreadData(worker.pthread); - worker.pthread = undefined; // Detach the worker from the pthread object, and return it to the worker pool as an unused worker. - },receiveObjectTransfer:function(data) { - },allocateUnusedWorkers:function(numWorkers, onFinishedLoading) { - if (typeof SharedArrayBuffer === 'undefined') return; // No multithreading support, no-op. - - var workers = []; - - var numWorkersToCreate = numWorkers; - if (PThread.preallocatedWorkers.length > 0) { - var workersUsed = Math.min(PThread.preallocatedWorkers.length, numWorkers); - workers = workers.concat(PThread.preallocatedWorkers.splice(0, workersUsed)); - numWorkersToCreate -= workersUsed; - } - if (numWorkersToCreate > 0) { - workers = workers.concat(PThread.createNewWorkers(numWorkersToCreate)); - } - - // Add the listeners. - PThread.attachListenerToWorkers(workers, onFinishedLoading); - - // Load the wasm module into the worker. - for (var i = 0; i < numWorkers; ++i) { - var worker = workers[i]; - - - // Ask the new worker to load up the Emscripten-compiled page. This is a heavy operation. - worker.postMessage({ - 'cmd': 'load', - // If the application main .js file was loaded from a Blob, then it is not possible - // to access the URL of the current script that could be passed to a Web Worker so that - // it could load up the same file. In that case, developer must either deliver the Blob - // object in Module['mainScriptUrlOrBlob'], or a URL to it, so that pthread Workers can - // independently load up the same main application file. - 'urlOrBlob': Module['mainScriptUrlOrBlob'] || _scriptDir, - 'wasmMemory': wasmMemory, - 'wasmModule': wasmModule, - 'DYNAMIC_BASE': DYNAMIC_BASE, - 'DYNAMICTOP_PTR': DYNAMICTOP_PTR - }); - PThread.unusedWorkers.push(worker); - } - },attachListenerToWorkers:function(workers, onFinishedLoading) { - var numWorkersLoaded = 0; - var numWorkers = workers.length; - for (var i = 0; i < numWorkers; ++i) { - var worker = workers[i]; - (function(worker) { - worker.onmessage = function(e) { - var d = e['data']; - var cmd = d['cmd']; - // Sometimes we need to backproxy events to the calling thread (e.g. HTML5 DOM events handlers such as emscripten_set_mousemove_callback()), so keep track in a globally accessible variable about the thread that initiated the proxying. - if (worker.pthread) PThread.currentProxiedOperationCallerThread = worker.pthread.threadInfoStruct; - - // If this message is intended to a recipient that is not the main thread, forward it to the target thread. - if (d['targetThread'] && d['targetThread'] != _pthread_self()) { - var thread = PThread.pthreads[d.targetThread]; - if (thread) { - thread.worker.postMessage(e.data, d['transferList']); - } else { - console.error('Internal error! Worker sent a message "' + cmd + '" to target pthread ' + d['targetThread'] + ', but that thread no longer exists!'); - } - PThread.currentProxiedOperationCallerThread = undefined; - return; - } - - if (cmd === 'processQueuedMainThreadWork') { - // TODO: Must post message to main Emscripten thread in PROXY_TO_WORKER mode. - _emscripten_main_thread_process_queued_calls(); - } else if (cmd === 'spawnThread') { - __spawn_thread(e.data); - } else if (cmd === 'cleanupThread') { - __cleanup_thread(d['thread']); - } else if (cmd === 'killThread') { - __kill_thread(d['thread']); - } else if (cmd === 'cancelThread') { - __cancel_thread(d['thread']); - } else if (cmd === 'loaded') { - worker.loaded = true; - // If this Worker is already pending to start running a thread, launch the thread now - if (worker.runPthread) { - worker.runPthread(); - delete worker.runPthread; - } - ++numWorkersLoaded; - if (numWorkersLoaded === numWorkers && onFinishedLoading) { - onFinishedLoading(); - } - } else if (cmd === 'print') { - out('Thread ' + d['threadId'] + ': ' + d['text']); - } else if (cmd === 'printErr') { - err('Thread ' + d['threadId'] + ': ' + d['text']); - } else if (cmd === 'alert') { - alert('Thread ' + d['threadId'] + ': ' + d['text']); - } else if (cmd === 'exit') { - var detached = worker.pthread && Atomics.load(HEAPU32, (worker.pthread.thread + 80) >> 2); - if (detached) { - PThread.returnWorkerToPool(worker); - } - } else if (cmd === 'exitProcess') { - // A pthread has requested to exit the whole application process (runtime). - noExitRuntime = false; - try { - exit(d['returnCode']); - } catch (e) { - if (e instanceof ExitStatus) return; - throw e; - } - } else if (cmd === 'cancelDone') { - PThread.returnWorkerToPool(worker); - } else if (cmd === 'objectTransfer') { - PThread.receiveObjectTransfer(e.data); - } else if (e.data.target === 'setimmediate') { - worker.postMessage(e.data); // Worker wants to postMessage() to itself to implement setImmediate() emulation. - } else { - err("worker sent an unknown command " + cmd); - } - PThread.currentProxiedOperationCallerThread = undefined; - }; - - worker.onerror = function(e) { - err('pthread sent an error! ' + e.filename + ':' + e.lineno + ': ' + e.message); - }; - - if (ENVIRONMENT_HAS_NODE) { - worker.on('message', function(data) { - worker.onmessage({ data: data }); - }); - worker.on('error', function(data) { - worker.onerror(data); - }); - worker.on('exit', function(data) { - console.log('worker exited - TODO: update the worker queue?'); - }); - } - }(worker)); - } // for each worker - },createNewWorkers:function(numWorkers) { - // Creates new workers with the discovered pthread worker file. - if (typeof SharedArrayBuffer === 'undefined') return []; // No multithreading support, no-op. - var pthreadMainJs = "x2t.worker.js"; - // Allow HTML module to configure the location where the 'worker.js' file will be loaded from, - // via Module.locateFile() function. If not specified, then the default URL 'worker.js' relative - // to the main html file is loaded. - pthreadMainJs = locateFile(pthreadMainJs); - var newWorkers = []; - for (var i = 0; i < numWorkers; ++i) { - newWorkers.push(new Worker(pthreadMainJs)); - } - return newWorkers; - },getNewWorker:function() { - if (PThread.unusedWorkers.length == 0) PThread.allocateUnusedWorkers(1); - if (PThread.unusedWorkers.length > 0) return PThread.unusedWorkers.pop(); - else return null; - },busySpinWait:function(msecs) { - var t = performance.now() + msecs; - while(performance.now() < t) { - ; - } - }}; - Module["PThread"] = PThread;function ___call_main(argc, argv) { - var returnCode = _main(argc, argv); - if (!noExitRuntime) postMessage({ 'cmd': 'exitProcess', 'returnCode': returnCode }); - return returnCode; - } - Module["___call_main"] = ___call_main; - - - - function _emscripten_get_now() { abort() } - Module["_emscripten_get_now"] = _emscripten_get_now; - - function _emscripten_get_now_is_monotonic() { - // return whether emscripten_get_now is guaranteed monotonic; the Date.now - // implementation is not :( - return (0 - || ENVIRONMENT_IS_NODE - || (typeof dateNow !== 'undefined') - || (typeof performance === 'object' && performance && typeof performance['now'] === 'function') - ); + if ((flags & 2097155) !== 0) { + trackingFlags |= FS.tracking.openFlags.WRITE; } - Module["_emscripten_get_now_is_monotonic"] = _emscripten_get_now_is_monotonic; - - function ___setErrNo(value) { - if (Module['___errno_location']) HEAP32[((Module['___errno_location']())>>2)]=value; - else err('failed to set errno from JS'); - return value; - } - Module["___setErrNo"] = ___setErrNo;function _clock_gettime(clk_id, tp) { - // int clock_gettime(clockid_t clk_id, struct timespec *tp); - var now; - if (clk_id === 0) { - now = Date.now(); - } else if (clk_id === 1 && _emscripten_get_now_is_monotonic()) { - now = _emscripten_get_now(); - } else { - ___setErrNo(28); - return -1; - } - HEAP32[((tp)>>2)]=(now/1000)|0; // seconds - HEAP32[(((tp)+(4))>>2)]=((now % 1000)*1000*1000)|0; // nanoseconds - return 0; - } - Module["_clock_gettime"] = _clock_gettime;function ___clock_gettime(a0,a1 - ) { - return _clock_gettime(a0,a1); + FS.trackingDelegate["onOpenFile"](path, trackingFlags); + } + } catch (e) { + console.log("FS.trackingDelegate['onOpenFile']('" + path + "', flags) threw an exception: " + e.message); } - Module["___clock_gettime"] = ___clock_gettime; - - function ___cxa_allocate_exception(size) { - return _malloc(size); - } - Module["___cxa_allocate_exception"] = ___cxa_allocate_exception; - - - function _atexit(func, arg) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(1, 1, func, arg); - - warnOnce('atexit() called, but EXIT_RUNTIME is not set, so atexits() will not be called. set EXIT_RUNTIME to 1 (see the FAQ)'); - __ATEXIT__.unshift({ func: func, arg: arg }); - } - - Module["_atexit"] = _atexit;function ___cxa_atexit( - ) { - return _atexit.apply(null, arguments) + return stream; + }), + close: (function(stream) { + if (FS.isClosed(stream)) { + throw new FS.ErrnoError(8); } - Module["___cxa_atexit"] = ___cxa_atexit; - - - var ___exception_caught= []; - Module["___exception_caught"] = ___exception_caught; - - - var ___exception_infos={}; - Module["___exception_infos"] = ___exception_infos;function ___exception_deAdjust(adjusted) { - if (!adjusted || ___exception_infos[adjusted]) return adjusted; - for (var key in ___exception_infos) { - var ptr = +key; // the iteration key is a string, and if we throw this, it must be an integer as that is what we look for - var adj = ___exception_infos[ptr].adjusted; - var len = adj.length; - for (var i = 0; i < len; i++) { - if (adj[i] === adjusted) { - return ptr; - } - } - } - return adjusted; - } - Module["___exception_deAdjust"] = ___exception_deAdjust; - - var ___exception_last=0; - Module["___exception_last"] = ___exception_last;function ___cxa_rethrow() { - var ptr = ___exception_caught.pop(); - ptr = ___exception_deAdjust(ptr); - if (!___exception_infos[ptr].rethrown) { - // Only pop if the corresponding push was through rethrow_primary_exception - ___exception_caught.push(ptr); - ___exception_infos[ptr].rethrown = true; - } - ___exception_last = ptr; - throw ptr + " - Exception catching is disabled, this exception cannot be caught. Compile with -s DISABLE_EXCEPTION_CATCHING=0 or DISABLE_EXCEPTION_CATCHING=2 to catch."; - } - Module["___cxa_rethrow"] = ___cxa_rethrow; - - function ___cxa_throw(ptr, type, destructor) { - ___exception_infos[ptr] = { - ptr: ptr, - adjusted: [ptr], - type: type, - destructor: destructor, - refcount: 0, - caught: false, - rethrown: false - }; - ___exception_last = ptr; - if (!("uncaught_exception" in __ZSt18uncaught_exceptionv)) { - __ZSt18uncaught_exceptionv.uncaught_exceptions = 1; - } else { - __ZSt18uncaught_exceptionv.uncaught_exceptions++; - } - throw ptr + " - Exception catching is disabled, this exception cannot be caught. Compile with -s DISABLE_EXCEPTION_CATCHING=0 or DISABLE_EXCEPTION_CATCHING=2 to catch."; - } - Module["___cxa_throw"] = ___cxa_throw; - - function ___lock() {} - Module["___lock"] = ___lock; - - function ___map_file(pathname, size) { - ___setErrNo(63); - return -1; - } - Module["___map_file"] = ___map_file; - - - - var PATH={splitPath:function(filename) { - var splitPathRe = /^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/; - return splitPathRe.exec(filename).slice(1); - },normalizeArray:function(parts, allowAboveRoot) { - // if the path tries to go above the root, `up` ends up > 0 - var up = 0; - for (var i = parts.length - 1; i >= 0; i--) { - var last = parts[i]; - if (last === '.') { - parts.splice(i, 1); - } else if (last === '..') { - parts.splice(i, 1); - up++; - } else if (up) { - parts.splice(i, 1); - up--; - } - } - // if the path is allowed to go above the root, restore leading ..s - if (allowAboveRoot) { - for (; up; up--) { - parts.unshift('..'); - } - } - return parts; - },normalize:function(path) { - var isAbsolute = path.charAt(0) === '/', - trailingSlash = path.substr(-1) === '/'; - // Normalize the path - path = PATH.normalizeArray(path.split('/').filter(function(p) { - return !!p; - }), !isAbsolute).join('/'); - if (!path && !isAbsolute) { - path = '.'; - } - if (path && trailingSlash) { - path += '/'; - } - return (isAbsolute ? '/' : '') + path; - },dirname:function(path) { - var result = PATH.splitPath(path), - root = result[0], - dir = result[1]; - if (!root && !dir) { - // No dirname whatsoever - return '.'; - } - if (dir) { - // It has a dirname, strip trailing slash - dir = dir.substr(0, dir.length - 1); - } - return root + dir; - },basename:function(path) { - // EMSCRIPTEN return '/'' for '/', not an empty string - if (path === '/') return '/'; - var lastSlash = path.lastIndexOf('/'); - if (lastSlash === -1) return path; - return path.substr(lastSlash+1); - },extname:function(path) { - return PATH.splitPath(path)[3]; - },join:function() { - var paths = Array.prototype.slice.call(arguments, 0); - return PATH.normalize(paths.join('/')); - },join2:function(l, r) { - return PATH.normalize(l + '/' + r); - }}; - Module["PATH"] = PATH; - - - var PATH_FS={resolve:function() { - var resolvedPath = '', - resolvedAbsolute = false; - for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) { - var path = (i >= 0) ? arguments[i] : FS.cwd(); - // Skip empty and invalid entries - if (typeof path !== 'string') { - throw new TypeError('Arguments to path.resolve must be strings'); - } else if (!path) { - return ''; // an invalid portion invalidates the whole thing - } - resolvedPath = path + '/' + resolvedPath; - resolvedAbsolute = path.charAt(0) === '/'; - } - // At this point the path should be resolved to a full absolute path, but - // handle relative paths to be safe (might happen when process.cwd() fails) - resolvedPath = PATH.normalizeArray(resolvedPath.split('/').filter(function(p) { - return !!p; - }), !resolvedAbsolute).join('/'); - return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.'; - },relative:function(from, to) { - from = PATH_FS.resolve(from).substr(1); - to = PATH_FS.resolve(to).substr(1); - function trim(arr) { - var start = 0; - for (; start < arr.length; start++) { - if (arr[start] !== '') break; - } - var end = arr.length - 1; - for (; end >= 0; end--) { - if (arr[end] !== '') break; - } - if (start > end) return []; - return arr.slice(start, end - start + 1); - } - var fromParts = trim(from.split('/')); - var toParts = trim(to.split('/')); - var length = Math.min(fromParts.length, toParts.length); - var samePartsLength = length; - for (var i = 0; i < length; i++) { - if (fromParts[i] !== toParts[i]) { - samePartsLength = i; - break; - } - } - var outputParts = []; - for (var i = samePartsLength; i < fromParts.length; i++) { - outputParts.push('..'); - } - outputParts = outputParts.concat(toParts.slice(samePartsLength)); - return outputParts.join('/'); - }}; - Module["PATH_FS"] = PATH_FS; - - var TTY={ttys:[],init:function () { - // https://github.com/emscripten-core/emscripten/pull/1555 - // if (ENVIRONMENT_IS_NODE) { - // // currently, FS.init does not distinguish if process.stdin is a file or TTY - // // device, it always assumes it's a TTY device. because of this, we're forcing - // // process.stdin to UTF8 encoding to at least make stdin reading compatible - // // with text files until FS.init can be refactored. - // process['stdin']['setEncoding']('utf8'); - // } - },shutdown:function() { - // https://github.com/emscripten-core/emscripten/pull/1555 - // if (ENVIRONMENT_IS_NODE) { - // // inolen: any idea as to why node -e 'process.stdin.read()' wouldn't exit immediately (with process.stdin being a tty)? - // // isaacs: because now it's reading from the stream, you've expressed interest in it, so that read() kicks off a _read() which creates a ReadReq operation - // // inolen: I thought read() in that case was a synchronous operation that just grabbed some amount of buffered data if it exists? - // // isaacs: it is. but it also triggers a _read() call, which calls readStart() on the handle - // // isaacs: do process.stdin.pause() and i'd think it'd probably close the pending call - // process['stdin']['pause'](); - // } - },register:function(dev, ops) { - TTY.ttys[dev] = { input: [], output: [], ops: ops }; - FS.registerDevice(dev, TTY.stream_ops); - },stream_ops:{open:function(stream) { - var tty = TTY.ttys[stream.node.rdev]; - if (!tty) { - throw new FS.ErrnoError(43); - } - stream.tty = tty; - stream.seekable = false; - },close:function(stream) { - // flush any pending line data - stream.tty.ops.flush(stream.tty); - },flush:function(stream) { - stream.tty.ops.flush(stream.tty); - },read:function(stream, buffer, offset, length, pos /* ignored */) { - if (!stream.tty || !stream.tty.ops.get_char) { - throw new FS.ErrnoError(60); - } - var bytesRead = 0; - for (var i = 0; i < length; i++) { - var result; - try { - result = stream.tty.ops.get_char(stream.tty); - } catch (e) { - throw new FS.ErrnoError(29); - } - if (result === undefined && bytesRead === 0) { - throw new FS.ErrnoError(6); - } - if (result === null || result === undefined) break; - bytesRead++; - buffer[offset+i] = result; - } - if (bytesRead) { - stream.node.timestamp = Date.now(); - } - return bytesRead; - },write:function(stream, buffer, offset, length, pos) { - if (!stream.tty || !stream.tty.ops.put_char) { - throw new FS.ErrnoError(60); - } - try { - for (var i = 0; i < length; i++) { - stream.tty.ops.put_char(stream.tty, buffer[offset+i]); - } - } catch (e) { - throw new FS.ErrnoError(29); - } - if (length) { - stream.node.timestamp = Date.now(); - } - return i; - }},default_tty_ops:{get_char:function(tty) { - if (!tty.input.length) { - var result = null; - if (ENVIRONMENT_IS_NODE) { - // we will read data by chunks of BUFSIZE - var BUFSIZE = 256; - var buf = Buffer.alloc ? Buffer.alloc(BUFSIZE) : new Buffer(BUFSIZE); - var bytesRead = 0; - - try { - bytesRead = nodeFS.readSync(process.stdin.fd, buf, 0, BUFSIZE, null); - } catch(e) { - // Cross-platform differences: on Windows, reading EOF throws an exception, but on other OSes, - // reading EOF returns 0. Uniformize behavior by treating the EOF exception to return 0. - if (e.toString().indexOf('EOF') != -1) bytesRead = 0; - else throw e; - } - - if (bytesRead > 0) { - result = buf.slice(0, bytesRead).toString('utf-8'); - } else { - result = null; - } - } else - if (typeof window != 'undefined' && - typeof window.prompt == 'function') { - // Browser. - result = window.prompt('Input: '); // returns null on cancel - if (result !== null) { - result += '\n'; - } - } else if (typeof readline == 'function') { - // Command line. - result = readline(); - if (result !== null) { - result += '\n'; - } - } - if (!result) { - return null; - } - tty.input = intArrayFromString(result, true); - } - return tty.input.shift(); - },put_char:function(tty, val) { - if (val === null || val === 10) { - out(UTF8ArrayToString(tty.output, 0)); - tty.output = []; - } else { - if (val != 0) tty.output.push(val); // val == 0 would cut text output off in the middle. - } - },flush:function(tty) { - if (tty.output && tty.output.length > 0) { - out(UTF8ArrayToString(tty.output, 0)); - tty.output = []; - } - }},default_tty1_ops:{put_char:function(tty, val) { - if (val === null || val === 10) { - err(UTF8ArrayToString(tty.output, 0)); - tty.output = []; - } else { - if (val != 0) tty.output.push(val); - } - },flush:function(tty) { - if (tty.output && tty.output.length > 0) { - err(UTF8ArrayToString(tty.output, 0)); - tty.output = []; - } - }}}; - Module["TTY"] = TTY; - - var MEMFS={ops_table:null,mount:function(mount) { - return MEMFS.createNode(null, '/', 16384 | 511 /* 0777 */, 0); - },createNode:function(parent, name, mode, dev) { - if (FS.isBlkdev(mode) || FS.isFIFO(mode)) { - // no supported - throw new FS.ErrnoError(63); - } - if (!MEMFS.ops_table) { - MEMFS.ops_table = { - dir: { - node: { - getattr: MEMFS.node_ops.getattr, - setattr: MEMFS.node_ops.setattr, - lookup: MEMFS.node_ops.lookup, - mknod: MEMFS.node_ops.mknod, - rename: MEMFS.node_ops.rename, - unlink: MEMFS.node_ops.unlink, - rmdir: MEMFS.node_ops.rmdir, - readdir: MEMFS.node_ops.readdir, - symlink: MEMFS.node_ops.symlink - }, - stream: { - llseek: MEMFS.stream_ops.llseek - } - }, - file: { - node: { - getattr: MEMFS.node_ops.getattr, - setattr: MEMFS.node_ops.setattr - }, - stream: { - llseek: MEMFS.stream_ops.llseek, - read: MEMFS.stream_ops.read, - write: MEMFS.stream_ops.write, - allocate: MEMFS.stream_ops.allocate, - mmap: MEMFS.stream_ops.mmap, - msync: MEMFS.stream_ops.msync - } - }, - link: { - node: { - getattr: MEMFS.node_ops.getattr, - setattr: MEMFS.node_ops.setattr, - readlink: MEMFS.node_ops.readlink - }, - stream: {} - }, - chrdev: { - node: { - getattr: MEMFS.node_ops.getattr, - setattr: MEMFS.node_ops.setattr - }, - stream: FS.chrdev_stream_ops - } - }; - } - var node = FS.createNode(parent, name, mode, dev); - if (FS.isDir(node.mode)) { - node.node_ops = MEMFS.ops_table.dir.node; - node.stream_ops = MEMFS.ops_table.dir.stream; - node.contents = {}; - } else if (FS.isFile(node.mode)) { - node.node_ops = MEMFS.ops_table.file.node; - node.stream_ops = MEMFS.ops_table.file.stream; - node.usedBytes = 0; // The actual number of bytes used in the typed array, as opposed to contents.length which gives the whole capacity. - // When the byte data of the file is populated, this will point to either a typed array, or a normal JS array. Typed arrays are preferred - // for performance, and used by default. However, typed arrays are not resizable like normal JS arrays are, so there is a small disk size - // penalty involved for appending file writes that continuously grow a file similar to std::vector capacity vs used -scheme. - node.contents = null; - } else if (FS.isLink(node.mode)) { - node.node_ops = MEMFS.ops_table.link.node; - node.stream_ops = MEMFS.ops_table.link.stream; - } else if (FS.isChrdev(node.mode)) { - node.node_ops = MEMFS.ops_table.chrdev.node; - node.stream_ops = MEMFS.ops_table.chrdev.stream; - } - node.timestamp = Date.now(); - // add the new node to the parent - if (parent) { - parent.contents[name] = node; - } - return node; - },getFileDataAsRegularArray:function(node) { - if (node.contents && node.contents.subarray) { - var arr = []; - for (var i = 0; i < node.usedBytes; ++i) arr.push(node.contents[i]); - return arr; // Returns a copy of the original data. - } - return node.contents; // No-op, the file contents are already in a JS array. Return as-is. - },getFileDataAsTypedArray:function(node) { - if (!node.contents) return new Uint8Array; - if (node.contents.subarray) return node.contents.subarray(0, node.usedBytes); // Make sure to not return excess unused bytes. - return new Uint8Array(node.contents); - },expandFileStorage:function(node, newCapacity) { - var prevCapacity = node.contents ? node.contents.length : 0; - if (prevCapacity >= newCapacity) return; // No need to expand, the storage was already large enough. - // Don't expand strictly to the given requested limit if it's only a very small increase, but instead geometrically grow capacity. - // For small filesizes (<1MB), perform size*2 geometric increase, but for large sizes, do a much more conservative size*1.125 increase to - // avoid overshooting the allocation cap by a very large margin. - var CAPACITY_DOUBLING_MAX = 1024 * 1024; - newCapacity = Math.max(newCapacity, (prevCapacity * (prevCapacity < CAPACITY_DOUBLING_MAX ? 2.0 : 1.125)) | 0); - if (prevCapacity != 0) newCapacity = Math.max(newCapacity, 256); // At minimum allocate 256b for each file when expanding. - var oldContents = node.contents; - node.contents = new Uint8Array(newCapacity); // Allocate new storage. - if (node.usedBytes > 0) node.contents.set(oldContents.subarray(0, node.usedBytes), 0); // Copy old data over to the new storage. - return; - },resizeFileStorage:function(node, newSize) { - if (node.usedBytes == newSize) return; - if (newSize == 0) { - node.contents = null; // Fully decommit when requesting a resize to zero. - node.usedBytes = 0; - return; - } - if (!node.contents || node.contents.subarray) { // Resize a typed array if that is being used as the backing store. - var oldContents = node.contents; - node.contents = new Uint8Array(new ArrayBuffer(newSize)); // Allocate new storage. - if (oldContents) { - node.contents.set(oldContents.subarray(0, Math.min(newSize, node.usedBytes))); // Copy old data over to the new storage. - } - node.usedBytes = newSize; - return; - } - // Backing with a JS array. - if (!node.contents) node.contents = []; - if (node.contents.length > newSize) node.contents.length = newSize; - else while (node.contents.length < newSize) node.contents.push(0); - node.usedBytes = newSize; - },node_ops:{getattr:function(node) { - var attr = {}; - // device numbers reuse inode numbers. - attr.dev = FS.isChrdev(node.mode) ? node.id : 1; - attr.ino = node.id; - attr.mode = node.mode; - attr.nlink = 1; - attr.uid = 0; - attr.gid = 0; - attr.rdev = node.rdev; - if (FS.isDir(node.mode)) { - attr.size = 4096; - } else if (FS.isFile(node.mode)) { - attr.size = node.usedBytes; - } else if (FS.isLink(node.mode)) { - attr.size = node.link.length; - } else { - attr.size = 0; - } - attr.atime = new Date(node.timestamp); - attr.mtime = new Date(node.timestamp); - attr.ctime = new Date(node.timestamp); - // NOTE: In our implementation, st_blocks = Math.ceil(st_size/st_blksize), - // but this is not required by the standard. - attr.blksize = 4096; - attr.blocks = Math.ceil(attr.size / attr.blksize); - return attr; - },setattr:function(node, attr) { - if (attr.mode !== undefined) { - node.mode = attr.mode; - } - if (attr.timestamp !== undefined) { - node.timestamp = attr.timestamp; - } - if (attr.size !== undefined) { - MEMFS.resizeFileStorage(node, attr.size); - } - },lookup:function(parent, name) { - throw FS.genericErrors[44]; - },mknod:function(parent, name, mode, dev) { - return MEMFS.createNode(parent, name, mode, dev); - },rename:function(old_node, new_dir, new_name) { - // if we're overwriting a directory at new_name, make sure it's empty. - if (FS.isDir(old_node.mode)) { - var new_node; - try { - new_node = FS.lookupNode(new_dir, new_name); - } catch (e) { - } - if (new_node) { - for (var i in new_node.contents) { - throw new FS.ErrnoError(55); - } - } - } - // do the internal rewiring - delete old_node.parent.contents[old_node.name]; - old_node.name = new_name; - new_dir.contents[new_name] = old_node; - old_node.parent = new_dir; - },unlink:function(parent, name) { - delete parent.contents[name]; - },rmdir:function(parent, name) { - var node = FS.lookupNode(parent, name); - for (var i in node.contents) { - throw new FS.ErrnoError(55); - } - delete parent.contents[name]; - },readdir:function(node) { - var entries = ['.', '..']; - for (var key in node.contents) { - if (!node.contents.hasOwnProperty(key)) { - continue; - } - entries.push(key); - } - return entries; - },symlink:function(parent, newname, oldpath) { - var node = MEMFS.createNode(parent, newname, 511 /* 0777 */ | 40960, 0); - node.link = oldpath; - return node; - },readlink:function(node) { - if (!FS.isLink(node.mode)) { - throw new FS.ErrnoError(28); - } - return node.link; - }},stream_ops:{read:function(stream, buffer, offset, length, position) { - var contents = stream.node.contents; - if (position >= stream.node.usedBytes) return 0; - var size = Math.min(stream.node.usedBytes - position, length); - assert(size >= 0); - if (size > 8 && contents.subarray) { // non-trivial, and typed array - buffer.set(contents.subarray(position, position + size), offset); - } else { - for (var i = 0; i < size; i++) buffer[offset + i] = contents[position + i]; - } - return size; - },write:function(stream, buffer, offset, length, position, canOwn) { - // The data buffer should be a typed array view - assert(!(buffer instanceof ArrayBuffer)); - - if (!length) return 0; - var node = stream.node; - node.timestamp = Date.now(); - - if (buffer.subarray && (!node.contents || node.contents.subarray)) { // This write is from a typed array to a typed array? - if (canOwn) { - assert(position === 0, 'canOwn must imply no weird position inside the file'); - node.contents = buffer.subarray(offset, offset + length); - node.usedBytes = length; - return length; - } else if (node.usedBytes === 0 && position === 0) { // If this is a simple first write to an empty file, do a fast set since we don't need to care about old data. - node.contents = new Uint8Array(buffer.subarray(offset, offset + length)); - node.usedBytes = length; - return length; - } else if (position + length <= node.usedBytes) { // Writing to an already allocated and used subrange of the file? - node.contents.set(buffer.subarray(offset, offset + length), position); - return length; - } - } - - // Appending to an existing file and we need to reallocate, or source data did not come as a typed array. - MEMFS.expandFileStorage(node, position+length); - if (node.contents.subarray && buffer.subarray) node.contents.set(buffer.subarray(offset, offset + length), position); // Use typed array write if available. - else { - for (var i = 0; i < length; i++) { - node.contents[position + i] = buffer[offset + i]; // Or fall back to manual write if not. - } - } - node.usedBytes = Math.max(node.usedBytes, position+length); - return length; - },llseek:function(stream, offset, whence) { - var position = offset; - if (whence === 1) { - position += stream.position; - } else if (whence === 2) { - if (FS.isFile(stream.node.mode)) { - position += stream.node.usedBytes; - } - } - if (position < 0) { - throw new FS.ErrnoError(28); - } - return position; - },allocate:function(stream, offset, length) { - MEMFS.expandFileStorage(stream.node, offset + length); - stream.node.usedBytes = Math.max(stream.node.usedBytes, offset + length); - },mmap:function(stream, buffer, offset, length, position, prot, flags) { - // The data buffer should be a typed array view - assert(!(buffer instanceof ArrayBuffer)); - if (!FS.isFile(stream.node.mode)) { - throw new FS.ErrnoError(43); - } - var ptr; - var allocated; - var contents = stream.node.contents; - // Only make a new copy when MAP_PRIVATE is specified. - if ( !(flags & 2) && - contents.buffer === buffer.buffer ) { - // We can't emulate MAP_SHARED when the file is not backed by the buffer - // we're mapping to (e.g. the HEAP buffer). - allocated = false; - ptr = contents.byteOffset; - } else { - // Try to avoid unnecessary slices. - if (position > 0 || position + length < stream.node.usedBytes) { - if (contents.subarray) { - contents = contents.subarray(position, position + length); - } else { - contents = Array.prototype.slice.call(contents, position, position + length); - } - } - allocated = true; - // malloc() can lead to growing the heap. If targeting the heap, we need to - // re-acquire the heap buffer object in case growth had occurred. - var fromHeap = (buffer.buffer == HEAP8.buffer); - ptr = _malloc(length); - if (!ptr) { - throw new FS.ErrnoError(48); - } - (fromHeap ? HEAP8 : buffer).set(contents, ptr); - } - return { ptr: ptr, allocated: allocated }; - },msync:function(stream, buffer, offset, length, mmapFlags) { - if (!FS.isFile(stream.node.mode)) { - throw new FS.ErrnoError(43); - } - if (mmapFlags & 2) { - // MAP_PRIVATE calls need not to be synced back to underlying fs - return 0; - } - - var bytesWritten = MEMFS.stream_ops.write(stream, buffer, 0, length, offset, false); - // should we check if bytesWritten and length are the same? - return 0; - }}}; - Module["MEMFS"] = MEMFS; - - var NODEFS={isWindows:false,staticInit:function() { - NODEFS.isWindows = !!process.platform.match(/^win/); - var flags = process["binding"]("constants"); - // Node.js 4 compatibility: it has no namespaces for constants - if (flags["fs"]) { - flags = flags["fs"]; - } - NODEFS.flagsForNodeMap = { - "1024": flags["O_APPEND"], - "64": flags["O_CREAT"], - "128": flags["O_EXCL"], - "0": flags["O_RDONLY"], - "2": flags["O_RDWR"], - "4096": flags["O_SYNC"], - "512": flags["O_TRUNC"], - "1": flags["O_WRONLY"] - }; - },bufferFrom:function (arrayBuffer) { - // Node.js < 4.5 compatibility: Buffer.from does not support ArrayBuffer - // Buffer.from before 4.5 was just a method inherited from Uint8Array - // Buffer.alloc has been added with Buffer.from together, so check it instead - return Buffer["alloc"] ? Buffer.from(arrayBuffer) : new Buffer(arrayBuffer); - },convertNodeCode:function(e) { - var code = e.code; - assert(code in ERRNO_CODES); - return ERRNO_CODES[code]; - },mount:function (mount) { - assert(ENVIRONMENT_HAS_NODE); - return NODEFS.createNode(null, '/', NODEFS.getMode(mount.opts.root), 0); - },createNode:function (parent, name, mode, dev) { - if (!FS.isDir(mode) && !FS.isFile(mode) && !FS.isLink(mode)) { - throw new FS.ErrnoError(28); - } - var node = FS.createNode(parent, name, mode); - node.node_ops = NODEFS.node_ops; - node.stream_ops = NODEFS.stream_ops; - return node; - },getMode:function (path) { - var stat; - try { - stat = fs.lstatSync(path); - if (NODEFS.isWindows) { - // Node.js on Windows never represents permission bit 'x', so - // propagate read bits to execute bits - stat.mode = stat.mode | ((stat.mode & 292) >> 2); - } - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - return stat.mode; - },realPath:function (node) { - var parts = []; - while (node.parent !== node) { - parts.push(node.name); - node = node.parent; - } - parts.push(node.mount.opts.root); - parts.reverse(); - return PATH.join.apply(null, parts); - },flagsForNode:function(flags) { - flags &= ~0x200000 /*O_PATH*/; // Ignore this flag from musl, otherwise node.js fails to open the file. - flags &= ~0x800 /*O_NONBLOCK*/; // Ignore this flag from musl, otherwise node.js fails to open the file. - flags &= ~0x8000 /*O_LARGEFILE*/; // Ignore this flag from musl, otherwise node.js fails to open the file. - flags &= ~0x80000 /*O_CLOEXEC*/; // Some applications may pass it; it makes no sense for a single process. - var newFlags = 0; - for (var k in NODEFS.flagsForNodeMap) { - if (flags & k) { - newFlags |= NODEFS.flagsForNodeMap[k]; - flags ^= k; - } - } - - if (!flags) { - return newFlags; - } else { - throw new FS.ErrnoError(28); - } - },node_ops:{getattr:function(node) { - var path = NODEFS.realPath(node); - var stat; - try { - stat = fs.lstatSync(path); - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - // node.js v0.10.20 doesn't report blksize and blocks on Windows. Fake them with default blksize of 4096. - // See http://support.microsoft.com/kb/140365 - if (NODEFS.isWindows && !stat.blksize) { - stat.blksize = 4096; - } - if (NODEFS.isWindows && !stat.blocks) { - stat.blocks = (stat.size+stat.blksize-1)/stat.blksize|0; - } - return { - dev: stat.dev, - ino: stat.ino, - mode: stat.mode, - nlink: stat.nlink, - uid: stat.uid, - gid: stat.gid, - rdev: stat.rdev, - size: stat.size, - atime: stat.atime, - mtime: stat.mtime, - ctime: stat.ctime, - blksize: stat.blksize, - blocks: stat.blocks - }; - },setattr:function(node, attr) { - var path = NODEFS.realPath(node); - try { - if (attr.mode !== undefined) { - fs.chmodSync(path, attr.mode); - // update the common node structure mode as well - node.mode = attr.mode; - } - if (attr.timestamp !== undefined) { - var date = new Date(attr.timestamp); - fs.utimesSync(path, date, date); - } - if (attr.size !== undefined) { - fs.truncateSync(path, attr.size); - } - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },lookup:function (parent, name) { - var path = PATH.join2(NODEFS.realPath(parent), name); - var mode = NODEFS.getMode(path); - return NODEFS.createNode(parent, name, mode); - },mknod:function (parent, name, mode, dev) { - var node = NODEFS.createNode(parent, name, mode, dev); - // create the backing node for this in the fs root as well - var path = NODEFS.realPath(node); - try { - if (FS.isDir(node.mode)) { - fs.mkdirSync(path, node.mode); - } else { - fs.writeFileSync(path, '', { mode: node.mode }); - } - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - return node; - },rename:function (oldNode, newDir, newName) { - var oldPath = NODEFS.realPath(oldNode); - var newPath = PATH.join2(NODEFS.realPath(newDir), newName); - try { - fs.renameSync(oldPath, newPath); - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },unlink:function(parent, name) { - var path = PATH.join2(NODEFS.realPath(parent), name); - try { - fs.unlinkSync(path); - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },rmdir:function(parent, name) { - var path = PATH.join2(NODEFS.realPath(parent), name); - try { - fs.rmdirSync(path); - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },readdir:function(node) { - var path = NODEFS.realPath(node); - try { - return fs.readdirSync(path); - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },symlink:function(parent, newName, oldPath) { - var newPath = PATH.join2(NODEFS.realPath(parent), newName); - try { - fs.symlinkSync(oldPath, newPath); - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },readlink:function(node) { - var path = NODEFS.realPath(node); - try { - path = fs.readlinkSync(path); - path = NODEJS_PATH.relative(NODEJS_PATH.resolve(node.mount.opts.root), path); - return path; - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - }},stream_ops:{open:function (stream) { - var path = NODEFS.realPath(stream.node); - try { - if (FS.isFile(stream.node.mode)) { - stream.nfd = fs.openSync(path, NODEFS.flagsForNode(stream.flags)); - } - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },close:function (stream) { - try { - if (FS.isFile(stream.node.mode) && stream.nfd) { - fs.closeSync(stream.nfd); - } - } catch (e) { - if (!e.code) throw e; - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },read:function (stream, buffer, offset, length, position) { - // Node.js < 6 compatibility: node errors on 0 length reads - if (length === 0) return 0; - try { - return fs.readSync(stream.nfd, NODEFS.bufferFrom(buffer.buffer), offset, length, position); - } catch (e) { - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },write:function (stream, buffer, offset, length, position) { - try { - return fs.writeSync(stream.nfd, NODEFS.bufferFrom(buffer.buffer), offset, length, position); - } catch (e) { - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - },llseek:function (stream, offset, whence) { - var position = offset; - if (whence === 1) { - position += stream.position; - } else if (whence === 2) { - if (FS.isFile(stream.node.mode)) { - try { - var stat = fs.fstatSync(stream.nfd); - position += stat.size; - } catch (e) { - throw new FS.ErrnoError(NODEFS.convertNodeCode(e)); - } - } - } - - if (position < 0) { - throw new FS.ErrnoError(28); - } - - return position; - }}}; - Module["NODEFS"] = NODEFS; - - var ERRNO_MESSAGES={0:"Success",1:"Arg list too long",2:"Permission denied",3:"Address already in use",4:"Address not available",5:"Address family not supported by protocol family",6:"No more processes",7:"Socket already connected",8:"Bad file number",9:"Trying to read unreadable message",10:"Mount device busy",11:"Operation canceled",12:"No children",13:"Connection aborted",14:"Connection refused",15:"Connection reset by peer",16:"File locking deadlock error",17:"Destination address required",18:"Math arg out of domain of func",19:"Quota exceeded",20:"File exists",21:"Bad address",22:"File too large",23:"Host is unreachable",24:"Identifier removed",25:"Illegal byte sequence",26:"Connection already in progress",27:"Interrupted system call",28:"Invalid argument",29:"I/O error",30:"Socket is already connected",31:"Is a directory",32:"Too many symbolic links",33:"Too many open files",34:"Too many links",35:"Message too long",36:"Multihop attempted",37:"File or path name too long",38:"Network interface is not configured",39:"Connection reset by network",40:"Network is unreachable",41:"Too many open files in system",42:"No buffer space available",43:"No such device",44:"No such file or directory",45:"Exec format error",46:"No record locks available",47:"The link has been severed",48:"Not enough core",49:"No message of desired type",50:"Protocol not available",51:"No space left on device",52:"Function not implemented",53:"Socket is not connected",54:"Not a directory",55:"Directory not empty",56:"State not recoverable",57:"Socket operation on non-socket",59:"Not a typewriter",60:"No such device or address",61:"Value too large for defined data type",62:"Previous owner died",63:"Not super-user",64:"Broken pipe",65:"Protocol error",66:"Unknown protocol",67:"Protocol wrong type for socket",68:"Math result not representable",69:"Read only file system",70:"Illegal seek",71:"No such process",72:"Stale file handle",73:"Connection timed out",74:"Text file busy",75:"Cross-device link",100:"Device not a stream",101:"Bad font file fmt",102:"Invalid slot",103:"Invalid request code",104:"No anode",105:"Block device required",106:"Channel number out of range",107:"Level 3 halted",108:"Level 3 reset",109:"Link number out of range",110:"Protocol driver not attached",111:"No CSI structure available",112:"Level 2 halted",113:"Invalid exchange",114:"Invalid request descriptor",115:"Exchange full",116:"No data (for no delay io)",117:"Timer expired",118:"Out of streams resources",119:"Machine is not on the network",120:"Package not installed",121:"The object is remote",122:"Advertise error",123:"Srmount error",124:"Communication error on send",125:"Cross mount point (not really error)",126:"Given log. name not unique",127:"f.d. invalid for this operation",128:"Remote address changed",129:"Can access a needed shared lib",130:"Accessing a corrupted shared lib",131:".lib section in a.out corrupted",132:"Attempting to link in too many libs",133:"Attempting to exec a shared library",135:"Streams pipe error",136:"Too many users",137:"Socket type not supported",138:"Not supported",139:"Protocol family not supported",140:"Can't send after socket shutdown",141:"Too many references",142:"Host is down",148:"No medium (in tape drive)",156:"Level 2 not synchronized"}; - Module["ERRNO_MESSAGES"] = ERRNO_MESSAGES;var FS={root:null,mounts:[],devices:{},streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:false,ignorePermissions:true,trackingDelegate:{},tracking:{openFlags:{READ:1,WRITE:2}},ErrnoError:null,genericErrors:{},filesystems:null,syncFSRequests:0,handleFSError:function(e) { - if (!(e instanceof FS.ErrnoError)) throw e + ' : ' + stackTrace(); - return ___setErrNo(e.errno); - },lookupPath:function(path, opts) { - path = PATH_FS.resolve(FS.cwd(), path); - opts = opts || {}; - - if (!path) return { path: '', node: null }; - - var defaults = { - follow_mount: true, - recurse_count: 0 - }; - for (var key in defaults) { - if (opts[key] === undefined) { - opts[key] = defaults[key]; - } - } - - if (opts.recurse_count > 8) { // max recursive lookup of 8 - throw new FS.ErrnoError(32); - } - - // split the path - var parts = PATH.normalizeArray(path.split('/').filter(function(p) { - return !!p; - }), false); - - // start at the root - var current = FS.root; - var current_path = '/'; - - for (var i = 0; i < parts.length; i++) { - var islast = (i === parts.length-1); - if (islast && opts.parent) { - // stop resolving - break; - } - - current = FS.lookupNode(current, parts[i]); - current_path = PATH.join2(current_path, parts[i]); - - // jump to the mount's root node if this is a mountpoint - if (FS.isMountpoint(current)) { - if (!islast || (islast && opts.follow_mount)) { - current = current.mounted.root; - } - } - - // by default, lookupPath will not follow a symlink if it is the final path component. - // setting opts.follow = true will override this behavior. - if (!islast || opts.follow) { - var count = 0; - while (FS.isLink(current.mode)) { - var link = FS.readlink(current_path); - current_path = PATH_FS.resolve(PATH.dirname(current_path), link); - - var lookup = FS.lookupPath(current_path, { recurse_count: opts.recurse_count }); - current = lookup.node; - - if (count++ > 40) { // limit max consecutive symlinks to 40 (SYMLOOP_MAX). - throw new FS.ErrnoError(32); - } - } - } - } - - return { path: current_path, node: current }; - },getPath:function(node) { - var path; - while (true) { - if (FS.isRoot(node)) { - var mount = node.mount.mountpoint; - if (!path) return mount; - return mount[mount.length-1] !== '/' ? mount + '/' + path : mount + path; - } - path = path ? node.name + '/' + path : node.name; - node = node.parent; - } - },hashName:function(parentid, name) { - var hash = 0; - - - for (var i = 0; i < name.length; i++) { - hash = ((hash << 5) - hash + name.charCodeAt(i)) | 0; - } - return ((parentid + hash) >>> 0) % FS.nameTable.length; - },hashAddNode:function(node) { - var hash = FS.hashName(node.parent.id, node.name); - node.name_next = FS.nameTable[hash]; - FS.nameTable[hash] = node; - },hashRemoveNode:function(node) { - var hash = FS.hashName(node.parent.id, node.name); - if (FS.nameTable[hash] === node) { - FS.nameTable[hash] = node.name_next; - } else { - var current = FS.nameTable[hash]; - while (current) { - if (current.name_next === node) { - current.name_next = node.name_next; - break; - } - current = current.name_next; - } - } - },lookupNode:function(parent, name) { - var err = FS.mayLookup(parent); - if (err) { - throw new FS.ErrnoError(err, parent); - } - var hash = FS.hashName(parent.id, name); - for (var node = FS.nameTable[hash]; node; node = node.name_next) { - var nodeName = node.name; - if (node.parent.id === parent.id && nodeName === name) { - return node; - } - } - // if we failed to find it in the cache, call into the VFS - return FS.lookup(parent, name); - },createNode:function(parent, name, mode, rdev) { - if (!FS.FSNode) { - FS.FSNode = function(parent, name, mode, rdev) { - if (!parent) { - parent = this; // root node sets parent to itself - } - this.parent = parent; - this.mount = parent.mount; - this.mounted = null; - this.id = FS.nextInode++; - this.name = name; - this.mode = mode; - this.node_ops = {}; - this.stream_ops = {}; - this.rdev = rdev; - }; - - FS.FSNode.prototype = {}; - - // compatibility - var readMode = 292 | 73; - var writeMode = 146; - - // NOTE we must use Object.defineProperties instead of individual calls to - // Object.defineProperty in order to make closure compiler happy - Object.defineProperties(FS.FSNode.prototype, { - read: { - get: function() { return (this.mode & readMode) === readMode; }, - set: function(val) { val ? this.mode |= readMode : this.mode &= ~readMode; } - }, - write: { - get: function() { return (this.mode & writeMode) === writeMode; }, - set: function(val) { val ? this.mode |= writeMode : this.mode &= ~writeMode; } - }, - isFolder: { - get: function() { return FS.isDir(this.mode); } - }, - isDevice: { - get: function() { return FS.isChrdev(this.mode); } - } - }); - } - - var node = new FS.FSNode(parent, name, mode, rdev); - - FS.hashAddNode(node); - - return node; - },destroyNode:function(node) { - FS.hashRemoveNode(node); - },isRoot:function(node) { - return node === node.parent; - },isMountpoint:function(node) { - return !!node.mounted; - },isFile:function(mode) { - return (mode & 61440) === 32768; - },isDir:function(mode) { - return (mode & 61440) === 16384; - },isLink:function(mode) { - return (mode & 61440) === 40960; - },isChrdev:function(mode) { - return (mode & 61440) === 8192; - },isBlkdev:function(mode) { - return (mode & 61440) === 24576; - },isFIFO:function(mode) { - return (mode & 61440) === 4096; - },isSocket:function(mode) { - return (mode & 49152) === 49152; - },flagModes:{"r":0,"rs":1052672,"r+":2,"w":577,"wx":705,"xw":705,"w+":578,"wx+":706,"xw+":706,"a":1089,"ax":1217,"xa":1217,"a+":1090,"ax+":1218,"xa+":1218},modeStringToFlags:function(str) { - var flags = FS.flagModes[str]; - if (typeof flags === 'undefined') { - throw new Error('Unknown file open mode: ' + str); - } - return flags; - },flagsToPermissionString:function(flag) { - var perms = ['r', 'w', 'rw'][flag & 3]; - if ((flag & 512)) { - perms += 'w'; - } - return perms; - },nodePermissions:function(node, perms) { - if (FS.ignorePermissions) { - return 0; - } - // return 0 if any user, group or owner bits are set. - if (perms.indexOf('r') !== -1 && !(node.mode & 292)) { - return 2; - } else if (perms.indexOf('w') !== -1 && !(node.mode & 146)) { - return 2; - } else if (perms.indexOf('x') !== -1 && !(node.mode & 73)) { - return 2; - } - return 0; - },mayLookup:function(dir) { - var err = FS.nodePermissions(dir, 'x'); - if (err) return err; - if (!dir.node_ops.lookup) return 2; - return 0; - },mayCreate:function(dir, name) { - try { - var node = FS.lookupNode(dir, name); - return 20; - } catch (e) { - } - return FS.nodePermissions(dir, 'wx'); - },mayDelete:function(dir, name, isdir) { - var node; - try { - node = FS.lookupNode(dir, name); - } catch (e) { - return e.errno; - } - var err = FS.nodePermissions(dir, 'wx'); - if (err) { - return err; - } - if (isdir) { - if (!FS.isDir(node.mode)) { - return 54; - } - if (FS.isRoot(node) || FS.getPath(node) === FS.cwd()) { - return 10; - } - } else { - if (FS.isDir(node.mode)) { - return 31; - } - } - return 0; - },mayOpen:function(node, flags) { - if (!node) { - return 44; - } - if (FS.isLink(node.mode)) { - return 32; - } else if (FS.isDir(node.mode)) { - if (FS.flagsToPermissionString(flags) !== 'r' || // opening for write - (flags & 512)) { // TODO: check for O_SEARCH? (== search for dir only) - return 31; - } - } - return FS.nodePermissions(node, FS.flagsToPermissionString(flags)); - },MAX_OPEN_FDS:4096,nextfd:function(fd_start, fd_end) { - fd_start = fd_start || 0; - fd_end = fd_end || FS.MAX_OPEN_FDS; - for (var fd = fd_start; fd <= fd_end; fd++) { - if (!FS.streams[fd]) { - return fd; - } - } - throw new FS.ErrnoError(33); - },getStream:function(fd) { - return FS.streams[fd]; - },createStream:function(stream, fd_start, fd_end) { - if (!FS.FSStream) { - FS.FSStream = function(){}; - FS.FSStream.prototype = {}; - // compatibility - Object.defineProperties(FS.FSStream.prototype, { - object: { - get: function() { return this.node; }, - set: function(val) { this.node = val; } - }, - isRead: { - get: function() { return (this.flags & 2097155) !== 1; } - }, - isWrite: { - get: function() { return (this.flags & 2097155) !== 0; } - }, - isAppend: { - get: function() { return (this.flags & 1024); } - } - }); - } - // clone it, so we can return an instance of FSStream - var newStream = new FS.FSStream(); - for (var p in stream) { - newStream[p] = stream[p]; - } - stream = newStream; - var fd = FS.nextfd(fd_start, fd_end); - stream.fd = fd; - FS.streams[fd] = stream; - return stream; - },closeStream:function(fd) { - FS.streams[fd] = null; - },chrdev_stream_ops:{open:function(stream) { - var device = FS.getDevice(stream.node.rdev); - // override node's stream ops with the device's - stream.stream_ops = device.stream_ops; - // forward the open call - if (stream.stream_ops.open) { - stream.stream_ops.open(stream); - } - },llseek:function() { - throw new FS.ErrnoError(70); - }},major:function(dev) { - return ((dev) >> 8); - },minor:function(dev) { - return ((dev) & 0xff); - },makedev:function(ma, mi) { - return ((ma) << 8 | (mi)); - },registerDevice:function(dev, ops) { - FS.devices[dev] = { stream_ops: ops }; - },getDevice:function(dev) { - return FS.devices[dev]; - },getMounts:function(mount) { - var mounts = []; - var check = [mount]; - - while (check.length) { - var m = check.pop(); - - mounts.push(m); - - check.push.apply(check, m.mounts); - } - - return mounts; - },syncfs:function(populate, callback) { - if (typeof(populate) === 'function') { - callback = populate; - populate = false; - } - - FS.syncFSRequests++; - - if (FS.syncFSRequests > 1) { - console.log('warning: ' + FS.syncFSRequests + ' FS.syncfs operations in flight at once, probably just doing extra work'); - } - - var mounts = FS.getMounts(FS.root.mount); - var completed = 0; - - function doCallback(err) { - assert(FS.syncFSRequests > 0); - FS.syncFSRequests--; - return callback(err); - } - - function done(err) { - if (err) { - if (!done.errored) { - done.errored = true; - return doCallback(err); - } - return; - } - if (++completed >= mounts.length) { - doCallback(null); - } - }; - - // sync all mounts - mounts.forEach(function (mount) { - if (!mount.type.syncfs) { - return done(null); - } - mount.type.syncfs(mount, populate, done); - }); - },mount:function(type, opts, mountpoint) { - if (typeof type === 'string') { - // The filesystem was not included, and instead we have an error - // message stored in the variable. - throw type; - } - var root = mountpoint === '/'; - var pseudo = !mountpoint; - var node; - - if (root && FS.root) { - throw new FS.ErrnoError(10); - } else if (!root && !pseudo) { - var lookup = FS.lookupPath(mountpoint, { follow_mount: false }); - - mountpoint = lookup.path; // use the absolute path - node = lookup.node; - - if (FS.isMountpoint(node)) { - throw new FS.ErrnoError(10); - } - - if (!FS.isDir(node.mode)) { - throw new FS.ErrnoError(54); - } - } - - var mount = { - type: type, - opts: opts, - mountpoint: mountpoint, - mounts: [] - }; - - // create a root node for the fs - var mountRoot = type.mount(mount); - mountRoot.mount = mount; - mount.root = mountRoot; - - if (root) { - FS.root = mountRoot; - } else if (node) { - // set as a mountpoint - node.mounted = mount; - - // add the new mount to the current mount's children - if (node.mount) { - node.mount.mounts.push(mount); - } - } - - return mountRoot; - },unmount:function (mountpoint) { - var lookup = FS.lookupPath(mountpoint, { follow_mount: false }); - - if (!FS.isMountpoint(lookup.node)) { - throw new FS.ErrnoError(28); - } - - // destroy the nodes for this mount, and all its child mounts - var node = lookup.node; - var mount = node.mounted; - var mounts = FS.getMounts(mount); - - Object.keys(FS.nameTable).forEach(function (hash) { - var current = FS.nameTable[hash]; - - while (current) { - var next = current.name_next; - - if (mounts.indexOf(current.mount) !== -1) { - FS.destroyNode(current); - } - - current = next; - } - }); - - // no longer a mountpoint - node.mounted = null; - - // remove this mount from the child mounts - var idx = node.mount.mounts.indexOf(mount); - assert(idx !== -1); - node.mount.mounts.splice(idx, 1); - },lookup:function(parent, name) { - return parent.node_ops.lookup(parent, name); - },mknod:function(path, mode, dev) { - var lookup = FS.lookupPath(path, { parent: true }); - var parent = lookup.node; - var name = PATH.basename(path); - if (!name || name === '.' || name === '..') { - throw new FS.ErrnoError(28); - } - var err = FS.mayCreate(parent, name); - if (err) { - throw new FS.ErrnoError(err); - } - if (!parent.node_ops.mknod) { - throw new FS.ErrnoError(63); - } - return parent.node_ops.mknod(parent, name, mode, dev); - },create:function(path, mode) { - mode = mode !== undefined ? mode : 438 /* 0666 */; - mode &= 4095; - mode |= 32768; - return FS.mknod(path, mode, 0); - },mkdir:function(path, mode) { - mode = mode !== undefined ? mode : 511 /* 0777 */; - mode &= 511 | 512; - mode |= 16384; - return FS.mknod(path, mode, 0); - },mkdirTree:function(path, mode) { - var dirs = path.split('/'); - var d = ''; - for (var i = 0; i < dirs.length; ++i) { - if (!dirs[i]) continue; - d += '/' + dirs[i]; - try { - FS.mkdir(d, mode); - } catch(e) { - if (e.errno != 20) throw e; - } - } - },mkdev:function(path, mode, dev) { - if (typeof(dev) === 'undefined') { - dev = mode; - mode = 438 /* 0666 */; - } - mode |= 8192; - return FS.mknod(path, mode, dev); - },symlink:function(oldpath, newpath) { - if (!PATH_FS.resolve(oldpath)) { - throw new FS.ErrnoError(44); - } - var lookup = FS.lookupPath(newpath, { parent: true }); - var parent = lookup.node; - if (!parent) { - throw new FS.ErrnoError(44); - } - var newname = PATH.basename(newpath); - var err = FS.mayCreate(parent, newname); - if (err) { - throw new FS.ErrnoError(err); - } - if (!parent.node_ops.symlink) { - throw new FS.ErrnoError(63); - } - return parent.node_ops.symlink(parent, newname, oldpath); - },rename:function(old_path, new_path) { - var old_dirname = PATH.dirname(old_path); - var new_dirname = PATH.dirname(new_path); - var old_name = PATH.basename(old_path); - var new_name = PATH.basename(new_path); - // parents must exist - var lookup, old_dir, new_dir; - try { - lookup = FS.lookupPath(old_path, { parent: true }); - old_dir = lookup.node; - lookup = FS.lookupPath(new_path, { parent: true }); - new_dir = lookup.node; - } catch (e) { - throw new FS.ErrnoError(10); - } - if (!old_dir || !new_dir) throw new FS.ErrnoError(44); - // need to be part of the same mount - if (old_dir.mount !== new_dir.mount) { - throw new FS.ErrnoError(75); - } - // source must exist - var old_node = FS.lookupNode(old_dir, old_name); - // old path should not be an ancestor of the new path - var relative = PATH_FS.relative(old_path, new_dirname); - if (relative.charAt(0) !== '.') { - throw new FS.ErrnoError(28); - } - // new path should not be an ancestor of the old path - relative = PATH_FS.relative(new_path, old_dirname); - if (relative.charAt(0) !== '.') { - throw new FS.ErrnoError(55); - } - // see if the new path already exists - var new_node; - try { - new_node = FS.lookupNode(new_dir, new_name); - } catch (e) { - // not fatal - } - // early out if nothing needs to change - if (old_node === new_node) { - return; - } - // we'll need to delete the old entry - var isdir = FS.isDir(old_node.mode); - var err = FS.mayDelete(old_dir, old_name, isdir); - if (err) { - throw new FS.ErrnoError(err); - } - // need delete permissions if we'll be overwriting. - // need create permissions if new doesn't already exist. - err = new_node ? - FS.mayDelete(new_dir, new_name, isdir) : - FS.mayCreate(new_dir, new_name); - if (err) { - throw new FS.ErrnoError(err); - } - if (!old_dir.node_ops.rename) { - throw new FS.ErrnoError(63); - } - if (FS.isMountpoint(old_node) || (new_node && FS.isMountpoint(new_node))) { - throw new FS.ErrnoError(10); - } - // if we are going to change the parent, check write permissions - if (new_dir !== old_dir) { - err = FS.nodePermissions(old_dir, 'w'); - if (err) { - throw new FS.ErrnoError(err); - } - } - try { - if (FS.trackingDelegate['willMovePath']) { - FS.trackingDelegate['willMovePath'](old_path, new_path); - } - } catch(e) { - console.log("FS.trackingDelegate['willMovePath']('"+old_path+"', '"+new_path+"') threw an exception: " + e.message); - } - // remove the node from the lookup hash - FS.hashRemoveNode(old_node); - // do the underlying fs rename - try { - old_dir.node_ops.rename(old_node, new_dir, new_name); - } catch (e) { - throw e; - } finally { - // add the node back to the hash (in case node_ops.rename - // changed its name) - FS.hashAddNode(old_node); - } - try { - if (FS.trackingDelegate['onMovePath']) FS.trackingDelegate['onMovePath'](old_path, new_path); - } catch(e) { - console.log("FS.trackingDelegate['onMovePath']('"+old_path+"', '"+new_path+"') threw an exception: " + e.message); - } - },rmdir:function(path) { - var lookup = FS.lookupPath(path, { parent: true }); - var parent = lookup.node; - var name = PATH.basename(path); - var node = FS.lookupNode(parent, name); - var err = FS.mayDelete(parent, name, true); - if (err) { - throw new FS.ErrnoError(err); - } - if (!parent.node_ops.rmdir) { - throw new FS.ErrnoError(63); - } - if (FS.isMountpoint(node)) { - throw new FS.ErrnoError(10); - } - try { - if (FS.trackingDelegate['willDeletePath']) { - FS.trackingDelegate['willDeletePath'](path); - } - } catch(e) { - console.log("FS.trackingDelegate['willDeletePath']('"+path+"') threw an exception: " + e.message); - } - parent.node_ops.rmdir(parent, name); - FS.destroyNode(node); - try { - if (FS.trackingDelegate['onDeletePath']) FS.trackingDelegate['onDeletePath'](path); - } catch(e) { - console.log("FS.trackingDelegate['onDeletePath']('"+path+"') threw an exception: " + e.message); - } - },readdir:function(path) { - var lookup = FS.lookupPath(path, { follow: true }); - var node = lookup.node; - if (!node.node_ops.readdir) { - throw new FS.ErrnoError(54); - } - return node.node_ops.readdir(node); - },unlink:function(path) { - var lookup = FS.lookupPath(path, { parent: true }); - var parent = lookup.node; - var name = PATH.basename(path); - var node = FS.lookupNode(parent, name); - var err = FS.mayDelete(parent, name, false); - if (err) { - // According to POSIX, we should map EISDIR to EPERM, but - // we instead do what Linux does (and we must, as we use - // the musl linux libc). - throw new FS.ErrnoError(err); - } - if (!parent.node_ops.unlink) { - throw new FS.ErrnoError(63); - } - if (FS.isMountpoint(node)) { - throw new FS.ErrnoError(10); - } - try { - if (FS.trackingDelegate['willDeletePath']) { - FS.trackingDelegate['willDeletePath'](path); - } - } catch(e) { - console.log("FS.trackingDelegate['willDeletePath']('"+path+"') threw an exception: " + e.message); - } - parent.node_ops.unlink(parent, name); - FS.destroyNode(node); - try { - if (FS.trackingDelegate['onDeletePath']) FS.trackingDelegate['onDeletePath'](path); - } catch(e) { - console.log("FS.trackingDelegate['onDeletePath']('"+path+"') threw an exception: " + e.message); - } - },readlink:function(path) { - var lookup = FS.lookupPath(path); - var link = lookup.node; - if (!link) { - throw new FS.ErrnoError(44); - } - if (!link.node_ops.readlink) { - throw new FS.ErrnoError(28); - } - return PATH_FS.resolve(FS.getPath(link.parent), link.node_ops.readlink(link)); - },stat:function(path, dontFollow) { - var lookup = FS.lookupPath(path, { follow: !dontFollow }); - var node = lookup.node; - if (!node) { - throw new FS.ErrnoError(44); - } - if (!node.node_ops.getattr) { - throw new FS.ErrnoError(63); - } - return node.node_ops.getattr(node); - },lstat:function(path) { - return FS.stat(path, true); - },chmod:function(path, mode, dontFollow) { - var node; - if (typeof path === 'string') { - var lookup = FS.lookupPath(path, { follow: !dontFollow }); - node = lookup.node; - } else { - node = path; - } - if (!node.node_ops.setattr) { - throw new FS.ErrnoError(63); - } - node.node_ops.setattr(node, { - mode: (mode & 4095) | (node.mode & ~4095), - timestamp: Date.now() - }); - },lchmod:function(path, mode) { - FS.chmod(path, mode, true); - },fchmod:function(fd, mode) { - var stream = FS.getStream(fd); - if (!stream) { - throw new FS.ErrnoError(8); - } - FS.chmod(stream.node, mode); - },chown:function(path, uid, gid, dontFollow) { - var node; - if (typeof path === 'string') { - var lookup = FS.lookupPath(path, { follow: !dontFollow }); - node = lookup.node; - } else { - node = path; - } - if (!node.node_ops.setattr) { - throw new FS.ErrnoError(63); - } - node.node_ops.setattr(node, { - timestamp: Date.now() - // we ignore the uid / gid for now - }); - },lchown:function(path, uid, gid) { - FS.chown(path, uid, gid, true); - },fchown:function(fd, uid, gid) { - var stream = FS.getStream(fd); - if (!stream) { - throw new FS.ErrnoError(8); - } - FS.chown(stream.node, uid, gid); - },truncate:function(path, len) { - if (len < 0) { - throw new FS.ErrnoError(28); - } - var node; - if (typeof path === 'string') { - var lookup = FS.lookupPath(path, { follow: true }); - node = lookup.node; - } else { - node = path; - } - if (!node.node_ops.setattr) { - throw new FS.ErrnoError(63); - } - if (FS.isDir(node.mode)) { - throw new FS.ErrnoError(31); - } - if (!FS.isFile(node.mode)) { - throw new FS.ErrnoError(28); - } - var err = FS.nodePermissions(node, 'w'); - if (err) { - throw new FS.ErrnoError(err); - } - node.node_ops.setattr(node, { - size: len, - timestamp: Date.now() - }); - },ftruncate:function(fd, len) { - var stream = FS.getStream(fd); - if (!stream) { - throw new FS.ErrnoError(8); - } - if ((stream.flags & 2097155) === 0) { - throw new FS.ErrnoError(28); - } - FS.truncate(stream.node, len); - },utime:function(path, atime, mtime) { - var lookup = FS.lookupPath(path, { follow: true }); - var node = lookup.node; - node.node_ops.setattr(node, { - timestamp: Math.max(atime, mtime) - }); - },open:function(path, flags, mode, fd_start, fd_end) { - if (path === "") { - throw new FS.ErrnoError(44); - } - flags = typeof flags === 'string' ? FS.modeStringToFlags(flags) : flags; - mode = typeof mode === 'undefined' ? 438 /* 0666 */ : mode; - if ((flags & 64)) { - mode = (mode & 4095) | 32768; - } else { - mode = 0; - } - var node; - if (typeof path === 'object') { - node = path; - } else { - path = PATH.normalize(path); - try { - var lookup = FS.lookupPath(path, { - follow: !(flags & 131072) - }); - node = lookup.node; - } catch (e) { - // ignore - } - } - // perhaps we need to create the node - var created = false; - if ((flags & 64)) { - if (node) { - // if O_CREAT and O_EXCL are set, error out if the node already exists - if ((flags & 128)) { - throw new FS.ErrnoError(20); - } - } else { - // node doesn't exist, try to create it - node = FS.mknod(path, mode, 0); - created = true; - } - } - if (!node) { - throw new FS.ErrnoError(44); - } - // can't truncate a device - if (FS.isChrdev(node.mode)) { - flags &= ~512; - } - // if asked only for a directory, then this must be one - if ((flags & 65536) && !FS.isDir(node.mode)) { - throw new FS.ErrnoError(54); - } - // check permissions, if this is not a file we just created now (it is ok to - // create and write to a file with read-only permissions; it is read-only - // for later use) - if (!created) { - var err = FS.mayOpen(node, flags); - if (err) { - throw new FS.ErrnoError(err); - } - } - // do truncation if necessary - if ((flags & 512)) { - FS.truncate(node, 0); - } - // we've already handled these, don't pass down to the underlying vfs - flags &= ~(128 | 512); - - // register the stream with the filesystem - var stream = FS.createStream({ - node: node, - path: FS.getPath(node), // we want the absolute path to the node - flags: flags, - seekable: true, - position: 0, - stream_ops: node.stream_ops, - // used by the file family libc calls (fopen, fwrite, ferror, etc.) - ungotten: [], - error: false - }, fd_start, fd_end); - // call the new stream's open function - if (stream.stream_ops.open) { - stream.stream_ops.open(stream); - } - if (Module['logReadFiles'] && !(flags & 1)) { - if (!FS.readFiles) FS.readFiles = {}; - if (!(path in FS.readFiles)) { - FS.readFiles[path] = 1; - console.log("FS.trackingDelegate error on read file: " + path); - } - } - try { - if (FS.trackingDelegate['onOpenFile']) { - var trackingFlags = 0; - if ((flags & 2097155) !== 1) { - trackingFlags |= FS.tracking.openFlags.READ; - } - if ((flags & 2097155) !== 0) { - trackingFlags |= FS.tracking.openFlags.WRITE; - } - FS.trackingDelegate['onOpenFile'](path, trackingFlags); - } - } catch(e) { - console.log("FS.trackingDelegate['onOpenFile']('"+path+"', flags) threw an exception: " + e.message); - } - return stream; - },close:function(stream) { - if (FS.isClosed(stream)) { - throw new FS.ErrnoError(8); - } - if (stream.getdents) stream.getdents = null; // free readdir state - try { - if (stream.stream_ops.close) { - stream.stream_ops.close(stream); - } - } catch (e) { - throw e; - } finally { - FS.closeStream(stream.fd); - } - stream.fd = null; - },isClosed:function(stream) { - return stream.fd === null; - },llseek:function(stream, offset, whence) { - if (FS.isClosed(stream)) { - throw new FS.ErrnoError(8); - } - if (!stream.seekable || !stream.stream_ops.llseek) { - throw new FS.ErrnoError(70); - } - if (whence != 0 && whence != 1 && whence != 2) { - throw new FS.ErrnoError(28); - } - stream.position = stream.stream_ops.llseek(stream, offset, whence); - stream.ungotten = []; - return stream.position; - },read:function(stream, buffer, offset, length, position) { - if (length < 0 || position < 0) { - throw new FS.ErrnoError(28); - } - if (FS.isClosed(stream)) { - throw new FS.ErrnoError(8); - } - if ((stream.flags & 2097155) === 1) { - throw new FS.ErrnoError(8); - } - if (FS.isDir(stream.node.mode)) { - throw new FS.ErrnoError(31); - } - if (!stream.stream_ops.read) { - throw new FS.ErrnoError(28); - } - var seeking = typeof position !== 'undefined'; - if (!seeking) { - position = stream.position; - } else if (!stream.seekable) { - throw new FS.ErrnoError(70); - } - var bytesRead = stream.stream_ops.read(stream, buffer, offset, length, position); - if (!seeking) stream.position += bytesRead; - return bytesRead; - },write:function(stream, buffer, offset, length, position, canOwn) { - if (length < 0 || position < 0) { - throw new FS.ErrnoError(28); - } - if (FS.isClosed(stream)) { - throw new FS.ErrnoError(8); - } - if ((stream.flags & 2097155) === 0) { - throw new FS.ErrnoError(8); - } - if (FS.isDir(stream.node.mode)) { - throw new FS.ErrnoError(31); - } - if (!stream.stream_ops.write) { - throw new FS.ErrnoError(28); - } - if (stream.flags & 1024) { - // seek to the end before writing in append mode - FS.llseek(stream, 0, 2); - } - var seeking = typeof position !== 'undefined'; - if (!seeking) { - position = stream.position; - } else if (!stream.seekable) { - throw new FS.ErrnoError(70); - } - var bytesWritten = stream.stream_ops.write(stream, buffer, offset, length, position, canOwn); - if (!seeking) stream.position += bytesWritten; - try { - if (stream.path && FS.trackingDelegate['onWriteToFile']) FS.trackingDelegate['onWriteToFile'](stream.path); - } catch(e) { - console.log("FS.trackingDelegate['onWriteToFile']('"+stream.path+"') threw an exception: " + e.message); - } - return bytesWritten; - },allocate:function(stream, offset, length) { - if (FS.isClosed(stream)) { - throw new FS.ErrnoError(8); - } - if (offset < 0 || length <= 0) { - throw new FS.ErrnoError(28); - } - if ((stream.flags & 2097155) === 0) { - throw new FS.ErrnoError(8); - } - if (!FS.isFile(stream.node.mode) && !FS.isDir(stream.node.mode)) { - throw new FS.ErrnoError(43); - } - if (!stream.stream_ops.allocate) { - throw new FS.ErrnoError(138); - } - stream.stream_ops.allocate(stream, offset, length); - },mmap:function(stream, buffer, offset, length, position, prot, flags) { - // User requests writing to file (prot & PROT_WRITE != 0). - // Checking if we have permissions to write to the file unless - // MAP_PRIVATE flag is set. According to POSIX spec it is possible - // to write to file opened in read-only mode with MAP_PRIVATE flag, - // as all modifications will be visible only in the memory of - // the current process. - if ((prot & 2) !== 0 - && (flags & 2) === 0 - && (stream.flags & 2097155) !== 2) { - throw new FS.ErrnoError(2); - } - if ((stream.flags & 2097155) === 1) { - throw new FS.ErrnoError(2); - } - if (!stream.stream_ops.mmap) { - throw new FS.ErrnoError(43); - } - return stream.stream_ops.mmap(stream, buffer, offset, length, position, prot, flags); - },msync:function(stream, buffer, offset, length, mmapFlags) { - if (!stream || !stream.stream_ops.msync) { - return 0; - } - return stream.stream_ops.msync(stream, buffer, offset, length, mmapFlags); - },munmap:function(stream) { - return 0; - },ioctl:function(stream, cmd, arg) { - if (!stream.stream_ops.ioctl) { - throw new FS.ErrnoError(59); - } - return stream.stream_ops.ioctl(stream, cmd, arg); - },readFile:function(path, opts) { - opts = opts || {}; - opts.flags = opts.flags || 'r'; - opts.encoding = opts.encoding || 'binary'; - if (opts.encoding !== 'utf8' && opts.encoding !== 'binary') { - throw new Error('Invalid encoding type "' + opts.encoding + '"'); - } - var ret; - var stream = FS.open(path, opts.flags); - var stat = FS.stat(path); - var length = stat.size; - var buf = new Uint8Array(length); - FS.read(stream, buf, 0, length, 0); - if (opts.encoding === 'utf8') { - ret = UTF8ArrayToString(buf, 0); - } else if (opts.encoding === 'binary') { - ret = buf; - } - FS.close(stream); - return ret; - },writeFile:function(path, data, opts) { - opts = opts || {}; - opts.flags = opts.flags || 'w'; - var stream = FS.open(path, opts.flags, opts.mode); - if (typeof data === 'string') { - var buf = new Uint8Array(lengthBytesUTF8(data)+1); - var actualNumBytes = stringToUTF8Array(data, buf, 0, buf.length); - FS.write(stream, buf, 0, actualNumBytes, undefined, opts.canOwn); - } else if (ArrayBuffer.isView(data)) { - FS.write(stream, data, 0, data.byteLength, undefined, opts.canOwn); - } else { - throw new Error('Unsupported data type'); - } - FS.close(stream); - },cwd:function() { - return FS.currentPath; - },chdir:function(path) { - var lookup = FS.lookupPath(path, { follow: true }); - if (lookup.node === null) { - throw new FS.ErrnoError(44); - } - if (!FS.isDir(lookup.node.mode)) { - throw new FS.ErrnoError(54); - } - var err = FS.nodePermissions(lookup.node, 'x'); - if (err) { - throw new FS.ErrnoError(err); - } - FS.currentPath = lookup.path; - },createDefaultDirectories:function() { - FS.mkdir('/tmp'); - FS.mkdir('/home'); - FS.mkdir('/home/web_user'); - },createDefaultDevices:function() { - // create /dev - FS.mkdir('/dev'); - // setup /dev/null - FS.registerDevice(FS.makedev(1, 3), { - read: function() { return 0; }, - write: function(stream, buffer, offset, length, pos) { return length; } - }); - FS.mkdev('/dev/null', FS.makedev(1, 3)); - // setup /dev/tty and /dev/tty1 - // stderr needs to print output using Module['printErr'] - // so we register a second tty just for it. - TTY.register(FS.makedev(5, 0), TTY.default_tty_ops); - TTY.register(FS.makedev(6, 0), TTY.default_tty1_ops); - FS.mkdev('/dev/tty', FS.makedev(5, 0)); - FS.mkdev('/dev/tty1', FS.makedev(6, 0)); - // setup /dev/[u]random - var random_device; - if (typeof crypto === 'object' && typeof crypto['getRandomValues'] === 'function') { - // for modern web browsers - var randomBuffer = new Uint8Array(1); - random_device = function() { crypto.getRandomValues(randomBuffer); return randomBuffer[0]; }; - } else - if (ENVIRONMENT_IS_NODE) { - // for nodejs with or without crypto support included - try { - var crypto_module = require('crypto'); - // nodejs has crypto support - random_device = function() { return crypto_module['randomBytes'](1)[0]; }; - } catch (e) { - // nodejs doesn't have crypto support - } - } else - {} - if (!random_device) { - // we couldn't find a proper implementation, as Math.random() is not suitable for /dev/random, see emscripten-core/emscripten/pull/7096 - random_device = function() { abort("no cryptographic support found for random_device. consider polyfilling it if you want to use something insecure like Math.random(), e.g. put this in a --pre-js: var crypto = { getRandomValues: function(array) { for (var i = 0; i < array.length; i++) array[i] = (Math.random()*256)|0 } };"); }; - } - FS.createDevice('/dev', 'random', random_device); - FS.createDevice('/dev', 'urandom', random_device); - // we're not going to emulate the actual shm device, - // just create the tmp dirs that reside in it commonly - FS.mkdir('/dev/shm'); - FS.mkdir('/dev/shm/tmp'); - },createSpecialDirectories:function() { - // create /proc/self/fd which allows /proc/self/fd/6 => readlink gives the name of the stream for fd 6 (see test_unistd_ttyname) - FS.mkdir('/proc'); - FS.mkdir('/proc/self'); - FS.mkdir('/proc/self/fd'); - FS.mount({ - mount: function() { - var node = FS.createNode('/proc/self', 'fd', 16384 | 511 /* 0777 */, 73); - node.node_ops = { - lookup: function(parent, name) { - var fd = +name; - var stream = FS.getStream(fd); - if (!stream) throw new FS.ErrnoError(8); - var ret = { - parent: null, - mount: { mountpoint: 'fake' }, - node_ops: { readlink: function() { return stream.path } } - }; - ret.parent = ret; // make it look like a simple root node - return ret; - } - }; - return node; - } - }, {}, '/proc/self/fd'); - },createStandardStreams:function() { - // TODO deprecate the old functionality of a single - // input / output callback and that utilizes FS.createDevice - // and instead require a unique set of stream ops - - // by default, we symlink the standard streams to the - // default tty devices. however, if the standard streams - // have been overwritten we create a unique device for - // them instead. - if (Module['stdin']) { - FS.createDevice('/dev', 'stdin', Module['stdin']); - } else { - FS.symlink('/dev/tty', '/dev/stdin'); - } - if (Module['stdout']) { - FS.createDevice('/dev', 'stdout', null, Module['stdout']); - } else { - FS.symlink('/dev/tty', '/dev/stdout'); - } - if (Module['stderr']) { - FS.createDevice('/dev', 'stderr', null, Module['stderr']); - } else { - FS.symlink('/dev/tty1', '/dev/stderr'); - } - - // open default streams for the stdin, stdout and stderr devices - var stdin = FS.open('/dev/stdin', 'r'); - var stdout = FS.open('/dev/stdout', 'w'); - var stderr = FS.open('/dev/stderr', 'w'); - assert(stdin.fd === 0, 'invalid handle for stdin (' + stdin.fd + ')'); - assert(stdout.fd === 1, 'invalid handle for stdout (' + stdout.fd + ')'); - assert(stderr.fd === 2, 'invalid handle for stderr (' + stderr.fd + ')'); - },ensureErrnoError:function() { - if (FS.ErrnoError) return; - FS.ErrnoError = function ErrnoError(errno, node) { - this.node = node; - this.setErrno = function(errno) { - this.errno = errno; - for (var key in ERRNO_CODES) { - if (ERRNO_CODES[key] === errno) { - this.code = key; - break; - } - } - }; - this.setErrno(errno); - this.message = ERRNO_MESSAGES[errno]; - - // Try to get a maximally helpful stack trace. On Node.js, getting Error.stack - // now ensures it shows what we want. - if (this.stack) { - // Define the stack property for Node.js 4, which otherwise errors on the next line. - Object.defineProperty(this, "stack", { value: (new Error).stack, writable: true }); - this.stack = demangleAll(this.stack); - } - }; - FS.ErrnoError.prototype = new Error(); - FS.ErrnoError.prototype.constructor = FS.ErrnoError; - // Some errors may happen quite a bit, to avoid overhead we reuse them (and suffer a lack of stack info) - [44].forEach(function(code) { - FS.genericErrors[code] = new FS.ErrnoError(code); - FS.genericErrors[code].stack = ''; - }); - },staticInit:function() { - FS.ensureErrnoError(); - - FS.nameTable = new Array(4096); - - FS.mount(MEMFS, {}, '/'); - - FS.createDefaultDirectories(); - FS.createDefaultDevices(); - FS.createSpecialDirectories(); - - FS.filesystems = { - 'MEMFS': MEMFS, - 'NODEFS': NODEFS, - }; - },init:function(input, output, error) { - assert(!FS.init.initialized, 'FS.init was previously called. If you want to initialize later with custom parameters, remove any earlier calls (note that one is automatically added to the generated code)'); - FS.init.initialized = true; - - FS.ensureErrnoError(); - - // Allow Module.stdin etc. to provide defaults, if none explicitly passed to us here - Module['stdin'] = input || Module['stdin']; - Module['stdout'] = output || Module['stdout']; - Module['stderr'] = error || Module['stderr']; - - FS.createStandardStreams(); - },quit:function() { - FS.init.initialized = false; - // force-flush all streams, so we get musl std streams printed out - var fflush = Module['_fflush']; - if (fflush) fflush(0); - // close all of our streams - for (var i = 0; i < FS.streams.length; i++) { - var stream = FS.streams[i]; - if (!stream) { - continue; - } - FS.close(stream); - } - },getMode:function(canRead, canWrite) { - var mode = 0; - if (canRead) mode |= 292 | 73; - if (canWrite) mode |= 146; - return mode; - },joinPath:function(parts, forceRelative) { - var path = PATH.join.apply(null, parts); - if (forceRelative && path[0] == '/') path = path.substr(1); - return path; - },absolutePath:function(relative, base) { - return PATH_FS.resolve(base, relative); - },standardizePath:function(path) { - return PATH.normalize(path); - },findObject:function(path, dontResolveLastLink) { - var ret = FS.analyzePath(path, dontResolveLastLink); - if (ret.exists) { - return ret.object; - } else { - ___setErrNo(ret.error); - return null; - } - },analyzePath:function(path, dontResolveLastLink) { - // operate from within the context of the symlink's target - try { - var lookup = FS.lookupPath(path, { follow: !dontResolveLastLink }); - path = lookup.path; - } catch (e) { - } - var ret = { - isRoot: false, exists: false, error: 0, name: null, path: null, object: null, - parentExists: false, parentPath: null, parentObject: null - }; - try { - var lookup = FS.lookupPath(path, { parent: true }); - ret.parentExists = true; - ret.parentPath = lookup.path; - ret.parentObject = lookup.node; - ret.name = PATH.basename(path); - lookup = FS.lookupPath(path, { follow: !dontResolveLastLink }); - ret.exists = true; - ret.path = lookup.path; - ret.object = lookup.node; - ret.name = lookup.node.name; - ret.isRoot = lookup.path === '/'; - } catch (e) { - ret.error = e.errno; - }; - return ret; - },createFolder:function(parent, name, canRead, canWrite) { - var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name); - var mode = FS.getMode(canRead, canWrite); - return FS.mkdir(path, mode); - },createPath:function(parent, path, canRead, canWrite) { - parent = typeof parent === 'string' ? parent : FS.getPath(parent); - var parts = path.split('/').reverse(); - while (parts.length) { - var part = parts.pop(); - if (!part) continue; - var current = PATH.join2(parent, part); - try { - FS.mkdir(current); - } catch (e) { - // ignore EEXIST - } - parent = current; - } - return current; - },createFile:function(parent, name, properties, canRead, canWrite) { - var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name); - var mode = FS.getMode(canRead, canWrite); - return FS.create(path, mode); - },createDataFile:function(parent, name, data, canRead, canWrite, canOwn) { - var path = name ? PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name) : parent; - var mode = FS.getMode(canRead, canWrite); - var node = FS.create(path, mode); - if (data) { - if (typeof data === 'string') { - var arr = new Array(data.length); - for (var i = 0, len = data.length; i < len; ++i) arr[i] = data.charCodeAt(i); - data = arr; - } - // make sure we can write to the file - FS.chmod(node, mode | 146); - var stream = FS.open(node, 'w'); - FS.write(stream, data, 0, data.length, 0, canOwn); - FS.close(stream); - FS.chmod(node, mode); - } - return node; - },createDevice:function(parent, name, input, output) { - var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name); - var mode = FS.getMode(!!input, !!output); - if (!FS.createDevice.major) FS.createDevice.major = 64; - var dev = FS.makedev(FS.createDevice.major++, 0); - // Create a fake device that a set of stream ops to emulate - // the old behavior. - FS.registerDevice(dev, { - open: function(stream) { - stream.seekable = false; - }, - close: function(stream) { - // flush any pending line data - if (output && output.buffer && output.buffer.length) { - output(10); - } - }, - read: function(stream, buffer, offset, length, pos /* ignored */) { - var bytesRead = 0; - for (var i = 0; i < length; i++) { - var result; - try { - result = input(); - } catch (e) { - throw new FS.ErrnoError(29); - } - if (result === undefined && bytesRead === 0) { - throw new FS.ErrnoError(6); - } - if (result === null || result === undefined) break; - bytesRead++; - buffer[offset+i] = result; - } - if (bytesRead) { - stream.node.timestamp = Date.now(); - } - return bytesRead; - }, - write: function(stream, buffer, offset, length, pos) { - for (var i = 0; i < length; i++) { - try { - output(buffer[offset+i]); - } catch (e) { - throw new FS.ErrnoError(29); - } - } - if (length) { - stream.node.timestamp = Date.now(); - } - return i; - } - }); - return FS.mkdev(path, mode, dev); - },createLink:function(parent, name, target, canRead, canWrite) { - var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name); - return FS.symlink(target, path); - },forceLoadFile:function(obj) { - if (obj.isDevice || obj.isFolder || obj.link || obj.contents) return true; - var success = true; - if (typeof XMLHttpRequest !== 'undefined') { - throw new Error("Lazy loading should have been performed (contents set) in createLazyFile, but it was not. Lazy loading only works in web workers. Use --embed-file or --preload-file in emcc on the main thread."); - } else if (read_) { - // Command-line. - try { - // WARNING: Can't read binary files in V8's d8 or tracemonkey's js, as - // read() will try to parse UTF8. - obj.contents = intArrayFromString(read_(obj.url), true); - obj.usedBytes = obj.contents.length; - } catch (e) { - success = false; - } - } else { - throw new Error('Cannot load without read() or XMLHttpRequest.'); - } - if (!success) ___setErrNo(29); - return success; - },createLazyFile:function(parent, name, url, canRead, canWrite) { - // Lazy chunked Uint8Array (implements get and length from Uint8Array). Actual getting is abstracted away for eventual reuse. - function LazyUint8Array() { - this.lengthKnown = false; - this.chunks = []; // Loaded chunks. Index is the chunk number - } - LazyUint8Array.prototype.get = function LazyUint8Array_get(idx) { - if (idx > this.length-1 || idx < 0) { - return undefined; - } - var chunkOffset = idx % this.chunkSize; - var chunkNum = (idx / this.chunkSize)|0; - return this.getter(chunkNum)[chunkOffset]; - }; - LazyUint8Array.prototype.setDataGetter = function LazyUint8Array_setDataGetter(getter) { - this.getter = getter; - }; - LazyUint8Array.prototype.cacheLength = function LazyUint8Array_cacheLength() { - // Find length - var xhr = new XMLHttpRequest(); - xhr.open('HEAD', url, false); - xhr.send(null); - if (!(xhr.status >= 200 && xhr.status < 300 || xhr.status === 304)) throw new Error("Couldn't load " + url + ". Status: " + xhr.status); - var datalength = Number(xhr.getResponseHeader("Content-length")); - var header; - var hasByteServing = (header = xhr.getResponseHeader("Accept-Ranges")) && header === "bytes"; - var usesGzip = (header = xhr.getResponseHeader("Content-Encoding")) && header === "gzip"; - - var chunkSize = 1024*1024; // Chunk size in bytes - - if (!hasByteServing) chunkSize = datalength; - - // Function to get a range from the remote URL. - var doXHR = (function(from, to) { - if (from > to) throw new Error("invalid range (" + from + ", " + to + ") or no bytes requested!"); - if (to > datalength-1) throw new Error("only " + datalength + " bytes available! programmer error!"); - - // TODO: Use mozResponseArrayBuffer, responseStream, etc. if available. - var xhr = new XMLHttpRequest(); - xhr.open('GET', url, false); - if (datalength !== chunkSize) xhr.setRequestHeader("Range", "bytes=" + from + "-" + to); - - // Some hints to the browser that we want binary data. - if (typeof Uint8Array != 'undefined') xhr.responseType = 'arraybuffer'; - if (xhr.overrideMimeType) { - xhr.overrideMimeType('text/plain; charset=x-user-defined'); - } - - xhr.send(null); - if (!(xhr.status >= 200 && xhr.status < 300 || xhr.status === 304)) throw new Error("Couldn't load " + url + ". Status: " + xhr.status); - if (xhr.response !== undefined) { - return new Uint8Array(xhr.response || []); - } else { - return intArrayFromString(xhr.responseText || '', true); - } - }); - var lazyArray = this; - lazyArray.setDataGetter(function(chunkNum) { - var start = chunkNum * chunkSize; - var end = (chunkNum+1) * chunkSize - 1; // including this byte - end = Math.min(end, datalength-1); // if datalength-1 is selected, this is the last block - if (typeof(lazyArray.chunks[chunkNum]) === "undefined") { - lazyArray.chunks[chunkNum] = doXHR(start, end); - } - if (typeof(lazyArray.chunks[chunkNum]) === "undefined") throw new Error("doXHR failed!"); - return lazyArray.chunks[chunkNum]; - }); - - if (usesGzip || !datalength) { - // if the server uses gzip or doesn't supply the length, we have to download the whole file to get the (uncompressed) length - chunkSize = datalength = 1; // this will force getter(0)/doXHR do download the whole file - datalength = this.getter(0).length; - chunkSize = datalength; - console.log("LazyFiles on gzip forces download of the whole file when length is accessed"); - } - - this._length = datalength; - this._chunkSize = chunkSize; - this.lengthKnown = true; - }; - if (typeof XMLHttpRequest !== 'undefined') { - if (!ENVIRONMENT_IS_WORKER) throw 'Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc'; - var lazyArray = new LazyUint8Array(); - Object.defineProperties(lazyArray, { - length: { - get: function() { - if(!this.lengthKnown) { - this.cacheLength(); - } - return this._length; - } - }, - chunkSize: { - get: function() { - if(!this.lengthKnown) { - this.cacheLength(); - } - return this._chunkSize; - } - } - }); - - var properties = { isDevice: false, contents: lazyArray }; - } else { - var properties = { isDevice: false, url: url }; - } - - var node = FS.createFile(parent, name, properties, canRead, canWrite); - // This is a total hack, but I want to get this lazy file code out of the - // core of MEMFS. If we want to keep this lazy file concept I feel it should - // be its own thin LAZYFS proxying calls to MEMFS. - if (properties.contents) { - node.contents = properties.contents; - } else if (properties.url) { - node.contents = null; - node.url = properties.url; - } - // Add a function that defers querying the file size until it is asked the first time. - Object.defineProperties(node, { - usedBytes: { - get: function() { return this.contents.length; } - } - }); - // override each stream op with one that tries to force load the lazy file first - var stream_ops = {}; - var keys = Object.keys(node.stream_ops); - keys.forEach(function(key) { - var fn = node.stream_ops[key]; - stream_ops[key] = function forceLoadLazyFile() { - if (!FS.forceLoadFile(node)) { - throw new FS.ErrnoError(29); - } - return fn.apply(null, arguments); - }; - }); - // use a custom read function - stream_ops.read = function stream_ops_read(stream, buffer, offset, length, position) { - if (!FS.forceLoadFile(node)) { - throw new FS.ErrnoError(29); - } - var contents = stream.node.contents; - if (position >= contents.length) - return 0; - var size = Math.min(contents.length - position, length); - assert(size >= 0); - if (contents.slice) { // normal array - for (var i = 0; i < size; i++) { - buffer[offset + i] = contents[position + i]; - } - } else { - for (var i = 0; i < size; i++) { // LazyUint8Array from sync binary XHR - buffer[offset + i] = contents.get(position + i); - } - } - return size; - }; - node.stream_ops = stream_ops; - return node; - },createPreloadedFile:function(parent, name, url, canRead, canWrite, onload, onerror, dontCreateFile, canOwn, preFinish) { - Browser.init(); // perhaps this method should move onto Browser? - // TODO we should allow people to just pass in a complete filename instead - // of parent and name being that we just join them anyways - var fullname = name ? PATH_FS.resolve(PATH.join2(parent, name)) : parent; - var dep = getUniqueRunDependency('cp ' + fullname); // might have several active requests for the same fullname - function processData(byteArray) { - function finish(byteArray) { - if (preFinish) preFinish(); - if (!dontCreateFile) { - FS.createDataFile(parent, name, byteArray, canRead, canWrite, canOwn); - } - if (onload) onload(); - removeRunDependency(dep); - } - var handled = false; - Module['preloadPlugins'].forEach(function(plugin) { - if (handled) return; - if (plugin['canHandle'](fullname)) { - plugin['handle'](byteArray, fullname, finish, function() { - if (onerror) onerror(); - removeRunDependency(dep); - }); - handled = true; - } - }); - if (!handled) finish(byteArray); - } - addRunDependency(dep); - if (typeof url == 'string') { - Browser.asyncLoad(url, function(byteArray) { - processData(byteArray); - }, onerror); - } else { - processData(url); - } - },indexedDB:function() { - return window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB; - },DB_NAME:function() { - return 'EM_FS_' + window.location.pathname; - },DB_VERSION:20,DB_STORE_NAME:"FILE_DATA",saveFilesToDB:function(paths, onload, onerror) { - onload = onload || function(){}; - onerror = onerror || function(){}; - var indexedDB = FS.indexedDB(); - try { - var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION); - } catch (e) { - return onerror(e); - } - openRequest.onupgradeneeded = function openRequest_onupgradeneeded() { - console.log('creating db'); - var db = openRequest.result; - db.createObjectStore(FS.DB_STORE_NAME); - }; - openRequest.onsuccess = function openRequest_onsuccess() { - var db = openRequest.result; - var transaction = db.transaction([FS.DB_STORE_NAME], 'readwrite'); - var files = transaction.objectStore(FS.DB_STORE_NAME); - var ok = 0, fail = 0, total = paths.length; - function finish() { - if (fail == 0) onload(); else onerror(); - } - paths.forEach(function(path) { - var putRequest = files.put(FS.analyzePath(path).object.contents, path); - putRequest.onsuccess = function putRequest_onsuccess() { ok++; if (ok + fail == total) finish() }; - putRequest.onerror = function putRequest_onerror() { fail++; if (ok + fail == total) finish() }; - }); - transaction.onerror = onerror; - }; - openRequest.onerror = onerror; - },loadFilesFromDB:function(paths, onload, onerror) { - onload = onload || function(){}; - onerror = onerror || function(){}; - var indexedDB = FS.indexedDB(); - try { - var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION); - } catch (e) { - return onerror(e); - } - openRequest.onupgradeneeded = onerror; // no database to load from - openRequest.onsuccess = function openRequest_onsuccess() { - var db = openRequest.result; - try { - var transaction = db.transaction([FS.DB_STORE_NAME], 'readonly'); - } catch(e) { - onerror(e); - return; - } - var files = transaction.objectStore(FS.DB_STORE_NAME); - var ok = 0, fail = 0, total = paths.length; - function finish() { - if (fail == 0) onload(); else onerror(); - } - paths.forEach(function(path) { - var getRequest = files.get(path); - getRequest.onsuccess = function getRequest_onsuccess() { - if (FS.analyzePath(path).exists) { - FS.unlink(path); - } - FS.createDataFile(PATH.dirname(path), PATH.basename(path), getRequest.result, true, true, true); - ok++; - if (ok + fail == total) finish(); - }; - getRequest.onerror = function getRequest_onerror() { fail++; if (ok + fail == total) finish() }; - }); - transaction.onerror = onerror; - }; - openRequest.onerror = onerror; - }}; - Module["FS"] = FS;var SYSCALLS={DEFAULT_POLLMASK:5,mappings:{},umask:511,calculateAt:function(dirfd, path) { - if (path[0] !== '/') { - // relative path - var dir; - if (dirfd === -100) { - dir = FS.cwd(); - } else { - var dirstream = FS.getStream(dirfd); - if (!dirstream) throw new FS.ErrnoError(8); - dir = dirstream.path; - } - path = PATH.join2(dir, path); - } - return path; - },doStat:function(func, path, buf) { - try { - var stat = func(path); - } catch (e) { - if (e && e.node && PATH.normalize(path) !== PATH.normalize(FS.getPath(e.node))) { - // an error occurred while trying to look up the path; we should just report ENOTDIR - return -54; - } - throw e; - } - HEAP32[((buf)>>2)]=stat.dev; - HEAP32[(((buf)+(4))>>2)]=0; - HEAP32[(((buf)+(8))>>2)]=stat.ino; - HEAP32[(((buf)+(12))>>2)]=stat.mode; - HEAP32[(((buf)+(16))>>2)]=stat.nlink; - HEAP32[(((buf)+(20))>>2)]=stat.uid; - HEAP32[(((buf)+(24))>>2)]=stat.gid; - HEAP32[(((buf)+(28))>>2)]=stat.rdev; - HEAP32[(((buf)+(32))>>2)]=0; - (tempI64 = [stat.size>>>0,(tempDouble=stat.size,(+(Math_abs(tempDouble))) >= 1.0 ? (tempDouble > 0.0 ? ((Math_min((+(Math_floor((tempDouble)/4294967296.0))), 4294967295.0))|0)>>>0 : (~~((+(Math_ceil((tempDouble - +(((~~(tempDouble)))>>>0))/4294967296.0)))))>>>0) : 0)],HEAP32[(((buf)+(40))>>2)]=tempI64[0],HEAP32[(((buf)+(44))>>2)]=tempI64[1]); - HEAP32[(((buf)+(48))>>2)]=4096; - HEAP32[(((buf)+(52))>>2)]=stat.blocks; - HEAP32[(((buf)+(56))>>2)]=(stat.atime.getTime() / 1000)|0; - HEAP32[(((buf)+(60))>>2)]=0; - HEAP32[(((buf)+(64))>>2)]=(stat.mtime.getTime() / 1000)|0; - HEAP32[(((buf)+(68))>>2)]=0; - HEAP32[(((buf)+(72))>>2)]=(stat.ctime.getTime() / 1000)|0; - HEAP32[(((buf)+(76))>>2)]=0; - (tempI64 = [stat.ino>>>0,(tempDouble=stat.ino,(+(Math_abs(tempDouble))) >= 1.0 ? (tempDouble > 0.0 ? ((Math_min((+(Math_floor((tempDouble)/4294967296.0))), 4294967295.0))|0)>>>0 : (~~((+(Math_ceil((tempDouble - +(((~~(tempDouble)))>>>0))/4294967296.0)))))>>>0) : 0)],HEAP32[(((buf)+(80))>>2)]=tempI64[0],HEAP32[(((buf)+(84))>>2)]=tempI64[1]); - return 0; - },doMsync:function(addr, stream, len, flags) { - var buffer = new Uint8Array(HEAPU8.subarray(addr, addr + len)); - FS.msync(stream, buffer, 0, len, flags); - },doMkdir:function(path, mode) { - // remove a trailing slash, if one - /a/b/ has basename of '', but - // we want to create b in the context of this function - path = PATH.normalize(path); - if (path[path.length-1] === '/') path = path.substr(0, path.length-1); - FS.mkdir(path, mode, 0); - return 0; - },doMknod:function(path, mode, dev) { - // we don't want this in the JS API as it uses mknod to create all nodes. - switch (mode & 61440) { - case 32768: - case 8192: - case 24576: - case 4096: - case 49152: - break; - default: return -28; - } - FS.mknod(path, mode, dev); - return 0; - },doReadlink:function(path, buf, bufsize) { - if (bufsize <= 0) return -28; - var ret = FS.readlink(path); - - var len = Math.min(bufsize, lengthBytesUTF8(ret)); - var endChar = HEAP8[buf+len]; - stringToUTF8(ret, buf, bufsize+1); - // readlink is one of the rare functions that write out a C string, but does never append a null to the output buffer(!) - // stringToUTF8() always appends a null byte, so restore the character under the null byte after the write. - HEAP8[buf+len] = endChar; - - return len; - },doAccess:function(path, amode) { - if (amode & ~7) { - // need a valid mode - return -28; - } - var node; - var lookup = FS.lookupPath(path, { follow: true }); - node = lookup.node; - if (!node) { - return -44; - } - var perms = ''; - if (amode & 4) perms += 'r'; - if (amode & 2) perms += 'w'; - if (amode & 1) perms += 'x'; - if (perms /* otherwise, they've just passed F_OK */ && FS.nodePermissions(node, perms)) { - return -2; - } - return 0; - },doDup:function(path, flags, suggestFD) { - var suggest = FS.getStream(suggestFD); - if (suggest) FS.close(suggest); - return FS.open(path, flags, 0, suggestFD, suggestFD).fd; - },doReadv:function(stream, iov, iovcnt, offset) { - var ret = 0; - for (var i = 0; i < iovcnt; i++) { - var ptr = HEAP32[(((iov)+(i*8))>>2)]; - var len = HEAP32[(((iov)+(i*8 + 4))>>2)]; - var curr = FS.read(stream, HEAP8,ptr, len, offset); - if (curr < 0) return -1; - ret += curr; - if (curr < len) break; // nothing more to read - } - return ret; - },doWritev:function(stream, iov, iovcnt, offset) { - var ret = 0; - for (var i = 0; i < iovcnt; i++) { - var ptr = HEAP32[(((iov)+(i*8))>>2)]; - var len = HEAP32[(((iov)+(i*8 + 4))>>2)]; - var curr = FS.write(stream, HEAP8,ptr, len, offset); - if (curr < 0) return -1; - ret += curr; - } - return ret; - },varargs:0,get:function(varargs) { - SYSCALLS.varargs += 4; - var ret = HEAP32[(((SYSCALLS.varargs)-(4))>>2)]; - return ret; - },getStr:function() { - var ret = UTF8ToString(SYSCALLS.get()); - return ret; - },getStreamFromFD:function(fd) { - // TODO: when all syscalls use wasi, can remove the next line - if (fd === undefined) fd = SYSCALLS.get(); - var stream = FS.getStream(fd); - if (!stream) throw new FS.ErrnoError(8); - return stream; - },get64:function() { - var low = SYSCALLS.get(), high = SYSCALLS.get(); - if (low >= 0) assert(high === 0); - else assert(high === -1); - return low; - },getZero:function() { - assert(SYSCALLS.get() === 0); - }}; - Module["SYSCALLS"] = SYSCALLS;function ___syscall10(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(2, 1, which, varargs); - SYSCALLS.varargs = varargs; + if (stream.getdents) stream.getdents = null; try { - // unlink - var path = SYSCALLS.getStr(); - FS.unlink(path); - return 0; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall10"] = ___syscall10; - - function ___syscall12(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(3, 1, which, varargs); - SYSCALLS.varargs = varargs; + if (stream.stream_ops.close) { + stream.stream_ops.close(stream); + } + } catch (e) { + throw e; + } finally { + FS.closeStream(stream.fd); + } + stream.fd = null; + }), + isClosed: (function(stream) { + return stream.fd === null; + }), + llseek: (function(stream, offset, whence) { + if (FS.isClosed(stream)) { + throw new FS.ErrnoError(8); + } + if (!stream.seekable || !stream.stream_ops.llseek) { + throw new FS.ErrnoError(70); + } + if (whence != 0 && whence != 1 && whence != 2) { + throw new FS.ErrnoError(28); + } + stream.position = stream.stream_ops.llseek(stream, offset, whence); + stream.ungotten = []; + return stream.position; + }), + read: (function(stream, buffer, offset, length, position) { + if (length < 0 || position < 0) { + throw new FS.ErrnoError(28); + } + if (FS.isClosed(stream)) { + throw new FS.ErrnoError(8); + } + if ((stream.flags & 2097155) === 1) { + throw new FS.ErrnoError(8); + } + if (FS.isDir(stream.node.mode)) { + throw new FS.ErrnoError(31); + } + if (!stream.stream_ops.read) { + throw new FS.ErrnoError(28); + } + var seeking = typeof position !== "undefined"; + if (!seeking) { + position = stream.position; + } else if (!stream.seekable) { + throw new FS.ErrnoError(70); + } + var bytesRead = stream.stream_ops.read(stream, buffer, offset, length, position); + if (!seeking) stream.position += bytesRead; + return bytesRead; + }), + write: (function(stream, buffer, offset, length, position, canOwn) { + if (length < 0 || position < 0) { + throw new FS.ErrnoError(28); + } + if (FS.isClosed(stream)) { + throw new FS.ErrnoError(8); + } + if ((stream.flags & 2097155) === 0) { + throw new FS.ErrnoError(8); + } + if (FS.isDir(stream.node.mode)) { + throw new FS.ErrnoError(31); + } + if (!stream.stream_ops.write) { + throw new FS.ErrnoError(28); + } + if (stream.flags & 1024) { + FS.llseek(stream, 0, 2); + } + var seeking = typeof position !== "undefined"; + if (!seeking) { + position = stream.position; + } else if (!stream.seekable) { + throw new FS.ErrnoError(70); + } + var bytesWritten = stream.stream_ops.write(stream, buffer, offset, length, position, canOwn); + if (!seeking) stream.position += bytesWritten; try { - // chdir - var path = SYSCALLS.getStr(); - FS.chdir(path); - return 0; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } + if (stream.path && FS.trackingDelegate["onWriteToFile"]) FS.trackingDelegate["onWriteToFile"](stream.path); + } catch (e) { + console.log("FS.trackingDelegate['onWriteToFile']('" + stream.path + "') threw an exception: " + e.message); + } + return bytesWritten; + }), + allocate: (function(stream, offset, length) { + if (FS.isClosed(stream)) { + throw new FS.ErrnoError(8); + } + if (offset < 0 || length <= 0) { + throw new FS.ErrnoError(28); + } + if ((stream.flags & 2097155) === 0) { + throw new FS.ErrnoError(8); + } + if (!FS.isFile(stream.node.mode) && !FS.isDir(stream.node.mode)) { + throw new FS.ErrnoError(43); + } + if (!stream.stream_ops.allocate) { + throw new FS.ErrnoError(138); + } + stream.stream_ops.allocate(stream, offset, length); + }), + mmap: (function(stream, buffer, offset, length, position, prot, flags) { + if ((prot & 2) !== 0 && (flags & 2) === 0 && (stream.flags & 2097155) !== 2) { + throw new FS.ErrnoError(2); + } + if ((stream.flags & 2097155) === 1) { + throw new FS.ErrnoError(2); + } + if (!stream.stream_ops.mmap) { + throw new FS.ErrnoError(43); + } + return stream.stream_ops.mmap(stream, buffer, offset, length, position, prot, flags); + }), + msync: (function(stream, buffer, offset, length, mmapFlags) { + if (!stream || !stream.stream_ops.msync) { + return 0; + } + return stream.stream_ops.msync(stream, buffer, offset, length, mmapFlags); + }), + munmap: (function(stream) { + return 0; + }), + ioctl: (function(stream, cmd, arg) { + if (!stream.stream_ops.ioctl) { + throw new FS.ErrnoError(59); + } + return stream.stream_ops.ioctl(stream, cmd, arg); + }), + readFile: (function(path, opts) { + opts = opts || {}; + opts.flags = opts.flags || "r"; + opts.encoding = opts.encoding || "binary"; + if (opts.encoding !== "utf8" && opts.encoding !== "binary") { + throw new Error('Invalid encoding type "' + opts.encoding + '"'); } - - Module["___syscall12"] = ___syscall12; - - function ___syscall183(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(4, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // getcwd - var buf = SYSCALLS.get(), size = SYSCALLS.get(); - if (size === 0) return -28; - var cwd = FS.cwd(); - var cwdLengthInBytes = lengthBytesUTF8(cwd); - if (size < cwdLengthInBytes + 1) return -68; - stringToUTF8(cwd, buf, size); - return buf; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; + var ret; + var stream = FS.open(path, opts.flags); + var stat = FS.stat(path); + var length = stat.size; + var buf = new Uint8Array(length); + FS.read(stream, buf, 0, length, 0); + if (opts.encoding === "utf8") { + ret = UTF8ArrayToString(buf, 0); + } else if (opts.encoding === "binary") { + ret = buf; + } + FS.close(stream); + return ret; + }), + writeFile: (function(path, data, opts) { + opts = opts || {}; + opts.flags = opts.flags || "w"; + var stream = FS.open(path, opts.flags, opts.mode); + if (typeof data === "string") { + var buf = new Uint8Array(lengthBytesUTF8(data) + 1); + var actualNumBytes = stringToUTF8Array(data, buf, 0, buf.length); + FS.write(stream, buf, 0, actualNumBytes, undefined, opts.canOwn); + } else if (ArrayBuffer.isView(data)) { + FS.write(stream, data, 0, data.byteLength, undefined, opts.canOwn); + } else { + throw new Error("Unsupported data type"); + } + FS.close(stream); + }), + cwd: (function() { + return FS.currentPath; + }), + chdir: (function(path) { + var lookup = FS.lookupPath(path, { + follow: true + }); + if (lookup.node === null) { + throw new FS.ErrnoError(44); + } + if (!FS.isDir(lookup.node.mode)) { + throw new FS.ErrnoError(54); + } + var err = FS.nodePermissions(lookup.node, "x"); + if (err) { + throw new FS.ErrnoError(err); + } + FS.currentPath = lookup.path; + }), + createDefaultDirectories: (function() { + FS.mkdir("/tmp"); + FS.mkdir("/home"); + FS.mkdir("/home/web_user"); + }), + createDefaultDevices: (function() { + FS.mkdir("/dev"); + FS.registerDevice(FS.makedev(1, 3), { + read: (function() { + return 0; + }), + write: (function(stream, buffer, offset, length, pos) { + return length; + }) + }); + FS.mkdev("/dev/null", FS.makedev(1, 3)); + TTY.register(FS.makedev(5, 0), TTY.default_tty_ops); + TTY.register(FS.makedev(6, 0), TTY.default_tty1_ops); + FS.mkdev("/dev/tty", FS.makedev(5, 0)); + FS.mkdev("/dev/tty1", FS.makedev(6, 0)); + var random_device; + if (typeof crypto === "object" && typeof crypto["getRandomValues"] === "function") { + var randomBuffer = new Uint8Array(1); + random_device = (function() { + crypto.getRandomValues(randomBuffer); + return randomBuffer[0]; + }); + } else if (ENVIRONMENT_IS_NODE) { + try { + var crypto_module = require("crypto"); + random_device = (function() { + return crypto_module["randomBytes"](1)[0]; + }); + } catch (e) {} + } else {} + if (!random_device) { + random_device = (function() { + abort("no cryptographic support found for random_device. consider polyfilling it if you want to use something insecure like Math.random(), e.g. put this in a --pre-js: var crypto = { getRandomValues: function(array) { for (var i = 0; i < array.length; i++) array[i] = (Math.random()*256)|0 } };"); + }); + } + FS.createDevice("/dev", "random", random_device); + FS.createDevice("/dev", "urandom", random_device); + FS.mkdir("/dev/shm"); + FS.mkdir("/dev/shm/tmp"); + }), + createSpecialDirectories: (function() { + FS.mkdir("/proc"); + FS.mkdir("/proc/self"); + FS.mkdir("/proc/self/fd"); + FS.mount({ + mount: (function() { + var node = FS.createNode("/proc/self", "fd", 16384 | 511, 73); + node.node_ops = { + lookup: (function(parent, name) { + var fd = +name; + var stream = FS.getStream(fd); + if (!stream) throw new FS.ErrnoError(8); + var ret = { + parent: null, + mount: { + mountpoint: "fake" + }, + node_ops: { + readlink: (function() { + return stream.path; + }) + } + }; + ret.parent = ret; + return ret; + }) + }; + return node; + }) + }, {}, "/proc/self/fd"); + }), + createStandardStreams: (function() { + if (Module["stdin"]) { + FS.createDevice("/dev", "stdin", Module["stdin"]); + } else { + FS.symlink("/dev/tty", "/dev/stdin"); } + if (Module["stdout"]) { + FS.createDevice("/dev", "stdout", null, Module["stdout"]); + } else { + FS.symlink("/dev/tty", "/dev/stdout"); } - - Module["___syscall183"] = ___syscall183; - - - - - function _memset(ptr, value, num) { - ptr = ptr|0; value = value|0; num = num|0; - var end = 0, aligned_end = 0, block_aligned_end = 0, value4 = 0; - end = (ptr + num)|0; - - value = value & 0xff; - if ((num|0) >= 67 /* 64 bytes for an unrolled loop + 3 bytes for unaligned head*/) { - while ((ptr&3) != 0) { - HEAP8[((ptr)>>0)]=value; - ptr = (ptr+1)|0; - } - - aligned_end = (end & -4)|0; - value4 = value | (value << 8) | (value << 16) | (value << 24); - - block_aligned_end = (aligned_end - 64)|0; - - while((ptr|0) <= (block_aligned_end|0)) { - HEAP32[((ptr)>>2)]=value4; - HEAP32[(((ptr)+(4))>>2)]=value4; - HEAP32[(((ptr)+(8))>>2)]=value4; - HEAP32[(((ptr)+(12))>>2)]=value4; - HEAP32[(((ptr)+(16))>>2)]=value4; - HEAP32[(((ptr)+(20))>>2)]=value4; - HEAP32[(((ptr)+(24))>>2)]=value4; - HEAP32[(((ptr)+(28))>>2)]=value4; - HEAP32[(((ptr)+(32))>>2)]=value4; - HEAP32[(((ptr)+(36))>>2)]=value4; - HEAP32[(((ptr)+(40))>>2)]=value4; - HEAP32[(((ptr)+(44))>>2)]=value4; - HEAP32[(((ptr)+(48))>>2)]=value4; - HEAP32[(((ptr)+(52))>>2)]=value4; - HEAP32[(((ptr)+(56))>>2)]=value4; - HEAP32[(((ptr)+(60))>>2)]=value4; - ptr = (ptr + 64)|0; - } - - while ((ptr|0) < (aligned_end|0) ) { - HEAP32[((ptr)>>2)]=value4; - ptr = (ptr+4)|0; - } - } - // The remaining bytes. - while ((ptr|0) < (end|0)) { - HEAP8[((ptr)>>0)]=value; - ptr = (ptr+1)|0; - } - return (end-num)|0; - } - Module["_memset"] = _memset;function __emscripten_syscall_mmap2(addr, len, prot, flags, fd, off) { - off <<= 12; // undo pgoffset - var ptr; - var allocated = false; - - // addr argument must be page aligned if MAP_FIXED flag is set. - if ((flags & 16) !== 0 && (addr % PAGE_SIZE) !== 0) { - return -28; - } - - // MAP_ANONYMOUS (aka MAP_ANON) isn't actually defined by POSIX spec, - // but it is widely used way to allocate memory pages on Linux, BSD and Mac. - // In this case fd argument is ignored. - if ((flags & 32) !== 0) { - ptr = _memalign(PAGE_SIZE, len); - if (!ptr) return -48; - _memset(ptr, 0, len); - allocated = true; - } else { - var info = FS.getStream(fd); - if (!info) return -8; - var res = FS.mmap(info, HEAPU8, addr, len, off, prot, flags); - ptr = res.ptr; - allocated = res.allocated; - } - SYSCALLS.mappings[ptr] = { malloc: ptr, len: len, allocated: allocated, fd: fd, flags: flags }; - return ptr; + if (Module["stderr"]) { + FS.createDevice("/dev", "stderr", null, Module["stderr"]); + } else { + FS.symlink("/dev/tty1", "/dev/stderr"); + } + var stdin = FS.open("/dev/stdin", "r"); + var stdout = FS.open("/dev/stdout", "w"); + var stderr = FS.open("/dev/stderr", "w"); + assert(stdin.fd === 0, "invalid handle for stdin (" + stdin.fd + ")"); + assert(stdout.fd === 1, "invalid handle for stdout (" + stdout.fd + ")"); + assert(stderr.fd === 2, "invalid handle for stderr (" + stderr.fd + ")"); + }), + ensureErrnoError: (function() { + if (FS.ErrnoError) return; + FS.ErrnoError = function ErrnoError(errno, node) { + this.node = node; + this.setErrno = (function(errno) { + this.errno = errno; + for (var key in ERRNO_CODES) { + if (ERRNO_CODES[key] === errno) { + this.code = key; + break; + } } - Module["__emscripten_syscall_mmap2"] = __emscripten_syscall_mmap2;function ___syscall192(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(5, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // mmap2 - var addr = SYSCALLS.get(), len = SYSCALLS.get(), prot = SYSCALLS.get(), flags = SYSCALLS.get(), fd = SYSCALLS.get(), off = SYSCALLS.get() - return __emscripten_syscall_mmap2(addr, len, prot, flags, fd, off); - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall192"] = ___syscall192; - - function ___syscall195(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(6, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // SYS_stat64 - var path = SYSCALLS.getStr(), buf = SYSCALLS.get(); - return SYSCALLS.doStat(FS.stat, path, buf); - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall195"] = ___syscall195; - - function ___syscall196(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(7, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // SYS_lstat64 - var path = SYSCALLS.getStr(), buf = SYSCALLS.get(); - return SYSCALLS.doStat(FS.lstat, path, buf); - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall196"] = ___syscall196; - - function ___syscall220(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(8, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // SYS_getdents64 - var stream = SYSCALLS.getStreamFromFD(), dirp = SYSCALLS.get(), count = SYSCALLS.get(); - if (!stream.getdents) { - stream.getdents = FS.readdir(stream.path); - } - - var struct_size = 280; - var pos = 0; - var off = FS.llseek(stream, 0, 1); - - var idx = Math.floor(off / struct_size); - - while (idx < stream.getdents.length && pos + struct_size <= count) { - var id; - var type; - var name = stream.getdents[idx]; - if (name[0] === '.') { - id = 1; - type = 4; // DT_DIR - } else { - var child = FS.lookupNode(stream.node, name); - id = child.id; - type = FS.isChrdev(child.mode) ? 2 : // DT_CHR, character device. - FS.isDir(child.mode) ? 4 : // DT_DIR, directory. - FS.isLink(child.mode) ? 10 : // DT_LNK, symbolic link. - 8; // DT_REG, regular file. - } - (tempI64 = [id>>>0,(tempDouble=id,(+(Math_abs(tempDouble))) >= 1.0 ? (tempDouble > 0.0 ? ((Math_min((+(Math_floor((tempDouble)/4294967296.0))), 4294967295.0))|0)>>>0 : (~~((+(Math_ceil((tempDouble - +(((~~(tempDouble)))>>>0))/4294967296.0)))))>>>0) : 0)],HEAP32[((dirp + pos)>>2)]=tempI64[0],HEAP32[(((dirp + pos)+(4))>>2)]=tempI64[1]); - (tempI64 = [(idx + 1) * struct_size>>>0,(tempDouble=(idx + 1) * struct_size,(+(Math_abs(tempDouble))) >= 1.0 ? (tempDouble > 0.0 ? ((Math_min((+(Math_floor((tempDouble)/4294967296.0))), 4294967295.0))|0)>>>0 : (~~((+(Math_ceil((tempDouble - +(((~~(tempDouble)))>>>0))/4294967296.0)))))>>>0) : 0)],HEAP32[(((dirp + pos)+(8))>>2)]=tempI64[0],HEAP32[(((dirp + pos)+(12))>>2)]=tempI64[1]); - HEAP16[(((dirp + pos)+(16))>>1)]=280; - HEAP8[(((dirp + pos)+(18))>>0)]=type; - stringToUTF8(name, dirp + pos + 19, 256); - pos += struct_size; - idx += 1; - } - FS.llseek(stream, idx * struct_size, 0); - return pos; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall220"] = ___syscall220; - - function ___syscall221(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(9, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // fcntl64 - var stream = SYSCALLS.getStreamFromFD(), cmd = SYSCALLS.get(); - switch (cmd) { - case 0: { - var arg = SYSCALLS.get(); - if (arg < 0) { - return -28; - } - var newStream; - newStream = FS.open(stream.path, stream.flags, 0, arg); - return newStream.fd; - } - case 1: - case 2: - return 0; // FD_CLOEXEC makes no sense for a single process. - case 3: - return stream.flags; - case 4: { - var arg = SYSCALLS.get(); - stream.flags |= arg; - return 0; - } - case 12: - /* case 12: Currently in musl F_GETLK64 has same value as F_GETLK, so omitted to avoid duplicate case blocks. If that changes, uncomment this */ { - - var arg = SYSCALLS.get(); - var offset = 0; - // We're always unlocked. - HEAP16[(((arg)+(offset))>>1)]=2; - return 0; - } - case 13: - case 14: - /* case 13: Currently in musl F_SETLK64 has same value as F_SETLK, so omitted to avoid duplicate case blocks. If that changes, uncomment this */ - /* case 14: Currently in musl F_SETLKW64 has same value as F_SETLKW, so omitted to avoid duplicate case blocks. If that changes, uncomment this */ - - - return 0; // Pretend that the locking is successful. - case 16: - case 8: - return -28; // These are for sockets. We don't have them fully implemented yet. - case 9: - // musl trusts getown return values, due to a bug where they must be, as they overlap with errors. just return -1 here, so fnctl() returns that, and we set errno ourselves. - ___setErrNo(28); - return -1; - default: { - return -28; - } - } - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall221"] = ___syscall221; - - function ___syscall3(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(10, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // read - var stream = SYSCALLS.getStreamFromFD(), buf = SYSCALLS.get(), count = SYSCALLS.get(); - return FS.read(stream, HEAP8,buf, count); - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall3"] = ___syscall3; - - function ___syscall39(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(11, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // mkdir - var path = SYSCALLS.getStr(), mode = SYSCALLS.get(); - return SYSCALLS.doMkdir(path, mode); - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall39"] = ___syscall39; - - function ___syscall4(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(12, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // write - var stream = SYSCALLS.getStreamFromFD(), buf = SYSCALLS.get(), count = SYSCALLS.get(); - return FS.write(stream, HEAP8,buf, count); - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall4"] = ___syscall4; - - function ___syscall40(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(13, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // rmdir - var path = SYSCALLS.getStr(); - FS.rmdir(path); - return 0; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall40"] = ___syscall40; - - function ___syscall5(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(14, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // open - var pathname = SYSCALLS.getStr(), flags = SYSCALLS.get(), mode = SYSCALLS.get(); // optional TODO - var stream = FS.open(pathname, flags, mode); - return stream.fd; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall5"] = ___syscall5; - - function ___syscall54(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(15, 1, which, varargs); - SYSCALLS.varargs = varargs; - try { - // ioctl - var stream = SYSCALLS.getStreamFromFD(), op = SYSCALLS.get(); - switch (op) { - case 21509: - case 21505: { - if (!stream.tty) return -59; - return 0; - } - case 21510: - case 21511: - case 21512: - case 21506: - case 21507: - case 21508: { - if (!stream.tty) return -59; - return 0; // no-op, not actually adjusting terminal settings - } - case 21519: { - if (!stream.tty) return -59; - var argp = SYSCALLS.get(); - HEAP32[((argp)>>2)]=0; - return 0; - } - case 21520: { - if (!stream.tty) return -59; - return -28; // not supported - } - case 21531: { - var argp = SYSCALLS.get(); - return FS.ioctl(stream, op, argp); - } - case 21523: { - // TODO: in theory we should write to the winsize struct that gets - // passed in, but for now musl doesn't read anything on it - if (!stream.tty) return -59; - return 0; - } - case 21524: { - // TODO: technically, this ioctl call should change the window size. - // but, since emscripten doesn't have any concept of a terminal window - // yet, we'll just silently throw it away as we do TIOCGWINSZ - if (!stream.tty) return -59; - return 0; - } - default: abort('bad ioctl syscall ' + op); - } - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } + }); + this.setErrno(errno); + this.message = ERRNO_MESSAGES[errno]; + if (this.stack) { + Object.defineProperty(this, "stack", { + value: (new Error).stack, + writable: true + }); + this.stack = demangleAll(this.stack); + } + }; + FS.ErrnoError.prototype = new Error; + FS.ErrnoError.prototype.constructor = FS.ErrnoError; + [ 44 ].forEach((function(code) { + FS.genericErrors[code] = new FS.ErrnoError(code); + FS.genericErrors[code].stack = ""; + })); + }), + staticInit: (function() { + FS.ensureErrnoError(); + FS.nameTable = new Array(4096); + FS.mount(MEMFS, {}, "/"); + FS.createDefaultDirectories(); + FS.createDefaultDevices(); + FS.createSpecialDirectories(); + FS.filesystems = { + "MEMFS": MEMFS, + "NODEFS": NODEFS + }; + }), + init: (function(input, output, error) { + assert(!FS.init.initialized, "FS.init was previously called. If you want to initialize later with custom parameters, remove any earlier calls (note that one is automatically added to the generated code)"); + FS.init.initialized = true; + FS.ensureErrnoError(); + Module["stdin"] = input || Module["stdin"]; + Module["stdout"] = output || Module["stdout"]; + Module["stderr"] = error || Module["stderr"]; + FS.createStandardStreams(); + }), + quit: (function() { + FS.init.initialized = false; + var fflush = Module["_fflush"]; + if (fflush) fflush(0); + for (var i = 0; i < FS.streams.length; i++) { + var stream = FS.streams[i]; + if (!stream) { + continue; + } + FS.close(stream); + } + }), + getMode: (function(canRead, canWrite) { + var mode = 0; + if (canRead) mode |= 292 | 73; + if (canWrite) mode |= 146; + return mode; + }), + joinPath: (function(parts, forceRelative) { + var path = PATH.join.apply(null, parts); + if (forceRelative && path[0] == "/") path = path.substr(1); + return path; + }), + absolutePath: (function(relative, base) { + return PATH_FS.resolve(base, relative); + }), + standardizePath: (function(path) { + return PATH.normalize(path); + }), + findObject: (function(path, dontResolveLastLink) { + var ret = FS.analyzePath(path, dontResolveLastLink); + if (ret.exists) { + return ret.object; + } else { + ___setErrNo(ret.error); + return null; } - - Module["___syscall54"] = ___syscall54; - - function ___syscall85(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(16, 1, which, varargs); - SYSCALLS.varargs = varargs; + }), + analyzePath: (function(path, dontResolveLastLink) { try { - // readlink - var path = SYSCALLS.getStr(), buf = SYSCALLS.get(), bufsize = SYSCALLS.get(); - return SYSCALLS.doReadlink(path, buf, bufsize); - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } - } - - Module["___syscall85"] = ___syscall85; - - - function __emscripten_syscall_munmap(addr, len) { - if (addr === -1 || len === 0) { - return -28; - } - // TODO: support unmmap'ing parts of allocations - var info = SYSCALLS.mappings[addr]; - if (!info) return 0; - if (len === info.len) { - var stream = FS.getStream(info.fd); - SYSCALLS.doMsync(addr, stream, len, info.flags); - FS.munmap(stream); - SYSCALLS.mappings[addr] = null; - if (info.allocated) { - _free(info.malloc); - } - } - return 0; - } - Module["__emscripten_syscall_munmap"] = __emscripten_syscall_munmap;function ___syscall91(which, varargs) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(17, 1, which, varargs); - SYSCALLS.varargs = varargs; + var lookup = FS.lookupPath(path, { + follow: !dontResolveLastLink + }); + path = lookup.path; + } catch (e) {} + var ret = { + isRoot: false, + exists: false, + error: 0, + name: null, + path: null, + object: null, + parentExists: false, + parentPath: null, + parentObject: null + }; try { - // munmap - var addr = SYSCALLS.get(), len = SYSCALLS.get(); - return __emscripten_syscall_munmap(addr, len); - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return -e.errno; - } + var lookup = FS.lookupPath(path, { + parent: true + }); + ret.parentExists = true; + ret.parentPath = lookup.path; + ret.parentObject = lookup.node; + ret.name = PATH.basename(path); + lookup = FS.lookupPath(path, { + follow: !dontResolveLastLink + }); + ret.exists = true; + ret.path = lookup.path; + ret.object = lookup.node; + ret.name = lookup.node.name; + ret.isRoot = lookup.path === "/"; + } catch (e) { + ret.error = e.errno; } - - Module["___syscall91"] = ___syscall91; - - function ___unlock() {} - Module["___unlock"] = ___unlock; - - function _abort() { - abort(); - } - Module["_abort"] = _abort; - - - function _emscripten_check_blocking_allowed() { - assert(ENVIRONMENT_IS_WEB); - warnOnce('Blocking on the main thread is very dangerous, see https://emscripten.org/docs/porting/pthreads.html#blocking-on-the-main-browser-thread'); - } - Module["_emscripten_check_blocking_allowed"] = _emscripten_check_blocking_allowed; - - - function _emscripten_conditional_set_current_thread_status_js(expectedStatus, newStatus) { - } - Module["_emscripten_conditional_set_current_thread_status_js"] = _emscripten_conditional_set_current_thread_status_js;function _emscripten_conditional_set_current_thread_status(expectedStatus, newStatus) { - expectedStatus = expectedStatus|0; - newStatus = newStatus|0; - } - Module["_emscripten_conditional_set_current_thread_status"] = _emscripten_conditional_set_current_thread_status; - - function _emscripten_futex_wait(addr, val, timeout) { - if (addr <= 0 || addr > HEAP8.length || addr&3 != 0) return -28; - // dump('futex_wait addr:' + addr + ' by thread: ' + _pthread_self() + (ENVIRONMENT_IS_PTHREAD?'(pthread)':'') + '\n'); - if (ENVIRONMENT_IS_WORKER) { - var ret = Atomics.wait(HEAP32, addr >> 2, val, timeout); - // dump('futex_wait done by thread: ' + _pthread_self() + (ENVIRONMENT_IS_PTHREAD?'(pthread)':'') + '\n'); - if (ret === 'timed-out') return -73; - if (ret === 'not-equal') return -6; - if (ret === 'ok') return 0; - throw 'Atomics.wait returned an unexpected value ' + ret; - } else { - // Atomics.wait is not available in the main browser thread, so simulate it via busy spinning. - var loadedVal = Atomics.load(HEAP32, addr >> 2); - if (val != loadedVal) return -6; - - var tNow = performance.now(); - var tEnd = tNow + timeout; - - - // Register globally which address the main thread is simulating to be waiting on. When zero, main thread is not waiting on anything, - // and on nonzero, the contents of address pointed by __main_thread_futex_wait_address tell which address the main thread is simulating its wait on. - Atomics.store(HEAP32, __main_thread_futex_wait_address >> 2, addr); - var ourWaitAddress = addr; // We may recursively re-enter this function while processing queued calls, in which case we'll do a spurious wakeup of the older wait operation. - while (addr == ourWaitAddress) { - tNow = performance.now(); - if (tNow > tEnd) { - return -73; - } - _emscripten_main_thread_process_queued_calls(); // We are performing a blocking loop here, so must pump any pthreads if they want to perform operations that are proxied. - addr = Atomics.load(HEAP32, __main_thread_futex_wait_address >> 2); // Look for a worker thread waking us up. - } - return 0; - } - } - Module["_emscripten_futex_wait"] = _emscripten_futex_wait; - - - function _emscripten_get_heap_size() { - return HEAP8.length; - } - Module["_emscripten_get_heap_size"] = _emscripten_get_heap_size; - - - function _emscripten_get_sbrk_ptr() { - return 12594960; - } - Module["_emscripten_get_sbrk_ptr"] = _emscripten_get_sbrk_ptr; - - function _emscripten_has_threading_support() { - return typeof SharedArrayBuffer !== 'undefined'; - } - Module["_emscripten_has_threading_support"] = _emscripten_has_threading_support; - - function _emscripten_is_main_browser_thread() { - return __pthread_is_main_browser_thread|0; // Semantically the same as testing "!ENVIRONMENT_IS_WORKER" outside the asm.js scope - } - Module["_emscripten_is_main_browser_thread"] = _emscripten_is_main_browser_thread; - - function _emscripten_is_main_runtime_thread() { - return __pthread_is_main_runtime_thread|0; // Semantically the same as testing "!ENVIRONMENT_IS_PTHREAD" outside the asm.js scope - } - Module["_emscripten_is_main_runtime_thread"] = _emscripten_is_main_runtime_thread; - - - - - var setjmpId=0; - Module["setjmpId"] = setjmpId;function _saveSetjmp(env, label, table, size) { - // Not particularly fast: slow table lookup of setjmpId to label. But setjmp - // prevents relooping anyhow, so slowness is to be expected. And typical case - // is 1 setjmp per invocation, or less. - env = env|0; - label = label|0; - table = table|0; - size = size|0; - var i = 0; - setjmpId = (setjmpId+1)|0; - HEAP32[((env)>>2)]=setjmpId; - while ((i|0) < (size|0)) { - if (((HEAP32[(((table)+((i<<3)))>>2)])|0) == 0) { - HEAP32[(((table)+((i<<3)))>>2)]=setjmpId; - HEAP32[(((table)+((i<<3)+4))>>2)]=label; - // prepare next slot - HEAP32[(((table)+((i<<3)+8))>>2)]=0; - setTempRet0((size) | 0); - return table | 0; - } - i = i+1|0; - } - // grow the table - size = (size*2)|0; - table = _realloc(table|0, 8*(size+1|0)|0) | 0; - table = _saveSetjmp(env|0, label|0, table|0, size|0) | 0; - setTempRet0((size) | 0); - return table | 0; - } - Module["_saveSetjmp"] = _saveSetjmp; - - function _testSetjmp(id, table, size) { - id = id|0; - table = table|0; - size = size|0; - var i = 0, curr = 0; - while ((i|0) < (size|0)) { - curr = ((HEAP32[(((table)+((i<<3)))>>2)])|0); - if ((curr|0) == 0) break; - if ((curr|0) == (id|0)) { - return ((HEAP32[(((table)+((i<<3)+4))>>2)])|0); - } - i = i+1|0; - } - return 0; - } - Module["_testSetjmp"] = _testSetjmp;function _longjmp(env, value) { - _setThrew(env, value || 1); - throw 'longjmp'; - } - Module["_longjmp"] = _longjmp;function _emscripten_longjmp(env, value) { - _longjmp(env, value); - } - Module["_emscripten_longjmp"] = _emscripten_longjmp; - - function _emscripten_memcpy_big(dest, src, num) { - HEAPU8.set(HEAPU8.subarray(src, src+num), dest); - } - Module["_emscripten_memcpy_big"] = _emscripten_memcpy_big; - - - function _emscripten_proxy_to_main_thread_js(index, sync) { - // Additional arguments are passed after those two, which are the actual - // function arguments. - // The serialization buffer contains the number of call params, and then - // all the args here. - // We also pass 'sync' to C separately, since C needs to look at it. - var numCallArgs = arguments.length - 2; - if (numCallArgs > 20-1) throw 'emscripten_proxy_to_main_thread_js: Too many arguments ' + numCallArgs + ' to proxied function idx=' + index + ', maximum supported is ' + (20-1) + '!'; - // Allocate a buffer, which will be copied by the C code. - var stack = stackSave(); - // First passed parameter specifies the number of arguments to the function. - var args = stackAlloc(numCallArgs * 8); - var b = args >> 3; - for (var i = 0; i < numCallArgs; i++) { - HEAPF64[b + i] = arguments[2 + i]; - } - var ret = _emscripten_run_in_main_runtime_thread_js(index, numCallArgs, args, sync); - stackRestore(stack); - return ret; - } - Module["_emscripten_proxy_to_main_thread_js"] = _emscripten_proxy_to_main_thread_js; - - var _emscripten_receive_on_main_thread_js_callArgs=[]; - Module["_emscripten_receive_on_main_thread_js_callArgs"] = _emscripten_receive_on_main_thread_js_callArgs;function _emscripten_receive_on_main_thread_js(index, numCallArgs, args) { - _emscripten_receive_on_main_thread_js_callArgs.length = numCallArgs; - var b = args >> 3; - for (var i = 0; i < numCallArgs; i++) { - _emscripten_receive_on_main_thread_js_callArgs[i] = HEAPF64[b + i]; - } - // Proxied JS library funcs are encoded as positive values, and - // EM_ASMs as negative values (see include_asm_consts) - var isEmAsmConst = index < 0; - var func = !isEmAsmConst ? proxiedFunctionTable[index] : ASM_CONSTS[-index - 1]; - if (isEmAsmConst) { - // EM_ASM arguments are stored in their own buffer in memory, that we need - // to unpack in order to call. The proxied arguments are the code index, - // signature pointer, and vararg buffer pointer, in that order. - var sigPtr = _emscripten_receive_on_main_thread_js_callArgs[1]; - var varargPtr = _emscripten_receive_on_main_thread_js_callArgs[2]; - var constArgs = readAsmConstArgs(sigPtr, varargPtr); - return func.apply(null, constArgs); - } - assert(func.length == numCallArgs, 'Call args mismatch in emscripten_receive_on_main_thread_js'); - return func.apply(null, _emscripten_receive_on_main_thread_js_callArgs); + return ret; + }), + createFolder: (function(parent, name, canRead, canWrite) { + var path = PATH.join2(typeof parent === "string" ? parent : FS.getPath(parent), name); + var mode = FS.getMode(canRead, canWrite); + return FS.mkdir(path, mode); + }), + createPath: (function(parent, path, canRead, canWrite) { + parent = typeof parent === "string" ? parent : FS.getPath(parent); + var parts = path.split("/").reverse(); + while (parts.length) { + var part = parts.pop(); + if (!part) continue; + var current = PATH.join2(parent, part); + try { + FS.mkdir(current); + } catch (e) {} + parent = current; + } + return current; + }), + createFile: (function(parent, name, properties, canRead, canWrite) { + var path = PATH.join2(typeof parent === "string" ? parent : FS.getPath(parent), name); + var mode = FS.getMode(canRead, canWrite); + return FS.create(path, mode); + }), + createDataFile: (function(parent, name, data, canRead, canWrite, canOwn) { + var path = name ? PATH.join2(typeof parent === "string" ? parent : FS.getPath(parent), name) : parent; + var mode = FS.getMode(canRead, canWrite); + var node = FS.create(path, mode); + if (data) { + if (typeof data === "string") { + var arr = new Array(data.length); + for (var i = 0, len = data.length; i < len; ++i) arr[i] = data.charCodeAt(i); + data = arr; + } + FS.chmod(node, mode | 146); + var stream = FS.open(node, "w"); + FS.write(stream, data, 0, data.length, 0, canOwn); + FS.close(stream); + FS.chmod(node, mode); + } + return node; + }), + createDevice: (function(parent, name, input, output) { + var path = PATH.join2(typeof parent === "string" ? parent : FS.getPath(parent), name); + var mode = FS.getMode(!!input, !!output); + if (!FS.createDevice.major) FS.createDevice.major = 64; + var dev = FS.makedev(FS.createDevice.major++, 0); + FS.registerDevice(dev, { + open: (function(stream) { + stream.seekable = false; + }), + close: (function(stream) { + if (output && output.buffer && output.buffer.length) { + output(10); } - Module["_emscripten_receive_on_main_thread_js"] = _emscripten_receive_on_main_thread_js; - - - function abortOnCannotGrowMemory(requestedSize) { - abort('Cannot enlarge memory arrays to size ' + requestedSize + ' bytes (OOM). Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value ' + HEAP8.length + ', (2) compile with -s ALLOW_MEMORY_GROWTH=1 which allows increasing the size at runtime, or (3) if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 '); + }), + read: (function(stream, buffer, offset, length, pos) { + var bytesRead = 0; + for (var i = 0; i < length; i++) { + var result; + try { + result = input(); + } catch (e) { + throw new FS.ErrnoError(29); + } + if (result === undefined && bytesRead === 0) { + throw new FS.ErrnoError(6); + } + if (result === null || result === undefined) break; + bytesRead++; + buffer[offset + i] = result; } - Module["abortOnCannotGrowMemory"] = abortOnCannotGrowMemory;function _emscripten_resize_heap(requestedSize) { - abortOnCannotGrowMemory(requestedSize); + if (bytesRead) { + stream.node.timestamp = Date.now(); } - Module["_emscripten_resize_heap"] = _emscripten_resize_heap; - - - var JSEvents={keyEvent:0,mouseEvent:0,wheelEvent:0,uiEvent:0,focusEvent:0,deviceOrientationEvent:0,deviceMotionEvent:0,fullscreenChangeEvent:0,pointerlockChangeEvent:0,visibilityChangeEvent:0,touchEvent:0,previousFullscreenElement:null,previousScreenX:null,previousScreenY:null,removeEventListenersRegistered:false,removeAllEventListeners:function() { - for(var i = JSEvents.eventHandlers.length-1; i >= 0; --i) { - JSEvents._removeHandler(i); - } - JSEvents.eventHandlers = []; - JSEvents.deferredCalls = []; - },registerRemoveEventListeners:function() { - if (!JSEvents.removeEventListenersRegistered) { - __ATEXIT__.push(JSEvents.removeAllEventListeners); - JSEvents.removeEventListenersRegistered = true; - } - },deferredCalls:[],deferCall:function(targetFunction, precedence, argsList) { - function arraysHaveEqualContent(arrA, arrB) { - if (arrA.length != arrB.length) return false; - - for(var i in arrA) { - if (arrA[i] != arrB[i]) return false; - } - return true; - } - // Test if the given call was already queued, and if so, don't add it again. - for(var i in JSEvents.deferredCalls) { - var call = JSEvents.deferredCalls[i]; - if (call.targetFunction == targetFunction && arraysHaveEqualContent(call.argsList, argsList)) { - return; - } - } - JSEvents.deferredCalls.push({ - targetFunction: targetFunction, - precedence: precedence, - argsList: argsList - }); - - JSEvents.deferredCalls.sort(function(x,y) { return x.precedence < y.precedence; }); - },removeDeferredCalls:function(targetFunction) { - for(var i = 0; i < JSEvents.deferredCalls.length; ++i) { - if (JSEvents.deferredCalls[i].targetFunction == targetFunction) { - JSEvents.deferredCalls.splice(i, 1); - --i; - } - } - },canPerformEventHandlerRequests:function() { - return JSEvents.inEventHandler && JSEvents.currentEventHandler.allowsDeferredCalls; - },runDeferredCalls:function() { - if (!JSEvents.canPerformEventHandlerRequests()) { - return; - } - for(var i = 0; i < JSEvents.deferredCalls.length; ++i) { - var call = JSEvents.deferredCalls[i]; - JSEvents.deferredCalls.splice(i, 1); - --i; - call.targetFunction.apply(this, call.argsList); - } - },inEventHandler:0,currentEventHandler:null,eventHandlers:[],isInternetExplorer:function() { return navigator.userAgent.indexOf('MSIE') !== -1 || navigator.appVersion.indexOf('Trident/') > 0; },removeAllHandlersOnTarget:function(target, eventTypeString) { - for(var i = 0; i < JSEvents.eventHandlers.length; ++i) { - if (JSEvents.eventHandlers[i].target == target && - (!eventTypeString || eventTypeString == JSEvents.eventHandlers[i].eventTypeString)) { - JSEvents._removeHandler(i--); - } - } - },_removeHandler:function(i) { - var h = JSEvents.eventHandlers[i]; - h.target.removeEventListener(h.eventTypeString, h.eventListenerFunc, h.useCapture); - JSEvents.eventHandlers.splice(i, 1); - },registerOrRemoveHandler:function(eventHandler) { - var jsEventHandler = function jsEventHandler(event) { - // Increment nesting count for the event handler. - ++JSEvents.inEventHandler; - JSEvents.currentEventHandler = eventHandler; - // Process any old deferred calls the user has placed. - JSEvents.runDeferredCalls(); - // Process the actual event, calls back to user C code handler. - eventHandler.handlerFunc(event); - // Process any new deferred calls that were placed right now from this event handler. - JSEvents.runDeferredCalls(); - // Out of event handler - restore nesting count. - --JSEvents.inEventHandler; - }; - - if (eventHandler.callbackfunc) { - eventHandler.eventListenerFunc = jsEventHandler; - eventHandler.target.addEventListener(eventHandler.eventTypeString, jsEventHandler, eventHandler.useCapture); - JSEvents.eventHandlers.push(eventHandler); - JSEvents.registerRemoveEventListeners(); - } else { - for(var i = 0; i < JSEvents.eventHandlers.length; ++i) { - if (JSEvents.eventHandlers[i].target == eventHandler.target - && JSEvents.eventHandlers[i].eventTypeString == eventHandler.eventTypeString) { - JSEvents._removeHandler(i--); - } - } - } - },queueEventHandlerOnThread_iiii:function(targetThread, eventHandlerFunc, eventTypeId, eventData, userData) { - var stackTop = stackSave(); - var varargs = stackAlloc(12); - HEAP32[((varargs)>>2)]=eventTypeId; - HEAP32[(((varargs)+(4))>>2)]=eventData; - HEAP32[(((varargs)+(8))>>2)]=userData; - _emscripten_async_queue_on_thread_(targetThread, 637534208, eventHandlerFunc, eventData, varargs); - stackRestore(stackTop); - },getTargetThreadForEventCallback:function(targetThread) { - switch(targetThread) { - case 1: return 0; // The event callback for the current event should be called on the main browser thread. (0 == don't proxy) - case 2: return PThread.currentProxiedOperationCallerThread; // The event callback for the current event should be backproxied to the the thread that is registering the event. - default: return targetThread; // The event callback for the current event should be proxied to the given specific thread. - } - },getBoundingClientRectOrZeros:function(target) { - return target.getBoundingClientRect ? target.getBoundingClientRect() : { left: 0, top: 0 }; - },getNodeNameForTarget:function(target) { - if (!target) return ''; - if (target == window) return '#window'; - if (target == screen) return '#screen'; - return (target && target.nodeName) ? target.nodeName : ''; - },tick:function() { - if (window['performance'] && window['performance']['now']) return window['performance']['now'](); - else return Date.now(); - },fullscreenEnabled:function() { - return document.fullscreenEnabled || document.mozFullScreenEnabled || document.webkitFullscreenEnabled || document.msFullscreenEnabled; - }}; - Module["JSEvents"] = JSEvents; - - - - - function stringToNewUTF8(jsString) { - var length = lengthBytesUTF8(jsString)+1; - var cString = _malloc(length); - stringToUTF8(jsString, cString, length); - return cString; + return bytesRead; + }), + write: (function(stream, buffer, offset, length, pos) { + for (var i = 0; i < length; i++) { + try { + output(buffer[offset + i]); + } catch (e) { + throw new FS.ErrnoError(29); + } } - Module["stringToNewUTF8"] = stringToNewUTF8;function _emscripten_set_offscreencanvas_size_on_target_thread_js(targetThread, targetCanvas, width, height) { - var stackTop = stackSave(); - var varargs = stackAlloc(12); - var targetCanvasPtr = 0; - if (targetCanvas) { - targetCanvasPtr = stringToNewUTF8(targetCanvas); - } - HEAP32[((varargs)>>2)]=targetCanvasPtr; - HEAP32[(((varargs)+(4))>>2)]=width; - HEAP32[(((varargs)+(8))>>2)]=height; - // Note: If we are also a pthread, the call below could theoretically be done synchronously. However if the target pthread is waiting for a mutex from us, then - // these two threads will deadlock. At the moment, we'd like to consider that this kind of deadlock would be an Emscripten runtime bug, although if - // emscripten_set_canvas_element_size() was documented to require running an event in the queue of thread that owns the OffscreenCanvas, then that might be ok. - // (safer this way however) - _emscripten_async_queue_on_thread_(targetThread, 657457152, 0, targetCanvasPtr /* satellite data */, varargs); - stackRestore(stackTop); + if (length) { + stream.node.timestamp = Date.now(); } - Module["_emscripten_set_offscreencanvas_size_on_target_thread_js"] = _emscripten_set_offscreencanvas_size_on_target_thread_js;function _emscripten_set_offscreencanvas_size_on_target_thread(targetThread, targetCanvas, width, height) { - targetCanvas = targetCanvas ? UTF8ToString(targetCanvas) : ''; - _emscripten_set_offscreencanvas_size_on_target_thread_js(targetThread, targetCanvas, width, height); + return i; + }) + }); + return FS.mkdev(path, mode, dev); + }), + createLink: (function(parent, name, target, canRead, canWrite) { + var path = PATH.join2(typeof parent === "string" ? parent : FS.getPath(parent), name); + return FS.symlink(target, path); + }), + forceLoadFile: (function(obj) { + if (obj.isDevice || obj.isFolder || obj.link || obj.contents) return true; + var success = true; + if (typeof XMLHttpRequest !== "undefined") { + throw new Error("Lazy loading should have been performed (contents set) in createLazyFile, but it was not. Lazy loading only works in web workers. Use --embed-file or --preload-file in emcc on the main thread."); + } else if (read_) { + try { + obj.contents = intArrayFromString(read_(obj.url), true); + obj.usedBytes = obj.contents.length; + } catch (e) { + success = false; + } + } else { + throw new Error("Cannot load without read() or XMLHttpRequest."); + } + if (!success) ___setErrNo(29); + return success; + }), + createLazyFile: (function(parent, name, url, canRead, canWrite) { + function LazyUint8Array() { + this.lengthKnown = false; + this.chunks = []; + } + LazyUint8Array.prototype.get = function LazyUint8Array_get(idx) { + if (idx > this.length - 1 || idx < 0) { + return undefined; + } + var chunkOffset = idx % this.chunkSize; + var chunkNum = idx / this.chunkSize | 0; + return this.getter(chunkNum)[chunkOffset]; + }; + LazyUint8Array.prototype.setDataGetter = function LazyUint8Array_setDataGetter(getter) { + this.getter = getter; + }; + LazyUint8Array.prototype.cacheLength = function LazyUint8Array_cacheLength() { + var xhr = new XMLHttpRequest; + xhr.open("HEAD", url, false); + xhr.send(null); + if (!(xhr.status >= 200 && xhr.status < 300 || xhr.status === 304)) throw new Error("Couldn't load " + url + ". Status: " + xhr.status); + var datalength = Number(xhr.getResponseHeader("Content-length")); + var header; + var hasByteServing = (header = xhr.getResponseHeader("Accept-Ranges")) && header === "bytes"; + var usesGzip = (header = xhr.getResponseHeader("Content-Encoding")) && header === "gzip"; + var chunkSize = 1024 * 1024; + if (!hasByteServing) chunkSize = datalength; + var doXHR = (function(from, to) { + if (from > to) throw new Error("invalid range (" + from + ", " + to + ") or no bytes requested!"); + if (to > datalength - 1) throw new Error("only " + datalength + " bytes available! programmer error!"); + var xhr = new XMLHttpRequest; + xhr.open("GET", url, false); + if (datalength !== chunkSize) xhr.setRequestHeader("Range", "bytes=" + from + "-" + to); + if (typeof Uint8Array != "undefined") xhr.responseType = "arraybuffer"; + if (xhr.overrideMimeType) { + xhr.overrideMimeType("text/plain; charset=x-user-defined"); } - Module["_emscripten_set_offscreencanvas_size_on_target_thread"] = _emscripten_set_offscreencanvas_size_on_target_thread; - - - - var __specialEventTargets=[0, typeof document !== 'undefined' ? document : 0, typeof window !== 'undefined' ? window : 0]; - Module["__specialEventTargets"] = __specialEventTargets;function __findEventTarget(target) { - warnOnce('Rules for selecting event targets in HTML5 API are changing: instead of using document.getElementById() that only can refer to elements by their DOM ID, new event target selection mechanism uses the more flexible function document.querySelector() that can look up element names, classes, and complex CSS selectors. Build with -s DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=1 to change to the new lookup rules. See https://github.com/emscripten-core/emscripten/pull/7977 for more details.'); - try { - // The sensible "default" target varies between events, but use window as the default - // since DOM events mostly can default to that. Specific callback registrations - // override their own defaults. - if (!target) return window; - if (typeof target === "number") target = __specialEventTargets[target] || UTF8ToString(target); - if (target === '#window') return window; - else if (target === '#document') return document; - else if (target === '#screen') return screen; - else if (target === '#canvas') return Module['canvas']; - return (typeof target === 'string') ? document.getElementById(target) : target; - } catch(e) { - // In Web Workers, some objects above, such as '#document' do not exist. Gracefully - // return null for them. - return null; - } + xhr.send(null); + if (!(xhr.status >= 200 && xhr.status < 300 || xhr.status === 304)) throw new Error("Couldn't load " + url + ". Status: " + xhr.status); + if (xhr.response !== undefined) { + return new Uint8Array(xhr.response || []); + } else { + return intArrayFromString(xhr.responseText || "", true); } - Module["__findEventTarget"] = __findEventTarget;function __findCanvasEventTarget(target) { - if (typeof target === 'number') target = UTF8ToString(target); - if (!target || target === '#canvas') { - if (typeof GL !== 'undefined' && GL.offscreenCanvases['canvas']) return GL.offscreenCanvases['canvas']; // TODO: Remove this line, target '#canvas' should refer only to Module['canvas'], not to GL.offscreenCanvases['canvas'] - but need stricter tests to be able to remove this line. - return Module['canvas']; - } - if (typeof GL !== 'undefined' && GL.offscreenCanvases[target]) return GL.offscreenCanvases[target]; - return __findEventTarget(target); + }); + var lazyArray = this; + lazyArray.setDataGetter((function(chunkNum) { + var start = chunkNum * chunkSize; + var end = (chunkNum + 1) * chunkSize - 1; + end = Math.min(end, datalength - 1); + if (typeof lazyArray.chunks[chunkNum] === "undefined") { + lazyArray.chunks[chunkNum] = doXHR(start, end); } - Module["__findCanvasEventTarget"] = __findCanvasEventTarget;function _emscripten_set_canvas_element_size_calling_thread(target, width, height) { - var canvas = __findCanvasEventTarget(target); - if (!canvas) return -4; - - if (canvas.canvasSharedPtr) { - // N.B. We hold the canvasSharedPtr info structure as the authoritative source for specifying the size of a canvas - // since the actual canvas size changes are asynchronous if the canvas is owned by an OffscreenCanvas on another thread. - // Therefore when setting the size, eagerly set the size of the canvas on the calling thread here, though this thread - // might not be the one that actually ends up specifying the size, but the actual size change may be dispatched - // as an asynchronous event below. - HEAP32[((canvas.canvasSharedPtr)>>2)]=width; - HEAP32[(((canvas.canvasSharedPtr)+(4))>>2)]=height; - } - - if (canvas.offscreenCanvas || !canvas.controlTransferredOffscreen) { - if (canvas.offscreenCanvas) canvas = canvas.offscreenCanvas; - var autoResizeViewport = false; - if (canvas.GLctxObject && canvas.GLctxObject.GLctx) { - var prevViewport = canvas.GLctxObject.GLctx.getParameter(canvas.GLctxObject.GLctx.VIEWPORT); - // TODO: Perhaps autoResizeViewport should only be true if FBO 0 is currently active? - autoResizeViewport = (prevViewport[0] === 0 && prevViewport[1] === 0 && prevViewport[2] === canvas.width && prevViewport[3] === canvas.height); - } - canvas.width = width; - canvas.height = height; - if (autoResizeViewport) { - // TODO: Add -s CANVAS_RESIZE_SETS_GL_VIEWPORT=0/1 option (default=1). This is commonly done and several graphics engines depend on this, - // but this can be quite disruptive. - canvas.GLctxObject.GLctx.viewport(0, 0, width, height); - } - } else if (canvas.canvasSharedPtr) { - var targetThread = HEAP32[(((canvas.canvasSharedPtr)+(8))>>2)]; - _emscripten_set_offscreencanvas_size_on_target_thread(targetThread, target, width, height); - return 1; // This will have to be done asynchronously - } else { - return -4; + if (typeof lazyArray.chunks[chunkNum] === "undefined") throw new Error("doXHR failed!"); + return lazyArray.chunks[chunkNum]; + })); + if (usesGzip || !datalength) { + chunkSize = datalength = 1; + datalength = this.getter(0).length; + chunkSize = datalength; + console.log("LazyFiles on gzip forces download of the whole file when length is accessed"); + } + this._length = datalength; + this._chunkSize = chunkSize; + this.lengthKnown = true; + }; + if (typeof XMLHttpRequest !== "undefined") { + if (!ENVIRONMENT_IS_WORKER) throw "Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc"; + var lazyArray = new LazyUint8Array; + Object.defineProperties(lazyArray, { + length: { + get: (function() { + if (!this.lengthKnown) { + this.cacheLength(); } - return 0; - } - Module["_emscripten_set_canvas_element_size_calling_thread"] = _emscripten_set_canvas_element_size_calling_thread; - - function _emscripten_set_canvas_element_size_main_thread(target, width, height) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(18, 1, target, width, height); - return _emscripten_set_canvas_element_size_calling_thread(target, width, height); } - - Module["_emscripten_set_canvas_element_size_main_thread"] = _emscripten_set_canvas_element_size_main_thread;function _emscripten_set_canvas_element_size(target, width, height) { - var canvas = __findCanvasEventTarget(target); - if (canvas) { - return _emscripten_set_canvas_element_size_calling_thread(target, width, height); - } else { - return _emscripten_set_canvas_element_size_main_thread(target, width, height); + return this._length; + }) + }, + chunkSize: { + get: (function() { + if (!this.lengthKnown) { + this.cacheLength(); } + return this._chunkSize; + }) } - Module["_emscripten_set_canvas_element_size"] = _emscripten_set_canvas_element_size; - - - function _emscripten_set_current_thread_status_js(newStatus) { - } - Module["_emscripten_set_current_thread_status_js"] = _emscripten_set_current_thread_status_js;function _emscripten_set_current_thread_status(newStatus) { - newStatus = newStatus|0; - } - Module["_emscripten_set_current_thread_status"] = _emscripten_set_current_thread_status; - - - function _emscripten_set_thread_name_js(threadId, name) { - } - Module["_emscripten_set_thread_name_js"] = _emscripten_set_thread_name_js;function _emscripten_set_thread_name(threadId, name) { - threadId = threadId|0; - name = name|0; - } - Module["_emscripten_set_thread_name"] = _emscripten_set_thread_name; - - function _emscripten_syscall(which, varargs) { - switch (which) { - case 10: return ___syscall10(which, varargs); - case 12: return ___syscall12(which, varargs); - case 183: return ___syscall183(which, varargs); - case 192: return ___syscall192(which, varargs); - case 195: return ___syscall195(which, varargs); - case 196: return ___syscall196(which, varargs); - case 220: return ___syscall220(which, varargs); - case 221: return ___syscall221(which, varargs); - case 3: return ___syscall3(which, varargs); - case 39: return ___syscall39(which, varargs); - case 4: return ___syscall4(which, varargs); - case 40: return ___syscall40(which, varargs); - case 5: return ___syscall5(which, varargs); - case 54: return ___syscall54(which, varargs); - case 85: return ___syscall85(which, varargs); - case 91: return ___syscall91(which, varargs); - default: throw "surprising proxied syscall: " + which; - } - } - Module["_emscripten_syscall"] = _emscripten_syscall; - - - - var __emscripten_webgl_power_preferences=['default', 'low-power', 'high-performance']; - Module["__emscripten_webgl_power_preferences"] = __emscripten_webgl_power_preferences; - - var GL={counter:1,lastError:0,buffers:[],mappedBuffers:{},programs:[],framebuffers:[],renderbuffers:[],textures:[],uniforms:[],shaders:[],vaos:[],contexts:{},currentContext:null,offscreenCanvases:{},timerQueriesEXT:[],programInfos:{},stringCache:{},unpackAlignment:4,init:function() { - GL.miniTempBuffer = new Float32Array(GL.MINI_TEMP_BUFFER_SIZE); - for (var i = 0; i < GL.MINI_TEMP_BUFFER_SIZE; i++) { - GL.miniTempBufferViews[i] = GL.miniTempBuffer.subarray(0, i+1); - } - },recordError:function recordError(errorCode) { - if (!GL.lastError) { - GL.lastError = errorCode; - } - },getNewId:function(table) { - var ret = GL.counter++; - for (var i = table.length; i < ret; i++) { - table[i] = null; - } - return ret; - },MINI_TEMP_BUFFER_SIZE:256,miniTempBuffer:null,miniTempBufferViews:[0],getSource:function(shader, count, string, length) { - var source = ''; - for (var i = 0; i < count; ++i) { - var len = length ? HEAP32[(((length)+(i*4))>>2)] : -1; - source += UTF8ToString(HEAP32[(((string)+(i*4))>>2)], len < 0 ? undefined : len); - } - return source; - },createContext:function(canvas, webGLContextAttributes) { - - - - - var ctx = - (canvas.getContext("webgl", webGLContextAttributes) || canvas.getContext("experimental-webgl", webGLContextAttributes)); - - - if (!ctx) return 0; - - var handle = GL.registerContext(ctx, webGLContextAttributes); - - - - return handle; - },registerContext:function(ctx, webGLContextAttributes) { - var handle = _malloc(8); // Make space on the heap to store GL context attributes that need to be accessible as shared between threads. - HEAP32[(((handle)+(4))>>2)]=_pthread_self(); // the thread pointer of the thread that owns the control of the context - var context = { - handle: handle, - attributes: webGLContextAttributes, - version: webGLContextAttributes.majorVersion, - GLctx: ctx - }; - - - - // Store the created context object so that we can access the context given a canvas without having to pass the parameters again. - if (ctx.canvas) ctx.canvas.GLctxObject = context; - GL.contexts[handle] = context; - if (typeof webGLContextAttributes.enableExtensionsByDefault === 'undefined' || webGLContextAttributes.enableExtensionsByDefault) { - GL.initExtensions(context); - } - - - - - return handle; - },makeContextCurrent:function(contextHandle) { - - GL.currentContext = GL.contexts[contextHandle]; // Active Emscripten GL layer context object. - Module.ctx = GLctx = GL.currentContext && GL.currentContext.GLctx; // Active WebGL context object. - return !(contextHandle && !GLctx); - },getContext:function(contextHandle) { - return GL.contexts[contextHandle]; - },deleteContext:function(contextHandle) { - if (GL.currentContext === GL.contexts[contextHandle]) GL.currentContext = null; - if (typeof JSEvents === 'object') JSEvents.removeAllHandlersOnTarget(GL.contexts[contextHandle].GLctx.canvas); // Release all JS event handlers on the DOM element that the GL context is associated with since the context is now deleted. - if (GL.contexts[contextHandle] && GL.contexts[contextHandle].GLctx.canvas) GL.contexts[contextHandle].GLctx.canvas.GLctxObject = undefined; // Make sure the canvas object no longer refers to the context object so there are no GC surprises. - _free(GL.contexts[contextHandle]); - GL.contexts[contextHandle] = null; - },acquireInstancedArraysExtension:function(ctx) { - // Extension available in WebGL 1 from Firefox 26 and Google Chrome 30 onwards. Core feature in WebGL 2. - var ext = ctx.getExtension('ANGLE_instanced_arrays'); - if (ext) { - ctx['vertexAttribDivisor'] = function(index, divisor) { ext['vertexAttribDivisorANGLE'](index, divisor); }; - ctx['drawArraysInstanced'] = function(mode, first, count, primcount) { ext['drawArraysInstancedANGLE'](mode, first, count, primcount); }; - ctx['drawElementsInstanced'] = function(mode, count, type, indices, primcount) { ext['drawElementsInstancedANGLE'](mode, count, type, indices, primcount); }; - } - },acquireVertexArrayObjectExtension:function(ctx) { - // Extension available in WebGL 1 from Firefox 25 and WebKit 536.28/desktop Safari 6.0.3 onwards. Core feature in WebGL 2. - var ext = ctx.getExtension('OES_vertex_array_object'); - if (ext) { - ctx['createVertexArray'] = function() { return ext['createVertexArrayOES'](); }; - ctx['deleteVertexArray'] = function(vao) { ext['deleteVertexArrayOES'](vao); }; - ctx['bindVertexArray'] = function(vao) { ext['bindVertexArrayOES'](vao); }; - ctx['isVertexArray'] = function(vao) { return ext['isVertexArrayOES'](vao); }; - } - },acquireDrawBuffersExtension:function(ctx) { - // Extension available in WebGL 1 from Firefox 28 onwards. Core feature in WebGL 2. - var ext = ctx.getExtension('WEBGL_draw_buffers'); - if (ext) { - ctx['drawBuffers'] = function(n, bufs) { ext['drawBuffersWEBGL'](n, bufs); }; - } - },initExtensions:function(context) { - // If this function is called without a specific context object, init the extensions of the currently active context. - if (!context) context = GL.currentContext; - - if (context.initExtensionsDone) return; - context.initExtensionsDone = true; - - var GLctx = context.GLctx; - - // Detect the presence of a few extensions manually, this GL interop layer itself will need to know if they exist. - - if (context.version < 2) { - GL.acquireInstancedArraysExtension(GLctx); - GL.acquireVertexArrayObjectExtension(GLctx); - GL.acquireDrawBuffersExtension(GLctx); - } - - GLctx.disjointTimerQueryExt = GLctx.getExtension("EXT_disjoint_timer_query"); - - // These are the 'safe' feature-enabling extensions that don't add any performance impact related to e.g. debugging, and - // should be enabled by default so that client GLES2/GL code will not need to go through extra hoops to get its stuff working. - // As new extensions are ratified at http://www.khronos.org/registry/webgl/extensions/ , feel free to add your new extensions - // here, as long as they don't produce a performance impact for users that might not be using those extensions. - // E.g. debugging-related extensions should probably be off by default. - var automaticallyEnabledExtensions = [ // Khronos ratified WebGL extensions ordered by number (no debug extensions): - "OES_texture_float", "OES_texture_half_float", "OES_standard_derivatives", - "OES_vertex_array_object", "WEBGL_compressed_texture_s3tc", "WEBGL_depth_texture", - "OES_element_index_uint", "EXT_texture_filter_anisotropic", "EXT_frag_depth", - "WEBGL_draw_buffers", "ANGLE_instanced_arrays", "OES_texture_float_linear", - "OES_texture_half_float_linear", "EXT_blend_minmax", "EXT_shader_texture_lod", - // Community approved WebGL extensions ordered by number: - "WEBGL_compressed_texture_pvrtc", "EXT_color_buffer_half_float", "WEBGL_color_buffer_float", - "EXT_sRGB", "WEBGL_compressed_texture_etc1", "EXT_disjoint_timer_query", - "WEBGL_compressed_texture_etc", "WEBGL_compressed_texture_astc", "EXT_color_buffer_float", - "WEBGL_compressed_texture_s3tc_srgb", "EXT_disjoint_timer_query_webgl2", - // Old style prefixed forms of extensions (but still currently used on e.g. iPhone Xs as - // tested on iOS 12.4.1): - "WEBKIT_WEBGL_compressed_texture_pvrtc"]; - - function shouldEnableAutomatically(extension) { - var ret = false; - automaticallyEnabledExtensions.forEach(function(include) { - if (extension.indexOf(include) != -1) { - ret = true; - } - }); - return ret; - } - - var exts = GLctx.getSupportedExtensions() || []; // .getSupportedExtensions() can return null if context is lost, so coerce to empty array. - exts.forEach(function(ext) { - if (automaticallyEnabledExtensions.indexOf(ext) != -1) { - GLctx.getExtension(ext); // Calling .getExtension enables that extension permanently, no need to store the return value to be enabled. - } - }); - },populateUniformTable:function(program) { - var p = GL.programs[program]; - var ptable = GL.programInfos[program] = { - uniforms: {}, - maxUniformLength: 0, // This is eagerly computed below, since we already enumerate all uniforms anyway. - maxAttributeLength: -1, // This is lazily computed and cached, computed when/if first asked, "-1" meaning not computed yet. - maxUniformBlockNameLength: -1 // Lazily computed as well - }; - - var utable = ptable.uniforms; - // A program's uniform table maps the string name of an uniform to an integer location of that uniform. - // The global GL.uniforms map maps integer locations to WebGLUniformLocations. - var numUniforms = GLctx.getProgramParameter(p, 0x8B86/*GL_ACTIVE_UNIFORMS*/); - for (var i = 0; i < numUniforms; ++i) { - var u = GLctx.getActiveUniform(p, i); - - var name = u.name; - ptable.maxUniformLength = Math.max(ptable.maxUniformLength, name.length+1); - - // If we are dealing with an array, e.g. vec4 foo[3], strip off the array index part to canonicalize that "foo", "foo[]", - // and "foo[0]" will mean the same. Loop below will populate foo[1] and foo[2]. - if (name.slice(-1) == ']') { - name = name.slice(0, name.lastIndexOf('[')); - } - - // Optimize memory usage slightly: If we have an array of uniforms, e.g. 'vec3 colors[3];', then - // only store the string 'colors' in utable, and 'colors[0]', 'colors[1]' and 'colors[2]' will be parsed as 'colors'+i. - // Note that for the GL.uniforms table, we still need to fetch the all WebGLUniformLocations for all the indices. - var loc = GLctx.getUniformLocation(p, name); - if (loc) { - var id = GL.getNewId(GL.uniforms); - utable[name] = [u.size, id]; - GL.uniforms[id] = loc; - - for (var j = 1; j < u.size; ++j) { - var n = name + '['+j+']'; - loc = GLctx.getUniformLocation(p, n); - id = GL.getNewId(GL.uniforms); - - GL.uniforms[id] = loc; - } - } - } - }}; - Module["GL"] = GL;function _emscripten_webgl_do_create_context(target, attributes) { - assert(attributes); - var contextAttributes = {}; - var a = attributes >> 2; - contextAttributes['alpha'] = !!HEAP32[a + (0>>2)]; - contextAttributes['depth'] = !!HEAP32[a + (4>>2)]; - contextAttributes['stencil'] = !!HEAP32[a + (8>>2)]; - contextAttributes['antialias'] = !!HEAP32[a + (12>>2)]; - contextAttributes['premultipliedAlpha'] = !!HEAP32[a + (16>>2)]; - contextAttributes['preserveDrawingBuffer'] = !!HEAP32[a + (20>>2)]; - var powerPreference = HEAP32[a + (24>>2)]; - contextAttributes['powerPreference'] = __emscripten_webgl_power_preferences[powerPreference]; - contextAttributes['failIfMajorPerformanceCaveat'] = !!HEAP32[a + (28>>2)]; - contextAttributes.majorVersion = HEAP32[a + (32>>2)]; - contextAttributes.minorVersion = HEAP32[a + (36>>2)]; - contextAttributes.enableExtensionsByDefault = HEAP32[a + (40>>2)]; - contextAttributes.explicitSwapControl = HEAP32[a + (44>>2)]; - contextAttributes.proxyContextToMainThread = HEAP32[a + (48>>2)]; - contextAttributes.renderViaOffscreenBackBuffer = HEAP32[a + (52>>2)]; - - var canvas = __findCanvasEventTarget(target); - - - - if (!canvas) { - return 0; - } - - if (contextAttributes.explicitSwapControl) { - return 0; - } - - - var contextHandle = GL.createContext(canvas, contextAttributes); - return contextHandle; + }); + var properties = { + isDevice: false, + contents: lazyArray + }; + } else { + var properties = { + isDevice: false, + url: url + }; + } + var node = FS.createFile(parent, name, properties, canRead, canWrite); + if (properties.contents) { + node.contents = properties.contents; + } else if (properties.url) { + node.contents = null; + node.url = properties.url; + } + Object.defineProperties(node, { + usedBytes: { + get: (function() { + return this.contents.length; + }) + } + }); + var stream_ops = {}; + var keys = Object.keys(node.stream_ops); + keys.forEach((function(key) { + var fn = node.stream_ops[key]; + stream_ops[key] = function forceLoadLazyFile() { + if (!FS.forceLoadFile(node)) { + throw new FS.ErrnoError(29); } - Module["_emscripten_webgl_do_create_context"] = _emscripten_webgl_do_create_context;function _emscripten_webgl_create_context(a0,a1 - ) { - return _emscripten_webgl_do_create_context(a0,a1); - } - Module["_emscripten_webgl_create_context"] = _emscripten_webgl_create_context; - - - - var ENV={}; - Module["ENV"] = ENV;function _emscripten_get_environ() { - if (!_emscripten_get_environ.strings) { - // Default values. - var env = { - 'USER': 'web_user', - 'LOGNAME': 'web_user', - 'PATH': '/', - 'PWD': '/', - 'HOME': '/home/web_user', - // Browser language detection #8751 - 'LANG': ((typeof navigator === 'object' && navigator.languages && navigator.languages[0]) || 'C').replace('-', '_') + '.UTF-8', - '_': thisProgram - }; - // Apply the user-provided values, if any. - for (var x in ENV) { - env[x] = ENV[x]; - } - var strings = []; - for (var x in env) { - strings.push(x + '=' + env[x]); - } - _emscripten_get_environ.strings = strings; - } - return _emscripten_get_environ.strings; + return fn.apply(null, arguments); + }; + })); + stream_ops.read = function stream_ops_read(stream, buffer, offset, length, position) { + if (!FS.forceLoadFile(node)) { + throw new FS.ErrnoError(29); + } + var contents = stream.node.contents; + if (position >= contents.length) return 0; + var size = Math.min(contents.length - position, length); + assert(size >= 0); + if (contents.slice) { + for (var i = 0; i < size; i++) { + buffer[offset + i] = contents[position + i]; } - Module["_emscripten_get_environ"] = _emscripten_get_environ;function _environ_get(__environ, environ_buf) { - var strings = _emscripten_get_environ(); - var bufSize = 0; - strings.forEach(function(string, i) { - var ptr = environ_buf + bufSize; - HEAP32[(((__environ)+(i * 4))>>2)]=ptr; - writeAsciiToMemory(string, ptr); - bufSize += string.length + 1; - }); - return 0; + } else { + for (var i = 0; i < size; i++) { + buffer[offset + i] = contents.get(position + i); } - Module["_environ_get"] = _environ_get; - - function _environ_sizes_get(penviron_count, penviron_buf_size) { - var strings = _emscripten_get_environ(); - HEAP32[((penviron_count)>>2)]=strings.length; - var bufSize = 0; - strings.forEach(function(string) { - bufSize += string.length + 1; - }); - HEAP32[((penviron_buf_size)>>2)]=bufSize; - return 0; + } + return size; + }; + node.stream_ops = stream_ops; + return node; + }), + createPreloadedFile: (function(parent, name, url, canRead, canWrite, onload, onerror, dontCreateFile, canOwn, preFinish) { + Browser.init(); + var fullname = name ? PATH_FS.resolve(PATH.join2(parent, name)) : parent; + var dep = getUniqueRunDependency("cp " + fullname); + function processData(byteArray) { + function finish(byteArray) { + if (preFinish) preFinish(); + if (!dontCreateFile) { + FS.createDataFile(parent, name, byteArray, canRead, canWrite, canOwn); } - Module["_environ_sizes_get"] = _environ_sizes_get; - - function _exit(status) { - // void _exit(int status); - // http://pubs.opengroup.org/onlinepubs/000095399/functions/exit.html - exit(status); + if (onload) onload(); + removeRunDependency(dep); + } + var handled = false; + Module["preloadPlugins"].forEach((function(plugin) { + if (handled) return; + if (plugin["canHandle"](fullname)) { + plugin["handle"](byteArray, fullname, finish, (function() { + if (onerror) onerror(); + removeRunDependency(dep); + })); + handled = true; } - Module["_exit"] = _exit; - - function _fd_close(fd) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(19, 1, fd); - try { - - var stream = SYSCALLS.getStreamFromFD(fd); - FS.close(stream); - return 0; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return e.errno; - } - } - - Module["_fd_close"] = _fd_close; - - function _fd_read(fd, iov, iovcnt, pnum) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(20, 1, fd, iov, iovcnt, pnum); + })); + if (!handled) finish(byteArray); + } + addRunDependency(dep); + if (typeof url == "string") { + Browser.asyncLoad(url, (function(byteArray) { + processData(byteArray); + }), onerror); + } else { + processData(url); + } + }), + indexedDB: (function() { + return window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB; + }), + DB_NAME: (function() { + return "EM_FS_" + window.location.pathname; + }), + DB_VERSION: 20, + DB_STORE_NAME: "FILE_DATA", + saveFilesToDB: (function(paths, onload, onerror) { + onload = onload || (function() {}); + onerror = onerror || (function() {}); + var indexedDB = FS.indexedDB(); try { - - var stream = SYSCALLS.getStreamFromFD(fd); - var num = SYSCALLS.doReadv(stream, iov, iovcnt); - HEAP32[((pnum)>>2)]=num - return 0; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return e.errno; - } + var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION); + } catch (e) { + return onerror(e); } - - Module["_fd_read"] = _fd_read; - - function _fd_seek(fd, offset_low, offset_high, whence, newOffset) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(21, 1, fd, offset_low, offset_high, whence, newOffset); + openRequest.onupgradeneeded = function openRequest_onupgradeneeded() { + console.log("creating db"); + var db = openRequest.result; + db.createObjectStore(FS.DB_STORE_NAME); + }; + openRequest.onsuccess = function openRequest_onsuccess() { + var db = openRequest.result; + var transaction = db.transaction([ FS.DB_STORE_NAME ], "readwrite"); + var files = transaction.objectStore(FS.DB_STORE_NAME); + var ok = 0, fail = 0, total = paths.length; + function finish() { + if (fail == 0) onload(); else onerror(); + } + paths.forEach((function(path) { + var putRequest = files.put(FS.analyzePath(path).object.contents, path); + putRequest.onsuccess = function putRequest_onsuccess() { + ok++; + if (ok + fail == total) finish(); + }; + putRequest.onerror = function putRequest_onerror() { + fail++; + if (ok + fail == total) finish(); + }; + })); + transaction.onerror = onerror; + }; + openRequest.onerror = onerror; + }), + loadFilesFromDB: (function(paths, onload, onerror) { + onload = onload || (function() {}); + onerror = onerror || (function() {}); + var indexedDB = FS.indexedDB(); try { - - var stream = SYSCALLS.getStreamFromFD(fd); - var HIGH_OFFSET = 0x100000000; // 2^32 - // use an unsigned operator on low and shift high by 32-bits - var offset = offset_high * HIGH_OFFSET + (offset_low >>> 0); - - var DOUBLE_LIMIT = 0x20000000000000; // 2^53 - // we also check for equality since DOUBLE_LIMIT + 1 == DOUBLE_LIMIT - if (offset <= -DOUBLE_LIMIT || offset >= DOUBLE_LIMIT) { - return -61; - } - - FS.llseek(stream, offset, whence); - (tempI64 = [stream.position>>>0,(tempDouble=stream.position,(+(Math_abs(tempDouble))) >= 1.0 ? (tempDouble > 0.0 ? ((Math_min((+(Math_floor((tempDouble)/4294967296.0))), 4294967295.0))|0)>>>0 : (~~((+(Math_ceil((tempDouble - +(((~~(tempDouble)))>>>0))/4294967296.0)))))>>>0) : 0)],HEAP32[((newOffset)>>2)]=tempI64[0],HEAP32[(((newOffset)+(4))>>2)]=tempI64[1]); - if (stream.getdents && offset === 0 && whence === 0) stream.getdents = null; // reset readdir state - return 0; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return e.errno; - } - } - - Module["_fd_seek"] = _fd_seek; - - function _fd_write(fd, iov, iovcnt, pnum) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(22, 1, fd, iov, iovcnt, pnum); + var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION); + } catch (e) { + return onerror(e); + } + openRequest.onupgradeneeded = onerror; + openRequest.onsuccess = function openRequest_onsuccess() { + var db = openRequest.result; + try { + var transaction = db.transaction([ FS.DB_STORE_NAME ], "readonly"); + } catch (e) { + onerror(e); + return; + } + var files = transaction.objectStore(FS.DB_STORE_NAME); + var ok = 0, fail = 0, total = paths.length; + function finish() { + if (fail == 0) onload(); else onerror(); + } + paths.forEach((function(path) { + var getRequest = files.get(path); + getRequest.onsuccess = function getRequest_onsuccess() { + if (FS.analyzePath(path).exists) { + FS.unlink(path); + } + FS.createDataFile(PATH.dirname(path), PATH.basename(path), getRequest.result, true, true, true); + ok++; + if (ok + fail == total) finish(); + }; + getRequest.onerror = function getRequest_onerror() { + fail++; + if (ok + fail == total) finish(); + }; + })); + transaction.onerror = onerror; + }; + openRequest.onerror = onerror; + }) +}; +Module["FS"] = FS; +var SYSCALLS = { + DEFAULT_POLLMASK: 5, + mappings: {}, + umask: 511, + calculateAt: (function(dirfd, path) { + if (path[0] !== "/") { + var dir; + if (dirfd === -100) { + dir = FS.cwd(); + } else { + var dirstream = FS.getStream(dirfd); + if (!dirstream) throw new FS.ErrnoError(8); + dir = dirstream.path; + } + path = PATH.join2(dir, path); + } + return path; + }), + doStat: (function(func, path, buf) { try { - - var stream = SYSCALLS.getStreamFromFD(fd); - var num = SYSCALLS.doWritev(stream, iov, iovcnt); - HEAP32[((pnum)>>2)]=num - return 0; - } catch (e) { - if (typeof FS === 'undefined' || !(e instanceof FS.ErrnoError)) abort(e); - return e.errno; + var stat = func(path); + } catch (e) { + if (e && e.node && PATH.normalize(path) !== PATH.normalize(FS.getPath(e.node))) { + return -54; + } + throw e; + } + GROWABLE_HEAP_STORE_I32(buf | 0, stat.dev); + GROWABLE_HEAP_STORE_I32(buf + 4 | 0, 0); + GROWABLE_HEAP_STORE_I32(buf + 8 | 0, stat.ino); + GROWABLE_HEAP_STORE_I32(buf + 12 | 0, stat.mode); + GROWABLE_HEAP_STORE_I32(buf + 16 | 0, stat.nlink); + GROWABLE_HEAP_STORE_I32(buf + 20 | 0, stat.uid); + GROWABLE_HEAP_STORE_I32(buf + 24 | 0, stat.gid); + GROWABLE_HEAP_STORE_I32(buf + 28 | 0, stat.rdev); + GROWABLE_HEAP_STORE_I32(buf + 32 | 0, 0); + tempI64 = [ stat.size >>> 0, (tempDouble = stat.size, +Math_abs(tempDouble) >= 1 ? tempDouble > 0 ? (Math_min(+Math_floor(tempDouble / 4294967296), 4294967295) | 0) >>> 0 : ~~+Math_ceil((tempDouble - +(~~tempDouble >>> 0)) / 4294967296) >>> 0 : 0) ], GROWABLE_HEAP_STORE_I32(buf + 40 | 0, tempI64[0]), GROWABLE_HEAP_STORE_I32(buf + 44 | 0, tempI64[1]); + GROWABLE_HEAP_STORE_I32(buf + 48 | 0, 4096); + GROWABLE_HEAP_STORE_I32(buf + 52 | 0, stat.blocks); + GROWABLE_HEAP_STORE_I32(buf + 56 | 0, stat.atime.getTime() / 1e3 | 0); + GROWABLE_HEAP_STORE_I32(buf + 60 | 0, 0); + GROWABLE_HEAP_STORE_I32(buf + 64 | 0, stat.mtime.getTime() / 1e3 | 0); + GROWABLE_HEAP_STORE_I32(buf + 68 | 0, 0); + GROWABLE_HEAP_STORE_I32(buf + 72 | 0, stat.ctime.getTime() / 1e3 | 0); + GROWABLE_HEAP_STORE_I32(buf + 76 | 0, 0); + tempI64 = [ stat.ino >>> 0, (tempDouble = stat.ino, +Math_abs(tempDouble) >= 1 ? tempDouble > 0 ? (Math_min(+Math_floor(tempDouble / 4294967296), 4294967295) | 0) >>> 0 : ~~+Math_ceil((tempDouble - +(~~tempDouble >>> 0)) / 4294967296) >>> 0 : 0) ], GROWABLE_HEAP_STORE_I32(buf + 80 | 0, tempI64[0]), GROWABLE_HEAP_STORE_I32(buf + 84 | 0, tempI64[1]); + return 0; + }), + doMsync: (function(addr, stream, len, flags) { + var buffer = new Uint8Array(HEAPU8.subarray(addr, addr + len)); + FS.msync(stream, buffer, 0, len, flags); + }), + doMkdir: (function(path, mode) { + path = PATH.normalize(path); + if (path[path.length - 1] === "/") path = path.substr(0, path.length - 1); + FS.mkdir(path, mode, 0); + return 0; + }), + doMknod: (function(path, mode, dev) { + switch (mode & 61440) { + case 32768: + case 8192: + case 24576: + case 4096: + case 49152: + break; + default: + return -28; + } + FS.mknod(path, mode, dev); + return 0; + }), + doReadlink: (function(path, buf, bufsize) { + if (bufsize <= 0) return -28; + var ret = FS.readlink(path); + var len = Math.min(bufsize, lengthBytesUTF8(ret)); + var endChar = GROWABLE_HEAP_LOAD_I8(buf + len | 0); + stringToUTF8(ret, buf, bufsize + 1); + GROWABLE_HEAP_STORE_I8(buf + len | 0, endChar); + return len; + }), + doAccess: (function(path, amode) { + if (amode & ~7) { + return -28; + } + var node; + var lookup = FS.lookupPath(path, { + follow: true + }); + node = lookup.node; + if (!node) { + return -44; + } + var perms = ""; + if (amode & 4) perms += "r"; + if (amode & 2) perms += "w"; + if (amode & 1) perms += "x"; + if (perms && FS.nodePermissions(node, perms)) { + return -2; + } + return 0; + }), + doDup: (function(path, flags, suggestFD) { + var suggest = FS.getStream(suggestFD); + if (suggest) FS.close(suggest); + return FS.open(path, flags, 0, suggestFD, suggestFD).fd; + }), + doReadv: (function(stream, iov, iovcnt, offset) { + var ret = 0; + for (var i = 0; i < iovcnt; i++) { + var ptr = GROWABLE_HEAP_LOAD_I32(iov + i * 8 | 0); + var len = GROWABLE_HEAP_LOAD_I32(iov + (i * 8 + 4) | 0); + var curr = FS.read(stream, HEAP8, ptr, len, offset); + if (curr < 0) return -1; + ret += curr; + if (curr < len) break; } + return ret; + }), + doWritev: (function(stream, iov, iovcnt, offset) { + var ret = 0; + for (var i = 0; i < iovcnt; i++) { + var ptr = GROWABLE_HEAP_LOAD_I32(iov + i * 8 | 0); + var len = GROWABLE_HEAP_LOAD_I32(iov + (i * 8 + 4) | 0); + var curr = FS.write(stream, HEAP8, ptr, len, offset); + if (curr < 0) return -1; + ret += curr; } - - Module["_fd_write"] = _fd_write; - - function _getTempRet0() { - return (getTempRet0() | 0); - } - Module["_getTempRet0"] = _getTempRet0; - - function _gettimeofday(ptr) { - var now = Date.now(); - HEAP32[((ptr)>>2)]=(now/1000)|0; // seconds - HEAP32[(((ptr)+(4))>>2)]=((now % 1000)*1000)|0; // microseconds - return 0; - } - Module["_gettimeofday"] = _gettimeofday; - - - var ___tm_current=12594976; - Module["___tm_current"] = ___tm_current; - - - var ___tm_timezone=(stringToUTF8("GMT", 12595024, 4), 12595024); - Module["___tm_timezone"] = ___tm_timezone;function _gmtime_r(time, tmPtr) { - var date = new Date(HEAP32[((time)>>2)]*1000); - HEAP32[((tmPtr)>>2)]=date.getUTCSeconds(); - HEAP32[(((tmPtr)+(4))>>2)]=date.getUTCMinutes(); - HEAP32[(((tmPtr)+(8))>>2)]=date.getUTCHours(); - HEAP32[(((tmPtr)+(12))>>2)]=date.getUTCDate(); - HEAP32[(((tmPtr)+(16))>>2)]=date.getUTCMonth(); - HEAP32[(((tmPtr)+(20))>>2)]=date.getUTCFullYear()-1900; - HEAP32[(((tmPtr)+(24))>>2)]=date.getUTCDay(); - HEAP32[(((tmPtr)+(36))>>2)]=0; - HEAP32[(((tmPtr)+(32))>>2)]=0; - var start = Date.UTC(date.getUTCFullYear(), 0, 1, 0, 0, 0, 0); - var yday = ((date.getTime() - start) / (1000 * 60 * 60 * 24))|0; - HEAP32[(((tmPtr)+(28))>>2)]=yday; - HEAP32[(((tmPtr)+(40))>>2)]=___tm_timezone; - - return tmPtr; - } - Module["_gmtime_r"] = _gmtime_r;function _gmtime(time) { - return _gmtime_r(time, ___tm_current); - } - Module["_gmtime"] = _gmtime; - - function _memcpy(dest, src, num) { - dest = dest|0; src = src|0; num = num|0; - var ret = 0; - var aligned_dest_end = 0; - var block_aligned_dest_end = 0; - var dest_end = 0; - // Test against a benchmarked cutoff limit for when HEAPU8.set() becomes faster to use. - if ((num|0) >= 8192) { - _emscripten_memcpy_big(dest|0, src|0, num|0)|0; - return dest|0; - } - - ret = dest|0; - dest_end = (dest + num)|0; - if ((dest&3) == (src&3)) { - // The initial unaligned < 4-byte front. - while (dest & 3) { - if ((num|0) == 0) return ret|0; - HEAP8[((dest)>>0)]=((HEAP8[((src)>>0)])|0); - dest = (dest+1)|0; - src = (src+1)|0; - num = (num-1)|0; - } - aligned_dest_end = (dest_end & -4)|0; - block_aligned_dest_end = (aligned_dest_end - 64)|0; - while ((dest|0) <= (block_aligned_dest_end|0) ) { - HEAP32[((dest)>>2)]=((HEAP32[((src)>>2)])|0); - HEAP32[(((dest)+(4))>>2)]=((HEAP32[(((src)+(4))>>2)])|0); - HEAP32[(((dest)+(8))>>2)]=((HEAP32[(((src)+(8))>>2)])|0); - HEAP32[(((dest)+(12))>>2)]=((HEAP32[(((src)+(12))>>2)])|0); - HEAP32[(((dest)+(16))>>2)]=((HEAP32[(((src)+(16))>>2)])|0); - HEAP32[(((dest)+(20))>>2)]=((HEAP32[(((src)+(20))>>2)])|0); - HEAP32[(((dest)+(24))>>2)]=((HEAP32[(((src)+(24))>>2)])|0); - HEAP32[(((dest)+(28))>>2)]=((HEAP32[(((src)+(28))>>2)])|0); - HEAP32[(((dest)+(32))>>2)]=((HEAP32[(((src)+(32))>>2)])|0); - HEAP32[(((dest)+(36))>>2)]=((HEAP32[(((src)+(36))>>2)])|0); - HEAP32[(((dest)+(40))>>2)]=((HEAP32[(((src)+(40))>>2)])|0); - HEAP32[(((dest)+(44))>>2)]=((HEAP32[(((src)+(44))>>2)])|0); - HEAP32[(((dest)+(48))>>2)]=((HEAP32[(((src)+(48))>>2)])|0); - HEAP32[(((dest)+(52))>>2)]=((HEAP32[(((src)+(52))>>2)])|0); - HEAP32[(((dest)+(56))>>2)]=((HEAP32[(((src)+(56))>>2)])|0); - HEAP32[(((dest)+(60))>>2)]=((HEAP32[(((src)+(60))>>2)])|0); - dest = (dest+64)|0; - src = (src+64)|0; - } - while ((dest|0) < (aligned_dest_end|0) ) { - HEAP32[((dest)>>2)]=((HEAP32[((src)>>2)])|0); - dest = (dest+4)|0; - src = (src+4)|0; - } - } else { - // In the unaligned copy case, unroll a bit as well. - aligned_dest_end = (dest_end - 4)|0; - while ((dest|0) < (aligned_dest_end|0) ) { - HEAP8[((dest)>>0)]=((HEAP8[((src)>>0)])|0); - HEAP8[(((dest)+(1))>>0)]=((HEAP8[(((src)+(1))>>0)])|0); - HEAP8[(((dest)+(2))>>0)]=((HEAP8[(((src)+(2))>>0)])|0); - HEAP8[(((dest)+(3))>>0)]=((HEAP8[(((src)+(3))>>0)])|0); - dest = (dest+4)|0; - src = (src+4)|0; - } - } - // The remaining unaligned < 4 byte tail. - while ((dest|0) < (dest_end|0)) { - HEAP8[((dest)>>0)]=((HEAP8[((src)>>0)])|0); - dest = (dest+1)|0; - src = (src+1)|0; - } - return ret|0; - } - Module["_memcpy"] = _memcpy; - - - - function _tzset() { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(23, 1); - - // TODO: Use (malleable) environment variables instead of system settings. - if (_tzset.called) return; - _tzset.called = true; - - // timezone is specified as seconds west of UTC ("The external variable - // `timezone` shall be set to the difference, in seconds, between - // Coordinated Universal Time (UTC) and local standard time."), the same - // as returned by getTimezoneOffset(). - // See http://pubs.opengroup.org/onlinepubs/009695399/functions/tzset.html - HEAP32[((__get_timezone())>>2)]=(new Date()).getTimezoneOffset() * 60; - - var currentYear = new Date().getFullYear(); - var winter = new Date(currentYear, 0, 1); - var summer = new Date(currentYear, 6, 1); - HEAP32[((__get_daylight())>>2)]=Number(winter.getTimezoneOffset() != summer.getTimezoneOffset()); - - function extractZone(date) { - var match = date.toTimeString().match(/\(([A-Za-z ]+)\)$/); - return match ? match[1] : "GMT"; - }; - var winterName = extractZone(winter); - var summerName = extractZone(summer); - var winterNamePtr = allocate(intArrayFromString(winterName), 'i8', ALLOC_NORMAL); - var summerNamePtr = allocate(intArrayFromString(summerName), 'i8', ALLOC_NORMAL); - if (summer.getTimezoneOffset() < winter.getTimezoneOffset()) { - // Northern hemisphere - HEAP32[((__get_tzname())>>2)]=winterNamePtr; - HEAP32[(((__get_tzname())+(4))>>2)]=summerNamePtr; - } else { - HEAP32[((__get_tzname())>>2)]=summerNamePtr; - HEAP32[(((__get_tzname())+(4))>>2)]=winterNamePtr; - } - } - - Module["_tzset"] = _tzset;function _mktime(tmPtr) { - _tzset(); - var date = new Date(HEAP32[(((tmPtr)+(20))>>2)] + 1900, - HEAP32[(((tmPtr)+(16))>>2)], - HEAP32[(((tmPtr)+(12))>>2)], - HEAP32[(((tmPtr)+(8))>>2)], - HEAP32[(((tmPtr)+(4))>>2)], - HEAP32[((tmPtr)>>2)], - 0); - - // There's an ambiguous hour when the time goes back; the tm_isdst field is - // used to disambiguate it. Date() basically guesses, so we fix it up if it - // guessed wrong, or fill in tm_isdst with the guess if it's -1. - var dst = HEAP32[(((tmPtr)+(32))>>2)]; - var guessedOffset = date.getTimezoneOffset(); - var start = new Date(date.getFullYear(), 0, 1); - var summerOffset = new Date(date.getFullYear(), 6, 1).getTimezoneOffset(); - var winterOffset = start.getTimezoneOffset(); - var dstOffset = Math.min(winterOffset, summerOffset); // DST is in December in South - if (dst < 0) { - // Attention: some regions don't have DST at all. - HEAP32[(((tmPtr)+(32))>>2)]=Number(summerOffset != winterOffset && dstOffset == guessedOffset); - } else if ((dst > 0) != (dstOffset == guessedOffset)) { - var nonDstOffset = Math.max(winterOffset, summerOffset); - var trueOffset = dst > 0 ? dstOffset : nonDstOffset; - // Don't try setMinutes(date.getMinutes() + ...) -- it's messed up. - date.setTime(date.getTime() + (trueOffset - guessedOffset)*60000); - } - - HEAP32[(((tmPtr)+(24))>>2)]=date.getDay(); - var yday = ((date.getTime() - start.getTime()) / (1000 * 60 * 60 * 24))|0; - HEAP32[(((tmPtr)+(28))>>2)]=yday; - - return (date.getTime() / 1000)|0; - } - Module["_mktime"] = _mktime; - - function _pthread_cleanup_pop(execute) { - var routine = PThread.exitHandlers.pop(); - if (execute) routine(); - } - Module["_pthread_cleanup_pop"] = _pthread_cleanup_pop; - - function _pthread_cleanup_push(routine, arg) { - if (PThread.exitHandlers === null) { - PThread.exitHandlers = []; - if (!ENVIRONMENT_IS_PTHREAD) { - __ATEXIT__.push(function() { PThread.runExitHandlers(); }); - } - } - PThread.exitHandlers.push(function() { dynCall_vi(routine, arg) }); - } - Module["_pthread_cleanup_push"] = _pthread_cleanup_push; - - - function __spawn_thread(threadParams) { - if (ENVIRONMENT_IS_PTHREAD) throw 'Internal Error! _spawn_thread() can only ever be called from main application thread!'; - - var worker = PThread.getNewWorker(); - - if (worker.pthread !== undefined) throw 'Internal error!'; - if (!threadParams.pthread_ptr) throw 'Internal error, no pthread ptr!'; - PThread.runningWorkers.push(worker); - - // Allocate memory for thread-local storage and initialize it to zero. - var tlsMemory = _malloc(128 * 4); - for (var i = 0; i < 128; ++i) { - HEAP32[(((tlsMemory)+(i*4))>>2)]=0; - } - - var stackHigh = threadParams.stackBase + threadParams.stackSize; - - var pthread = PThread.pthreads[threadParams.pthread_ptr] = { // Create a pthread info object to represent this thread. - worker: worker, - stackBase: threadParams.stackBase, - stackSize: threadParams.stackSize, - allocatedOwnStack: threadParams.allocatedOwnStack, - thread: threadParams.pthread_ptr, - threadInfoStruct: threadParams.pthread_ptr // Info area for this thread in Emscripten HEAP (shared) - }; - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 0 ) >> 2, 0); // threadStatus <- 0, meaning not yet exited. - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 4 ) >> 2, 0); // threadExitCode <- 0. - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 20 ) >> 2, 0); // profilerBlock <- 0. - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 80 ) >> 2, threadParams.detached); - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 116 ) >> 2, tlsMemory); // Init thread-local-storage memory array. - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 60 ) >> 2, 0); // Mark initial status to unused. - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 52 ) >> 2, pthread.threadInfoStruct); // Main thread ID. - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 56 ) >> 2, PROCINFO.pid); // Process ID. - - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 120) >> 2, threadParams.stackSize); - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 96) >> 2, threadParams.stackSize); - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 92) >> 2, stackHigh); - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 120 + 8) >> 2, stackHigh); - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 120 + 12) >> 2, threadParams.detached); - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 120 + 20) >> 2, threadParams.schedPolicy); - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 120 + 24) >> 2, threadParams.schedPrio); - - var global_libc = _emscripten_get_global_libc(); - var global_locale = global_libc + 40; - Atomics.store(HEAPU32, (pthread.threadInfoStruct + 188) >> 2, global_locale); - - - worker.pthread = pthread; - var msg = { - 'cmd': 'run', - 'start_routine': threadParams.startRoutine, - 'arg': threadParams.arg, - 'threadInfoStruct': threadParams.pthread_ptr, - 'selfThreadId': threadParams.pthread_ptr, // TODO: Remove this since thread ID is now the same as the thread address. - 'parentThreadId': threadParams.parent_pthread_ptr, - 'stackBase': threadParams.stackBase, - 'stackSize': threadParams.stackSize, - }; - worker.runPthread = function() { - // Ask the worker to start executing its pthread entry point function. - msg.time = performance.now(); - worker.postMessage(msg, threadParams.transferList); - }; - if (worker.loaded) { - worker.runPthread(); - delete worker.runPthread; - } - } - Module["__spawn_thread"] = __spawn_thread; - - function _pthread_getschedparam(thread, policy, schedparam) { - if (!policy && !schedparam) return ERRNO_CODES.EINVAL; - - if (!thread) { - err('pthread_getschedparam called with a null thread pointer!'); - return ERRNO_CODES.ESRCH; - } - var self = HEAP32[(((thread)+(24))>>2)]; - if (self !== thread) { - err('pthread_getschedparam attempted on thread ' + thread + ', which does not point to a valid thread, or does not exist anymore!'); - return ERRNO_CODES.ESRCH; - } - - var schedPolicy = Atomics.load(HEAPU32, (thread + 120 + 20 ) >> 2); - var schedPrio = Atomics.load(HEAPU32, (thread + 120 + 24 ) >> 2); - - if (policy) HEAP32[((policy)>>2)]=schedPolicy; - if (schedparam) HEAP32[((schedparam)>>2)]=schedPrio; - return 0; - } - Module["_pthread_getschedparam"] = _pthread_getschedparam; - - function _pthread_self() { - return __pthread_ptr|0; - } - Module["_pthread_self"] = _pthread_self;function _pthread_create(pthread_ptr, attr, start_routine, arg) { - if (typeof SharedArrayBuffer === 'undefined') { - err('Current environment does not support SharedArrayBuffer, pthreads are not available!'); - return 6; - } - if (!pthread_ptr) { - err('pthread_create called with a null thread pointer!'); - return 28; - } - - var transferList = []; // List of JS objects that will transfer ownership to the Worker hosting the thread - var error = 0; - - - // Synchronously proxy the thread creation to main thread if possible. If we need to transfer ownership of objects, then - // proxy asynchronously via postMessage. - if (ENVIRONMENT_IS_PTHREAD && (transferList.length === 0 || error)) { - return _emscripten_sync_run_in_main_thread_4(687865856, pthread_ptr, attr, start_routine, arg); - } - - // If on the main thread, and accessing Canvas/OffscreenCanvas failed, abort with the detected error. - if (error) return error; - - var stackSize = 0; - var stackBase = 0; - var detached = 0; // Default thread attr is PTHREAD_CREATE_JOINABLE, i.e. start as not detached. - var schedPolicy = 0; /*SCHED_OTHER*/ - var schedPrio = 0; - if (attr) { - stackSize = HEAP32[((attr)>>2)]; - // Musl has a convention that the stack size that is stored to the pthread attribute structure is always musl's #define DEFAULT_STACK_SIZE - // smaller than the actual created stack size. That is, stored stack size of 0 would mean a stack of DEFAULT_STACK_SIZE in size. All musl - // functions hide this impl detail, and offset the size transparently, so pthread_*() API user does not see this offset when operating with - // the pthread API. When reading the structure directly on JS side however, we need to offset the size manually here. - stackSize += 81920 /*DEFAULT_STACK_SIZE*/; - stackBase = HEAP32[(((attr)+(8))>>2)]; - detached = HEAP32[(((attr)+(12))>>2)] !== 0/*PTHREAD_CREATE_JOINABLE*/; - var inheritSched = HEAP32[(((attr)+(16))>>2)] === 0/*PTHREAD_INHERIT_SCHED*/; - if (inheritSched) { - var prevSchedPolicy = HEAP32[(((attr)+(20))>>2)]; - var prevSchedPrio = HEAP32[(((attr)+(24))>>2)]; - // If we are inheriting the scheduling properties from the parent thread, we need to identify the parent thread properly - this function call may - // be getting proxied, in which case _pthread_self() will point to the thread performing the proxying, not the thread that initiated the call. - var parentThreadPtr = PThread.currentProxiedOperationCallerThread ? PThread.currentProxiedOperationCallerThread : _pthread_self(); - _pthread_getschedparam(parentThreadPtr, attr + 20, attr + 24); - schedPolicy = HEAP32[(((attr)+(20))>>2)]; - schedPrio = HEAP32[(((attr)+(24))>>2)]; - HEAP32[(((attr)+(20))>>2)]=prevSchedPolicy; - HEAP32[(((attr)+(24))>>2)]=prevSchedPrio; - } else { - schedPolicy = HEAP32[(((attr)+(20))>>2)]; - schedPrio = HEAP32[(((attr)+(24))>>2)]; - } - } else { - // According to http://man7.org/linux/man-pages/man3/pthread_create.3.html, default stack size if not specified is 2 MB, so follow that convention. - stackSize = 2097152; - } - var allocatedOwnStack = stackBase == 0; // If allocatedOwnStack == true, then the pthread impl maintains the stack allocation. - if (allocatedOwnStack) { - stackBase = _memalign(16, stackSize); // Allocate a stack if the user doesn't want to place the stack in a custom memory area. - } else { - // Musl stores the stack base address assuming stack grows downwards, so adjust it to Emscripten convention that the - // stack grows upwards instead. - stackBase -= stackSize; - assert(stackBase > 0); - } - - // Allocate thread block (pthread_t structure). - var threadInfoStruct = _malloc(244); - for (var i = 0; i < 244 >> 2; ++i) HEAPU32[(threadInfoStruct>>2) + i] = 0; // zero-initialize thread structure. - HEAP32[((pthread_ptr)>>2)]=threadInfoStruct; - - // The pthread struct has a field that points to itself - this is used as a magic ID to detect whether the pthread_t - // structure is 'alive'. - HEAP32[(((threadInfoStruct)+(24))>>2)]=threadInfoStruct; - - // pthread struct robust_list head should point to itself. - var headPtr = threadInfoStruct + 168; - HEAP32[((headPtr)>>2)]=headPtr; - - - var threadParams = { - stackBase: stackBase, - stackSize: stackSize, - allocatedOwnStack: allocatedOwnStack, - schedPolicy: schedPolicy, - schedPrio: schedPrio, - detached: detached, - startRoutine: start_routine, - pthread_ptr: threadInfoStruct, - parent_pthread_ptr: _pthread_self(), - arg: arg, - transferList: transferList - }; - - if (ENVIRONMENT_IS_PTHREAD) { - // The prepopulated pool of web workers that can host pthreads is stored in the main JS thread. Therefore if a - // pthread is attempting to spawn a new thread, the thread creation must be deferred to the main JS thread. - threadParams.cmd = 'spawnThread'; - postMessage(threadParams, transferList); - } else { - // We are the main thread, so we have the pthread warmup pool in this thread and can fire off JS thread creation - // directly ourselves. - __spawn_thread(threadParams); - } - - return 0; - } - Module["_pthread_create"] = _pthread_create; - - - - function _setTempRet0($i) { - setTempRet0(($i) | 0); - } - Module["_setTempRet0"] = _setTempRet0; - - - - function __isLeapYear(year) { - return year%4 === 0 && (year%100 !== 0 || year%400 === 0); - } - Module["__isLeapYear"] = __isLeapYear; - - function __arraySum(array, index) { - var sum = 0; - for (var i = 0; i <= index; sum += array[i++]); - return sum; - } - Module["__arraySum"] = __arraySum; - - - var __MONTH_DAYS_LEAP=[31,29,31,30,31,30,31,31,30,31,30,31]; - Module["__MONTH_DAYS_LEAP"] = __MONTH_DAYS_LEAP; - - var __MONTH_DAYS_REGULAR=[31,28,31,30,31,30,31,31,30,31,30,31]; - Module["__MONTH_DAYS_REGULAR"] = __MONTH_DAYS_REGULAR;function __addDays(date, days) { - var newDate = new Date(date.getTime()); - while(days > 0) { - var leap = __isLeapYear(newDate.getFullYear()); - var currentMonth = newDate.getMonth(); - var daysInCurrentMonth = (leap ? __MONTH_DAYS_LEAP : __MONTH_DAYS_REGULAR)[currentMonth]; - - if (days > daysInCurrentMonth-newDate.getDate()) { - // we spill over to next month - days -= (daysInCurrentMonth-newDate.getDate()+1); - newDate.setDate(1); - if (currentMonth < 11) { - newDate.setMonth(currentMonth+1) - } else { - newDate.setMonth(0); - newDate.setFullYear(newDate.getFullYear()+1); - } - } else { - // we stay in current month - newDate.setDate(newDate.getDate()+days); - return newDate; - } - } - - return newDate; - } - Module["__addDays"] = __addDays;function _strftime(s, maxsize, format, tm) { - // size_t strftime(char *restrict s, size_t maxsize, const char *restrict format, const struct tm *restrict timeptr); - // http://pubs.opengroup.org/onlinepubs/009695399/functions/strftime.html - - var tm_zone = HEAP32[(((tm)+(40))>>2)]; - - var date = { - tm_sec: HEAP32[((tm)>>2)], - tm_min: HEAP32[(((tm)+(4))>>2)], - tm_hour: HEAP32[(((tm)+(8))>>2)], - tm_mday: HEAP32[(((tm)+(12))>>2)], - tm_mon: HEAP32[(((tm)+(16))>>2)], - tm_year: HEAP32[(((tm)+(20))>>2)], - tm_wday: HEAP32[(((tm)+(24))>>2)], - tm_yday: HEAP32[(((tm)+(28))>>2)], - tm_isdst: HEAP32[(((tm)+(32))>>2)], - tm_gmtoff: HEAP32[(((tm)+(36))>>2)], - tm_zone: tm_zone ? UTF8ToString(tm_zone) : '' - }; - - var pattern = UTF8ToString(format); - - // expand format - var EXPANSION_RULES_1 = { - '%c': '%a %b %d %H:%M:%S %Y', // Replaced by the locale's appropriate date and time representation - e.g., Mon Aug 3 14:02:01 2013 - '%D': '%m/%d/%y', // Equivalent to %m / %d / %y - '%F': '%Y-%m-%d', // Equivalent to %Y - %m - %d - '%h': '%b', // Equivalent to %b - '%r': '%I:%M:%S %p', // Replaced by the time in a.m. and p.m. notation - '%R': '%H:%M', // Replaced by the time in 24-hour notation - '%T': '%H:%M:%S', // Replaced by the time - '%x': '%m/%d/%y', // Replaced by the locale's appropriate date representation - '%X': '%H:%M:%S', // Replaced by the locale's appropriate time representation - // Modified Conversion Specifiers - '%Ec': '%c', // Replaced by the locale's alternative appropriate date and time representation. - '%EC': '%C', // Replaced by the name of the base year (period) in the locale's alternative representation. - '%Ex': '%m/%d/%y', // Replaced by the locale's alternative date representation. - '%EX': '%H:%M:%S', // Replaced by the locale's alternative time representation. - '%Ey': '%y', // Replaced by the offset from %EC (year only) in the locale's alternative representation. - '%EY': '%Y', // Replaced by the full alternative year representation. - '%Od': '%d', // Replaced by the day of the month, using the locale's alternative numeric symbols, filled as needed with leading zeros if there is any alternative symbol for zero; otherwise, with leading characters. - '%Oe': '%e', // Replaced by the day of the month, using the locale's alternative numeric symbols, filled as needed with leading characters. - '%OH': '%H', // Replaced by the hour (24-hour clock) using the locale's alternative numeric symbols. - '%OI': '%I', // Replaced by the hour (12-hour clock) using the locale's alternative numeric symbols. - '%Om': '%m', // Replaced by the month using the locale's alternative numeric symbols. - '%OM': '%M', // Replaced by the minutes using the locale's alternative numeric symbols. - '%OS': '%S', // Replaced by the seconds using the locale's alternative numeric symbols. - '%Ou': '%u', // Replaced by the weekday as a number in the locale's alternative representation (Monday=1). - '%OU': '%U', // Replaced by the week number of the year (Sunday as the first day of the week, rules corresponding to %U ) using the locale's alternative numeric symbols. - '%OV': '%V', // Replaced by the week number of the year (Monday as the first day of the week, rules corresponding to %V ) using the locale's alternative numeric symbols. - '%Ow': '%w', // Replaced by the number of the weekday (Sunday=0) using the locale's alternative numeric symbols. - '%OW': '%W', // Replaced by the week number of the year (Monday as the first day of the week) using the locale's alternative numeric symbols. - '%Oy': '%y', // Replaced by the year (offset from %C ) using the locale's alternative numeric symbols. - }; - for (var rule in EXPANSION_RULES_1) { - pattern = pattern.replace(new RegExp(rule, 'g'), EXPANSION_RULES_1[rule]); - } - - var WEEKDAYS = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday']; - var MONTHS = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December']; - - function leadingSomething(value, digits, character) { - var str = typeof value === 'number' ? value.toString() : (value || ''); - while (str.length < digits) { - str = character[0]+str; - } - return str; - } - - function leadingNulls(value, digits) { - return leadingSomething(value, digits, '0'); - } - - function compareByDay(date1, date2) { - function sgn(value) { - return value < 0 ? -1 : (value > 0 ? 1 : 0); - } - - var compare; - if ((compare = sgn(date1.getFullYear()-date2.getFullYear())) === 0) { - if ((compare = sgn(date1.getMonth()-date2.getMonth())) === 0) { - compare = sgn(date1.getDate()-date2.getDate()); - } - } - return compare; - } - - function getFirstWeekStartDate(janFourth) { - switch (janFourth.getDay()) { - case 0: // Sunday - return new Date(janFourth.getFullYear()-1, 11, 29); - case 1: // Monday - return janFourth; - case 2: // Tuesday - return new Date(janFourth.getFullYear(), 0, 3); - case 3: // Wednesday - return new Date(janFourth.getFullYear(), 0, 2); - case 4: // Thursday - return new Date(janFourth.getFullYear(), 0, 1); - case 5: // Friday - return new Date(janFourth.getFullYear()-1, 11, 31); - case 6: // Saturday - return new Date(janFourth.getFullYear()-1, 11, 30); - } - } - - function getWeekBasedYear(date) { - var thisDate = __addDays(new Date(date.tm_year+1900, 0, 1), date.tm_yday); - - var janFourthThisYear = new Date(thisDate.getFullYear(), 0, 4); - var janFourthNextYear = new Date(thisDate.getFullYear()+1, 0, 4); - - var firstWeekStartThisYear = getFirstWeekStartDate(janFourthThisYear); - var firstWeekStartNextYear = getFirstWeekStartDate(janFourthNextYear); - - if (compareByDay(firstWeekStartThisYear, thisDate) <= 0) { - // this date is after the start of the first week of this year - if (compareByDay(firstWeekStartNextYear, thisDate) <= 0) { - return thisDate.getFullYear()+1; - } else { - return thisDate.getFullYear(); - } - } else { - return thisDate.getFullYear()-1; - } - } - - var EXPANSION_RULES_2 = { - '%a': function(date) { - return WEEKDAYS[date.tm_wday].substring(0,3); - }, - '%A': function(date) { - return WEEKDAYS[date.tm_wday]; - }, - '%b': function(date) { - return MONTHS[date.tm_mon].substring(0,3); - }, - '%B': function(date) { - return MONTHS[date.tm_mon]; - }, - '%C': function(date) { - var year = date.tm_year+1900; - return leadingNulls((year/100)|0,2); - }, - '%d': function(date) { - return leadingNulls(date.tm_mday, 2); - }, - '%e': function(date) { - return leadingSomething(date.tm_mday, 2, ' '); - }, - '%g': function(date) { - // %g, %G, and %V give values according to the ISO 8601:2000 standard week-based year. - // In this system, weeks begin on a Monday and week 1 of the year is the week that includes - // January 4th, which is also the week that includes the first Thursday of the year, and - // is also the first week that contains at least four days in the year. - // If the first Monday of January is the 2nd, 3rd, or 4th, the preceding days are part of - // the last week of the preceding year; thus, for Saturday 2nd January 1999, - // %G is replaced by 1998 and %V is replaced by 53. If December 29th, 30th, - // or 31st is a Monday, it and any following days are part of week 1 of the following year. - // Thus, for Tuesday 30th December 1997, %G is replaced by 1998 and %V is replaced by 01. - - return getWeekBasedYear(date).toString().substring(2); - }, - '%G': function(date) { - return getWeekBasedYear(date); - }, - '%H': function(date) { - return leadingNulls(date.tm_hour, 2); - }, - '%I': function(date) { - var twelveHour = date.tm_hour; - if (twelveHour == 0) twelveHour = 12; - else if (twelveHour > 12) twelveHour -= 12; - return leadingNulls(twelveHour, 2); - }, - '%j': function(date) { - // Day of the year (001-366) - return leadingNulls(date.tm_mday+__arraySum(__isLeapYear(date.tm_year+1900) ? __MONTH_DAYS_LEAP : __MONTH_DAYS_REGULAR, date.tm_mon-1), 3); - }, - '%m': function(date) { - return leadingNulls(date.tm_mon+1, 2); - }, - '%M': function(date) { - return leadingNulls(date.tm_min, 2); - }, - '%n': function() { - return '\n'; - }, - '%p': function(date) { - if (date.tm_hour >= 0 && date.tm_hour < 12) { - return 'AM'; - } else { - return 'PM'; - } - }, - '%S': function(date) { - return leadingNulls(date.tm_sec, 2); - }, - '%t': function() { - return '\t'; - }, - '%u': function(date) { - return date.tm_wday || 7; - }, - '%U': function(date) { - // Replaced by the week number of the year as a decimal number [00,53]. - // The first Sunday of January is the first day of week 1; - // days in the new year before this are in week 0. [ tm_year, tm_wday, tm_yday] - var janFirst = new Date(date.tm_year+1900, 0, 1); - var firstSunday = janFirst.getDay() === 0 ? janFirst : __addDays(janFirst, 7-janFirst.getDay()); - var endDate = new Date(date.tm_year+1900, date.tm_mon, date.tm_mday); - - // is target date after the first Sunday? - if (compareByDay(firstSunday, endDate) < 0) { - // calculate difference in days between first Sunday and endDate - var februaryFirstUntilEndMonth = __arraySum(__isLeapYear(endDate.getFullYear()) ? __MONTH_DAYS_LEAP : __MONTH_DAYS_REGULAR, endDate.getMonth()-1)-31; - var firstSundayUntilEndJanuary = 31-firstSunday.getDate(); - var days = firstSundayUntilEndJanuary+februaryFirstUntilEndMonth+endDate.getDate(); - return leadingNulls(Math.ceil(days/7), 2); - } - - return compareByDay(firstSunday, janFirst) === 0 ? '01': '00'; - }, - '%V': function(date) { - // Replaced by the week number of the year (Monday as the first day of the week) - // as a decimal number [01,53]. If the week containing 1 January has four - // or more days in the new year, then it is considered week 1. - // Otherwise, it is the last week of the previous year, and the next week is week 1. - // Both January 4th and the first Thursday of January are always in week 1. [ tm_year, tm_wday, tm_yday] - var janFourthThisYear = new Date(date.tm_year+1900, 0, 4); - var janFourthNextYear = new Date(date.tm_year+1901, 0, 4); - - var firstWeekStartThisYear = getFirstWeekStartDate(janFourthThisYear); - var firstWeekStartNextYear = getFirstWeekStartDate(janFourthNextYear); - - var endDate = __addDays(new Date(date.tm_year+1900, 0, 1), date.tm_yday); - - if (compareByDay(endDate, firstWeekStartThisYear) < 0) { - // if given date is before this years first week, then it belongs to the 53rd week of last year - return '53'; - } - - if (compareByDay(firstWeekStartNextYear, endDate) <= 0) { - // if given date is after next years first week, then it belongs to the 01th week of next year - return '01'; - } - - // given date is in between CW 01..53 of this calendar year - var daysDifference; - if (firstWeekStartThisYear.getFullYear() < date.tm_year+1900) { - // first CW of this year starts last year - daysDifference = date.tm_yday+32-firstWeekStartThisYear.getDate() - } else { - // first CW of this year starts this year - daysDifference = date.tm_yday+1-firstWeekStartThisYear.getDate(); - } - return leadingNulls(Math.ceil(daysDifference/7), 2); - }, - '%w': function(date) { - return date.tm_wday; - }, - '%W': function(date) { - // Replaced by the week number of the year as a decimal number [00,53]. - // The first Monday of January is the first day of week 1; - // days in the new year before this are in week 0. [ tm_year, tm_wday, tm_yday] - var janFirst = new Date(date.tm_year, 0, 1); - var firstMonday = janFirst.getDay() === 1 ? janFirst : __addDays(janFirst, janFirst.getDay() === 0 ? 1 : 7-janFirst.getDay()+1); - var endDate = new Date(date.tm_year+1900, date.tm_mon, date.tm_mday); - - // is target date after the first Monday? - if (compareByDay(firstMonday, endDate) < 0) { - var februaryFirstUntilEndMonth = __arraySum(__isLeapYear(endDate.getFullYear()) ? __MONTH_DAYS_LEAP : __MONTH_DAYS_REGULAR, endDate.getMonth()-1)-31; - var firstMondayUntilEndJanuary = 31-firstMonday.getDate(); - var days = firstMondayUntilEndJanuary+februaryFirstUntilEndMonth+endDate.getDate(); - return leadingNulls(Math.ceil(days/7), 2); - } - return compareByDay(firstMonday, janFirst) === 0 ? '01': '00'; - }, - '%y': function(date) { - // Replaced by the last two digits of the year as a decimal number [00,99]. [ tm_year] - return (date.tm_year+1900).toString().substring(2); - }, - '%Y': function(date) { - // Replaced by the year as a decimal number (for example, 1997). [ tm_year] - return date.tm_year+1900; - }, - '%z': function(date) { - // Replaced by the offset from UTC in the ISO 8601:2000 standard format ( +hhmm or -hhmm ). - // For example, "-0430" means 4 hours 30 minutes behind UTC (west of Greenwich). - var off = date.tm_gmtoff; - var ahead = off >= 0; - off = Math.abs(off) / 60; - // convert from minutes into hhmm format (which means 60 minutes = 100 units) - off = (off / 60)*100 + (off % 60); - return (ahead ? '+' : '-') + String("0000" + off).slice(-4); - }, - '%Z': function(date) { - return date.tm_zone; - }, - '%%': function() { - return '%'; - } - }; - for (var rule in EXPANSION_RULES_2) { - if (pattern.indexOf(rule) >= 0) { - pattern = pattern.replace(new RegExp(rule, 'g'), EXPANSION_RULES_2[rule](date)); - } - } - - var bytes = intArrayFromString(pattern, false); - if (bytes.length > maxsize) { - return 0; - } - - writeArrayToMemory(bytes, s); - return bytes.length-1; - } - Module["_strftime"] = _strftime;function _strftime_l(s, maxsize, format, tm) { - return _strftime(s, maxsize, format, tm); // no locale support yet - } - Module["_strftime_l"] = _strftime_l; - - function _sysconf(name) { - if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(24, 1, name); - - // long sysconf(int name); - // http://pubs.opengroup.org/onlinepubs/009695399/functions/sysconf.html - switch(name) { - case 30: return PAGE_SIZE; - case 85: - var maxHeapSize = 2*1024*1024*1024 - 65536; - maxHeapSize = HEAPU8.length; - return maxHeapSize / PAGE_SIZE; - case 132: - case 133: - case 12: - case 137: - case 138: - case 15: - case 235: - case 16: - case 17: - case 18: - case 19: - case 20: - case 149: - case 13: - case 10: - case 236: - case 153: - case 9: - case 21: - case 22: - case 159: - case 154: - case 14: - case 77: - case 78: - case 139: - case 80: - case 81: - case 82: - case 68: - case 67: - case 164: - case 11: - case 29: - case 47: - case 48: - case 95: - case 52: - case 51: - case 46: - return 200809; - case 79: - return 0; - case 27: - case 246: - case 127: - case 128: - case 23: - case 24: - case 160: - case 161: - case 181: - case 182: - case 242: - case 183: - case 184: - case 243: - case 244: - case 245: - case 165: - case 178: - case 179: - case 49: - case 50: - case 168: - case 169: - case 175: - case 170: - case 171: - case 172: - case 97: - case 76: - case 32: - case 173: - case 35: - return -1; - case 176: - case 177: - case 7: - case 155: - case 8: - case 157: - case 125: - case 126: - case 92: - case 93: - case 129: - case 130: - case 131: - case 94: - case 91: - return 1; - case 74: - case 60: - case 69: - case 70: - case 4: - return 1024; - case 31: - case 42: - case 72: - return 32; - case 87: - case 26: - case 33: - return 2147483647; - case 34: - case 1: - return 47839; - case 38: - case 36: - return 99; - case 43: - case 37: - return 2048; - case 0: return 2097152; - case 3: return 65536; - case 28: return 32768; - case 44: return 32767; - case 75: return 16384; - case 39: return 1000; - case 89: return 700; - case 71: return 256; - case 40: return 255; - case 2: return 100; - case 180: return 64; - case 25: return 20; - case 5: return 16; - case 6: return 6; - case 73: return 4; - case 84: { - if (typeof navigator === 'object') return navigator['hardwareConcurrency'] || 1; - return 1; - } - } - ___setErrNo(28); - return -1; + return ret; + }), + varargs: 0, + get: (function(varargs) { + SYSCALLS.varargs += 4; + var ret = GROWABLE_HEAP_LOAD_I32(SYSCALLS.varargs - 4 | 0); + return ret; + }), + getStr: (function() { + var ret = UTF8ToString(SYSCALLS.get()); + return ret; + }), + getStreamFromFD: (function(fd) { + if (fd === undefined) fd = SYSCALLS.get(); + var stream = FS.getStream(fd); + if (!stream) throw new FS.ErrnoError(8); + return stream; + }), + get64: (function() { + var low = SYSCALLS.get(), high = SYSCALLS.get(); + if (low >= 0) assert(high === 0); else assert(high === -1); + return low; + }), + getZero: (function() { + assert(SYSCALLS.get() === 0); + }) +}; +Module["SYSCALLS"] = SYSCALLS; +function ___syscall10(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(2, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var path = SYSCALLS.getStr(); + FS.unlink(path); + return 0; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall10"] = ___syscall10; +function ___syscall12(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(3, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var path = SYSCALLS.getStr(); + FS.chdir(path); + return 0; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall12"] = ___syscall12; +function ___syscall183(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(4, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var buf = SYSCALLS.get(), size = SYSCALLS.get(); + if (size === 0) return -28; + var cwd = FS.cwd(); + var cwdLengthInBytes = lengthBytesUTF8(cwd); + if (size < cwdLengthInBytes + 1) return -68; + stringToUTF8(cwd, buf, size); + return buf; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall183"] = ___syscall183; +function _memset(ptr, value, num) { + ptr = ptr | 0; + value = value | 0; + num = num | 0; + var end = 0, aligned_end = 0, block_aligned_end = 0, value4 = 0; + end = ptr + num | 0; + value = value & 255; + if ((num | 0) >= 67) { + while ((ptr & 3) != 0) { + GROWABLE_HEAP_STORE_I8(ptr >> 0 | 0, value); + ptr = ptr + 1 | 0; + } + aligned_end = end & -4 | 0; + value4 = value | value << 8 | value << 16 | value << 24; + block_aligned_end = aligned_end - 64 | 0; + while ((ptr | 0) <= (block_aligned_end | 0)) { + GROWABLE_HEAP_STORE_I32(ptr | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 4 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 8 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 12 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 16 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 20 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 24 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 28 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 32 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 36 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 40 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 44 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 48 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 52 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 56 | 0, value4); + GROWABLE_HEAP_STORE_I32(ptr + 60 | 0, value4); + ptr = ptr + 64 | 0; + } + while ((ptr | 0) < (aligned_end | 0)) { + GROWABLE_HEAP_STORE_I32(ptr | 0, value4); + ptr = ptr + 4 | 0; + } + } + while ((ptr | 0) < (end | 0)) { + GROWABLE_HEAP_STORE_I8(ptr >> 0 | 0, value); + ptr = ptr + 1 | 0; + } + return end - num | 0; +} +Module["_memset"] = _memset; +function __emscripten_syscall_mmap2(addr, len, prot, flags, fd, off) { + off <<= 12; + var ptr; + var allocated = false; + if ((flags & 16) !== 0 && addr % PAGE_SIZE !== 0) { + return -28; + } + if ((flags & 32) !== 0) { + ptr = _memalign(PAGE_SIZE, len); + if (!ptr) return -48; + _memset(ptr, 0, len); + allocated = true; + } else { + var info = FS.getStream(fd); + if (!info) return -8; + var res = FS.mmap(info, HEAPU8, addr, len, off, prot, flags); + ptr = res.ptr; + allocated = res.allocated; + } + SYSCALLS.mappings[ptr] = { + malloc: ptr, + len: len, + allocated: allocated, + fd: fd, + flags: flags + }; + return ptr; +} +Module["__emscripten_syscall_mmap2"] = __emscripten_syscall_mmap2; +function ___syscall192(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(5, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var addr = SYSCALLS.get(), len = SYSCALLS.get(), prot = SYSCALLS.get(), flags = SYSCALLS.get(), fd = SYSCALLS.get(), off = SYSCALLS.get(); + return __emscripten_syscall_mmap2(addr, len, prot, flags, fd, off); + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall192"] = ___syscall192; +function ___syscall195(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(6, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var path = SYSCALLS.getStr(), buf = SYSCALLS.get(); + return SYSCALLS.doStat(FS.stat, path, buf); + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall195"] = ___syscall195; +function ___syscall196(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(7, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var path = SYSCALLS.getStr(), buf = SYSCALLS.get(); + return SYSCALLS.doStat(FS.lstat, path, buf); + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall196"] = ___syscall196; +function ___syscall220(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(8, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var stream = SYSCALLS.getStreamFromFD(), dirp = SYSCALLS.get(), count = SYSCALLS.get(); + if (!stream.getdents) { + stream.getdents = FS.readdir(stream.path); + } + var struct_size = 280; + var pos = 0; + var off = FS.llseek(stream, 0, 1); + var idx = Math.floor(off / struct_size); + while (idx < stream.getdents.length && pos + struct_size <= count) { + var id; + var type; + var name = stream.getdents[idx]; + if (name[0] === ".") { + id = 1; + type = 4; + } else { + var child = FS.lookupNode(stream.node, name); + id = child.id; + type = FS.isChrdev(child.mode) ? 2 : FS.isDir(child.mode) ? 4 : FS.isLink(child.mode) ? 10 : 8; + } + tempI64 = [ id >>> 0, (tempDouble = id, +Math_abs(tempDouble) >= 1 ? tempDouble > 0 ? (Math_min(+Math_floor(tempDouble / 4294967296), 4294967295) | 0) >>> 0 : ~~+Math_ceil((tempDouble - +(~~tempDouble >>> 0)) / 4294967296) >>> 0 : 0) ], GROWABLE_HEAP_STORE_I32(dirp + pos | 0, tempI64[0]), GROWABLE_HEAP_STORE_I32(dirp + pos + 4 | 0, tempI64[1]); + tempI64 = [ (idx + 1) * struct_size >>> 0, (tempDouble = (idx + 1) * struct_size, +Math_abs(tempDouble) >= 1 ? tempDouble > 0 ? (Math_min(+Math_floor(tempDouble / 4294967296), 4294967295) | 0) >>> 0 : ~~+Math_ceil((tempDouble - +(~~tempDouble >>> 0)) / 4294967296) >>> 0 : 0) ], GROWABLE_HEAP_STORE_I32(dirp + pos + 8 | 0, tempI64[0]), GROWABLE_HEAP_STORE_I32(dirp + pos + 12 | 0, tempI64[1]); + GROWABLE_HEAP_STORE_I16(dirp + pos + 16 | 0, 280); + GROWABLE_HEAP_STORE_I8(dirp + pos + 18 >> 0 | 0, type); + stringToUTF8(name, dirp + pos + 19, 256); + pos += struct_size; + idx += 1; + } + FS.llseek(stream, idx * struct_size, 0); + return pos; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall220"] = ___syscall220; +function ___syscall221(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(9, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var stream = SYSCALLS.getStreamFromFD(), cmd = SYSCALLS.get(); + switch (cmd) { + case 0: + { + var arg = SYSCALLS.get(); + if (arg < 0) { + return -28; } - - Module["_sysconf"] = _sysconf; - - function _system(command) { - // int system(const char *command); - // http://pubs.opengroup.org/onlinepubs/000095399/functions/system.html - // Can't call external programs. - ___setErrNo(6); - return -1; + var newStream; + newStream = FS.open(stream.path, stream.flags, 0, arg); + return newStream.fd; + } + case 1: + case 2: + return 0; + case 3: + return stream.flags; + case 4: + { + var arg = SYSCALLS.get(); + stream.flags |= arg; + return 0; + } + case 12: + { + var arg = SYSCALLS.get(); + var offset = 0; + GROWABLE_HEAP_STORE_I16(arg + offset | 0, 2); + return 0; + } + case 13: + case 14: + return 0; + case 16: + case 8: + return -28; + case 9: + ___setErrNo(28); + return -1; + default: + { + return -28; + } + } + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall221"] = ___syscall221; +function ___syscall3(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(10, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var stream = SYSCALLS.getStreamFromFD(), buf = SYSCALLS.get(), count = SYSCALLS.get(); + return FS.read(stream, HEAP8, buf, count); + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall3"] = ___syscall3; +function ___syscall39(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(11, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var path = SYSCALLS.getStr(), mode = SYSCALLS.get(); + return SYSCALLS.doMkdir(path, mode); + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall39"] = ___syscall39; +function ___syscall4(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(12, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var stream = SYSCALLS.getStreamFromFD(), buf = SYSCALLS.get(), count = SYSCALLS.get(); + return FS.write(stream, HEAP8, buf, count); + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall4"] = ___syscall4; +function ___syscall40(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(13, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var path = SYSCALLS.getStr(); + FS.rmdir(path); + return 0; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall40"] = ___syscall40; +function ___syscall5(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(14, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var pathname = SYSCALLS.getStr(), flags = SYSCALLS.get(), mode = SYSCALLS.get(); + var stream = FS.open(pathname, flags, mode); + return stream.fd; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall5"] = ___syscall5; +function ___syscall54(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(15, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var stream = SYSCALLS.getStreamFromFD(), op = SYSCALLS.get(); + switch (op) { + case 21509: + case 21505: + { + if (!stream.tty) return -59; + return 0; + } + case 21510: + case 21511: + case 21512: + case 21506: + case 21507: + case 21508: + { + if (!stream.tty) return -59; + return 0; + } + case 21519: + { + if (!stream.tty) return -59; + var argp = SYSCALLS.get(); + GROWABLE_HEAP_STORE_I32(argp | 0, 0); + return 0; + } + case 21520: + { + if (!stream.tty) return -59; + return -28; + } + case 21531: + { + var argp = SYSCALLS.get(); + return FS.ioctl(stream, op, argp); + } + case 21523: + { + if (!stream.tty) return -59; + return 0; + } + case 21524: + { + if (!stream.tty) return -59; + return 0; + } + default: + abort("bad ioctl syscall " + op); + } + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall54"] = ___syscall54; +function ___syscall85(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(16, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var path = SYSCALLS.getStr(), buf = SYSCALLS.get(), bufsize = SYSCALLS.get(); + return SYSCALLS.doReadlink(path, buf, bufsize); + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall85"] = ___syscall85; +function __emscripten_syscall_munmap(addr, len) { + if (addr === -1 || len === 0) { + return -28; + } + var info = SYSCALLS.mappings[addr]; + if (!info) return 0; + if (len === info.len) { + var stream = FS.getStream(info.fd); + SYSCALLS.doMsync(addr, stream, len, info.flags); + FS.munmap(stream); + SYSCALLS.mappings[addr] = null; + if (info.allocated) { + _free(info.malloc); + } + } + return 0; +} +Module["__emscripten_syscall_munmap"] = __emscripten_syscall_munmap; +function ___syscall91(which, varargs) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(17, 1, which, varargs); + SYSCALLS.varargs = varargs; + try { + var addr = SYSCALLS.get(), len = SYSCALLS.get(); + return __emscripten_syscall_munmap(addr, len); + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return -e.errno; + } +} +Module["___syscall91"] = ___syscall91; +function ___unlock() {} +Module["___unlock"] = ___unlock; +function _abort() { + abort(); +} +Module["_abort"] = _abort; +function _emscripten_check_blocking_allowed() { + assert(ENVIRONMENT_IS_WEB); + warnOnce("Blocking on the main thread is very dangerous, see https://emscripten.org/docs/porting/pthreads.html#blocking-on-the-main-browser-thread"); +} +Module["_emscripten_check_blocking_allowed"] = _emscripten_check_blocking_allowed; +function _emscripten_conditional_set_current_thread_status_js(expectedStatus, newStatus) {} +Module["_emscripten_conditional_set_current_thread_status_js"] = _emscripten_conditional_set_current_thread_status_js; +function _emscripten_conditional_set_current_thread_status(expectedStatus, newStatus) { + expectedStatus = expectedStatus | 0; + newStatus = newStatus | 0; +} +Module["_emscripten_conditional_set_current_thread_status"] = _emscripten_conditional_set_current_thread_status; +function _emscripten_futex_wait(addr, val, timeout) { + if (addr <= 0 || addr > HEAP8.length || addr & 3 != 0) return -28; + if (ENVIRONMENT_IS_WORKER) { + var ret = Atomics.wait(HEAP32, addr >> 2, val, timeout); + if (ret === "timed-out") return -73; + if (ret === "not-equal") return -6; + if (ret === "ok") return 0; + throw "Atomics.wait returned an unexpected value " + ret; + } else { + var loadedVal = Atomics.load(HEAP32, addr >> 2); + if (val != loadedVal) return -6; + var tNow = performance.now(); + var tEnd = tNow + timeout; + Atomics.store(HEAP32, __main_thread_futex_wait_address >> 2, addr); + var ourWaitAddress = addr; + while (addr == ourWaitAddress) { + tNow = performance.now(); + if (tNow > tEnd) { + return -73; + } + _emscripten_main_thread_process_queued_calls(); + addr = Atomics.load(HEAP32, __main_thread_futex_wait_address >> 2); + } + return 0; + } +} +Module["_emscripten_futex_wait"] = _emscripten_futex_wait; +function _emscripten_get_heap_size() { + return HEAP8.length; +} +Module["_emscripten_get_heap_size"] = _emscripten_get_heap_size; +function _emscripten_get_sbrk_ptr() { + return 12594960; +} +Module["_emscripten_get_sbrk_ptr"] = _emscripten_get_sbrk_ptr; +function _emscripten_has_threading_support() { + return typeof SharedArrayBuffer !== "undefined"; +} +Module["_emscripten_has_threading_support"] = _emscripten_has_threading_support; +function _emscripten_is_main_browser_thread() { + return __pthread_is_main_browser_thread | 0; +} +Module["_emscripten_is_main_browser_thread"] = _emscripten_is_main_browser_thread; +function _emscripten_is_main_runtime_thread() { + return __pthread_is_main_runtime_thread | 0; +} +Module["_emscripten_is_main_runtime_thread"] = _emscripten_is_main_runtime_thread; +var setjmpId = 0; +Module["setjmpId"] = setjmpId; +function _saveSetjmp(env, label, table, size) { + env = env | 0; + label = label | 0; + table = table | 0; + size = size | 0; + var i = 0; + setjmpId = setjmpId + 1 | 0; + GROWABLE_HEAP_STORE_I32(env | 0, setjmpId); + while ((i | 0) < (size | 0)) { + if ((GROWABLE_HEAP_LOAD_I32(table + (i << 3) | 0) | 0) == 0) { + GROWABLE_HEAP_STORE_I32(table + (i << 3) | 0, setjmpId); + GROWABLE_HEAP_STORE_I32(table + ((i << 3) + 4) | 0, label); + GROWABLE_HEAP_STORE_I32(table + ((i << 3) + 8) | 0, 0); + setTempRet0(size | 0); + return table | 0; + } + i = i + 1 | 0; + } + size = size * 2 | 0; + table = _realloc(table | 0, 8 * (size + 1 | 0) | 0) | 0; + table = _saveSetjmp(env | 0, label | 0, table | 0, size | 0) | 0; + setTempRet0(size | 0); + return table | 0; +} +Module["_saveSetjmp"] = _saveSetjmp; +function _testSetjmp(id, table, size) { + id = id | 0; + table = table | 0; + size = size | 0; + var i = 0, curr = 0; + while ((i | 0) < (size | 0)) { + curr = GROWABLE_HEAP_LOAD_I32(table + (i << 3) | 0) | 0; + if ((curr | 0) == 0) break; + if ((curr | 0) == (id | 0)) { + return GROWABLE_HEAP_LOAD_I32(table + ((i << 3) + 4) | 0) | 0; + } + i = i + 1 | 0; + } + return 0; +} +Module["_testSetjmp"] = _testSetjmp; +function _longjmp(env, value) { + _setThrew(env, value || 1); + throw "longjmp"; +} +Module["_longjmp"] = _longjmp; +function _emscripten_longjmp(env, value) { + _longjmp(env, value); +} +Module["_emscripten_longjmp"] = _emscripten_longjmp; +function _emscripten_memcpy_big(dest, src, num) { + HEAPU8.set(HEAPU8.subarray(src, src + num), dest); +} +Module["_emscripten_memcpy_big"] = _emscripten_memcpy_big; +function _emscripten_proxy_to_main_thread_js(index, sync) { + var numCallArgs = arguments.length - 2; + if (numCallArgs > 20 - 1) throw "emscripten_proxy_to_main_thread_js: Too many arguments " + numCallArgs + " to proxied function idx=" + index + ", maximum supported is " + (20 - 1) + "!"; + var stack = stackSave(); + var args = stackAlloc(numCallArgs * 8); + var b = args >> 3; + for (var i = 0; i < numCallArgs; i++) { + GROWABLE_HEAP_STORE_F64((b + i) * 8 | 0, arguments[2 + i]); + } + var ret = _emscripten_run_in_main_runtime_thread_js(index, numCallArgs, args, sync); + stackRestore(stack); + return ret; +} +Module["_emscripten_proxy_to_main_thread_js"] = _emscripten_proxy_to_main_thread_js; +var _emscripten_receive_on_main_thread_js_callArgs = []; +Module["_emscripten_receive_on_main_thread_js_callArgs"] = _emscripten_receive_on_main_thread_js_callArgs; +function _emscripten_receive_on_main_thread_js(index, numCallArgs, args) { + _emscripten_receive_on_main_thread_js_callArgs.length = numCallArgs; + var b = args >> 3; + for (var i = 0; i < numCallArgs; i++) { + _emscripten_receive_on_main_thread_js_callArgs[i] = GROWABLE_HEAP_LOAD_F64((b + i) * 8 | 0); + } + var isEmAsmConst = index < 0; + var func = !isEmAsmConst ? proxiedFunctionTable[index] : ASM_CONSTS[-index - 1]; + if (isEmAsmConst) { + var sigPtr = _emscripten_receive_on_main_thread_js_callArgs[1]; + var varargPtr = _emscripten_receive_on_main_thread_js_callArgs[2]; + var constArgs = readAsmConstArgs(sigPtr, varargPtr); + return func.apply(null, constArgs); + } + assert(func.length == numCallArgs, "Call args mismatch in emscripten_receive_on_main_thread_js"); + return func.apply(null, _emscripten_receive_on_main_thread_js_callArgs); +} +Module["_emscripten_receive_on_main_thread_js"] = _emscripten_receive_on_main_thread_js; +function abortOnCannotGrowMemory(requestedSize) { + abort("Cannot enlarge memory arrays to size " + requestedSize + " bytes (OOM). Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value " + HEAP8.length + ", (2) compile with -s ALLOW_MEMORY_GROWTH=1 which allows increasing the size at runtime, or (3) if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 "); +} +Module["abortOnCannotGrowMemory"] = abortOnCannotGrowMemory; +function emscripten_realloc_buffer(size) { + try { + wasmMemory.grow(size - buffer.byteLength + 65535 >> 16); + updateGlobalBufferAndViews(wasmMemory.buffer); + return 1; + } catch (e) { + console.error("emscripten_realloc_buffer: Attempted to grow heap from " + buffer.byteLength + " bytes to " + size + " bytes, but got error: " + e); + } +} +Module["emscripten_realloc_buffer"] = emscripten_realloc_buffer; +function _emscripten_resize_heap(requestedSize) { + var oldSize = _emscripten_get_heap_size(); + if (requestedSize <= oldSize) { + return false; + } + var PAGE_MULTIPLE = 65536; + var LIMIT = 2147483648 - PAGE_MULTIPLE; + if (requestedSize > LIMIT) { + err("Cannot enlarge memory, asked to go up to " + requestedSize + " bytes, but the limit is " + LIMIT + " bytes!"); + return false; + } + var MIN_TOTAL_MEMORY = 16777216; + var newSize = Math.max(oldSize, MIN_TOTAL_MEMORY); + while (newSize < requestedSize) { + if (newSize <= 536870912) { + newSize = alignUp(2 * newSize, PAGE_MULTIPLE); + } else { + newSize = Math.min(alignUp((3 * newSize + 2147483648) / 4, PAGE_MULTIPLE), LIMIT); + } + if (newSize === oldSize) { + warnOnce("Cannot ask for more memory since we reached the practical limit in browsers (which is just below 2GB), so the request would have failed. Requesting only " + HEAP8.length); + } + } + newSize = Math.min(newSize, 1073741824); + if (newSize == oldSize) { + err("Failed to grow the heap from " + oldSize + ", as we reached the WASM_MEM_MAX limit (" + 1073741824 + ") set during compilation"); + return false; + } + var replacement = emscripten_realloc_buffer(newSize); + if (!replacement) { + err("Failed to grow the heap from " + oldSize + " bytes to " + newSize + " bytes, not enough memory!"); + return false; + } + return true; +} +Module["_emscripten_resize_heap"] = _emscripten_resize_heap; +var JSEvents = { + keyEvent: 0, + mouseEvent: 0, + wheelEvent: 0, + uiEvent: 0, + focusEvent: 0, + deviceOrientationEvent: 0, + deviceMotionEvent: 0, + fullscreenChangeEvent: 0, + pointerlockChangeEvent: 0, + visibilityChangeEvent: 0, + touchEvent: 0, + previousFullscreenElement: null, + previousScreenX: null, + previousScreenY: null, + removeEventListenersRegistered: false, + removeAllEventListeners: (function() { + for (var i = JSEvents.eventHandlers.length - 1; i >= 0; --i) { + JSEvents._removeHandler(i); + } + JSEvents.eventHandlers = []; + JSEvents.deferredCalls = []; + }), + registerRemoveEventListeners: (function() { + if (!JSEvents.removeEventListenersRegistered) { + __ATEXIT__.push(JSEvents.removeAllEventListeners); + JSEvents.removeEventListenersRegistered = true; + } + }), + deferredCalls: [], + deferCall: (function(targetFunction, precedence, argsList) { + function arraysHaveEqualContent(arrA, arrB) { + if (arrA.length != arrB.length) return false; + for (var i in arrA) { + if (arrA[i] != arrB[i]) return false; + } + return true; + } + for (var i in JSEvents.deferredCalls) { + var call = JSEvents.deferredCalls[i]; + if (call.targetFunction == targetFunction && arraysHaveEqualContent(call.argsList, argsList)) { + return; + } + } + JSEvents.deferredCalls.push({ + targetFunction: targetFunction, + precedence: precedence, + argsList: argsList + }); + JSEvents.deferredCalls.sort((function(x, y) { + return x.precedence < y.precedence; + })); + }), + removeDeferredCalls: (function(targetFunction) { + for (var i = 0; i < JSEvents.deferredCalls.length; ++i) { + if (JSEvents.deferredCalls[i].targetFunction == targetFunction) { + JSEvents.deferredCalls.splice(i, 1); + --i; + } + } + }), + canPerformEventHandlerRequests: (function() { + return JSEvents.inEventHandler && JSEvents.currentEventHandler.allowsDeferredCalls; + }), + runDeferredCalls: (function() { + if (!JSEvents.canPerformEventHandlerRequests()) { + return; + } + for (var i = 0; i < JSEvents.deferredCalls.length; ++i) { + var call = JSEvents.deferredCalls[i]; + JSEvents.deferredCalls.splice(i, 1); + --i; + call.targetFunction.apply(this, call.argsList); + } + }), + inEventHandler: 0, + currentEventHandler: null, + eventHandlers: [], + isInternetExplorer: (function() { + return navigator.userAgent.indexOf("MSIE") !== -1 || navigator.appVersion.indexOf("Trident/") > 0; + }), + removeAllHandlersOnTarget: (function(target, eventTypeString) { + for (var i = 0; i < JSEvents.eventHandlers.length; ++i) { + if (JSEvents.eventHandlers[i].target == target && (!eventTypeString || eventTypeString == JSEvents.eventHandlers[i].eventTypeString)) { + JSEvents._removeHandler(i--); + } + } + }), + _removeHandler: (function(i) { + var h = JSEvents.eventHandlers[i]; + h.target.removeEventListener(h.eventTypeString, h.eventListenerFunc, h.useCapture); + JSEvents.eventHandlers.splice(i, 1); + }), + registerOrRemoveHandler: (function(eventHandler) { + var jsEventHandler = function jsEventHandler(event) { + ++JSEvents.inEventHandler; + JSEvents.currentEventHandler = eventHandler; + JSEvents.runDeferredCalls(); + eventHandler.handlerFunc(event); + JSEvents.runDeferredCalls(); + --JSEvents.inEventHandler; + }; + if (eventHandler.callbackfunc) { + eventHandler.eventListenerFunc = jsEventHandler; + eventHandler.target.addEventListener(eventHandler.eventTypeString, jsEventHandler, eventHandler.useCapture); + JSEvents.eventHandlers.push(eventHandler); + JSEvents.registerRemoveEventListeners(); + } else { + for (var i = 0; i < JSEvents.eventHandlers.length; ++i) { + if (JSEvents.eventHandlers[i].target == eventHandler.target && JSEvents.eventHandlers[i].eventTypeString == eventHandler.eventTypeString) { + JSEvents._removeHandler(i--); } - Module["_system"] = _system; - - - function _time(ptr) { - var ret = (Date.now()/1000)|0; - if (ptr) { - HEAP32[((ptr)>>2)]=ret; - } - return ret; + } + } + }), + queueEventHandlerOnThread_iiii: (function(targetThread, eventHandlerFunc, eventTypeId, eventData, userData) { + var stackTop = stackSave(); + var varargs = stackAlloc(12); + GROWABLE_HEAP_STORE_I32(varargs | 0, eventTypeId); + GROWABLE_HEAP_STORE_I32(varargs + 4 | 0, eventData); + GROWABLE_HEAP_STORE_I32(varargs + 8 | 0, userData); + _emscripten_async_queue_on_thread_(targetThread, 637534208, eventHandlerFunc, eventData, varargs); + stackRestore(stackTop); + }), + getTargetThreadForEventCallback: (function(targetThread) { + switch (targetThread) { + case 1: + return 0; + case 2: + return PThread.currentProxiedOperationCallerThread; + default: + return targetThread; + } + }), + getBoundingClientRectOrZeros: (function(target) { + return target.getBoundingClientRect ? target.getBoundingClientRect() : { + left: 0, + top: 0 + }; + }), + getNodeNameForTarget: (function(target) { + if (!target) return ""; + if (target == window) return "#window"; + if (target == screen) return "#screen"; + return target && target.nodeName ? target.nodeName : ""; + }), + tick: (function() { + if (window["performance"] && window["performance"]["now"]) return window["performance"]["now"](); else return Date.now(); + }), + fullscreenEnabled: (function() { + return document.fullscreenEnabled || document.mozFullScreenEnabled || document.webkitFullscreenEnabled || document.msFullscreenEnabled; + }) +}; +Module["JSEvents"] = JSEvents; +function stringToNewUTF8(jsString) { + var length = lengthBytesUTF8(jsString) + 1; + var cString = _malloc(length); + stringToUTF8(jsString, cString, length); + return cString; +} +Module["stringToNewUTF8"] = stringToNewUTF8; +function _emscripten_set_offscreencanvas_size_on_target_thread_js(targetThread, targetCanvas, width, height) { + var stackTop = stackSave(); + var varargs = stackAlloc(12); + var targetCanvasPtr = 0; + if (targetCanvas) { + targetCanvasPtr = stringToNewUTF8(targetCanvas); + } + GROWABLE_HEAP_STORE_I32(varargs | 0, targetCanvasPtr); + GROWABLE_HEAP_STORE_I32(varargs + 4 | 0, width); + GROWABLE_HEAP_STORE_I32(varargs + 8 | 0, height); + _emscripten_async_queue_on_thread_(targetThread, 657457152, 0, targetCanvasPtr, varargs); + stackRestore(stackTop); +} +Module["_emscripten_set_offscreencanvas_size_on_target_thread_js"] = _emscripten_set_offscreencanvas_size_on_target_thread_js; +function _emscripten_set_offscreencanvas_size_on_target_thread(targetThread, targetCanvas, width, height) { + targetCanvas = targetCanvas ? UTF8ToString(targetCanvas) : ""; + _emscripten_set_offscreencanvas_size_on_target_thread_js(targetThread, targetCanvas, width, height); +} +Module["_emscripten_set_offscreencanvas_size_on_target_thread"] = _emscripten_set_offscreencanvas_size_on_target_thread; +var __specialEventTargets = [ 0, typeof document !== "undefined" ? document : 0, typeof window !== "undefined" ? window : 0 ]; +Module["__specialEventTargets"] = __specialEventTargets; +function __findEventTarget(target) { + warnOnce("Rules for selecting event targets in HTML5 API are changing: instead of using document.getElementById() that only can refer to elements by their DOM ID, new event target selection mechanism uses the more flexible function document.querySelector() that can look up element names, classes, and complex CSS selectors. Build with -s DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=1 to change to the new lookup rules. See https://github.com/emscripten-core/emscripten/pull/7977 for more details."); + try { + if (!target) return window; + if (typeof target === "number") target = __specialEventTargets[target] || UTF8ToString(target); + if (target === "#window") return window; else if (target === "#document") return document; else if (target === "#screen") return screen; else if (target === "#canvas") return Module["canvas"]; + return typeof target === "string" ? document.getElementById(target) : target; + } catch (e) { + return null; + } +} +Module["__findEventTarget"] = __findEventTarget; +function __findCanvasEventTarget(target) { + if (typeof target === "number") target = UTF8ToString(target); + if (!target || target === "#canvas") { + if (typeof GL !== "undefined" && GL.offscreenCanvases["canvas"]) return GL.offscreenCanvases["canvas"]; + return Module["canvas"]; + } + if (typeof GL !== "undefined" && GL.offscreenCanvases[target]) return GL.offscreenCanvases[target]; + return __findEventTarget(target); +} +Module["__findCanvasEventTarget"] = __findCanvasEventTarget; +function _emscripten_set_canvas_element_size_calling_thread(target, width, height) { + var canvas = __findCanvasEventTarget(target); + if (!canvas) return -4; + if (canvas.canvasSharedPtr) { + GROWABLE_HEAP_STORE_I32(canvas.canvasSharedPtr | 0, width); + GROWABLE_HEAP_STORE_I32(canvas.canvasSharedPtr + 4 | 0, height); + } + if (canvas.offscreenCanvas || !canvas.controlTransferredOffscreen) { + if (canvas.offscreenCanvas) canvas = canvas.offscreenCanvas; + var autoResizeViewport = false; + if (canvas.GLctxObject && canvas.GLctxObject.GLctx) { + var prevViewport = canvas.GLctxObject.GLctx.getParameter(canvas.GLctxObject.GLctx.VIEWPORT); + autoResizeViewport = prevViewport[0] === 0 && prevViewport[1] === 0 && prevViewport[2] === canvas.width && prevViewport[3] === canvas.height; + } + canvas.width = width; + canvas.height = height; + if (autoResizeViewport) { + canvas.GLctxObject.GLctx.viewport(0, 0, width, height); + } + } else if (canvas.canvasSharedPtr) { + var targetThread = GROWABLE_HEAP_LOAD_I32(canvas.canvasSharedPtr + 8 | 0); + _emscripten_set_offscreencanvas_size_on_target_thread(targetThread, target, width, height); + return 1; + } else { + return -4; + } + return 0; +} +Module["_emscripten_set_canvas_element_size_calling_thread"] = _emscripten_set_canvas_element_size_calling_thread; +function _emscripten_set_canvas_element_size_main_thread(target, width, height) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(18, 1, target, width, height); + return _emscripten_set_canvas_element_size_calling_thread(target, width, height); +} +Module["_emscripten_set_canvas_element_size_main_thread"] = _emscripten_set_canvas_element_size_main_thread; +function _emscripten_set_canvas_element_size(target, width, height) { + var canvas = __findCanvasEventTarget(target); + if (canvas) { + return _emscripten_set_canvas_element_size_calling_thread(target, width, height); + } else { + return _emscripten_set_canvas_element_size_main_thread(target, width, height); + } +} +Module["_emscripten_set_canvas_element_size"] = _emscripten_set_canvas_element_size; +function _emscripten_set_current_thread_status_js(newStatus) {} +Module["_emscripten_set_current_thread_status_js"] = _emscripten_set_current_thread_status_js; +function _emscripten_set_current_thread_status(newStatus) { + newStatus = newStatus | 0; +} +Module["_emscripten_set_current_thread_status"] = _emscripten_set_current_thread_status; +function _emscripten_set_thread_name_js(threadId, name) {} +Module["_emscripten_set_thread_name_js"] = _emscripten_set_thread_name_js; +function _emscripten_set_thread_name(threadId, name) { + threadId = threadId | 0; + name = name | 0; +} +Module["_emscripten_set_thread_name"] = _emscripten_set_thread_name; +function _emscripten_syscall(which, varargs) { + switch (which) { + case 10: + return ___syscall10(which, varargs); + case 12: + return ___syscall12(which, varargs); + case 183: + return ___syscall183(which, varargs); + case 192: + return ___syscall192(which, varargs); + case 195: + return ___syscall195(which, varargs); + case 196: + return ___syscall196(which, varargs); + case 220: + return ___syscall220(which, varargs); + case 221: + return ___syscall221(which, varargs); + case 3: + return ___syscall3(which, varargs); + case 39: + return ___syscall39(which, varargs); + case 4: + return ___syscall4(which, varargs); + case 40: + return ___syscall40(which, varargs); + case 5: + return ___syscall5(which, varargs); + case 54: + return ___syscall54(which, varargs); + case 85: + return ___syscall85(which, varargs); + case 91: + return ___syscall91(which, varargs); + default: + throw "surprising proxied syscall: " + which; + } +} +Module["_emscripten_syscall"] = _emscripten_syscall; +var __emscripten_webgl_power_preferences = [ "default", "low-power", "high-performance" ]; +Module["__emscripten_webgl_power_preferences"] = __emscripten_webgl_power_preferences; +var GL = { + counter: 1, + lastError: 0, + buffers: [], + mappedBuffers: {}, + programs: [], + framebuffers: [], + renderbuffers: [], + textures: [], + uniforms: [], + shaders: [], + vaos: [], + contexts: {}, + currentContext: null, + offscreenCanvases: {}, + timerQueriesEXT: [], + programInfos: {}, + stringCache: {}, + unpackAlignment: 4, + init: (function() { + GL.miniTempBuffer = new Float32Array(GL.MINI_TEMP_BUFFER_SIZE); + for (var i = 0; i < GL.MINI_TEMP_BUFFER_SIZE; i++) { + GL.miniTempBufferViews[i] = GL.miniTempBuffer.subarray(0, i + 1); + } + }), + recordError: function recordError(errorCode) { + if (!GL.lastError) { + GL.lastError = errorCode; + } + }, + getNewId: (function(table) { + var ret = GL.counter++; + for (var i = table.length; i < ret; i++) { + table[i] = null; + } + return ret; + }), + MINI_TEMP_BUFFER_SIZE: 256, + miniTempBuffer: null, + miniTempBufferViews: [ 0 ], + getSource: (function(shader, count, string, length) { + var source = ""; + for (var i = 0; i < count; ++i) { + var len = length ? GROWABLE_HEAP_LOAD_I32(length + i * 4 | 0) : -1; + source += UTF8ToString(GROWABLE_HEAP_LOAD_I32(string + i * 4 | 0), len < 0 ? undefined : len); + } + return source; + }), + createContext: (function(canvas, webGLContextAttributes) { + var ctx = canvas.getContext("webgl", webGLContextAttributes) || canvas.getContext("experimental-webgl", webGLContextAttributes); + if (!ctx) return 0; + var handle = GL.registerContext(ctx, webGLContextAttributes); + return handle; + }), + registerContext: (function(ctx, webGLContextAttributes) { + var handle = _malloc(8); + GROWABLE_HEAP_STORE_I32(handle + 4 | 0, _pthread_self()); + var context = { + handle: handle, + attributes: webGLContextAttributes, + version: webGLContextAttributes.majorVersion, + GLctx: ctx + }; + if (ctx.canvas) ctx.canvas.GLctxObject = context; + GL.contexts[handle] = context; + if (typeof webGLContextAttributes.enableExtensionsByDefault === "undefined" || webGLContextAttributes.enableExtensionsByDefault) { + GL.initExtensions(context); + } + return handle; + }), + makeContextCurrent: (function(contextHandle) { + GL.currentContext = GL.contexts[contextHandle]; + Module.ctx = GLctx = GL.currentContext && GL.currentContext.GLctx; + return !(contextHandle && !GLctx); + }), + getContext: (function(contextHandle) { + return GL.contexts[contextHandle]; + }), + deleteContext: (function(contextHandle) { + if (GL.currentContext === GL.contexts[contextHandle]) GL.currentContext = null; + if (typeof JSEvents === "object") JSEvents.removeAllHandlersOnTarget(GL.contexts[contextHandle].GLctx.canvas); + if (GL.contexts[contextHandle] && GL.contexts[contextHandle].GLctx.canvas) GL.contexts[contextHandle].GLctx.canvas.GLctxObject = undefined; + _free(GL.contexts[contextHandle]); + GL.contexts[contextHandle] = null; + }), + acquireInstancedArraysExtension: (function(ctx) { + var ext = ctx.getExtension("ANGLE_instanced_arrays"); + if (ext) { + ctx["vertexAttribDivisor"] = (function(index, divisor) { + ext["vertexAttribDivisorANGLE"](index, divisor); + }); + ctx["drawArraysInstanced"] = (function(mode, first, count, primcount) { + ext["drawArraysInstancedANGLE"](mode, first, count, primcount); + }); + ctx["drawElementsInstanced"] = (function(mode, count, type, indices, primcount) { + ext["drawElementsInstancedANGLE"](mode, count, type, indices, primcount); + }); + } + }), + acquireVertexArrayObjectExtension: (function(ctx) { + var ext = ctx.getExtension("OES_vertex_array_object"); + if (ext) { + ctx["createVertexArray"] = (function() { + return ext["createVertexArrayOES"](); + }); + ctx["deleteVertexArray"] = (function(vao) { + ext["deleteVertexArrayOES"](vao); + }); + ctx["bindVertexArray"] = (function(vao) { + ext["bindVertexArrayOES"](vao); + }); + ctx["isVertexArray"] = (function(vao) { + return ext["isVertexArrayOES"](vao); + }); + } + }), + acquireDrawBuffersExtension: (function(ctx) { + var ext = ctx.getExtension("WEBGL_draw_buffers"); + if (ext) { + ctx["drawBuffers"] = (function(n, bufs) { + ext["drawBuffersWEBGL"](n, bufs); + }); + } + }), + initExtensions: (function(context) { + if (!context) context = GL.currentContext; + if (context.initExtensionsDone) return; + context.initExtensionsDone = true; + var GLctx = context.GLctx; + if (context.version < 2) { + GL.acquireInstancedArraysExtension(GLctx); + GL.acquireVertexArrayObjectExtension(GLctx); + GL.acquireDrawBuffersExtension(GLctx); + } + GLctx.disjointTimerQueryExt = GLctx.getExtension("EXT_disjoint_timer_query"); + var automaticallyEnabledExtensions = [ "OES_texture_float", "OES_texture_half_float", "OES_standard_derivatives", "OES_vertex_array_object", "WEBGL_compressed_texture_s3tc", "WEBGL_depth_texture", "OES_element_index_uint", "EXT_texture_filter_anisotropic", "EXT_frag_depth", "WEBGL_draw_buffers", "ANGLE_instanced_arrays", "OES_texture_float_linear", "OES_texture_half_float_linear", "EXT_blend_minmax", "EXT_shader_texture_lod", "WEBGL_compressed_texture_pvrtc", "EXT_color_buffer_half_float", "WEBGL_color_buffer_float", "EXT_sRGB", "WEBGL_compressed_texture_etc1", "EXT_disjoint_timer_query", "WEBGL_compressed_texture_etc", "WEBGL_compressed_texture_astc", "EXT_color_buffer_float", "WEBGL_compressed_texture_s3tc_srgb", "EXT_disjoint_timer_query_webgl2", "WEBKIT_WEBGL_compressed_texture_pvrtc" ]; + function shouldEnableAutomatically(extension) { + var ret = false; + automaticallyEnabledExtensions.forEach((function(include) { + if (extension.indexOf(include) != -1) { + ret = true; } - Module["_time"] = _time; - - function _times(buffer) { - // clock_t times(struct tms *buffer); - // http://pubs.opengroup.org/onlinepubs/009695399/functions/times.html - // NOTE: This is fake, since we can't calculate real CPU time usage in JS. - if (buffer !== 0) { - _memset(buffer, 0, 16); - } - return 0; + })); + return ret; + } + var exts = GLctx.getSupportedExtensions() || []; + exts.forEach((function(ext) { + if (automaticallyEnabledExtensions.indexOf(ext) != -1) { + GLctx.getExtension(ext); + } + })); + }), + populateUniformTable: (function(program) { + var p = GL.programs[program]; + var ptable = GL.programInfos[program] = { + uniforms: {}, + maxUniformLength: 0, + maxAttributeLength: -1, + maxUniformBlockNameLength: -1 + }; + var utable = ptable.uniforms; + var numUniforms = GLctx.getProgramParameter(p, 35718); + for (var i = 0; i < numUniforms; ++i) { + var u = GLctx.getActiveUniform(p, i); + var name = u.name; + ptable.maxUniformLength = Math.max(ptable.maxUniformLength, name.length + 1); + if (name.slice(-1) == "]") { + name = name.slice(0, name.lastIndexOf("[")); + } + var loc = GLctx.getUniformLocation(p, name); + if (loc) { + var id = GL.getNewId(GL.uniforms); + utable[name] = [ u.size, id ]; + GL.uniforms[id] = loc; + for (var j = 1; j < u.size; ++j) { + var n = name + "[" + j + "]"; + loc = GLctx.getUniformLocation(p, n); + id = GL.getNewId(GL.uniforms); + GL.uniforms[id] = loc; } - Module["_times"] = _times; -if (!ENVIRONMENT_IS_PTHREAD) PThread.initMainThreadBlock(); else PThread.initWorker();; -if (ENVIRONMENT_IS_NODE) { - _emscripten_get_now = function _emscripten_get_now_actual() { - var t = process['hrtime'](); - return t[0] * 1e3 + t[1] / 1e6; - }; - } else if (ENVIRONMENT_IS_PTHREAD) { - _emscripten_get_now = function() { return performance['now']() - __performance_now_clock_drift; }; - } else if (typeof dateNow !== 'undefined') { - _emscripten_get_now = dateNow; - } else if (typeof performance === 'object' && performance && typeof performance['now'] === 'function') { - _emscripten_get_now = function() { return performance['now'](); }; - } else { - _emscripten_get_now = Date.now; + } + } + }) +}; +Module["GL"] = GL; +function _emscripten_webgl_do_create_context(target, attributes) { + assert(attributes); + var contextAttributes = {}; + var a = attributes >> 2; + contextAttributes["alpha"] = !!GROWABLE_HEAP_LOAD_I32((a + (0 >> 2)) * 4 | 0); + contextAttributes["depth"] = !!GROWABLE_HEAP_LOAD_I32((a + (4 >> 2)) * 4 | 0); + contextAttributes["stencil"] = !!GROWABLE_HEAP_LOAD_I32((a + (8 >> 2)) * 4 | 0); + contextAttributes["antialias"] = !!GROWABLE_HEAP_LOAD_I32((a + (12 >> 2)) * 4 | 0); + contextAttributes["premultipliedAlpha"] = !!GROWABLE_HEAP_LOAD_I32((a + (16 >> 2)) * 4 | 0); + contextAttributes["preserveDrawingBuffer"] = !!GROWABLE_HEAP_LOAD_I32((a + (20 >> 2)) * 4 | 0); + var powerPreference = GROWABLE_HEAP_LOAD_I32((a + (24 >> 2)) * 4 | 0); + contextAttributes["powerPreference"] = __emscripten_webgl_power_preferences[powerPreference]; + contextAttributes["failIfMajorPerformanceCaveat"] = !!GROWABLE_HEAP_LOAD_I32((a + (28 >> 2)) * 4 | 0); + contextAttributes.majorVersion = GROWABLE_HEAP_LOAD_I32((a + (32 >> 2)) * 4 | 0); + contextAttributes.minorVersion = GROWABLE_HEAP_LOAD_I32((a + (36 >> 2)) * 4 | 0); + contextAttributes.enableExtensionsByDefault = GROWABLE_HEAP_LOAD_I32((a + (40 >> 2)) * 4 | 0); + contextAttributes.explicitSwapControl = GROWABLE_HEAP_LOAD_I32((a + (44 >> 2)) * 4 | 0); + contextAttributes.proxyContextToMainThread = GROWABLE_HEAP_LOAD_I32((a + (48 >> 2)) * 4 | 0); + contextAttributes.renderViaOffscreenBackBuffer = GROWABLE_HEAP_LOAD_I32((a + (52 >> 2)) * 4 | 0); + var canvas = __findCanvasEventTarget(target); + if (!canvas) { + return 0; + } + if (contextAttributes.explicitSwapControl) { + return 0; + } + var contextHandle = GL.createContext(canvas, contextAttributes); + return contextHandle; +} +Module["_emscripten_webgl_do_create_context"] = _emscripten_webgl_do_create_context; +function _emscripten_webgl_create_context(a0, a1) { + return _emscripten_webgl_do_create_context(a0, a1); +} +Module["_emscripten_webgl_create_context"] = _emscripten_webgl_create_context; +var ENV = {}; +Module["ENV"] = ENV; +function _emscripten_get_environ() { + if (!_emscripten_get_environ.strings) { + var env = { + "USER": "web_user", + "LOGNAME": "web_user", + "PATH": "/", + "PWD": "/", + "HOME": "/home/web_user", + "LANG": (typeof navigator === "object" && navigator.languages && navigator.languages[0] || "C").replace("-", "_") + ".UTF-8", + "_": thisProgram }; -FS.staticInit();; -if (ENVIRONMENT_HAS_NODE) { var fs = require("fs"); var NODEJS_PATH = require("path"); NODEFS.staticInit(); }; -var GLctx; GL.init(); - - // proxiedFunctionTable specifies the list of functions that can be called either synchronously or asynchronously from other threads in postMessage()d or internally queued events. This way a pthread in a Worker can synchronously access e.g. the DOM on the main thread. - -var proxiedFunctionTable = [null,_atexit,___syscall10,___syscall12,___syscall183,___syscall192,___syscall195,___syscall196,___syscall220,___syscall221,___syscall3,___syscall39,___syscall4,___syscall40,___syscall5,___syscall54,___syscall85,___syscall91,_emscripten_set_canvas_element_size_main_thread,_fd_close,_fd_read,_fd_seek,_fd_write,_tzset,_sysconf]; - + for (var x in ENV) { + env[x] = ENV[x]; + } + var strings = []; + for (var x in env) { + strings.push(x + "=" + env[x]); + } + _emscripten_get_environ.strings = strings; + } + return _emscripten_get_environ.strings; +} +Module["_emscripten_get_environ"] = _emscripten_get_environ; +function _environ_get(__environ, environ_buf) { + var strings = _emscripten_get_environ(); + var bufSize = 0; + strings.forEach((function(string, i) { + var ptr = environ_buf + bufSize; + GROWABLE_HEAP_STORE_I32(__environ + i * 4 | 0, ptr); + writeAsciiToMemory(string, ptr); + bufSize += string.length + 1; + })); + return 0; +} +Module["_environ_get"] = _environ_get; +function _environ_sizes_get(penviron_count, penviron_buf_size) { + var strings = _emscripten_get_environ(); + GROWABLE_HEAP_STORE_I32(penviron_count | 0, strings.length); + var bufSize = 0; + strings.forEach((function(string) { + bufSize += string.length + 1; + })); + GROWABLE_HEAP_STORE_I32(penviron_buf_size | 0, bufSize); + return 0; +} +Module["_environ_sizes_get"] = _environ_sizes_get; +function _exit(status) { + exit(status); +} +Module["_exit"] = _exit; +function _fd_close(fd) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(19, 1, fd); + try { + var stream = SYSCALLS.getStreamFromFD(fd); + FS.close(stream); + return 0; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return e.errno; + } +} +Module["_fd_close"] = _fd_close; +function _fd_read(fd, iov, iovcnt, pnum) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(20, 1, fd, iov, iovcnt, pnum); + try { + var stream = SYSCALLS.getStreamFromFD(fd); + var num = SYSCALLS.doReadv(stream, iov, iovcnt); + GROWABLE_HEAP_STORE_I32(pnum | 0, num); + return 0; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return e.errno; + } +} +Module["_fd_read"] = _fd_read; +function _fd_seek(fd, offset_low, offset_high, whence, newOffset) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(21, 1, fd, offset_low, offset_high, whence, newOffset); + try { + var stream = SYSCALLS.getStreamFromFD(fd); + var HIGH_OFFSET = 4294967296; + var offset = offset_high * HIGH_OFFSET + (offset_low >>> 0); + var DOUBLE_LIMIT = 9007199254740992; + if (offset <= -DOUBLE_LIMIT || offset >= DOUBLE_LIMIT) { + return -61; + } + FS.llseek(stream, offset, whence); + tempI64 = [ stream.position >>> 0, (tempDouble = stream.position, +Math_abs(tempDouble) >= 1 ? tempDouble > 0 ? (Math_min(+Math_floor(tempDouble / 4294967296), 4294967295) | 0) >>> 0 : ~~+Math_ceil((tempDouble - +(~~tempDouble >>> 0)) / 4294967296) >>> 0 : 0) ], GROWABLE_HEAP_STORE_I32(newOffset | 0, tempI64[0]), GROWABLE_HEAP_STORE_I32(newOffset + 4 | 0, tempI64[1]); + if (stream.getdents && offset === 0 && whence === 0) stream.getdents = null; + return 0; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return e.errno; + } +} +Module["_fd_seek"] = _fd_seek; +function _fd_write(fd, iov, iovcnt, pnum) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(22, 1, fd, iov, iovcnt, pnum); + try { + var stream = SYSCALLS.getStreamFromFD(fd); + var num = SYSCALLS.doWritev(stream, iov, iovcnt); + GROWABLE_HEAP_STORE_I32(pnum | 0, num); + return 0; + } catch (e) { + if (typeof FS === "undefined" || !(e instanceof FS.ErrnoError)) abort(e); + return e.errno; + } +} +Module["_fd_write"] = _fd_write; +function _getTempRet0() { + return getTempRet0() | 0; +} +Module["_getTempRet0"] = _getTempRet0; +function _gettimeofday(ptr) { + var now = Date.now(); + GROWABLE_HEAP_STORE_I32(ptr | 0, now / 1e3 | 0); + GROWABLE_HEAP_STORE_I32(ptr + 4 | 0, now % 1e3 * 1e3 | 0); + return 0; +} +Module["_gettimeofday"] = _gettimeofday; +var ___tm_current = 12594976; +Module["___tm_current"] = ___tm_current; +var ___tm_timezone = (stringToUTF8("GMT", 12595024, 4), 12595024); +Module["___tm_timezone"] = ___tm_timezone; +function _gmtime_r(time, tmPtr) { + var date = new Date(GROWABLE_HEAP_LOAD_I32(time | 0) * 1e3); + GROWABLE_HEAP_STORE_I32(tmPtr | 0, date.getUTCSeconds()); + GROWABLE_HEAP_STORE_I32(tmPtr + 4 | 0, date.getUTCMinutes()); + GROWABLE_HEAP_STORE_I32(tmPtr + 8 | 0, date.getUTCHours()); + GROWABLE_HEAP_STORE_I32(tmPtr + 12 | 0, date.getUTCDate()); + GROWABLE_HEAP_STORE_I32(tmPtr + 16 | 0, date.getUTCMonth()); + GROWABLE_HEAP_STORE_I32(tmPtr + 20 | 0, date.getUTCFullYear() - 1900); + GROWABLE_HEAP_STORE_I32(tmPtr + 24 | 0, date.getUTCDay()); + GROWABLE_HEAP_STORE_I32(tmPtr + 36 | 0, 0); + GROWABLE_HEAP_STORE_I32(tmPtr + 32 | 0, 0); + var start = Date.UTC(date.getUTCFullYear(), 0, 1, 0, 0, 0, 0); + var yday = (date.getTime() - start) / (1e3 * 60 * 60 * 24) | 0; + GROWABLE_HEAP_STORE_I32(tmPtr + 28 | 0, yday); + GROWABLE_HEAP_STORE_I32(tmPtr + 40 | 0, ___tm_timezone); + return tmPtr; +} +Module["_gmtime_r"] = _gmtime_r; +function _gmtime(time) { + return _gmtime_r(time, ___tm_current); +} +Module["_gmtime"] = _gmtime; +function _memcpy(dest, src, num) { + dest = dest | 0; + src = src | 0; + num = num | 0; + var ret = 0; + var aligned_dest_end = 0; + var block_aligned_dest_end = 0; + var dest_end = 0; + if ((num | 0) >= 8192) { + _emscripten_memcpy_big(dest | 0, src | 0, num | 0) | 0; + return dest | 0; + } + ret = dest | 0; + dest_end = dest + num | 0; + if ((dest & 3) == (src & 3)) { + while (dest & 3) { + if ((num | 0) == 0) return ret | 0; + GROWABLE_HEAP_STORE_I8(dest >> 0 | 0, GROWABLE_HEAP_LOAD_I8(src >> 0 | 0) | 0); + dest = dest + 1 | 0; + src = src + 1 | 0; + num = num - 1 | 0; + } + aligned_dest_end = dest_end & -4 | 0; + block_aligned_dest_end = aligned_dest_end - 64 | 0; + while ((dest | 0) <= (block_aligned_dest_end | 0)) { + GROWABLE_HEAP_STORE_I32(dest | 0, GROWABLE_HEAP_LOAD_I32(src | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 4 | 0, GROWABLE_HEAP_LOAD_I32(src + 4 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 8 | 0, GROWABLE_HEAP_LOAD_I32(src + 8 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 12 | 0, GROWABLE_HEAP_LOAD_I32(src + 12 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 16 | 0, GROWABLE_HEAP_LOAD_I32(src + 16 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 20 | 0, GROWABLE_HEAP_LOAD_I32(src + 20 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 24 | 0, GROWABLE_HEAP_LOAD_I32(src + 24 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 28 | 0, GROWABLE_HEAP_LOAD_I32(src + 28 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 32 | 0, GROWABLE_HEAP_LOAD_I32(src + 32 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 36 | 0, GROWABLE_HEAP_LOAD_I32(src + 36 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 40 | 0, GROWABLE_HEAP_LOAD_I32(src + 40 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 44 | 0, GROWABLE_HEAP_LOAD_I32(src + 44 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 48 | 0, GROWABLE_HEAP_LOAD_I32(src + 48 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 52 | 0, GROWABLE_HEAP_LOAD_I32(src + 52 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 56 | 0, GROWABLE_HEAP_LOAD_I32(src + 56 | 0) | 0); + GROWABLE_HEAP_STORE_I32(dest + 60 | 0, GROWABLE_HEAP_LOAD_I32(src + 60 | 0) | 0); + dest = dest + 64 | 0; + src = src + 64 | 0; + } + while ((dest | 0) < (aligned_dest_end | 0)) { + GROWABLE_HEAP_STORE_I32(dest | 0, GROWABLE_HEAP_LOAD_I32(src | 0) | 0); + dest = dest + 4 | 0; + src = src + 4 | 0; + } + } else { + aligned_dest_end = dest_end - 4 | 0; + while ((dest | 0) < (aligned_dest_end | 0)) { + GROWABLE_HEAP_STORE_I8(dest >> 0 | 0, GROWABLE_HEAP_LOAD_I8(src >> 0 | 0) | 0); + GROWABLE_HEAP_STORE_I8(dest + 1 >> 0 | 0, GROWABLE_HEAP_LOAD_I8(src + 1 >> 0 | 0) | 0); + GROWABLE_HEAP_STORE_I8(dest + 2 >> 0 | 0, GROWABLE_HEAP_LOAD_I8(src + 2 >> 0 | 0) | 0); + GROWABLE_HEAP_STORE_I8(dest + 3 >> 0 | 0, GROWABLE_HEAP_LOAD_I8(src + 3 >> 0 | 0) | 0); + dest = dest + 4 | 0; + src = src + 4 | 0; + } + } + while ((dest | 0) < (dest_end | 0)) { + GROWABLE_HEAP_STORE_I8(dest >> 0 | 0, GROWABLE_HEAP_LOAD_I8(src >> 0 | 0) | 0); + dest = dest + 1 | 0; + src = src + 1 | 0; + } + return ret | 0; +} +Module["_memcpy"] = _memcpy; +function _tzset() { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(23, 1); + if (_tzset.called) return; + _tzset.called = true; + GROWABLE_HEAP_STORE_I32(__get_timezone() | 0, (new Date).getTimezoneOffset() * 60); + var currentYear = (new Date).getFullYear(); + var winter = new Date(currentYear, 0, 1); + var summer = new Date(currentYear, 6, 1); + GROWABLE_HEAP_STORE_I32(__get_daylight() | 0, Number(winter.getTimezoneOffset() != summer.getTimezoneOffset())); + function extractZone(date) { + var match = date.toTimeString().match(/\(([A-Za-z ]+)\)$/); + return match ? match[1] : "GMT"; + } + var winterName = extractZone(winter); + var summerName = extractZone(summer); + var winterNamePtr = allocate(intArrayFromString(winterName), "i8", ALLOC_NORMAL); + var summerNamePtr = allocate(intArrayFromString(summerName), "i8", ALLOC_NORMAL); + if (summer.getTimezoneOffset() < winter.getTimezoneOffset()) { + GROWABLE_HEAP_STORE_I32(__get_tzname() | 0, winterNamePtr); + GROWABLE_HEAP_STORE_I32(__get_tzname() + 4 | 0, summerNamePtr); + } else { + GROWABLE_HEAP_STORE_I32(__get_tzname() | 0, summerNamePtr); + GROWABLE_HEAP_STORE_I32(__get_tzname() + 4 | 0, winterNamePtr); + } +} +Module["_tzset"] = _tzset; +function _mktime(tmPtr) { + _tzset(); + var date = new Date(GROWABLE_HEAP_LOAD_I32(tmPtr + 20 | 0) + 1900, GROWABLE_HEAP_LOAD_I32(tmPtr + 16 | 0), GROWABLE_HEAP_LOAD_I32(tmPtr + 12 | 0), GROWABLE_HEAP_LOAD_I32(tmPtr + 8 | 0), GROWABLE_HEAP_LOAD_I32(tmPtr + 4 | 0), GROWABLE_HEAP_LOAD_I32(tmPtr | 0), 0); + var dst = GROWABLE_HEAP_LOAD_I32(tmPtr + 32 | 0); + var guessedOffset = date.getTimezoneOffset(); + var start = new Date(date.getFullYear(), 0, 1); + var summerOffset = (new Date(date.getFullYear(), 6, 1)).getTimezoneOffset(); + var winterOffset = start.getTimezoneOffset(); + var dstOffset = Math.min(winterOffset, summerOffset); + if (dst < 0) { + GROWABLE_HEAP_STORE_I32(tmPtr + 32 | 0, Number(summerOffset != winterOffset && dstOffset == guessedOffset)); + } else if (dst > 0 != (dstOffset == guessedOffset)) { + var nonDstOffset = Math.max(winterOffset, summerOffset); + var trueOffset = dst > 0 ? dstOffset : nonDstOffset; + date.setTime(date.getTime() + (trueOffset - guessedOffset) * 6e4); + } + GROWABLE_HEAP_STORE_I32(tmPtr + 24 | 0, date.getDay()); + var yday = (date.getTime() - start.getTime()) / (1e3 * 60 * 60 * 24) | 0; + GROWABLE_HEAP_STORE_I32(tmPtr + 28 | 0, yday); + return date.getTime() / 1e3 | 0; +} +Module["_mktime"] = _mktime; +function _pthread_cleanup_pop(execute) { + var routine = PThread.exitHandlers.pop(); + if (execute) routine(); +} +Module["_pthread_cleanup_pop"] = _pthread_cleanup_pop; +function _pthread_cleanup_push(routine, arg) { + if (PThread.exitHandlers === null) { + PThread.exitHandlers = []; + if (!ENVIRONMENT_IS_PTHREAD) { + __ATEXIT__.push((function() { + PThread.runExitHandlers(); + })); + } + } + PThread.exitHandlers.push((function() { + dynCall_vi(routine, arg); + })); +} +Module["_pthread_cleanup_push"] = _pthread_cleanup_push; +function __spawn_thread(threadParams) { + if (ENVIRONMENT_IS_PTHREAD) throw "Internal Error! _spawn_thread() can only ever be called from main application thread!"; + var worker = PThread.getNewWorker(); + if (worker.pthread !== undefined) throw "Internal error!"; + if (!threadParams.pthread_ptr) throw "Internal error, no pthread ptr!"; + PThread.runningWorkers.push(worker); + var tlsMemory = _malloc(128 * 4); + for (var i = 0; i < 128; ++i) { + GROWABLE_HEAP_STORE_I32(tlsMemory + i * 4 | 0, 0); + } + var stackHigh = threadParams.stackBase + threadParams.stackSize; + var pthread = PThread.pthreads[threadParams.pthread_ptr] = { + worker: worker, + stackBase: threadParams.stackBase, + stackSize: threadParams.stackSize, + allocatedOwnStack: threadParams.allocatedOwnStack, + thread: threadParams.pthread_ptr, + threadInfoStruct: threadParams.pthread_ptr + }; + Atomics.store(HEAPU32, pthread.threadInfoStruct + 0 >> 2, 0); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 4 >> 2, 0); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 20 >> 2, 0); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 80 >> 2, threadParams.detached); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 116 >> 2, tlsMemory); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 60 >> 2, 0); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 52 >> 2, pthread.threadInfoStruct); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 56 >> 2, PROCINFO.pid); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 120 >> 2, threadParams.stackSize); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 96 >> 2, threadParams.stackSize); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 92 >> 2, stackHigh); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 120 + 8 >> 2, stackHigh); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 120 + 12 >> 2, threadParams.detached); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 120 + 20 >> 2, threadParams.schedPolicy); + Atomics.store(HEAPU32, pthread.threadInfoStruct + 120 + 24 >> 2, threadParams.schedPrio); + var global_libc = _emscripten_get_global_libc(); + var global_locale = global_libc + 40; + Atomics.store(HEAPU32, pthread.threadInfoStruct + 188 >> 2, global_locale); + worker.pthread = pthread; + var msg = { + "cmd": "run", + "start_routine": threadParams.startRoutine, + "arg": threadParams.arg, + "threadInfoStruct": threadParams.pthread_ptr, + "selfThreadId": threadParams.pthread_ptr, + "parentThreadId": threadParams.parent_pthread_ptr, + "stackBase": threadParams.stackBase, + "stackSize": threadParams.stackSize + }; + worker.runPthread = (function() { + msg.time = performance.now(); + worker.postMessage(msg, threadParams.transferList); + }); + if (worker.loaded) { + worker.runPthread(); + delete worker.runPthread; + } +} +Module["__spawn_thread"] = __spawn_thread; +function _pthread_getschedparam(thread, policy, schedparam) { + if (!policy && !schedparam) return ERRNO_CODES.EINVAL; + if (!thread) { + err("pthread_getschedparam called with a null thread pointer!"); + return ERRNO_CODES.ESRCH; + } + var self = GROWABLE_HEAP_LOAD_I32(thread + 24 | 0); + if (self !== thread) { + err("pthread_getschedparam attempted on thread " + thread + ", which does not point to a valid thread, or does not exist anymore!"); + return ERRNO_CODES.ESRCH; + } + var schedPolicy = Atomics.load(HEAPU32, thread + 120 + 20 >> 2); + var schedPrio = Atomics.load(HEAPU32, thread + 120 + 24 >> 2); + if (policy) GROWABLE_HEAP_STORE_I32(policy | 0, schedPolicy); + if (schedparam) GROWABLE_HEAP_STORE_I32(schedparam | 0, schedPrio); + return 0; +} +Module["_pthread_getschedparam"] = _pthread_getschedparam; +function _pthread_self() { + return __pthread_ptr | 0; +} +Module["_pthread_self"] = _pthread_self; +function _pthread_create(pthread_ptr, attr, start_routine, arg) { + if (typeof SharedArrayBuffer === "undefined") { + err("Current environment does not support SharedArrayBuffer, pthreads are not available!"); + return 6; + } + if (!pthread_ptr) { + err("pthread_create called with a null thread pointer!"); + return 28; + } + var transferList = []; + var error = 0; + if (ENVIRONMENT_IS_PTHREAD && (transferList.length === 0 || error)) { + return _emscripten_sync_run_in_main_thread_4(687865856, pthread_ptr, attr, start_routine, arg); + } + if (error) return error; + var stackSize = 0; + var stackBase = 0; + var detached = 0; + var schedPolicy = 0; + var schedPrio = 0; + if (attr) { + stackSize = GROWABLE_HEAP_LOAD_I32(attr | 0); + stackSize += 81920; + stackBase = GROWABLE_HEAP_LOAD_I32(attr + 8 | 0); + detached = GROWABLE_HEAP_LOAD_I32(attr + 12 | 0) !== 0; + var inheritSched = GROWABLE_HEAP_LOAD_I32(attr + 16 | 0) === 0; + if (inheritSched) { + var prevSchedPolicy = GROWABLE_HEAP_LOAD_I32(attr + 20 | 0); + var prevSchedPrio = GROWABLE_HEAP_LOAD_I32(attr + 24 | 0); + var parentThreadPtr = PThread.currentProxiedOperationCallerThread ? PThread.currentProxiedOperationCallerThread : _pthread_self(); + _pthread_getschedparam(parentThreadPtr, attr + 20, attr + 24); + schedPolicy = GROWABLE_HEAP_LOAD_I32(attr + 20 | 0); + schedPrio = GROWABLE_HEAP_LOAD_I32(attr + 24 | 0); + GROWABLE_HEAP_STORE_I32(attr + 20 | 0, prevSchedPolicy); + GROWABLE_HEAP_STORE_I32(attr + 24 | 0, prevSchedPrio); + } else { + schedPolicy = GROWABLE_HEAP_LOAD_I32(attr + 20 | 0); + schedPrio = GROWABLE_HEAP_LOAD_I32(attr + 24 | 0); + } + } else { + stackSize = 2097152; + } + var allocatedOwnStack = stackBase == 0; + if (allocatedOwnStack) { + stackBase = _memalign(16, stackSize); + } else { + stackBase -= stackSize; + assert(stackBase > 0); + } + var threadInfoStruct = _malloc(244); + for (var i = 0; i < 244 >> 2; ++i) GROWABLE_HEAP_STORE_I32(((threadInfoStruct >> 2) + i) * 4 | 0, 0); + GROWABLE_HEAP_STORE_I32(pthread_ptr | 0, threadInfoStruct); + GROWABLE_HEAP_STORE_I32(threadInfoStruct + 24 | 0, threadInfoStruct); + var headPtr = threadInfoStruct + 168; + GROWABLE_HEAP_STORE_I32(headPtr | 0, headPtr); + var threadParams = { + stackBase: stackBase, + stackSize: stackSize, + allocatedOwnStack: allocatedOwnStack, + schedPolicy: schedPolicy, + schedPrio: schedPrio, + detached: detached, + startRoutine: start_routine, + pthread_ptr: threadInfoStruct, + parent_pthread_ptr: _pthread_self(), + arg: arg, + transferList: transferList + }; + if (ENVIRONMENT_IS_PTHREAD) { + threadParams.cmd = "spawnThread"; + postMessage(threadParams, transferList); + } else { + __spawn_thread(threadParams); + } + return 0; +} +Module["_pthread_create"] = _pthread_create; +function _setTempRet0($i) { + setTempRet0($i | 0); +} +Module["_setTempRet0"] = _setTempRet0; +function __isLeapYear(year) { + return year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0); +} +Module["__isLeapYear"] = __isLeapYear; +function __arraySum(array, index) { + var sum = 0; + for (var i = 0; i <= index; sum += array[i++]) ; + return sum; +} +Module["__arraySum"] = __arraySum; +var __MONTH_DAYS_LEAP = [ 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 ]; +Module["__MONTH_DAYS_LEAP"] = __MONTH_DAYS_LEAP; +var __MONTH_DAYS_REGULAR = [ 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 ]; +Module["__MONTH_DAYS_REGULAR"] = __MONTH_DAYS_REGULAR; +function __addDays(date, days) { + var newDate = new Date(date.getTime()); + while (days > 0) { + var leap = __isLeapYear(newDate.getFullYear()); + var currentMonth = newDate.getMonth(); + var daysInCurrentMonth = (leap ? __MONTH_DAYS_LEAP : __MONTH_DAYS_REGULAR)[currentMonth]; + if (days > daysInCurrentMonth - newDate.getDate()) { + days -= daysInCurrentMonth - newDate.getDate() + 1; + newDate.setDate(1); + if (currentMonth < 11) { + newDate.setMonth(currentMonth + 1); + } else { + newDate.setMonth(0); + newDate.setFullYear(newDate.getFullYear() + 1); + } + } else { + newDate.setDate(newDate.getDate() + days); + return newDate; + } + } + return newDate; +} +Module["__addDays"] = __addDays; +function _strftime(s, maxsize, format, tm) { + var tm_zone = GROWABLE_HEAP_LOAD_I32(tm + 40 | 0); + var date = { + tm_sec: GROWABLE_HEAP_LOAD_I32(tm | 0), + tm_min: GROWABLE_HEAP_LOAD_I32(tm + 4 | 0), + tm_hour: GROWABLE_HEAP_LOAD_I32(tm + 8 | 0), + tm_mday: GROWABLE_HEAP_LOAD_I32(tm + 12 | 0), + tm_mon: GROWABLE_HEAP_LOAD_I32(tm + 16 | 0), + tm_year: GROWABLE_HEAP_LOAD_I32(tm + 20 | 0), + tm_wday: GROWABLE_HEAP_LOAD_I32(tm + 24 | 0), + tm_yday: GROWABLE_HEAP_LOAD_I32(tm + 28 | 0), + tm_isdst: GROWABLE_HEAP_LOAD_I32(tm + 32 | 0), + tm_gmtoff: GROWABLE_HEAP_LOAD_I32(tm + 36 | 0), + tm_zone: tm_zone ? UTF8ToString(tm_zone) : "" + }; + var pattern = UTF8ToString(format); + var EXPANSION_RULES_1 = { + "%c": "%a %b %d %H:%M:%S %Y", + "%D": "%m/%d/%y", + "%F": "%Y-%m-%d", + "%h": "%b", + "%r": "%I:%M:%S %p", + "%R": "%H:%M", + "%T": "%H:%M:%S", + "%x": "%m/%d/%y", + "%X": "%H:%M:%S", + "%Ec": "%c", + "%EC": "%C", + "%Ex": "%m/%d/%y", + "%EX": "%H:%M:%S", + "%Ey": "%y", + "%EY": "%Y", + "%Od": "%d", + "%Oe": "%e", + "%OH": "%H", + "%OI": "%I", + "%Om": "%m", + "%OM": "%M", + "%OS": "%S", + "%Ou": "%u", + "%OU": "%U", + "%OV": "%V", + "%Ow": "%w", + "%OW": "%W", + "%Oy": "%y" + }; + for (var rule in EXPANSION_RULES_1) { + pattern = pattern.replace(new RegExp(rule, "g"), EXPANSION_RULES_1[rule]); + } + var WEEKDAYS = [ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" ]; + var MONTHS = [ "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ]; + function leadingSomething(value, digits, character) { + var str = typeof value === "number" ? value.toString() : value || ""; + while (str.length < digits) { + str = character[0] + str; + } + return str; + } + function leadingNulls(value, digits) { + return leadingSomething(value, digits, "0"); + } + function compareByDay(date1, date2) { + function sgn(value) { + return value < 0 ? -1 : value > 0 ? 1 : 0; + } + var compare; + if ((compare = sgn(date1.getFullYear() - date2.getFullYear())) === 0) { + if ((compare = sgn(date1.getMonth() - date2.getMonth())) === 0) { + compare = sgn(date1.getDate() - date2.getDate()); + } + } + return compare; + } + function getFirstWeekStartDate(janFourth) { + switch (janFourth.getDay()) { + case 0: + return new Date(janFourth.getFullYear() - 1, 11, 29); + case 1: + return janFourth; + case 2: + return new Date(janFourth.getFullYear(), 0, 3); + case 3: + return new Date(janFourth.getFullYear(), 0, 2); + case 4: + return new Date(janFourth.getFullYear(), 0, 1); + case 5: + return new Date(janFourth.getFullYear() - 1, 11, 31); + case 6: + return new Date(janFourth.getFullYear() - 1, 11, 30); + } + } + function getWeekBasedYear(date) { + var thisDate = __addDays(new Date(date.tm_year + 1900, 0, 1), date.tm_yday); + var janFourthThisYear = new Date(thisDate.getFullYear(), 0, 4); + var janFourthNextYear = new Date(thisDate.getFullYear() + 1, 0, 4); + var firstWeekStartThisYear = getFirstWeekStartDate(janFourthThisYear); + var firstWeekStartNextYear = getFirstWeekStartDate(janFourthNextYear); + if (compareByDay(firstWeekStartThisYear, thisDate) <= 0) { + if (compareByDay(firstWeekStartNextYear, thisDate) <= 0) { + return thisDate.getFullYear() + 1; + } else { + return thisDate.getFullYear(); + } + } else { + return thisDate.getFullYear() - 1; + } + } + var EXPANSION_RULES_2 = { + "%a": (function(date) { + return WEEKDAYS[date.tm_wday].substring(0, 3); + }), + "%A": (function(date) { + return WEEKDAYS[date.tm_wday]; + }), + "%b": (function(date) { + return MONTHS[date.tm_mon].substring(0, 3); + }), + "%B": (function(date) { + return MONTHS[date.tm_mon]; + }), + "%C": (function(date) { + var year = date.tm_year + 1900; + return leadingNulls(year / 100 | 0, 2); + }), + "%d": (function(date) { + return leadingNulls(date.tm_mday, 2); + }), + "%e": (function(date) { + return leadingSomething(date.tm_mday, 2, " "); + }), + "%g": (function(date) { + return getWeekBasedYear(date).toString().substring(2); + }), + "%G": (function(date) { + return getWeekBasedYear(date); + }), + "%H": (function(date) { + return leadingNulls(date.tm_hour, 2); + }), + "%I": (function(date) { + var twelveHour = date.tm_hour; + if (twelveHour == 0) twelveHour = 12; else if (twelveHour > 12) twelveHour -= 12; + return leadingNulls(twelveHour, 2); + }), + "%j": (function(date) { + return leadingNulls(date.tm_mday + __arraySum(__isLeapYear(date.tm_year + 1900) ? __MONTH_DAYS_LEAP : __MONTH_DAYS_REGULAR, date.tm_mon - 1), 3); + }), + "%m": (function(date) { + return leadingNulls(date.tm_mon + 1, 2); + }), + "%M": (function(date) { + return leadingNulls(date.tm_min, 2); + }), + "%n": (function() { + return "\n"; + }), + "%p": (function(date) { + if (date.tm_hour >= 0 && date.tm_hour < 12) { + return "AM"; + } else { + return "PM"; + } + }), + "%S": (function(date) { + return leadingNulls(date.tm_sec, 2); + }), + "%t": (function() { + return "\t"; + }), + "%u": (function(date) { + return date.tm_wday || 7; + }), + "%U": (function(date) { + var janFirst = new Date(date.tm_year + 1900, 0, 1); + var firstSunday = janFirst.getDay() === 0 ? janFirst : __addDays(janFirst, 7 - janFirst.getDay()); + var endDate = new Date(date.tm_year + 1900, date.tm_mon, date.tm_mday); + if (compareByDay(firstSunday, endDate) < 0) { + var februaryFirstUntilEndMonth = __arraySum(__isLeapYear(endDate.getFullYear()) ? __MONTH_DAYS_LEAP : __MONTH_DAYS_REGULAR, endDate.getMonth() - 1) - 31; + var firstSundayUntilEndJanuary = 31 - firstSunday.getDate(); + var days = firstSundayUntilEndJanuary + februaryFirstUntilEndMonth + endDate.getDate(); + return leadingNulls(Math.ceil(days / 7), 2); + } + return compareByDay(firstSunday, janFirst) === 0 ? "01" : "00"; + }), + "%V": (function(date) { + var janFourthThisYear = new Date(date.tm_year + 1900, 0, 4); + var janFourthNextYear = new Date(date.tm_year + 1901, 0, 4); + var firstWeekStartThisYear = getFirstWeekStartDate(janFourthThisYear); + var firstWeekStartNextYear = getFirstWeekStartDate(janFourthNextYear); + var endDate = __addDays(new Date(date.tm_year + 1900, 0, 1), date.tm_yday); + if (compareByDay(endDate, firstWeekStartThisYear) < 0) { + return "53"; + } + if (compareByDay(firstWeekStartNextYear, endDate) <= 0) { + return "01"; + } + var daysDifference; + if (firstWeekStartThisYear.getFullYear() < date.tm_year + 1900) { + daysDifference = date.tm_yday + 32 - firstWeekStartThisYear.getDate(); + } else { + daysDifference = date.tm_yday + 1 - firstWeekStartThisYear.getDate(); + } + return leadingNulls(Math.ceil(daysDifference / 7), 2); + }), + "%w": (function(date) { + return date.tm_wday; + }), + "%W": (function(date) { + var janFirst = new Date(date.tm_year, 0, 1); + var firstMonday = janFirst.getDay() === 1 ? janFirst : __addDays(janFirst, janFirst.getDay() === 0 ? 1 : 7 - janFirst.getDay() + 1); + var endDate = new Date(date.tm_year + 1900, date.tm_mon, date.tm_mday); + if (compareByDay(firstMonday, endDate) < 0) { + var februaryFirstUntilEndMonth = __arraySum(__isLeapYear(endDate.getFullYear()) ? __MONTH_DAYS_LEAP : __MONTH_DAYS_REGULAR, endDate.getMonth() - 1) - 31; + var firstMondayUntilEndJanuary = 31 - firstMonday.getDate(); + var days = firstMondayUntilEndJanuary + februaryFirstUntilEndMonth + endDate.getDate(); + return leadingNulls(Math.ceil(days / 7), 2); + } + return compareByDay(firstMonday, janFirst) === 0 ? "01" : "00"; + }), + "%y": (function(date) { + return (date.tm_year + 1900).toString().substring(2); + }), + "%Y": (function(date) { + return date.tm_year + 1900; + }), + "%z": (function(date) { + var off = date.tm_gmtoff; + var ahead = off >= 0; + off = Math.abs(off) / 60; + off = off / 60 * 100 + off % 60; + return (ahead ? "+" : "-") + String("0000" + off).slice(-4); + }), + "%Z": (function(date) { + return date.tm_zone; + }), + "%%": (function() { + return "%"; + }) + }; + for (var rule in EXPANSION_RULES_2) { + if (pattern.indexOf(rule) >= 0) { + pattern = pattern.replace(new RegExp(rule, "g"), EXPANSION_RULES_2[rule](date)); + } + } + var bytes = intArrayFromString(pattern, false); + if (bytes.length > maxsize) { + return 0; + } + writeArrayToMemory(bytes, s); + return bytes.length - 1; +} +Module["_strftime"] = _strftime; +function _strftime_l(s, maxsize, format, tm) { + return _strftime(s, maxsize, format, tm); +} +Module["_strftime_l"] = _strftime_l; +function _sysconf(name) { + if (ENVIRONMENT_IS_PTHREAD) return _emscripten_proxy_to_main_thread_js(24, 1, name); + switch (name) { + case 30: + return PAGE_SIZE; + case 85: + var maxHeapSize = 2 * 1024 * 1024 * 1024 - 65536; + maxHeapSize = 1073741824; + return maxHeapSize / PAGE_SIZE; + case 132: + case 133: + case 12: + case 137: + case 138: + case 15: + case 235: + case 16: + case 17: + case 18: + case 19: + case 20: + case 149: + case 13: + case 10: + case 236: + case 153: + case 9: + case 21: + case 22: + case 159: + case 154: + case 14: + case 77: + case 78: + case 139: + case 80: + case 81: + case 82: + case 68: + case 67: + case 164: + case 11: + case 29: + case 47: + case 48: + case 95: + case 52: + case 51: + case 46: + return 200809; + case 79: + return 0; + case 27: + case 246: + case 127: + case 128: + case 23: + case 24: + case 160: + case 161: + case 181: + case 182: + case 242: + case 183: + case 184: + case 243: + case 244: + case 245: + case 165: + case 178: + case 179: + case 49: + case 50: + case 168: + case 169: + case 175: + case 170: + case 171: + case 172: + case 97: + case 76: + case 32: + case 173: + case 35: + return -1; + case 176: + case 177: + case 7: + case 155: + case 8: + case 157: + case 125: + case 126: + case 92: + case 93: + case 129: + case 130: + case 131: + case 94: + case 91: + return 1; + case 74: + case 60: + case 69: + case 70: + case 4: + return 1024; + case 31: + case 42: + case 72: + return 32; + case 87: + case 26: + case 33: + return 2147483647; + case 34: + case 1: + return 47839; + case 38: + case 36: + return 99; + case 43: + case 37: + return 2048; + case 0: + return 2097152; + case 3: + return 65536; + case 28: + return 32768; + case 44: + return 32767; + case 75: + return 16384; + case 39: + return 1e3; + case 89: + return 700; + case 71: + return 256; + case 40: + return 255; + case 2: + return 100; + case 180: + return 64; + case 25: + return 20; + case 5: + return 16; + case 6: + return 6; + case 73: + return 4; + case 84: + { + if (typeof navigator === "object") return navigator["hardwareConcurrency"] || 1; + return 1; + } + } + ___setErrNo(28); + return -1; +} +Module["_sysconf"] = _sysconf; +function _system(command) { + ___setErrNo(6); + return -1; +} +Module["_system"] = _system; +function _time(ptr) { + var ret = Date.now() / 1e3 | 0; + if (ptr) { + GROWABLE_HEAP_STORE_I32(ptr | 0, ret); + } + return ret; +} +Module["_time"] = _time; +function _times(buffer) { + if (buffer !== 0) { + _memset(buffer, 0, 16); + } + return 0; +} +Module["_times"] = _times; +if (!ENVIRONMENT_IS_PTHREAD) PThread.initMainThreadBlock(); else PThread.initWorker(); +if (ENVIRONMENT_IS_NODE) { + _emscripten_get_now = function _emscripten_get_now_actual() { + var t = process["hrtime"](); + return t[0] * 1e3 + t[1] / 1e6; + }; +} else if (ENVIRONMENT_IS_PTHREAD) { + _emscripten_get_now = (function() { + return performance["now"]() - __performance_now_clock_drift; + }); +} else if (typeof dateNow !== "undefined") { + _emscripten_get_now = dateNow; +} else if (typeof performance === "object" && performance && typeof performance["now"] === "function") { + _emscripten_get_now = (function() { + return performance["now"](); + }); +} else { + _emscripten_get_now = Date.now; +} +FS.staticInit(); +if (ENVIRONMENT_HAS_NODE) { + var fs = require("fs"); + var NODEJS_PATH = require("path"); + NODEFS.staticInit(); +} +var GLctx; +GL.init(); +var proxiedFunctionTable = [ null, _atexit, ___syscall10, ___syscall12, ___syscall183, ___syscall192, ___syscall195, ___syscall196, ___syscall220, ___syscall221, ___syscall3, ___syscall39, ___syscall4, ___syscall40, ___syscall5, ___syscall54, ___syscall85, ___syscall91, _emscripten_set_canvas_element_size_main_thread, _fd_close, _fd_read, _fd_seek, _fd_write, _tzset, _sysconf ]; var ASSERTIONS = true; - -// Copyright 2017 The Emscripten Authors. All rights reserved. -// Emscripten is available under two separate licenses, the MIT license and the -// University of Illinois/NCSA Open Source License. Both these licenses can be -// found in the LICENSE file. - -/** @type {function(string, boolean=, number=)} */ function intArrayFromString(stringy, dontAddNull, length) { - var len = length > 0 ? length : lengthBytesUTF8(stringy)+1; - var u8array = new Array(len); - var numBytesWritten = stringToUTF8Array(stringy, u8array, 0, u8array.length); - if (dontAddNull) u8array.length = numBytesWritten; - return u8array; + var len = length > 0 ? length : lengthBytesUTF8(stringy) + 1; + var u8array = new Array(len); + var numBytesWritten = stringToUTF8Array(stringy, u8array, 0, u8array.length); + if (dontAddNull) u8array.length = numBytesWritten; + return u8array; } - function intArrayToString(array) { - var ret = []; - for (var i = 0; i < array.length; i++) { - var chr = array[i]; - if (chr > 0xFF) { - if (ASSERTIONS) { - assert(false, 'Character code ' + chr + ' (' + String.fromCharCode(chr) + ') at offset ' + i + ' not in 0x00-0xFF.'); - } - chr &= 0xFF; - } - ret.push(String.fromCharCode(chr)); - } - return ret.join(''); + var ret = []; + for (var i = 0; i < array.length; i++) { + var chr = array[i]; + if (chr > 255) { + if (ASSERTIONS) { + assert(false, "Character code " + chr + " (" + String.fromCharCode(chr) + ") at offset " + i + " not in 0x00-0xFF."); + } + chr &= 255; + } + ret.push(String.fromCharCode(chr)); + } + return ret.join(""); } - - -// ASM_LIBRARY EXTERN PRIMITIVES: Int8Array,Int32Array - var asmGlobalArg = {}; -var asmLibraryArg = { "_ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, "_ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, "_ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, "_ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, "_ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, "_ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb": __ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb, "_ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb": __ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb, "_ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb": __ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb, "_ZN12CPdfRendererD1Ev": __ZN12CPdfRendererD1Ev, "_ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv": __ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv, "_ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_": __ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_, "_ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE": __ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE, "_ZN14NSDoctRenderer13CDoctrendererD1Ev": __ZN14NSDoctRenderer13CDoctrendererD1Ev, "_ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_": __ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_, "_ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb": __ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb, "_ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev": __ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev, "_ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev": __ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev, "_ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb": __ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb, "_ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE": __ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE, "_ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE": __ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE, "_ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_": __ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_, "_ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_": __ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_, "_ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_": __ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_, "_ZN9CHtmlFileC1Ev": __ZN9CHtmlFileC1Ev, "_ZN9CHtmlFileD1Ev": __ZN9CHtmlFileD1Ev, "_ZN9PdfReader10CPdfReader8GetErrorEv": __ZN9PdfReader10CPdfReader8GetErrorEv, "_ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE": __ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE, "__assert_fail": ___assert_fail, "__call_main": ___call_main, "__clock_gettime": ___clock_gettime, "__cxa_allocate_exception": ___cxa_allocate_exception, "__cxa_atexit": ___cxa_atexit, "__cxa_rethrow": ___cxa_rethrow, "__cxa_throw": ___cxa_throw, "__lock": ___lock, "__map_file": ___map_file, "__syscall10": ___syscall10, "__syscall12": ___syscall12, "__syscall183": ___syscall183, "__syscall192": ___syscall192, "__syscall195": ___syscall195, "__syscall196": ___syscall196, "__syscall220": ___syscall220, "__syscall221": ___syscall221, "__syscall3": ___syscall3, "__syscall39": ___syscall39, "__syscall4": ___syscall4, "__syscall40": ___syscall40, "__syscall5": ___syscall5, "__syscall54": ___syscall54, "__syscall85": ___syscall85, "__syscall91": ___syscall91, "__unlock": ___unlock, "abort": _abort, "atexit": _atexit, "emscripten_asm_const_iii": _emscripten_asm_const_iii, "emscripten_check_blocking_allowed": _emscripten_check_blocking_allowed, "emscripten_conditional_set_current_thread_status": _emscripten_conditional_set_current_thread_status, "emscripten_futex_wait": _emscripten_futex_wait, "emscripten_futex_wake": _emscripten_futex_wake, "emscripten_get_now": _emscripten_get_now, "emscripten_get_sbrk_ptr": _emscripten_get_sbrk_ptr, "emscripten_has_threading_support": _emscripten_has_threading_support, "emscripten_is_main_browser_thread": _emscripten_is_main_browser_thread, "emscripten_is_main_runtime_thread": _emscripten_is_main_runtime_thread, "emscripten_longjmp": _emscripten_longjmp, "emscripten_memcpy_big": _emscripten_memcpy_big, "emscripten_receive_on_main_thread_js": _emscripten_receive_on_main_thread_js, "emscripten_resize_heap": _emscripten_resize_heap, "emscripten_set_canvas_element_size": _emscripten_set_canvas_element_size, "emscripten_set_current_thread_status": _emscripten_set_current_thread_status, "emscripten_set_thread_name": _emscripten_set_thread_name, "emscripten_syscall": _emscripten_syscall, "emscripten_webgl_create_context": _emscripten_webgl_create_context, "environ_get": _environ_get, "environ_sizes_get": _environ_sizes_get, "exit": _exit, "fd_close": _fd_close, "fd_read": _fd_read, "fd_seek": _fd_seek, "fd_write": _fd_write, "getTempRet0": _getTempRet0, "gettimeofday": _gettimeofday, "gmtime": _gmtime, "initPthreadsJS": initPthreadsJS, "invoke_ii": invoke_ii, "invoke_iii": invoke_iii, "invoke_iiii": invoke_iiii, "invoke_iiiii": invoke_iiiii, "invoke_iiiiii": invoke_iiiiii, "invoke_v": invoke_v, "invoke_vi": invoke_vi, "invoke_vii": invoke_vii, "invoke_viii": invoke_viii, "invoke_viiii": invoke_viiii, "invoke_viiiii": invoke_viiiii, "invoke_viiiiii": invoke_viiiiii, "invoke_viiiiiiiii": invoke_viiiiiiiii, "memory": wasmMemory, "mktime": _mktime, "pthread_cleanup_pop": _pthread_cleanup_pop, "pthread_cleanup_push": _pthread_cleanup_push, "pthread_create": _pthread_create, "pthread_self": _pthread_self, "saveSetjmp": _saveSetjmp, "setTempRet0": _setTempRet0, "strftime_l": _strftime_l, "sysconf": _sysconf, "system": _system, "table": wasmTable, "testSetjmp": _testSetjmp, "time": _time, "times": _times }; +var asmLibraryArg = { + "_ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer10SaveToFileERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, + "_ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer11SetPasswordERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, + "_ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer13SetDocumentIDERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, + "_ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer13SetTempFolderERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, + "_ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE": __ZN12CPdfRenderer14SetThemesPlaceERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEE, + "_ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb": __ZN12CPdfRenderer15OnlineWordToPdfERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb, + "_ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb": __ZN12CPdfRenderer25OnlineWordToPdfFromBinaryERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_RKb, + "_ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb": __ZN12CPdfRendererC1EPN7NSFonts17IApplicationFontsEb, + "_ZN12CPdfRendererD1Ev": __ZN12CPdfRendererD1Ev, + "_ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv": __ZN14NSDoctRenderer13CDoctrenderer18GetImagesInChangesEv, + "_ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_": __ZN14NSDoctRenderer13CDoctrenderer7ExecuteERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERS7_, + "_ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE": __ZN14NSDoctRenderer13CDoctrendererC1ERKNSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEE, + "_ZN14NSDoctRenderer13CDoctrendererD1Ev": __ZN14NSDoctRenderer13CDoctrendererD1Ev, + "_ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_": __ZN14NSHtmlRenderer17CASCHTMLRenderer316CreateOfficeFileENSt3__212basic_stringIwNS1_11char_traitsIwEENS1_9allocatorIwEEEERKS7_, + "_ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb": __ZN14NSHtmlRenderer17CASCHTMLRenderer39CloseFileEb, + "_ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev": __ZN14NSHtmlRenderer17CASCHTMLRenderer3C1Ev, + "_ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev": __ZN14NSHtmlRenderer17CASCHTMLRenderer3D1Ev, + "_ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb": __ZN23CFileDownloader_privateC1ENSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEEb, + "_ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE": __ZN8CXpsFileC1EPN7NSFonts17IApplicationFontsE, + "_ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE": __ZN9CDjVuFileC1EPN7NSFonts17IApplicationFontsE, + "_ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_": __ZN9CHtmlFile10ConvertMhtERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEES8_S8_, + "_ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_": __ZN9CHtmlFile11ConvertEpubERKNSt3__212basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEERS6_S8_S8_, + "_ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_": __ZN9CHtmlFile7ConvertERKNSt3__26vectorINS0_12basic_stringIwNS0_11char_traitsIwEENS0_9allocatorIwEEEENS5_IS7_EEEERKS7_SD_, + "_ZN9CHtmlFileC1Ev": __ZN9CHtmlFileC1Ev, + "_ZN9CHtmlFileD1Ev": __ZN9CHtmlFileD1Ev, + "_ZN9PdfReader10CPdfReader8GetErrorEv": __ZN9PdfReader10CPdfReader8GetErrorEv, + "_ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE": __ZN9PdfReader10CPdfReaderC1EPN7NSFonts17IApplicationFontsE, + "__assert_fail": ___assert_fail, + "__call_main": ___call_main, + "__clock_gettime": ___clock_gettime, + "__cxa_allocate_exception": ___cxa_allocate_exception, + "__cxa_atexit": ___cxa_atexit, + "__cxa_rethrow": ___cxa_rethrow, + "__cxa_throw": ___cxa_throw, + "__lock": ___lock, + "__map_file": ___map_file, + "__syscall10": ___syscall10, + "__syscall12": ___syscall12, + "__syscall183": ___syscall183, + "__syscall192": ___syscall192, + "__syscall195": ___syscall195, + "__syscall196": ___syscall196, + "__syscall220": ___syscall220, + "__syscall221": ___syscall221, + "__syscall3": ___syscall3, + "__syscall39": ___syscall39, + "__syscall4": ___syscall4, + "__syscall40": ___syscall40, + "__syscall5": ___syscall5, + "__syscall54": ___syscall54, + "__syscall85": ___syscall85, + "__syscall91": ___syscall91, + "__unlock": ___unlock, + "abort": _abort, + "atexit": _atexit, + "emscripten_asm_const_iii": _emscripten_asm_const_iii, + "emscripten_check_blocking_allowed": _emscripten_check_blocking_allowed, + "emscripten_conditional_set_current_thread_status": _emscripten_conditional_set_current_thread_status, + "emscripten_futex_wait": _emscripten_futex_wait, + "emscripten_futex_wake": _emscripten_futex_wake, + "emscripten_get_now": _emscripten_get_now, + "emscripten_get_sbrk_ptr": _emscripten_get_sbrk_ptr, + "emscripten_has_threading_support": _emscripten_has_threading_support, + "emscripten_is_main_browser_thread": _emscripten_is_main_browser_thread, + "emscripten_is_main_runtime_thread": _emscripten_is_main_runtime_thread, + "emscripten_longjmp": _emscripten_longjmp, + "emscripten_memcpy_big": _emscripten_memcpy_big, + "emscripten_receive_on_main_thread_js": _emscripten_receive_on_main_thread_js, + "emscripten_resize_heap": _emscripten_resize_heap, + "emscripten_set_canvas_element_size": _emscripten_set_canvas_element_size, + "emscripten_set_current_thread_status": _emscripten_set_current_thread_status, + "emscripten_set_thread_name": _emscripten_set_thread_name, + "emscripten_syscall": _emscripten_syscall, + "emscripten_webgl_create_context": _emscripten_webgl_create_context, + "environ_get": _environ_get, + "environ_sizes_get": _environ_sizes_get, + "exit": _exit, + "fd_close": _fd_close, + "fd_read": _fd_read, + "fd_seek": _fd_seek, + "fd_write": _fd_write, + "getTempRet0": _getTempRet0, + "gettimeofday": _gettimeofday, + "gmtime": _gmtime, + "initPthreadsJS": initPthreadsJS, + "invoke_ii": invoke_ii, + "invoke_iii": invoke_iii, + "invoke_iiii": invoke_iiii, + "invoke_iiiii": invoke_iiiii, + "invoke_iiiiii": invoke_iiiiii, + "invoke_v": invoke_v, + "invoke_vi": invoke_vi, + "invoke_vii": invoke_vii, + "invoke_viii": invoke_viii, + "invoke_viiii": invoke_viiii, + "invoke_viiiii": invoke_viiiii, + "invoke_viiiiii": invoke_viiiiii, + "invoke_viiiiiiiii": invoke_viiiiiiiii, + "memory": wasmMemory, + "mktime": _mktime, + "pthread_cleanup_pop": _pthread_cleanup_pop, + "pthread_cleanup_push": _pthread_cleanup_push, + "pthread_create": _pthread_create, + "pthread_self": _pthread_self, + "saveSetjmp": _saveSetjmp, + "setTempRet0": _setTempRet0, + "strftime_l": _strftime_l, + "sysconf": _sysconf, + "system": _system, + "table": wasmTable, + "testSetjmp": _testSetjmp, + "time": _time, + "times": _times +}; var asm = createWasm(); var real____wasm_call_ctors = asm["__wasm_call_ctors"]; -asm["__wasm_call_ctors"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real____wasm_call_ctors.apply(null, arguments); -}; - +asm["__wasm_call_ctors"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real____wasm_call_ctors.apply(null, arguments); +}); var real__runX2T = asm["runX2T"]; -asm["runX2T"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__runX2T.apply(null, arguments); -}; - +asm["runX2T"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__runX2T.apply(null, arguments); +}); var real__malloc = asm["malloc"]; -asm["malloc"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__malloc.apply(null, arguments); -}; - +asm["malloc"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__malloc.apply(null, arguments); +}); var real__free = asm["free"]; -asm["free"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__free.apply(null, arguments); -}; - +asm["free"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__free.apply(null, arguments); +}); var real__main = asm["main"]; -asm["main"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__main.apply(null, arguments); -}; - +asm["main"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__main.apply(null, arguments); +}); var real__fflush = asm["fflush"]; -asm["fflush"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__fflush.apply(null, arguments); -}; - +asm["fflush"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__fflush.apply(null, arguments); +}); var real__realloc = asm["realloc"]; -asm["realloc"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__realloc.apply(null, arguments); -}; - +asm["realloc"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__realloc.apply(null, arguments); +}); var real___ZSt18uncaught_exceptionv = asm["_ZSt18uncaught_exceptionv"]; -asm["_ZSt18uncaught_exceptionv"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real___ZSt18uncaught_exceptionv.apply(null, arguments); -}; - +asm["_ZSt18uncaught_exceptionv"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real___ZSt18uncaught_exceptionv.apply(null, arguments); +}); var real____errno_location = asm["__errno_location"]; -asm["__errno_location"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real____errno_location.apply(null, arguments); -}; - +asm["__errno_location"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real____errno_location.apply(null, arguments); +}); var real__ntohs = asm["ntohs"]; -asm["ntohs"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__ntohs.apply(null, arguments); -}; - +asm["ntohs"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__ntohs.apply(null, arguments); +}); var real__htonl = asm["htonl"]; -asm["htonl"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__htonl.apply(null, arguments); -}; - +asm["htonl"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__htonl.apply(null, arguments); +}); var real__htons = asm["htons"]; -asm["htons"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__htons.apply(null, arguments); -}; - +asm["htons"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__htons.apply(null, arguments); +}); +var real__emscripten_get_global_libc = asm["emscripten_get_global_libc"]; +asm["emscripten_get_global_libc"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_get_global_libc.apply(null, arguments); +}); var real____em_js__initPthreadsJS = asm["__em_js__initPthreadsJS"]; -asm["__em_js__initPthreadsJS"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real____em_js__initPthreadsJS.apply(null, arguments); -}; - +asm["__em_js__initPthreadsJS"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real____em_js__initPthreadsJS.apply(null, arguments); +}); var real____emscripten_pthread_data_constructor = asm["__emscripten_pthread_data_constructor"]; -asm["__emscripten_pthread_data_constructor"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real____emscripten_pthread_data_constructor.apply(null, arguments); -}; - -var real__emscripten_get_global_libc = asm["emscripten_get_global_libc"]; -asm["emscripten_get_global_libc"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_get_global_libc.apply(null, arguments); -}; - +asm["__emscripten_pthread_data_constructor"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real____emscripten_pthread_data_constructor.apply(null, arguments); +}); var real___get_tzname = asm["_get_tzname"]; -asm["_get_tzname"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real___get_tzname.apply(null, arguments); -}; - +asm["_get_tzname"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real___get_tzname.apply(null, arguments); +}); var real___get_daylight = asm["_get_daylight"]; -asm["_get_daylight"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real___get_daylight.apply(null, arguments); -}; - +asm["_get_daylight"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real___get_daylight.apply(null, arguments); +}); var real___get_timezone = asm["_get_timezone"]; -asm["_get_timezone"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real___get_timezone.apply(null, arguments); -}; - +asm["_get_timezone"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real___get_timezone.apply(null, arguments); +}); var real__setThrew = asm["setThrew"]; -asm["setThrew"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__setThrew.apply(null, arguments); -}; - +asm["setThrew"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__setThrew.apply(null, arguments); +}); var real__memalign = asm["memalign"]; -asm["memalign"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__memalign.apply(null, arguments); -}; - +asm["memalign"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__memalign.apply(null, arguments); +}); var real__emscripten_builtin_free = asm["emscripten_builtin_free"]; -asm["emscripten_builtin_free"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_builtin_free.apply(null, arguments); -}; - +asm["emscripten_builtin_free"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_builtin_free.apply(null, arguments); +}); var real__emscripten_builtin_memalign = asm["emscripten_builtin_memalign"]; -asm["emscripten_builtin_memalign"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_builtin_memalign.apply(null, arguments); -}; - +asm["emscripten_builtin_memalign"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_builtin_memalign.apply(null, arguments); +}); var real__emscripten_main_browser_thread_id = asm["emscripten_main_browser_thread_id"]; -asm["emscripten_main_browser_thread_id"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_main_browser_thread_id.apply(null, arguments); -}; - +asm["emscripten_main_browser_thread_id"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_main_browser_thread_id.apply(null, arguments); +}); var real____pthread_tsd_run_dtors = asm["__pthread_tsd_run_dtors"]; -asm["__pthread_tsd_run_dtors"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real____pthread_tsd_run_dtors.apply(null, arguments); -}; - +asm["__pthread_tsd_run_dtors"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real____pthread_tsd_run_dtors.apply(null, arguments); +}); var real__emscripten_main_thread_process_queued_calls = asm["emscripten_main_thread_process_queued_calls"]; -asm["emscripten_main_thread_process_queued_calls"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_main_thread_process_queued_calls.apply(null, arguments); -}; - +asm["emscripten_main_thread_process_queued_calls"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_main_thread_process_queued_calls.apply(null, arguments); +}); var real__emscripten_current_thread_process_queued_calls = asm["emscripten_current_thread_process_queued_calls"]; -asm["emscripten_current_thread_process_queued_calls"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_current_thread_process_queued_calls.apply(null, arguments); -}; - +asm["emscripten_current_thread_process_queued_calls"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_current_thread_process_queued_calls.apply(null, arguments); +}); var real__usleep = asm["usleep"]; -asm["usleep"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__usleep.apply(null, arguments); -}; - +asm["usleep"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__usleep.apply(null, arguments); +}); var real__emscripten_register_main_browser_thread_id = asm["emscripten_register_main_browser_thread_id"]; -asm["emscripten_register_main_browser_thread_id"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_register_main_browser_thread_id.apply(null, arguments); -}; - +asm["emscripten_register_main_browser_thread_id"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_register_main_browser_thread_id.apply(null, arguments); +}); var real__emscripten_async_run_in_main_thread = asm["emscripten_async_run_in_main_thread"]; -asm["emscripten_async_run_in_main_thread"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_async_run_in_main_thread.apply(null, arguments); -}; - +asm["emscripten_async_run_in_main_thread"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_async_run_in_main_thread.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread = asm["emscripten_sync_run_in_main_thread"]; -asm["emscripten_sync_run_in_main_thread"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_0 = asm["emscripten_sync_run_in_main_thread_0"]; -asm["emscripten_sync_run_in_main_thread_0"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_0.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_0"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_0.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_1 = asm["emscripten_sync_run_in_main_thread_1"]; -asm["emscripten_sync_run_in_main_thread_1"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_1.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_1"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_1.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_2 = asm["emscripten_sync_run_in_main_thread_2"]; -asm["emscripten_sync_run_in_main_thread_2"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_2.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_2"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_2.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_xprintf_varargs = asm["emscripten_sync_run_in_main_thread_xprintf_varargs"]; -asm["emscripten_sync_run_in_main_thread_xprintf_varargs"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_xprintf_varargs.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_xprintf_varargs"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_xprintf_varargs.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_3 = asm["emscripten_sync_run_in_main_thread_3"]; -asm["emscripten_sync_run_in_main_thread_3"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_3.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_3"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_3.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_4 = asm["emscripten_sync_run_in_main_thread_4"]; -asm["emscripten_sync_run_in_main_thread_4"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_4.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_4"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_4.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_5 = asm["emscripten_sync_run_in_main_thread_5"]; -asm["emscripten_sync_run_in_main_thread_5"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_5.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_5"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_5.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_6 = asm["emscripten_sync_run_in_main_thread_6"]; -asm["emscripten_sync_run_in_main_thread_6"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_6.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_6"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_6.apply(null, arguments); +}); var real__emscripten_sync_run_in_main_thread_7 = asm["emscripten_sync_run_in_main_thread_7"]; -asm["emscripten_sync_run_in_main_thread_7"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_sync_run_in_main_thread_7.apply(null, arguments); -}; - +asm["emscripten_sync_run_in_main_thread_7"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_sync_run_in_main_thread_7.apply(null, arguments); +}); var real__emscripten_run_in_main_runtime_thread_js = asm["emscripten_run_in_main_runtime_thread_js"]; -asm["emscripten_run_in_main_runtime_thread_js"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_run_in_main_runtime_thread_js.apply(null, arguments); -}; - +asm["emscripten_run_in_main_runtime_thread_js"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_run_in_main_runtime_thread_js.apply(null, arguments); +}); var real__emscripten_async_queue_on_thread_ = asm["emscripten_async_queue_on_thread_"]; -asm["emscripten_async_queue_on_thread_"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_async_queue_on_thread_.apply(null, arguments); -}; - +asm["emscripten_async_queue_on_thread_"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_async_queue_on_thread_.apply(null, arguments); +}); var real__proxy_main = asm["proxy_main"]; -asm["proxy_main"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__proxy_main.apply(null, arguments); -}; - +asm["proxy_main"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__proxy_main.apply(null, arguments); +}); var real__emscripten_tls_init = asm["emscripten_tls_init"]; -asm["emscripten_tls_init"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real__emscripten_tls_init.apply(null, arguments); -}; - +asm["emscripten_tls_init"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real__emscripten_tls_init.apply(null, arguments); +}); var real_dynCall_ii = asm["dynCall_ii"]; -asm["dynCall_ii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_ii.apply(null, arguments); -}; - +asm["dynCall_ii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_ii.apply(null, arguments); +}); var real_dynCall_iii = asm["dynCall_iii"]; -asm["dynCall_iii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iii.apply(null, arguments); -}; - +asm["dynCall_iii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iii.apply(null, arguments); +}); var real_dynCall_iiii = asm["dynCall_iiii"]; -asm["dynCall_iiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiii.apply(null, arguments); -}; - +asm["dynCall_iiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiii.apply(null, arguments); +}); var real_dynCall_iiiii = asm["dynCall_iiiii"]; -asm["dynCall_iiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiii.apply(null, arguments); -}; - +asm["dynCall_iiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiii.apply(null, arguments); +}); var real_dynCall_iiiiii = asm["dynCall_iiiiii"]; -asm["dynCall_iiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiii.apply(null, arguments); -}; - +asm["dynCall_iiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiii.apply(null, arguments); +}); var real_dynCall_v = asm["dynCall_v"]; -asm["dynCall_v"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_v.apply(null, arguments); -}; - +asm["dynCall_v"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_v.apply(null, arguments); +}); var real_dynCall_vi = asm["dynCall_vi"]; -asm["dynCall_vi"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_vi.apply(null, arguments); -}; - +asm["dynCall_vi"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_vi.apply(null, arguments); +}); var real_dynCall_vii = asm["dynCall_vii"]; -asm["dynCall_vii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_vii.apply(null, arguments); -}; - +asm["dynCall_vii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_vii.apply(null, arguments); +}); var real_dynCall_viii = asm["dynCall_viii"]; -asm["dynCall_viii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viii.apply(null, arguments); -}; - +asm["dynCall_viii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viii.apply(null, arguments); +}); var real_dynCall_viiii = asm["dynCall_viiii"]; -asm["dynCall_viiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiii.apply(null, arguments); -}; - +asm["dynCall_viiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiii.apply(null, arguments); +}); var real_dynCall_viiiii = asm["dynCall_viiiii"]; -asm["dynCall_viiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiiii.apply(null, arguments); -}; - +asm["dynCall_viiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiiii.apply(null, arguments); +}); var real_dynCall_viiiiii = asm["dynCall_viiiiii"]; -asm["dynCall_viiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiiiii.apply(null, arguments); -}; - +asm["dynCall_viiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiiiii.apply(null, arguments); +}); var real_dynCall_viiiiiiiii = asm["dynCall_viiiiiiiii"]; -asm["dynCall_viiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiiiiiiii.apply(null, arguments); -}; - +asm["dynCall_viiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiiiiiiii.apply(null, arguments); +}); var real_stackSave = asm["stackSave"]; -asm["stackSave"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_stackSave.apply(null, arguments); -}; - +asm["stackSave"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_stackSave.apply(null, arguments); +}); var real_stackAlloc = asm["stackAlloc"]; -asm["stackAlloc"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_stackAlloc.apply(null, arguments); -}; - +asm["stackAlloc"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_stackAlloc.apply(null, arguments); +}); var real_stackRestore = asm["stackRestore"]; -asm["stackRestore"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_stackRestore.apply(null, arguments); -}; - +asm["stackRestore"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_stackRestore.apply(null, arguments); +}); var real___growWasmMemory = asm["__growWasmMemory"]; -asm["__growWasmMemory"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real___growWasmMemory.apply(null, arguments); -}; - +asm["__growWasmMemory"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real___growWasmMemory.apply(null, arguments); +}); var real_dynCall_viijii = asm["dynCall_viijii"]; -asm["dynCall_viijii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viijii.apply(null, arguments); -}; - +asm["dynCall_viijii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viijii.apply(null, arguments); +}); var real_dynCall_dii = asm["dynCall_dii"]; -asm["dynCall_dii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_dii.apply(null, arguments); -}; - +asm["dynCall_dii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_dii.apply(null, arguments); +}); var real_dynCall_did = asm["dynCall_did"]; -asm["dynCall_did"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_did.apply(null, arguments); -}; - +asm["dynCall_did"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_did.apply(null, arguments); +}); var real_dynCall_di = asm["dynCall_di"]; -asm["dynCall_di"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_di.apply(null, arguments); -}; - +asm["dynCall_di"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_di.apply(null, arguments); +}); var real_dynCall_ji = asm["dynCall_ji"]; -asm["dynCall_ji"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_ji.apply(null, arguments); -}; - +asm["dynCall_ji"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_ji.apply(null, arguments); +}); var real_dynCall_vij = asm["dynCall_vij"]; -asm["dynCall_vij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_vij.apply(null, arguments); -}; - +asm["dynCall_vij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_vij.apply(null, arguments); +}); var real_dynCall_jii = asm["dynCall_jii"]; -asm["dynCall_jii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_jii.apply(null, arguments); -}; - +asm["dynCall_jii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_jii.apply(null, arguments); +}); var real_dynCall_iiiiiii = asm["dynCall_iiiiiii"]; -asm["dynCall_iiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiiii.apply(null, arguments); -}; - +asm["dynCall_iiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiiii.apply(null, arguments); +}); var real_dynCall_iiiiiiii = asm["dynCall_iiiiiiii"]; -asm["dynCall_iiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiiiii.apply(null, arguments); -}; - +asm["dynCall_iiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiiiii.apply(null, arguments); +}); var real_dynCall_iiiiiiiii = asm["dynCall_iiiiiiiii"]; -asm["dynCall_iiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiiiiii.apply(null, arguments); -}; - +asm["dynCall_iiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiiiiii.apply(null, arguments); +}); var real_dynCall_iidddddi = asm["dynCall_iidddddi"]; -asm["dynCall_iidddddi"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iidddddi.apply(null, arguments); -}; - +asm["dynCall_iidddddi"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iidddddi.apply(null, arguments); +}); var real_dynCall_viiiddii = asm["dynCall_viiiddii"]; -asm["dynCall_viiiddii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiiddii.apply(null, arguments); -}; - +asm["dynCall_viiiddii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiiddii.apply(null, arguments); +}); var real_dynCall_viij = asm["dynCall_viij"]; -asm["dynCall_viij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viij.apply(null, arguments); -}; - +asm["dynCall_viij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viij.apply(null, arguments); +}); var real_dynCall_viji = asm["dynCall_viji"]; -asm["dynCall_viji"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viji.apply(null, arguments); -}; - +asm["dynCall_viji"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viji.apply(null, arguments); +}); var real_dynCall_jij = asm["dynCall_jij"]; -asm["dynCall_jij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_jij.apply(null, arguments); -}; - +asm["dynCall_jij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_jij.apply(null, arguments); +}); var real_dynCall_iiiijii = asm["dynCall_iiiijii"]; -asm["dynCall_iiiijii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiijii.apply(null, arguments); -}; - +asm["dynCall_iiiijii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiijii.apply(null, arguments); +}); var real_dynCall_viiij = asm["dynCall_viiij"]; -asm["dynCall_viiij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiij.apply(null, arguments); -}; - +asm["dynCall_viiij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiij.apply(null, arguments); +}); var real_dynCall_viiiiiiiiii = asm["dynCall_viiiiiiiiii"]; -asm["dynCall_viiiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiiiiiiiii.apply(null, arguments); -}; - +asm["dynCall_viiiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiiiiiiiii.apply(null, arguments); +}); var real_dynCall_iiiji = asm["dynCall_iiiji"]; -asm["dynCall_iiiji"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiji.apply(null, arguments); -}; - +asm["dynCall_iiiji"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiji.apply(null, arguments); +}); var real_dynCall_i = asm["dynCall_i"]; -asm["dynCall_i"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_i.apply(null, arguments); -}; - +asm["dynCall_i"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_i.apply(null, arguments); +}); var real_dynCall_viiiiiii = asm["dynCall_viiiiiii"]; -asm["dynCall_viiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiiiiii.apply(null, arguments); -}; - +asm["dynCall_viiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiiiiii.apply(null, arguments); +}); var real_dynCall_viiiiiiiiiiii = asm["dynCall_viiiiiiiiiiii"]; -asm["dynCall_viiiiiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiiiiiiiiiii.apply(null, arguments); -}; - +asm["dynCall_viiiiiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiiiiiiiiiii.apply(null, arguments); +}); var real_dynCall_iidd = asm["dynCall_iidd"]; -asm["dynCall_iidd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iidd.apply(null, arguments); -}; - +asm["dynCall_iidd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iidd.apply(null, arguments); +}); var real_dynCall_iidddddd = asm["dynCall_iidddddd"]; -asm["dynCall_iidddddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iidddddd.apply(null, arguments); -}; - +asm["dynCall_iidddddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iidddddd.apply(null, arguments); +}); var real_dynCall_vidd = asm["dynCall_vidd"]; -asm["dynCall_vidd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_vidd.apply(null, arguments); -}; - +asm["dynCall_vidd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_vidd.apply(null, arguments); +}); var real_dynCall_vidddd = asm["dynCall_vidddd"]; -asm["dynCall_vidddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_vidddd.apply(null, arguments); -}; - +asm["dynCall_vidddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_vidddd.apply(null, arguments); +}); var real_dynCall_viidddd = asm["dynCall_viidddd"]; -asm["dynCall_viidddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viidddd.apply(null, arguments); -}; - +asm["dynCall_viidddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viidddd.apply(null, arguments); +}); var real_dynCall_viidddddd = asm["dynCall_viidddddd"]; -asm["dynCall_viidddddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viidddddd.apply(null, arguments); -}; - +asm["dynCall_viidddddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viidddddd.apply(null, arguments); +}); var real_dynCall_iiiiiddd = asm["dynCall_iiiiiddd"]; -asm["dynCall_iiiiiddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiiddd.apply(null, arguments); -}; - +asm["dynCall_iiiiiddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiiddd.apply(null, arguments); +}); var real_dynCall_viiiiddd = asm["dynCall_viiiiddd"]; -asm["dynCall_viiiiddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viiiiddd.apply(null, arguments); -}; - +asm["dynCall_viiiiddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viiiiddd.apply(null, arguments); +}); var real_dynCall_diiii = asm["dynCall_diiii"]; -asm["dynCall_diiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_diiii.apply(null, arguments); -}; - +asm["dynCall_diiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_diiii.apply(null, arguments); +}); var real_dynCall_iiidddd = asm["dynCall_iiidddd"]; -asm["dynCall_iiidddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiidddd.apply(null, arguments); -}; - +asm["dynCall_iiidddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiidddd.apply(null, arguments); +}); var real_dynCall_viddddiii = asm["dynCall_viddddiii"]; -asm["dynCall_viddddiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_viddddiii.apply(null, arguments); -}; - +asm["dynCall_viddddiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_viddddiii.apply(null, arguments); +}); var real_dynCall_vidddddd = asm["dynCall_vidddddd"]; -asm["dynCall_vidddddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_vidddddd.apply(null, arguments); -}; - +asm["dynCall_vidddddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_vidddddd.apply(null, arguments); +}); var real_dynCall_iiiiiiiiii = asm["dynCall_iiiiiiiiii"]; -asm["dynCall_iiiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiiiiiii.apply(null, arguments); -}; - +asm["dynCall_iiiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiiiiiii.apply(null, arguments); +}); var real_dynCall_jiji = asm["dynCall_jiji"]; -asm["dynCall_jiji"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_jiji.apply(null, arguments); -}; - +asm["dynCall_jiji"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_jiji.apply(null, arguments); +}); var real_dynCall_iidiiii = asm["dynCall_iidiiii"]; -asm["dynCall_iidiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iidiiii.apply(null, arguments); -}; - +asm["dynCall_iidiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iidiiii.apply(null, arguments); +}); var real_dynCall_iiiiij = asm["dynCall_iiiiij"]; -asm["dynCall_iiiiij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiij.apply(null, arguments); -}; - +asm["dynCall_iiiiij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiij.apply(null, arguments); +}); var real_dynCall_iiiiid = asm["dynCall_iiiiid"]; -asm["dynCall_iiiiid"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiid.apply(null, arguments); -}; - +asm["dynCall_iiiiid"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiid.apply(null, arguments); +}); var real_dynCall_iiiiijj = asm["dynCall_iiiiijj"]; -asm["dynCall_iiiiijj"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiijj.apply(null, arguments); -}; - +asm["dynCall_iiiiijj"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiijj.apply(null, arguments); +}); var real_dynCall_iiiiiijj = asm["dynCall_iiiiiijj"]; -asm["dynCall_iiiiiijj"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return real_dynCall_iiiiiijj.apply(null, arguments); -}; - +asm["dynCall_iiiiiijj"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return real_dynCall_iiiiiijj.apply(null, arguments); +}); Module["asm"] = asm; -var ___wasm_call_ctors = Module["___wasm_call_ctors"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["__wasm_call_ctors"].apply(null, arguments) -}; - -var _runX2T = Module["_runX2T"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["runX2T"].apply(null, arguments) -}; - -var _malloc = Module["_malloc"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["malloc"].apply(null, arguments) -}; - -var _free = Module["_free"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["free"].apply(null, arguments) -}; - -var _main = Module["_main"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["main"].apply(null, arguments) -}; - -var _fflush = Module["_fflush"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["fflush"].apply(null, arguments) -}; - -var _realloc = Module["_realloc"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["realloc"].apply(null, arguments) -}; - -var __ZSt18uncaught_exceptionv = Module["__ZSt18uncaught_exceptionv"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["_ZSt18uncaught_exceptionv"].apply(null, arguments) -}; - -var ___errno_location = Module["___errno_location"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["__errno_location"].apply(null, arguments) -}; - -var _ntohs = Module["_ntohs"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["ntohs"].apply(null, arguments) -}; - -var _htonl = Module["_htonl"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["htonl"].apply(null, arguments) -}; - -var _htons = Module["_htons"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["htons"].apply(null, arguments) -}; - -var ___em_js__initPthreadsJS = Module["___em_js__initPthreadsJS"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["__em_js__initPthreadsJS"].apply(null, arguments) -}; - -var ___emscripten_pthread_data_constructor = Module["___emscripten_pthread_data_constructor"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["__emscripten_pthread_data_constructor"].apply(null, arguments) -}; - -var _emscripten_get_global_libc = Module["_emscripten_get_global_libc"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_get_global_libc"].apply(null, arguments) -}; - -var __get_tzname = Module["__get_tzname"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["_get_tzname"].apply(null, arguments) -}; - -var __get_daylight = Module["__get_daylight"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["_get_daylight"].apply(null, arguments) -}; - -var __get_timezone = Module["__get_timezone"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["_get_timezone"].apply(null, arguments) -}; - -var _setThrew = Module["_setThrew"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["setThrew"].apply(null, arguments) -}; - -var _memalign = Module["_memalign"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["memalign"].apply(null, arguments) -}; - -var _emscripten_builtin_free = Module["_emscripten_builtin_free"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_builtin_free"].apply(null, arguments) -}; - -var _emscripten_builtin_memalign = Module["_emscripten_builtin_memalign"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_builtin_memalign"].apply(null, arguments) -}; - -var _emscripten_main_browser_thread_id = Module["_emscripten_main_browser_thread_id"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_main_browser_thread_id"].apply(null, arguments) -}; - -var ___pthread_tsd_run_dtors = Module["___pthread_tsd_run_dtors"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["__pthread_tsd_run_dtors"].apply(null, arguments) -}; - -var _emscripten_main_thread_process_queued_calls = Module["_emscripten_main_thread_process_queued_calls"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_main_thread_process_queued_calls"].apply(null, arguments) -}; - -var _emscripten_current_thread_process_queued_calls = Module["_emscripten_current_thread_process_queued_calls"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_current_thread_process_queued_calls"].apply(null, arguments) -}; - -var _usleep = Module["_usleep"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["usleep"].apply(null, arguments) -}; - -var _emscripten_register_main_browser_thread_id = Module["_emscripten_register_main_browser_thread_id"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_register_main_browser_thread_id"].apply(null, arguments) -}; - -var _emscripten_async_run_in_main_thread = Module["_emscripten_async_run_in_main_thread"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_async_run_in_main_thread"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread = Module["_emscripten_sync_run_in_main_thread"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_0 = Module["_emscripten_sync_run_in_main_thread_0"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_0"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_1 = Module["_emscripten_sync_run_in_main_thread_1"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_1"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_2 = Module["_emscripten_sync_run_in_main_thread_2"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_2"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_xprintf_varargs = Module["_emscripten_sync_run_in_main_thread_xprintf_varargs"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_xprintf_varargs"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_3 = Module["_emscripten_sync_run_in_main_thread_3"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_3"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_4 = Module["_emscripten_sync_run_in_main_thread_4"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_4"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_5 = Module["_emscripten_sync_run_in_main_thread_5"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_5"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_6 = Module["_emscripten_sync_run_in_main_thread_6"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_6"].apply(null, arguments) -}; - -var _emscripten_sync_run_in_main_thread_7 = Module["_emscripten_sync_run_in_main_thread_7"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_sync_run_in_main_thread_7"].apply(null, arguments) -}; - -var _emscripten_run_in_main_runtime_thread_js = Module["_emscripten_run_in_main_runtime_thread_js"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_run_in_main_runtime_thread_js"].apply(null, arguments) -}; - -var _emscripten_async_queue_on_thread_ = Module["_emscripten_async_queue_on_thread_"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_async_queue_on_thread_"].apply(null, arguments) -}; - -var _proxy_main = Module["_proxy_main"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["proxy_main"].apply(null, arguments) -}; - -var _emscripten_tls_init = Module["_emscripten_tls_init"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["emscripten_tls_init"].apply(null, arguments) -}; - -var dynCall_ii = Module["dynCall_ii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_ii"].apply(null, arguments) -}; - -var dynCall_iii = Module["dynCall_iii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iii"].apply(null, arguments) -}; - -var dynCall_iiii = Module["dynCall_iiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiii"].apply(null, arguments) -}; - -var dynCall_iiiii = Module["dynCall_iiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiii"].apply(null, arguments) -}; - -var dynCall_iiiiii = Module["dynCall_iiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiii"].apply(null, arguments) -}; - -var dynCall_v = Module["dynCall_v"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_v"].apply(null, arguments) -}; - -var dynCall_vi = Module["dynCall_vi"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_vi"].apply(null, arguments) -}; - -var dynCall_vii = Module["dynCall_vii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_vii"].apply(null, arguments) -}; - -var dynCall_viii = Module["dynCall_viii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viii"].apply(null, arguments) -}; - -var dynCall_viiii = Module["dynCall_viiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiii"].apply(null, arguments) -}; - -var dynCall_viiiii = Module["dynCall_viiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiiii"].apply(null, arguments) -}; - -var dynCall_viiiiii = Module["dynCall_viiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiiiii"].apply(null, arguments) -}; - -var dynCall_viiiiiiiii = Module["dynCall_viiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiiiiiiii"].apply(null, arguments) -}; - -var stackSave = Module["stackSave"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["stackSave"].apply(null, arguments) -}; - -var stackAlloc = Module["stackAlloc"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["stackAlloc"].apply(null, arguments) -}; - -var stackRestore = Module["stackRestore"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["stackRestore"].apply(null, arguments) -}; - -var __growWasmMemory = Module["__growWasmMemory"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["__growWasmMemory"].apply(null, arguments) -}; - -var dynCall_viijii = Module["dynCall_viijii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viijii"].apply(null, arguments) -}; - -var dynCall_dii = Module["dynCall_dii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_dii"].apply(null, arguments) -}; - -var dynCall_did = Module["dynCall_did"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_did"].apply(null, arguments) -}; - -var dynCall_di = Module["dynCall_di"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_di"].apply(null, arguments) -}; - -var dynCall_ji = Module["dynCall_ji"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_ji"].apply(null, arguments) -}; - -var dynCall_vij = Module["dynCall_vij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_vij"].apply(null, arguments) -}; - -var dynCall_jii = Module["dynCall_jii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_jii"].apply(null, arguments) -}; - -var dynCall_iiiiiii = Module["dynCall_iiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiiii"].apply(null, arguments) -}; - -var dynCall_iiiiiiii = Module["dynCall_iiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiiiii"].apply(null, arguments) -}; - -var dynCall_iiiiiiiii = Module["dynCall_iiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiiiiii"].apply(null, arguments) -}; - -var dynCall_iidddddi = Module["dynCall_iidddddi"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iidddddi"].apply(null, arguments) -}; - -var dynCall_viiiddii = Module["dynCall_viiiddii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiiddii"].apply(null, arguments) -}; - -var dynCall_viij = Module["dynCall_viij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viij"].apply(null, arguments) -}; - -var dynCall_viji = Module["dynCall_viji"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viji"].apply(null, arguments) -}; - -var dynCall_jij = Module["dynCall_jij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_jij"].apply(null, arguments) -}; - -var dynCall_iiiijii = Module["dynCall_iiiijii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiijii"].apply(null, arguments) -}; - -var dynCall_viiij = Module["dynCall_viiij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiij"].apply(null, arguments) -}; - -var dynCall_viiiiiiiiii = Module["dynCall_viiiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiiiiiiiii"].apply(null, arguments) -}; - -var dynCall_iiiji = Module["dynCall_iiiji"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiji"].apply(null, arguments) -}; - -var dynCall_i = Module["dynCall_i"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_i"].apply(null, arguments) -}; - -var dynCall_viiiiiii = Module["dynCall_viiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiiiiii"].apply(null, arguments) -}; - -var dynCall_viiiiiiiiiiii = Module["dynCall_viiiiiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiiiiiiiiiii"].apply(null, arguments) -}; - -var dynCall_iidd = Module["dynCall_iidd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iidd"].apply(null, arguments) -}; - -var dynCall_iidddddd = Module["dynCall_iidddddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iidddddd"].apply(null, arguments) -}; - -var dynCall_vidd = Module["dynCall_vidd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_vidd"].apply(null, arguments) -}; - -var dynCall_vidddd = Module["dynCall_vidddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_vidddd"].apply(null, arguments) -}; - -var dynCall_viidddd = Module["dynCall_viidddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viidddd"].apply(null, arguments) -}; - -var dynCall_viidddddd = Module["dynCall_viidddddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viidddddd"].apply(null, arguments) -}; - -var dynCall_iiiiiddd = Module["dynCall_iiiiiddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiiddd"].apply(null, arguments) -}; - -var dynCall_viiiiddd = Module["dynCall_viiiiddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viiiiddd"].apply(null, arguments) -}; - -var dynCall_diiii = Module["dynCall_diiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_diiii"].apply(null, arguments) -}; - -var dynCall_iiidddd = Module["dynCall_iiidddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiidddd"].apply(null, arguments) -}; - -var dynCall_viddddiii = Module["dynCall_viddddiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_viddddiii"].apply(null, arguments) -}; - -var dynCall_vidddddd = Module["dynCall_vidddddd"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_vidddddd"].apply(null, arguments) -}; - -var dynCall_iiiiiiiiii = Module["dynCall_iiiiiiiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiiiiiii"].apply(null, arguments) -}; - -var dynCall_jiji = Module["dynCall_jiji"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_jiji"].apply(null, arguments) -}; - -var dynCall_iidiiii = Module["dynCall_iidiiii"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iidiiii"].apply(null, arguments) -}; - -var dynCall_iiiiij = Module["dynCall_iiiiij"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiij"].apply(null, arguments) -}; - -var dynCall_iiiiid = Module["dynCall_iiiiid"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiid"].apply(null, arguments) -}; - -var dynCall_iiiiijj = Module["dynCall_iiiiijj"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiijj"].apply(null, arguments) -}; - -var dynCall_iiiiiijj = Module["dynCall_iiiiiijj"] = function() { - assert(runtimeInitialized, 'you need to wait for the runtime to be ready (e.g. wait for main() to be called)'); - assert(!runtimeExited, 'the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)'); - return Module["asm"]["dynCall_iiiiiijj"].apply(null, arguments) -}; - - -function invoke_viiii(index,a1,a2,a3,a4) { - var sp = stackSave(); - try { - dynCall_viiii(index,a1,a2,a3,a4); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +var ___wasm_call_ctors = Module["___wasm_call_ctors"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["__wasm_call_ctors"].apply(null, arguments); +}); +var _runX2T = Module["_runX2T"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["runX2T"].apply(null, arguments); +}); +var _malloc = Module["_malloc"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["malloc"].apply(null, arguments); +}); +var _free = Module["_free"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["free"].apply(null, arguments); +}); +var _main = Module["_main"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["main"].apply(null, arguments); +}); +var _fflush = Module["_fflush"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["fflush"].apply(null, arguments); +}); +var _realloc = Module["_realloc"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["realloc"].apply(null, arguments); +}); +var __ZSt18uncaught_exceptionv = Module["__ZSt18uncaught_exceptionv"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["_ZSt18uncaught_exceptionv"].apply(null, arguments); +}); +var ___errno_location = Module["___errno_location"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["__errno_location"].apply(null, arguments); +}); +var _ntohs = Module["_ntohs"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["ntohs"].apply(null, arguments); +}); +var _htonl = Module["_htonl"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["htonl"].apply(null, arguments); +}); +var _htons = Module["_htons"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["htons"].apply(null, arguments); +}); +var _emscripten_get_global_libc = Module["_emscripten_get_global_libc"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_get_global_libc"].apply(null, arguments); +}); +var ___em_js__initPthreadsJS = Module["___em_js__initPthreadsJS"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["__em_js__initPthreadsJS"].apply(null, arguments); +}); +var ___emscripten_pthread_data_constructor = Module["___emscripten_pthread_data_constructor"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["__emscripten_pthread_data_constructor"].apply(null, arguments); +}); +var __get_tzname = Module["__get_tzname"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["_get_tzname"].apply(null, arguments); +}); +var __get_daylight = Module["__get_daylight"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["_get_daylight"].apply(null, arguments); +}); +var __get_timezone = Module["__get_timezone"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["_get_timezone"].apply(null, arguments); +}); +var _setThrew = Module["_setThrew"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["setThrew"].apply(null, arguments); +}); +var _memalign = Module["_memalign"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["memalign"].apply(null, arguments); +}); +var _emscripten_builtin_free = Module["_emscripten_builtin_free"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_builtin_free"].apply(null, arguments); +}); +var _emscripten_builtin_memalign = Module["_emscripten_builtin_memalign"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_builtin_memalign"].apply(null, arguments); +}); +var _emscripten_main_browser_thread_id = Module["_emscripten_main_browser_thread_id"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_main_browser_thread_id"].apply(null, arguments); +}); +var ___pthread_tsd_run_dtors = Module["___pthread_tsd_run_dtors"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["__pthread_tsd_run_dtors"].apply(null, arguments); +}); +var _emscripten_main_thread_process_queued_calls = Module["_emscripten_main_thread_process_queued_calls"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_main_thread_process_queued_calls"].apply(null, arguments); +}); +var _emscripten_current_thread_process_queued_calls = Module["_emscripten_current_thread_process_queued_calls"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_current_thread_process_queued_calls"].apply(null, arguments); +}); +var _usleep = Module["_usleep"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["usleep"].apply(null, arguments); +}); +var _emscripten_register_main_browser_thread_id = Module["_emscripten_register_main_browser_thread_id"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_register_main_browser_thread_id"].apply(null, arguments); +}); +var _emscripten_async_run_in_main_thread = Module["_emscripten_async_run_in_main_thread"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_async_run_in_main_thread"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread = Module["_emscripten_sync_run_in_main_thread"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_0 = Module["_emscripten_sync_run_in_main_thread_0"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_0"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_1 = Module["_emscripten_sync_run_in_main_thread_1"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_1"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_2 = Module["_emscripten_sync_run_in_main_thread_2"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_2"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_xprintf_varargs = Module["_emscripten_sync_run_in_main_thread_xprintf_varargs"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_xprintf_varargs"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_3 = Module["_emscripten_sync_run_in_main_thread_3"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_3"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_4 = Module["_emscripten_sync_run_in_main_thread_4"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_4"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_5 = Module["_emscripten_sync_run_in_main_thread_5"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_5"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_6 = Module["_emscripten_sync_run_in_main_thread_6"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_6"].apply(null, arguments); +}); +var _emscripten_sync_run_in_main_thread_7 = Module["_emscripten_sync_run_in_main_thread_7"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_sync_run_in_main_thread_7"].apply(null, arguments); +}); +var _emscripten_run_in_main_runtime_thread_js = Module["_emscripten_run_in_main_runtime_thread_js"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_run_in_main_runtime_thread_js"].apply(null, arguments); +}); +var _emscripten_async_queue_on_thread_ = Module["_emscripten_async_queue_on_thread_"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_async_queue_on_thread_"].apply(null, arguments); +}); +var _proxy_main = Module["_proxy_main"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["proxy_main"].apply(null, arguments); +}); +var _emscripten_tls_init = Module["_emscripten_tls_init"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["emscripten_tls_init"].apply(null, arguments); +}); +var dynCall_ii = Module["dynCall_ii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_ii"].apply(null, arguments); +}); +var dynCall_iii = Module["dynCall_iii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iii"].apply(null, arguments); +}); +var dynCall_iiii = Module["dynCall_iiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiii"].apply(null, arguments); +}); +var dynCall_iiiii = Module["dynCall_iiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiii"].apply(null, arguments); +}); +var dynCall_iiiiii = Module["dynCall_iiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiii"].apply(null, arguments); +}); +var dynCall_v = Module["dynCall_v"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_v"].apply(null, arguments); +}); +var dynCall_vi = Module["dynCall_vi"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_vi"].apply(null, arguments); +}); +var dynCall_vii = Module["dynCall_vii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_vii"].apply(null, arguments); +}); +var dynCall_viii = Module["dynCall_viii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viii"].apply(null, arguments); +}); +var dynCall_viiii = Module["dynCall_viiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiii"].apply(null, arguments); +}); +var dynCall_viiiii = Module["dynCall_viiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiiii"].apply(null, arguments); +}); +var dynCall_viiiiii = Module["dynCall_viiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiiiii"].apply(null, arguments); +}); +var dynCall_viiiiiiiii = Module["dynCall_viiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiiiiiiii"].apply(null, arguments); +}); +var stackSave = Module["stackSave"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["stackSave"].apply(null, arguments); +}); +var stackAlloc = Module["stackAlloc"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["stackAlloc"].apply(null, arguments); +}); +var stackRestore = Module["stackRestore"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["stackRestore"].apply(null, arguments); +}); +var __growWasmMemory = Module["__growWasmMemory"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["__growWasmMemory"].apply(null, arguments); +}); +var dynCall_viijii = Module["dynCall_viijii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viijii"].apply(null, arguments); +}); +var dynCall_dii = Module["dynCall_dii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_dii"].apply(null, arguments); +}); +var dynCall_did = Module["dynCall_did"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_did"].apply(null, arguments); +}); +var dynCall_di = Module["dynCall_di"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_di"].apply(null, arguments); +}); +var dynCall_ji = Module["dynCall_ji"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_ji"].apply(null, arguments); +}); +var dynCall_vij = Module["dynCall_vij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_vij"].apply(null, arguments); +}); +var dynCall_jii = Module["dynCall_jii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_jii"].apply(null, arguments); +}); +var dynCall_iiiiiii = Module["dynCall_iiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiiii"].apply(null, arguments); +}); +var dynCall_iiiiiiii = Module["dynCall_iiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiiiii"].apply(null, arguments); +}); +var dynCall_iiiiiiiii = Module["dynCall_iiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiiiiii"].apply(null, arguments); +}); +var dynCall_iidddddi = Module["dynCall_iidddddi"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iidddddi"].apply(null, arguments); +}); +var dynCall_viiiddii = Module["dynCall_viiiddii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiiddii"].apply(null, arguments); +}); +var dynCall_viij = Module["dynCall_viij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viij"].apply(null, arguments); +}); +var dynCall_viji = Module["dynCall_viji"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viji"].apply(null, arguments); +}); +var dynCall_jij = Module["dynCall_jij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_jij"].apply(null, arguments); +}); +var dynCall_iiiijii = Module["dynCall_iiiijii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiijii"].apply(null, arguments); +}); +var dynCall_viiij = Module["dynCall_viiij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiij"].apply(null, arguments); +}); +var dynCall_viiiiiiiiii = Module["dynCall_viiiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiiiiiiiii"].apply(null, arguments); +}); +var dynCall_iiiji = Module["dynCall_iiiji"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiji"].apply(null, arguments); +}); +var dynCall_i = Module["dynCall_i"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_i"].apply(null, arguments); +}); +var dynCall_viiiiiii = Module["dynCall_viiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiiiiii"].apply(null, arguments); +}); +var dynCall_viiiiiiiiiiii = Module["dynCall_viiiiiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiiiiiiiiiii"].apply(null, arguments); +}); +var dynCall_iidd = Module["dynCall_iidd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iidd"].apply(null, arguments); +}); +var dynCall_iidddddd = Module["dynCall_iidddddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iidddddd"].apply(null, arguments); +}); +var dynCall_vidd = Module["dynCall_vidd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_vidd"].apply(null, arguments); +}); +var dynCall_vidddd = Module["dynCall_vidddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_vidddd"].apply(null, arguments); +}); +var dynCall_viidddd = Module["dynCall_viidddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viidddd"].apply(null, arguments); +}); +var dynCall_viidddddd = Module["dynCall_viidddddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viidddddd"].apply(null, arguments); +}); +var dynCall_iiiiiddd = Module["dynCall_iiiiiddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiiddd"].apply(null, arguments); +}); +var dynCall_viiiiddd = Module["dynCall_viiiiddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viiiiddd"].apply(null, arguments); +}); +var dynCall_diiii = Module["dynCall_diiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_diiii"].apply(null, arguments); +}); +var dynCall_iiidddd = Module["dynCall_iiidddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiidddd"].apply(null, arguments); +}); +var dynCall_viddddiii = Module["dynCall_viddddiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_viddddiii"].apply(null, arguments); +}); +var dynCall_vidddddd = Module["dynCall_vidddddd"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_vidddddd"].apply(null, arguments); +}); +var dynCall_iiiiiiiiii = Module["dynCall_iiiiiiiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiiiiiii"].apply(null, arguments); +}); +var dynCall_jiji = Module["dynCall_jiji"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_jiji"].apply(null, arguments); +}); +var dynCall_iidiiii = Module["dynCall_iidiiii"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iidiiii"].apply(null, arguments); +}); +var dynCall_iiiiij = Module["dynCall_iiiiij"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiij"].apply(null, arguments); +}); +var dynCall_iiiiid = Module["dynCall_iiiiid"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiid"].apply(null, arguments); +}); +var dynCall_iiiiijj = Module["dynCall_iiiiijj"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiijj"].apply(null, arguments); +}); +var dynCall_iiiiiijj = Module["dynCall_iiiiiijj"] = (function() { + assert(runtimeInitialized, "you need to wait for the runtime to be ready (e.g. wait for main() to be called)"); + assert(!runtimeExited, "the runtime was exited (use NO_EXIT_RUNTIME to keep it alive after main() exits)"); + return Module["asm"]["dynCall_iiiiiijj"].apply(null, arguments); +}); +function invoke_viiii(index, a1, a2, a3, a4) { + var sp = stackSave(); + try { + dynCall_viiii(index, a1, a2, a3, a4); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_iii(index,a1,a2) { - var sp = stackSave(); - try { - return dynCall_iii(index,a1,a2); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_iii(index, a1, a2) { + var sp = stackSave(); + try { + return dynCall_iii(index, a1, a2); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_iiiii(index,a1,a2,a3,a4) { - var sp = stackSave(); - try { - return dynCall_iiiii(index,a1,a2,a3,a4); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_iiiii(index, a1, a2, a3, a4) { + var sp = stackSave(); + try { + return dynCall_iiiii(index, a1, a2, a3, a4); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_iiii(index,a1,a2,a3) { - var sp = stackSave(); - try { - return dynCall_iiii(index,a1,a2,a3); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_iiii(index, a1, a2, a3) { + var sp = stackSave(); + try { + return dynCall_iiii(index, a1, a2, a3); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_vi(index,a1) { - var sp = stackSave(); - try { - dynCall_vi(index,a1); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_vi(index, a1) { + var sp = stackSave(); + try { + dynCall_vi(index, a1); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_vii(index,a1,a2) { - var sp = stackSave(); - try { - dynCall_vii(index,a1,a2); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_vii(index, a1, a2) { + var sp = stackSave(); + try { + dynCall_vii(index, a1, a2); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_ii(index,a1) { - var sp = stackSave(); - try { - return dynCall_ii(index,a1); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_ii(index, a1) { + var sp = stackSave(); + try { + return dynCall_ii(index, a1); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_viii(index,a1,a2,a3) { - var sp = stackSave(); - try { - dynCall_viii(index,a1,a2,a3); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_viii(index, a1, a2, a3) { + var sp = stackSave(); + try { + dynCall_viii(index, a1, a2, a3); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - function invoke_v(index) { - var sp = stackSave(); - try { - dynCall_v(index); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } + var sp = stackSave(); + try { + dynCall_v(index); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_iiiiii(index,a1,a2,a3,a4,a5) { - var sp = stackSave(); - try { - return dynCall_iiiiii(index,a1,a2,a3,a4,a5); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_iiiiii(index, a1, a2, a3, a4, a5) { + var sp = stackSave(); + try { + return dynCall_iiiiii(index, a1, a2, a3, a4, a5); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_viiiii(index,a1,a2,a3,a4,a5) { - var sp = stackSave(); - try { - dynCall_viiiii(index,a1,a2,a3,a4,a5); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_viiiii(index, a1, a2, a3, a4, a5) { + var sp = stackSave(); + try { + dynCall_viiiii(index, a1, a2, a3, a4, a5); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_viiiiii(index,a1,a2,a3,a4,a5,a6) { - var sp = stackSave(); - try { - dynCall_viiiiii(index,a1,a2,a3,a4,a5,a6); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_viiiiii(index, a1, a2, a3, a4, a5, a6) { + var sp = stackSave(); + try { + dynCall_viiiiii(index, a1, a2, a3, a4, a5, a6); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - -function invoke_viiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9) { - var sp = stackSave(); - try { - dynCall_viiiiiiiii(index,a1,a2,a3,a4,a5,a6,a7,a8,a9); - } catch(e) { - stackRestore(sp); - if (e !== e+0 && e !== 'longjmp') throw e; - _setThrew(1, 0); - } +function invoke_viiiiiiiii(index, a1, a2, a3, a4, a5, a6, a7, a8, a9) { + var sp = stackSave(); + try { + dynCall_viiiiiiiii(index, a1, a2, a3, a4, a5, a6, a7, a8, a9); + } catch (e) { + stackRestore(sp); + if (e !== e + 0 && e !== "longjmp") throw e; + _setThrew(1, 0); + } } - - - -// === Auto-generated postamble setup entry stuff === - -Module['asm'] = asm; - -if (!Object.getOwnPropertyDescriptor(Module, "intArrayFromString")) Module["intArrayFromString"] = function() { abort("'intArrayFromString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "intArrayToString")) Module["intArrayToString"] = function() { abort("'intArrayToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; +Module["asm"] = asm; +if (!Object.getOwnPropertyDescriptor(Module, "intArrayFromString")) Module["intArrayFromString"] = (function() { + abort("'intArrayFromString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "intArrayToString")) Module["intArrayToString"] = (function() { + abort("'intArrayToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); Module["ccall"] = ccall; -if (!Object.getOwnPropertyDescriptor(Module, "cwrap")) Module["cwrap"] = function() { abort("'cwrap' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "setValue")) Module["setValue"] = function() { abort("'setValue' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "getValue")) Module["getValue"] = function() { abort("'getValue' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "allocate")) Module["allocate"] = function() { abort("'allocate' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "getMemory")) Module["getMemory"] = function() { abort("'getMemory' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "AsciiToString")) Module["AsciiToString"] = function() { abort("'AsciiToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stringToAscii")) Module["stringToAscii"] = function() { abort("'stringToAscii' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "UTF8ArrayToString")) Module["UTF8ArrayToString"] = function() { abort("'UTF8ArrayToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "UTF8ToString")) Module["UTF8ToString"] = function() { abort("'UTF8ToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stringToUTF8Array")) Module["stringToUTF8Array"] = function() { abort("'stringToUTF8Array' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stringToUTF8")) Module["stringToUTF8"] = function() { abort("'stringToUTF8' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "lengthBytesUTF8")) Module["lengthBytesUTF8"] = function() { abort("'lengthBytesUTF8' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "UTF16ToString")) Module["UTF16ToString"] = function() { abort("'UTF16ToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stringToUTF16")) Module["stringToUTF16"] = function() { abort("'stringToUTF16' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "lengthBytesUTF16")) Module["lengthBytesUTF16"] = function() { abort("'lengthBytesUTF16' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "UTF32ToString")) Module["UTF32ToString"] = function() { abort("'UTF32ToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stringToUTF32")) Module["stringToUTF32"] = function() { abort("'stringToUTF32' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "lengthBytesUTF32")) Module["lengthBytesUTF32"] = function() { abort("'lengthBytesUTF32' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "allocateUTF8")) Module["allocateUTF8"] = function() { abort("'allocateUTF8' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stackTrace")) Module["stackTrace"] = function() { abort("'stackTrace' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "addOnPreRun")) Module["addOnPreRun"] = function() { abort("'addOnPreRun' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "addOnInit")) Module["addOnInit"] = function() { abort("'addOnInit' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "addOnPreMain")) Module["addOnPreMain"] = function() { abort("'addOnPreMain' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "addOnExit")) Module["addOnExit"] = function() { abort("'addOnExit' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "addOnPostRun")) Module["addOnPostRun"] = function() { abort("'addOnPostRun' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "writeStringToMemory")) Module["writeStringToMemory"] = function() { abort("'writeStringToMemory' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "writeArrayToMemory")) Module["writeArrayToMemory"] = function() { abort("'writeArrayToMemory' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "writeAsciiToMemory")) Module["writeAsciiToMemory"] = function() { abort("'writeAsciiToMemory' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "addRunDependency")) Module["addRunDependency"] = function() { abort("'addRunDependency' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "removeRunDependency")) Module["removeRunDependency"] = function() { abort("'removeRunDependency' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "ENV")) Module["ENV"] = function() { abort("'ENV' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS")) Module["FS"] = function() { abort("'FS' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS_createFolder")) Module["FS_createFolder"] = function() { abort("'FS_createFolder' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS_createPath")) Module["FS_createPath"] = function() { abort("'FS_createPath' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS_createDataFile")) Module["FS_createDataFile"] = function() { abort("'FS_createDataFile' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS_createPreloadedFile")) Module["FS_createPreloadedFile"] = function() { abort("'FS_createPreloadedFile' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS_createLazyFile")) Module["FS_createLazyFile"] = function() { abort("'FS_createLazyFile' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS_createLink")) Module["FS_createLink"] = function() { abort("'FS_createLink' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS_createDevice")) Module["FS_createDevice"] = function() { abort("'FS_createDevice' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "FS_unlink")) Module["FS_unlink"] = function() { abort("'FS_unlink' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") }; -if (!Object.getOwnPropertyDescriptor(Module, "GL")) Module["GL"] = function() { abort("'GL' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "dynamicAlloc")) Module["dynamicAlloc"] = function() { abort("'dynamicAlloc' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "loadDynamicLibrary")) Module["loadDynamicLibrary"] = function() { abort("'loadDynamicLibrary' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "loadWebAssemblyModule")) Module["loadWebAssemblyModule"] = function() { abort("'loadWebAssemblyModule' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "getLEB")) Module["getLEB"] = function() { abort("'getLEB' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "getFunctionTables")) Module["getFunctionTables"] = function() { abort("'getFunctionTables' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "alignFunctionTables")) Module["alignFunctionTables"] = function() { abort("'alignFunctionTables' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "registerFunctions")) Module["registerFunctions"] = function() { abort("'registerFunctions' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "addFunction")) Module["addFunction"] = function() { abort("'addFunction' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "removeFunction")) Module["removeFunction"] = function() { abort("'removeFunction' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "getFuncWrapper")) Module["getFuncWrapper"] = function() { abort("'getFuncWrapper' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "prettyPrint")) Module["prettyPrint"] = function() { abort("'prettyPrint' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "makeBigInt")) Module["makeBigInt"] = function() { abort("'makeBigInt' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "dynCall")) Module["dynCall"] = function() { abort("'dynCall' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "getCompilerSetting")) Module["getCompilerSetting"] = function() { abort("'getCompilerSetting' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stackSave")) Module["stackSave"] = function() { abort("'stackSave' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stackRestore")) Module["stackRestore"] = function() { abort("'stackRestore' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "stackAlloc")) Module["stackAlloc"] = function() { abort("'stackAlloc' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; +if (!Object.getOwnPropertyDescriptor(Module, "cwrap")) Module["cwrap"] = (function() { + abort("'cwrap' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "setValue")) Module["setValue"] = (function() { + abort("'setValue' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "getValue")) Module["getValue"] = (function() { + abort("'getValue' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "allocate")) Module["allocate"] = (function() { + abort("'allocate' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "getMemory")) Module["getMemory"] = (function() { + abort("'getMemory' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "AsciiToString")) Module["AsciiToString"] = (function() { + abort("'AsciiToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stringToAscii")) Module["stringToAscii"] = (function() { + abort("'stringToAscii' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "UTF8ArrayToString")) Module["UTF8ArrayToString"] = (function() { + abort("'UTF8ArrayToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "UTF8ToString")) Module["UTF8ToString"] = (function() { + abort("'UTF8ToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stringToUTF8Array")) Module["stringToUTF8Array"] = (function() { + abort("'stringToUTF8Array' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stringToUTF8")) Module["stringToUTF8"] = (function() { + abort("'stringToUTF8' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "lengthBytesUTF8")) Module["lengthBytesUTF8"] = (function() { + abort("'lengthBytesUTF8' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "UTF16ToString")) Module["UTF16ToString"] = (function() { + abort("'UTF16ToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stringToUTF16")) Module["stringToUTF16"] = (function() { + abort("'stringToUTF16' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "lengthBytesUTF16")) Module["lengthBytesUTF16"] = (function() { + abort("'lengthBytesUTF16' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "UTF32ToString")) Module["UTF32ToString"] = (function() { + abort("'UTF32ToString' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stringToUTF32")) Module["stringToUTF32"] = (function() { + abort("'stringToUTF32' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "lengthBytesUTF32")) Module["lengthBytesUTF32"] = (function() { + abort("'lengthBytesUTF32' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "allocateUTF8")) Module["allocateUTF8"] = (function() { + abort("'allocateUTF8' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stackTrace")) Module["stackTrace"] = (function() { + abort("'stackTrace' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "addOnPreRun")) Module["addOnPreRun"] = (function() { + abort("'addOnPreRun' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "addOnInit")) Module["addOnInit"] = (function() { + abort("'addOnInit' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "addOnPreMain")) Module["addOnPreMain"] = (function() { + abort("'addOnPreMain' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "addOnExit")) Module["addOnExit"] = (function() { + abort("'addOnExit' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "addOnPostRun")) Module["addOnPostRun"] = (function() { + abort("'addOnPostRun' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "writeStringToMemory")) Module["writeStringToMemory"] = (function() { + abort("'writeStringToMemory' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "writeArrayToMemory")) Module["writeArrayToMemory"] = (function() { + abort("'writeArrayToMemory' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "writeAsciiToMemory")) Module["writeAsciiToMemory"] = (function() { + abort("'writeAsciiToMemory' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "addRunDependency")) Module["addRunDependency"] = (function() { + abort("'addRunDependency' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "removeRunDependency")) Module["removeRunDependency"] = (function() { + abort("'removeRunDependency' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "ENV")) Module["ENV"] = (function() { + abort("'ENV' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS")) Module["FS"] = (function() { + abort("'FS' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS_createFolder")) Module["FS_createFolder"] = (function() { + abort("'FS_createFolder' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS_createPath")) Module["FS_createPath"] = (function() { + abort("'FS_createPath' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS_createDataFile")) Module["FS_createDataFile"] = (function() { + abort("'FS_createDataFile' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS_createPreloadedFile")) Module["FS_createPreloadedFile"] = (function() { + abort("'FS_createPreloadedFile' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS_createLazyFile")) Module["FS_createLazyFile"] = (function() { + abort("'FS_createLazyFile' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS_createLink")) Module["FS_createLink"] = (function() { + abort("'FS_createLink' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS_createDevice")) Module["FS_createDevice"] = (function() { + abort("'FS_createDevice' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "FS_unlink")) Module["FS_unlink"] = (function() { + abort("'FS_unlink' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "GL")) Module["GL"] = (function() { + abort("'GL' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "dynamicAlloc")) Module["dynamicAlloc"] = (function() { + abort("'dynamicAlloc' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "loadDynamicLibrary")) Module["loadDynamicLibrary"] = (function() { + abort("'loadDynamicLibrary' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "loadWebAssemblyModule")) Module["loadWebAssemblyModule"] = (function() { + abort("'loadWebAssemblyModule' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "getLEB")) Module["getLEB"] = (function() { + abort("'getLEB' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "getFunctionTables")) Module["getFunctionTables"] = (function() { + abort("'getFunctionTables' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "alignFunctionTables")) Module["alignFunctionTables"] = (function() { + abort("'alignFunctionTables' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "registerFunctions")) Module["registerFunctions"] = (function() { + abort("'registerFunctions' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "addFunction")) Module["addFunction"] = (function() { + abort("'addFunction' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "removeFunction")) Module["removeFunction"] = (function() { + abort("'removeFunction' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "getFuncWrapper")) Module["getFuncWrapper"] = (function() { + abort("'getFuncWrapper' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "prettyPrint")) Module["prettyPrint"] = (function() { + abort("'prettyPrint' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "makeBigInt")) Module["makeBigInt"] = (function() { + abort("'makeBigInt' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "dynCall")) Module["dynCall"] = (function() { + abort("'dynCall' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "getCompilerSetting")) Module["getCompilerSetting"] = (function() { + abort("'getCompilerSetting' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stackSave")) Module["stackSave"] = (function() { + abort("'stackSave' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stackRestore")) Module["stackRestore"] = (function() { + abort("'stackRestore' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "stackAlloc")) Module["stackAlloc"] = (function() { + abort("'stackAlloc' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); Module["establishStackSpace"] = establishStackSpace; -if (!Object.getOwnPropertyDescriptor(Module, "print")) Module["print"] = function() { abort("'print' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "printErr")) Module["printErr"] = function() { abort("'printErr' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "getTempRet0")) Module["getTempRet0"] = function() { abort("'getTempRet0' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "setTempRet0")) Module["setTempRet0"] = function() { abort("'setTempRet0' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "callMain")) Module["callMain"] = function() { abort("'callMain' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "abort")) Module["abort"] = function() { abort("'abort' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "Pointer_stringify")) Module["Pointer_stringify"] = function() { abort("'Pointer_stringify' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; -if (!Object.getOwnPropertyDescriptor(Module, "warnOnce")) Module["warnOnce"] = function() { abort("'warnOnce' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") }; +if (!Object.getOwnPropertyDescriptor(Module, "print")) Module["print"] = (function() { + abort("'print' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "printErr")) Module["printErr"] = (function() { + abort("'printErr' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "getTempRet0")) Module["getTempRet0"] = (function() { + abort("'getTempRet0' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "setTempRet0")) Module["setTempRet0"] = (function() { + abort("'setTempRet0' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "callMain")) Module["callMain"] = (function() { + abort("'callMain' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "abort")) Module["abort"] = (function() { + abort("'abort' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "Pointer_stringify")) Module["Pointer_stringify"] = (function() { + abort("'Pointer_stringify' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); +if (!Object.getOwnPropertyDescriptor(Module, "warnOnce")) Module["warnOnce"] = (function() { + abort("'warnOnce' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); +}); Module["writeStackCookie"] = writeStackCookie; Module["checkStackCookie"] = checkStackCookie; Module["abortStackOverflow"] = abortStackOverflow; @@ -9226,230 +8762,168 @@ Module["wasmMemory"] = wasmMemory; Module["_pthread_self"] = _pthread_self; Module["ExitStatus"] = ExitStatus; Module["tempDoublePtr"] = tempDoublePtr; -Module["dynCall_ii"] = dynCall_ii;if (!Object.getOwnPropertyDescriptor(Module, "ALLOC_NORMAL")) Object.defineProperty(Module, "ALLOC_NORMAL", { configurable: true, get: function() { abort("'ALLOC_NORMAL' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") } }); -if (!Object.getOwnPropertyDescriptor(Module, "ALLOC_STACK")) Object.defineProperty(Module, "ALLOC_STACK", { configurable: true, get: function() { abort("'ALLOC_STACK' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") } }); -if (!Object.getOwnPropertyDescriptor(Module, "ALLOC_DYNAMIC")) Object.defineProperty(Module, "ALLOC_DYNAMIC", { configurable: true, get: function() { abort("'ALLOC_DYNAMIC' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") } }); -if (!Object.getOwnPropertyDescriptor(Module, "ALLOC_NONE")) Object.defineProperty(Module, "ALLOC_NONE", { configurable: true, get: function() { abort("'ALLOC_NONE' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)") } }); -if (!Object.getOwnPropertyDescriptor(Module, "calledRun")) Object.defineProperty(Module, "calledRun", { configurable: true, get: function() { abort("'calledRun' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you") } }); - - - +Module["dynCall_ii"] = dynCall_ii; +if (!Object.getOwnPropertyDescriptor(Module, "ALLOC_NORMAL")) Object.defineProperty(Module, "ALLOC_NORMAL", { + configurable: true, + get: (function() { + abort("'ALLOC_NORMAL' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); + }) +}); +if (!Object.getOwnPropertyDescriptor(Module, "ALLOC_STACK")) Object.defineProperty(Module, "ALLOC_STACK", { + configurable: true, + get: (function() { + abort("'ALLOC_STACK' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); + }) +}); +if (!Object.getOwnPropertyDescriptor(Module, "ALLOC_DYNAMIC")) Object.defineProperty(Module, "ALLOC_DYNAMIC", { + configurable: true, + get: (function() { + abort("'ALLOC_DYNAMIC' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); + }) +}); +if (!Object.getOwnPropertyDescriptor(Module, "ALLOC_NONE")) Object.defineProperty(Module, "ALLOC_NONE", { + configurable: true, + get: (function() { + abort("'ALLOC_NONE' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ)"); + }) +}); +if (!Object.getOwnPropertyDescriptor(Module, "calledRun")) Object.defineProperty(Module, "calledRun", { + configurable: true, + get: (function() { + abort("'calledRun' was not exported. add it to EXTRA_EXPORTED_RUNTIME_METHODS (see the FAQ). Alternatively, forcing filesystem support (-s FORCE_FILESYSTEM=1) can export this for you"); + }) +}); var calledRun; - - -/** - * @constructor - * @this {ExitStatus} - */ function ExitStatus(status) { - this.name = "ExitStatus"; - this.message = "Program terminated with exit(" + status + ")"; - this.status = status; + this.name = "ExitStatus"; + this.message = "Program terminated with exit(" + status + ")"; + this.status = status; } - var calledMain = false; - - dependenciesFulfilled = function runCaller() { - // If run has never been called, and we should call run (INVOKE_RUN is true, and Module.noInitialRun is not false) - if (!calledRun) run(); - if (!calledRun) dependenciesFulfilled = runCaller; // try this again later, after new deps are fulfilled + if (!calledRun) run(); + if (!calledRun) dependenciesFulfilled = runCaller; }; - function callMain(args) { - assert(runDependencies == 0, 'cannot call main when async dependencies remain! (listen on Module["onRuntimeInitialized"])'); - assert(__ATPRERUN__.length == 0, 'cannot call main when preRun functions remain to be called'); - - var entryFunction = Module['_main']; - - - args = args || []; - - var argc = args.length+1; - var argv = stackAlloc((argc + 1) * 4); - HEAP32[argv >> 2] = allocateUTF8OnStack(thisProgram); - for (var i = 1; i < argc; i++) { - HEAP32[(argv >> 2) + i] = allocateUTF8OnStack(args[i - 1]); - } - HEAP32[(argv >> 2) + argc] = 0; - - - try { - - - var ret = entryFunction(argc, argv); - - - // if we're not running an evented main loop, it's time to exit - exit(ret, /* implicit = */ true); - } - catch(e) { - if (e instanceof ExitStatus) { - // exit() throws this once it's done to make sure execution - // has been stopped completely - return; - } else if (e == 'SimulateInfiniteLoop') { - // running an evented main loop, don't immediately exit - noExitRuntime = true; - return; - } else { - var toLog = e; - if (e && typeof e === 'object' && e.stack) { - toLog = [e, e.stack]; - } - err('exception thrown: ' + toLog); - quit_(1, e); - } - } finally { - calledMain = true; - } + assert(runDependencies == 0, 'cannot call main when async dependencies remain! (listen on Module["onRuntimeInitialized"])'); + assert(__ATPRERUN__.length == 0, "cannot call main when preRun functions remain to be called"); + var entryFunction = Module["_main"]; + args = args || []; + var argc = args.length + 1; + var argv = stackAlloc((argc + 1) * 4); + GROWABLE_HEAP_STORE_I32(argv | 0, allocateUTF8OnStack(thisProgram)); + for (var i = 1; i < argc; i++) { + GROWABLE_HEAP_STORE_I32(((argv >> 2) + i) * 4 | 0, allocateUTF8OnStack(args[i - 1])); + } + GROWABLE_HEAP_STORE_I32(((argv >> 2) + argc) * 4 | 0, 0); + try { + var ret = entryFunction(argc, argv); + exit(ret, true); + } catch (e) { + if (e instanceof ExitStatus) { + return; + } else if (e == "SimulateInfiniteLoop") { + noExitRuntime = true; + return; + } else { + var toLog = e; + if (e && typeof e === "object" && e.stack) { + toLog = [ e, e.stack ]; + } + err("exception thrown: " + toLog); + quit_(1, e); + } + } finally { + calledMain = true; + } } - - - - -/** @type {function(Array=)} */ function run(args) { - args = args || arguments_; - - if (runDependencies > 0) { - return; - } - - writeStackCookie(); - - preRun(); - - if (runDependencies > 0) return; // a preRun added a dependency, run will be called later - - function doRun() { - // run may have just been called through dependencies being fulfilled just in this very frame, - // or while the async setStatus time below was happening - if (calledRun) return; - calledRun = true; - - if (ABORT) return; - - initRuntime(); - - preMain(); - - if (Module['onRuntimeInitialized']) Module['onRuntimeInitialized'](); - - if (shouldRunNow) callMain(args); - - postRun(); - } - - if (Module['setStatus']) { - Module['setStatus']('Running...'); - setTimeout(function() { - setTimeout(function() { - Module['setStatus'](''); - }, 1); - doRun(); - }, 1); - } else - { - doRun(); - } - checkStackCookie(); + args = args || arguments_; + if (runDependencies > 0) { + return; + } + writeStackCookie(); + preRun(); + if (runDependencies > 0) return; + function doRun() { + if (calledRun) return; + calledRun = true; + if (ABORT) return; + initRuntime(); + preMain(); + if (Module["onRuntimeInitialized"]) Module["onRuntimeInitialized"](); + if (shouldRunNow) callMain(args); + postRun(); + } + if (Module["setStatus"]) { + Module["setStatus"]("Running..."); + setTimeout((function() { + setTimeout((function() { + Module["setStatus"](""); + }), 1); + doRun(); + }), 1); + } else { + doRun(); + } + checkStackCookie(); } -Module['run'] = run; - +Module["run"] = run; function checkUnflushedContent() { - // Compiler settings do not allow exiting the runtime, so flushing - // the streams is not possible. but in ASSERTIONS mode we check - // if there was something to flush, and if so tell the user they - // should request that the runtime be exitable. - // Normally we would not even include flush() at all, but in ASSERTIONS - // builds we do so just for this check, and here we see if there is any - // content to flush, that is, we check if there would have been - // something a non-ASSERTIONS build would have not seen. - // How we flush the streams depends on whether we are in SYSCALLS_REQUIRE_FILESYSTEM=0 - // mode (which has its own special function for this; otherwise, all - // the code is inside libc) - var print = out; - var printErr = err; - var has = false; - out = err = function(x) { + var print = out; + var printErr = err; + var has = false; + out = err = (function(x) { + has = true; + }); + try { + var flush = Module["_fflush"]; + if (flush) flush(0); + [ "stdout", "stderr" ].forEach((function(name) { + var info = FS.analyzePath("/dev/" + name); + if (!info) return; + var stream = info.object; + var rdev = stream.rdev; + var tty = TTY.ttys[rdev]; + if (tty && tty.output && tty.output.length) { has = true; - } - try { // it doesn't matter if it fails - var flush = Module['_fflush']; - if (flush) flush(0); - // also flush in the JS FS layer - ['stdout', 'stderr'].forEach(function(name) { - var info = FS.analyzePath('/dev/' + name); - if (!info) return; - var stream = info.object; - var rdev = stream.rdev; - var tty = TTY.ttys[rdev]; - if (tty && tty.output && tty.output.length) { - has = true; - } - }); - } catch(e) {} - out = print; - err = printErr; - if (has) { - warnOnce('stdio streams had content in them that was not flushed. you should set EXIT_RUNTIME to 1 (see the FAQ), or make sure to emit a newline when you printf etc.'); - } + } + })); + } catch (e) {} + out = print; + err = printErr; + if (has) { + warnOnce("stdio streams had content in them that was not flushed. you should set EXIT_RUNTIME to 1 (see the FAQ), or make sure to emit a newline when you printf etc."); + } } - function exit(status, implicit) { - checkUnflushedContent(); - - // if this is just main exit-ing implicitly, and the status is 0, then we - // don't need to do anything here and can just leave. if the status is - // non-zero, though, then we need to report it. - // (we may have warned about this earlier, if a situation justifies doing so) - if (implicit && noExitRuntime && status === 0) { - return; - } - - if (noExitRuntime) { - // if exit() was called, we may warn the user if the runtime isn't actually being shut down - if (!implicit) { - err('program exited (with status: ' + status + '), but EXIT_RUNTIME is not set, so halting execution but not exiting the runtime or preventing further async execution (build with EXIT_RUNTIME=1, if you want a true shutdown)'); - } - } else { - PThread.terminateAllThreads(); - - ABORT = true; - EXITSTATUS = status; - - exitRuntime(); - - if (Module['onExit']) Module['onExit'](status); - } - - quit_(status, new ExitStatus(status)); + checkUnflushedContent(); + if (implicit && noExitRuntime && status === 0) { + return; + } + if (noExitRuntime) { + if (!implicit) { + err("program exited (with status: " + status + "), but EXIT_RUNTIME is not set, so halting execution but not exiting the runtime or preventing further async execution (build with EXIT_RUNTIME=1, if you want a true shutdown)"); + } + } else { + PThread.terminateAllThreads(); + ABORT = true; + EXITSTATUS = status; + exitRuntime(); + if (Module["onExit"]) Module["onExit"](status); + } + quit_(status, new ExitStatus(status)); } - -if (Module['preInit']) { - if (typeof Module['preInit'] == 'function') Module['preInit'] = [Module['preInit']]; - while (Module['preInit'].length > 0) { - Module['preInit'].pop()(); - } +if (Module["preInit"]) { + if (typeof Module["preInit"] == "function") Module["preInit"] = [ Module["preInit"] ]; + while (Module["preInit"].length > 0) { + Module["preInit"].pop()(); + } } - -// shouldRunNow refers to calling main(), not run(). var shouldRunNow = true; - -if (Module['noInitialRun']) shouldRunNow = false; - - -if (!ENVIRONMENT_IS_PTHREAD) // EXIT_RUNTIME=0 only applies to default behavior of the main browser thread - noExitRuntime = true; - +if (Module["noInitialRun"]) shouldRunNow = false; +if (!ENVIRONMENT_IS_PTHREAD) noExitRuntime = true; if (!ENVIRONMENT_IS_PTHREAD) run(); - - -// {{MODULE_ADDITIONS}} - - - diff --git a/www/common/onlyoffice/x2t/x2t.wasm b/www/common/onlyoffice/x2t/x2t.wasm index 0f5879bef..3a35af86a 100644 Binary files a/www/common/onlyoffice/x2t/x2t.wasm and b/www/common/onlyoffice/x2t/x2t.wasm differ diff --git a/www/common/outer/async-store.js b/www/common/outer/async-store.js index 574b2584a..885bc1131 100644 --- a/www/common/outer/async-store.js +++ b/www/common/outer/async-store.js @@ -727,10 +727,13 @@ define([ // Owned drive if (metadata && metadata.owners && metadata.owners.length === 1 && metadata.owners.indexOf(edPublic) !== -1) { + var token; nThen(function (waitFor) { + self.accountDeletion = clientId; + // Log out from other workers var token = Math.floor(Math.random()*Number.MAX_SAFE_INTEGER); store.proxy[Constants.tokenKey] = token; - postMessage(clientId, "DELETE_ACCOUNT", token, waitFor()); + onSync(null, waitFor()); }).nThen(function (waitFor) { removeOwnedPads(waitFor); }).nThen(function (waitFor) { @@ -745,6 +748,10 @@ define([ force: true }, waitFor()); }).nThen(function () { + // XXX users need to login after registration if they register after account deletion (token issue?) + // XXX delete block + // Log out current worker + postMessage(clientId, "DELETE_ACCOUNT", token, function () {}); store.network.disconnect(); cb({ state: true @@ -2663,6 +2670,7 @@ define([ }; Store.disconnect = function () { + if (self.accountDeletion) { return; } if (!store.network) { return; } store.network.disconnect(); }; diff --git a/www/common/outer/mailbox.js b/www/common/outer/mailbox.js index 8e29333be..706f1c8c2 100644 --- a/www/common/outer/mailbox.js +++ b/www/common/outer/mailbox.js @@ -134,13 +134,8 @@ proxy.mailboxes = { // If the hash in in our history, get the index from the history: // - if the index is 0, we can change our lastKnownHash // - otherwise, just push to view - var idx; - if (box.history.some(function (el, i) { - if (hash === el) { - idx = i; - return true; - } - })) { + var idx = box.history.indexOf(hash); + if (idx !== -1) { if (idx === 0) { m.lastKnownHash = hash; box.history.shift(); @@ -153,15 +148,25 @@ proxy.mailboxes = { // Check the "viewed" array to see if we're able to bump lastKnownhash more var sliceIdx; var lastKnownHash; + var toForget = []; box.history.some(function (hash, i) { + // naming here is confusing... isViewed implies it's a boolean + // when in fact it's an index var isViewed = m.viewed.indexOf(hash); - if (isViewed !== -1) { - sliceIdx = i + 1; - m.viewed.splice(isViewed, 1); - lastKnownHash = hash; - return false; - } - return true; + + // iterate over your history until you hit an element you haven't viewed + if (isViewed === -1) { return true; } + // update the index that you'll use to slice off viewed parts of history + sliceIdx = i + 1; + // keep track of which hashes you should remove from your 'viewed' array + toForget.push(hash); + // prevent fetching dismissed messages on (re)connect + lastKnownHash = hash; + }); + + // remove all elements in 'toForget' from the 'viewed' array in one step + m.viewed = m.viewed.filter(function (hash) { + return toForget.indexOf(hash) === -1; }); if (sliceIdx) { diff --git a/www/common/outer/sharedworker.js b/www/common/outer/sharedworker.js index 706512847..a89376407 100644 --- a/www/common/outer/sharedworker.js +++ b/www/common/outer/sharedworker.js @@ -63,8 +63,11 @@ var init = function (client, cb) { } if (q === "DISCONNECT") { console.log('Deleting existing store!'); - delete self.Rpc; - delete self.store; + client.close(); + if (self.accountDeletion && self.accountDeletion === client.id) { + delete self.Rpc; + delete self.store; + } } }); }); diff --git a/www/common/sframe-app-framework.js b/www/common/sframe-app-framework.js index e690bfb08..6e10b0a77 100644 --- a/www/common/sframe-app-framework.js +++ b/www/common/sframe-app-framework.js @@ -433,21 +433,37 @@ define([ var ext = (typeof(extension) === 'function') ? extension() : extension; var suggestion = title.suggestTitle('cryptpad-document'); ext = ext || '.txt'; - var types = [{ - tag: 'a', - attributes: { - 'data-value': ext, - 'href': '#' - }, - content: ext - }, { + var types = []; + if (Array.isArray(ext) && ext.length) { + ext.forEach(function (_ext) { + types.push({ + tag: 'a', + attributes: { + 'data-value': _ext, + 'href': '#' + }, + content: _ext + }); + }); + ext = ext[0]; + } else { + types.push({ + tag: 'a', + attributes: { + 'data-value': ext, + 'href': '#' + }, + content: ext + }); + } + types.push({ tag: 'a', attributes: { 'data-value': '', 'href': '#' }, content: ' ' - }]; + }); var dropdownConfig = { text: ext, // Button initial text caretDown: true, @@ -461,14 +477,15 @@ define([ Util.fixFileName(suggestion), function (filename) { if (!(typeof(filename) === 'string' && filename)) { return; } - filename = filename + $select.getValue(); + var ext = $select.getValue(); + filename = filename + ext; if (async) { fe(function (blob) { SaveAs(blob, filename); - }); + }, ext); return; } - var blob = fe(); + var blob = fe(null, ext); SaveAs(blob, filename); }, { typeInput: $select[0] diff --git a/www/common/sframe-common-codemirror.js b/www/common/sframe-common-codemirror.js index fe251e696..c3e3b2566 100644 --- a/www/common/sframe-common-codemirror.js +++ b/www/common/sframe-common-codemirror.js @@ -176,14 +176,14 @@ define([ updateIndentSettings(); }; - module.create = function (defaultMode, CMeditor) { + module.create = function (defaultMode, CMeditor, textarea) { var exp = {}; var CodeMirror = exp.CodeMirror = CMeditor; CodeMirror.modeURL = "cm/mode/%N/%N"; var $pad = $('#pad-iframe'); - var $textarea = exp.$textarea = $('#editor1'); + var $textarea = exp.$textarea = textarea ? $(textarea) : $('#editor1'); if (!$textarea.length) { $textarea = exp.$textarea = $pad.contents().find('#editor1'); } var Title; @@ -311,14 +311,7 @@ define([ common: Common }; var $block = exp.$language = UIElements.createDropdown(dropdownConfig); - $block.find('button').attr('title', Messages.languageButtonTitle).click(function () { - var state = $block.find('.cp-dropdown-content').is(':visible'); - var $c = $block.closest('.cp-toolbar-drawer-content'); - $c.removeClass('cp-dropdown-visible'); - if (!state) { - $c.addClass('cp-dropdown-visible'); - } - }); + $block.find('button').attr('title', Messages.languageButtonTitle); var isHovering = false; var $aLanguages = $block.find('a'); diff --git a/www/common/sframe-common.js b/www/common/sframe-common.js index 4fe715cf9..3d5df4f03 100644 --- a/www/common/sframe-common.js +++ b/www/common/sframe-common.js @@ -202,6 +202,33 @@ define([ }; }; + funcs.getAuthorId = function () { + }; + + var authorUid = function(existing) { + if (!Array.isArray(existing)) { existing = []; } + var n; + var i = 0; + while (!n || existing.indexOf(n) !== -1 && i++ < 1000) { + n = Math.floor(Math.random() * 1000000); + } + // If we can't find a valid number in 1000 iterations, use 0... + if (existing.indexOf(n) !== -1) { n = 0; } + return n; + }; + funcs.getAuthorId = function(authors, curve) { + var existing = Object.keys(authors || {}).map(Number); + if (!funcs.isLoggedIn()) { return authorUid(existing); } + + var uid; + existing.some(function(id) { + var author = authors[id] || {}; + if (author.curvePublic !== curve) { return; } + uid = Number(id); + return true; + }); + return uid || authorUid(existing); + }; // Chat var padChatChannel; diff --git a/www/common/translations/old/messages.de.js b/www/common/translations/old/messages.de.js deleted file mode 100644 index eb6dd4361..000000000 --- a/www/common/translations/old/messages.de.js +++ /dev/null @@ -1,1352 +0,0 @@ -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - - // translations must set this key for their language to be available in - // the language dropdowns that are shown throughout Cryptpad's interface - out._languageName = 'German'; - - out.main_title = "CryptPad: Zusammenarbeit in Echtzeit ohne Preisgabe von Informationen"; - - out.type = {}; - out.type.pad = 'Rich Text'; - out.type.code = 'Code'; - out.type.poll = 'Umfrage'; - out.type.kanban = 'Kanban'; - out.type.slide = 'Präsentation'; - out.type.drive = 'CryptDrive'; - out.type.whiteboard = 'Whiteboard'; - out.type.file = 'Datei'; - out.type.media = 'Medien'; - out.type.todo = 'Aufgaben'; - out.type.contacts = 'Kontakte'; - out.type.sheet = 'Tabelle (Beta)'; - - out.button_newpad = 'Neues Rich-Text-Pad'; - out.button_newcode = 'Neues Code-Pad'; - out.button_newpoll = 'Neue Umfrage'; - out.button_newslide = 'Neue Präsentation'; - out.button_newwhiteboard = 'Neues Whiteboard'; - out.button_newkanban = 'Neues Kanban'; - - // NOTE: Remove updated_0_ if we need an updated_1_ - out.updated_0_common_connectionLost = "Die Verbindung zum Server ist abgebrochen
    Du verwendest jetzt das Dokument schreibgeschützt, bis die Verbindung wieder funktioniert."; - out.common_connectionLost = out.updated_0_common_connectionLost; - - out.websocketError = 'Verbindung zum Websocket fehlgeschlagen...'; - out.typeError = "Dieses Dokument ist nicht mit der ausgewählten Anwendung kompatibel"; - out.onLogout = 'Du bist ausgeloggt. {0}Klicke hier{1}, um dich wieder einzuloggen,
    oder drücke Escape, um dein Pad schreibgeschützt zu benutzen.'; - out.wrongApp = "Der Inhalt dieser Echtzeitsitzung kann nicht in deinem Browser angezeigt werden. Bitte lade die Seite neu."; - out.padNotPinned = 'Dieses Pad wird nach 3 Monaten ohne Aktivität auslaufen, {0}logge dich ein{1} oder {2}registriere dich{3}, um das Auslaufen zu verhindern.'; - out.anonymousStoreDisabled = "Der Webmaster dieses CryptPad-Servers hat die anonyme Verwendung des Speichers deaktiviert. Du musst dich einloggen, um CryptDrive zu verwenden."; - out.expiredError = 'Dieses Pad ist abgelaufen und ist nicht mehr verfügbar.'; - out.deletedError = 'Dieses Pad wurde von seinem Besitzer gelöscht und ist nicht mehr verfügbar.'; - out.inactiveError = 'Dieses Pad ist wegen Inaktivität gelöscht worden. Drücke Esc, um ein neues Pad zu erstellen.'; - out.chainpadError = 'Ein kritischer Fehler ist beim Aktualisieren deines Inhalts aufgetreten. Diese Seite ist schreibgeschützt, damit du sicherstellen kannst, dass kein Inhalt verloren geht.
    '+ - 'Drücke Esc, um das Pad schreibgeschützt zu lesen oder lade es neu, um die Bearbeitung fortzusetzen.'; - out.errorCopy = ' Du kannst noch den Inhalt woanders hin kopieren, nachdem du Esc gedrückt hast.
    Wenn du die Seite verlässt, verschwindet der Inhalt für immer!'; - out.errorRedirectToHome = 'Drücke Esc, um zu deinem CryptDrive zurückzukehren.'; - out.newVersionError = "Eine neue Version von CryptPad ist verfügbar.
    " + - "Lade die Seite neu, um die neue Version zu benutzen. Drücke Esc, um im Offline-Modus weiterzuarbeiten."; - - out.loading = "Laden..."; - out.error = "Fehler"; - out.saved = "Gespeichert"; - out.synced = "Alles gespeichert"; - out.deleted = "Pad wurde aus deinem CryptDrive gelöscht"; - out.deletedFromServer = "Pad wurde vom Server gelöscht"; - - out.mustLogin = "Du musst angemeldet sein, um auf diese Seite zuzugreifen"; - out.disabledApp = "Diese Anwendung wurde deaktiviert. Kontaktiere den Administrator dieses CryptPads, um mehr Informationen zu erhalten."; - - out.realtime_unrecoverableError = "Es ist ein nicht reparierbarer Fehler aufgetreten. Klicke auf OK, um neu zu laden."; - - out.disconnected = 'Getrennt'; - out.synchronizing = 'Synchronisieren'; - out.reconnecting = 'Verbindung wird aufgebaut'; - out.typing = "Es wird getippt"; - out.initializing = "Starten..."; - out.forgotten = 'In den Papierkorb verschoben'; - out.errorState = 'Kritischer Fehler: {0}'; - out.lag = 'Verzögerung'; - out.readonly = 'schreibgeschützt'; - out.anonymous = "Anonym"; - out.yourself = "Du"; - out.anonymousUsers = "anonyme Nutzer"; - out.anonymousUser = "anonyme Nutzer"; - out.users = "Nutzer"; - out.and = "Und"; - out.viewer = "Betrachter"; - out.viewers = "Betrachter"; - out.editor = "Bearbeiter"; - out.editors = "Bearbeiter"; - out.userlist_offline = "Du bist aktuell offline, die Benutzerliste ist nicht verfügbar."; - - out.language = "Sprache"; - - out.comingSoon = "Kommt bald..."; - - out.newVersion = 'CryptPad wurde aktualisiert!
    ' + - 'Entdecke, was neu in dieser Version ist:
    '+ - 'Versionshinweise für CryptPad {0}'; - - out.upgrade = "Upgrade"; - out.upgradeTitle = "Dein Konto upgraden, um mehr Speicherplatz zu haben"; - - out.upgradeAccount = "Konto upgraden"; - out.MB = "MB"; - out.GB = "GB"; - out.KB = "KB"; - - out.supportCryptpad = "CryptPad unterstützen"; - - out.formattedMB = "{0} MB"; - out.formattedGB = "{0} GB"; - out.formattedKB = "{0} KB"; - - out.greenLight = "Alles funktioniert bestens!"; - out.orangeLight = "Deine langsame Verbindung kann die Nutzung beeinträchtigen."; - out.redLight = "Du wurdest von dieser Sitzung getrennt."; - - out.pinLimitReached = "Du hast deine Speicherplatzbegrenzung erreicht"; - out.updated_0_pinLimitReachedAlert = "Du hast deine Speicherplatzbegrenzung erreicht. Neue Pads werden nicht mehr in deinem CryptDrive gespeichert.
    " + - 'Du kannst entweder ein Pad von deinem CryptDrive entfernen oder ein Premiumangebot anfordern, damit deine Begrenzung erhöht wird.'; - out.pinLimitReachedAlert = out.updated_0_pinLimitReachedAlert; - out.pinLimitReachedAlertNoAccounts = out.pinLimitReached; - out.pinLimitNotPinned = "Du hast deine Speicherplatzbegrenzung erreicht.
    "+ - "Dieses Pad ist nicht in deinem CryptDrive gespeichert."; - out.pinLimitDrive = "Du hast deine Speicherplatzbegrenzung erreicht.
    " + - "Du kannst keine neuen Pads erstellen."; - - out.moreActions = "Mehr Aktionen"; - - out.importButton = "Importieren"; - out.importButtonTitle = 'Importiere eine lokale Pad-Datei'; - - out.exportButton = "Exportieren"; - out.exportButtonTitle = 'Exportiere dieses Pad in eine lokale Datei'; - out.exportPrompt = 'Wie möchtest du die Datei nennen?'; - - out.changeNamePrompt = 'Ändere deinen Namen (oder lasse dieses Feld leer, um anonym zu bleiben): '; - out.user_rename = "Bearbeite deinen Anzeigename"; - out.user_displayName = "Anzeigename"; - out.user_accountName = "Kontoname"; - - out.clickToEdit = "Zum Bearbeiten klicken"; - out.saveTitle = "Den Titel speichern (Enter)"; - - out.forgetButton = "Entfernen"; - out.forgetButtonTitle = 'Dieses Pad in den Papierkorb verschieben'; - out.forgetPrompt = 'Mit dem Klick auf OK wird das Pad in den Papierkorb verschoben. Bist du sicher?'; - out.movedToTrash = 'Dieses Dokument liegt im Papierkorb.
    Du kannst zum CryptDrive navigieren.'; - - out.shareButton = 'Teilen'; - out.shareSuccess = 'Die URL wurde in die Zwischenablage kopiert'; - - out.userListButton = "Benutzerliste"; - - out.chatButton = "Chat"; - - out.userAccountButton = "Dein Konto"; - - out.newButton = 'Neu'; - out.newButtonTitle = 'Neues Pad erstellen'; - out.uploadButton = 'Hochladen'; - out.uploadButtonTitle = 'Eine neue Datei in den aktuellen Ordner hochladen'; - - out.saveTemplateButton = "Als Vorlage speichern"; - out.saveTemplatePrompt = "Bitte gib einen Titel für die Vorlage ein"; - out.templateSaved = "Vorlage gespeichert!"; - out.selectTemplate = "Bitte wähle eine Vorlage oder drücke Esc"; - out.useTemplate = "Mit einer Vorlage starten?"; //Would you like to "You have available templates for this type of pad. Do you want to use one?"; - out.useTemplateOK = 'Wähle eine Vorlage (Enter)'; - out.useTemplateCancel = 'Neu starten (Esc)'; - out.template_import = "Eine Vorlage importieren"; - out.template_empty = "Keine Vorlagen verfügbar"; - - out.previewButtonTitle = "Die Markdown-Vorschau anzeigen oder verbergen"; - - out.presentButtonTitle = "Zum Präsentationsmodus wechseln"; - - out.backgroundButtonTitle = 'Hintergrundfarbe der Präsentation ändern'; - out.colorButtonTitle = 'Textfarbe des Präsentationsmodus bearbeiten'; - - out.propertiesButton = "Eigenschaften"; - out.propertiesButtonTitle = 'Die Eigenschaften des Pads ansehen'; - - out.printText = "Drucken"; - out.printButton = "Drucken (Enter)"; - out.printButtonTitle2 = "Dein Pad ausdrucken oder als PDF-Datei exportieren"; - out.printOptions = "Layouteinstellungen"; - out.printSlideNumber = "Foliennummer anzeigen"; - out.printDate = "Datum anzeigen"; - out.printTitle = "Titel der Präsentation anzeigen"; - out.printCSS = "Benutzerdefinierte Stil-Regeln (CSS):"; - out.printTransition = "Animierte Übergänge aktivieren"; - out.printBackground = "Ein Hintergrundbild verwenden"; - out.printBackgroundButton = "Bitte ein Bild wählen"; - out.printBackgroundValue = "Aktueller Hintergrund: {0}"; - out.printBackgroundNoValue = "Kein Hintergrundbild gewählt"; - out.printBackgroundRemove = "Das Hintergrundbild entfernen"; - - out.filePickerButton = "Eine Datei aus deinem CryptDrive einbetten"; - out.filePicker_close = "Schließen"; - out.filePicker_description = "Bitte wähle eine Datei aus deinem CryptDrive oder lade eine neue hoch"; - out.filePicker_filter = "Dateien nach Namen filtern"; - out.or = 'oder'; - - out.tags_title = "Tags (nur für dich)"; - out.tags_add = "Die Tags dieser Seite bearbeiten"; - out.tags_searchHint = "Dateien anhand ihrer Tags in deinem CryptDrive suchen"; - out.tags_searchHint = "Beginne die Suche in deinem CryptDrive mit #, um getaggte Dokumente zu finden."; - out.tags_notShared = "Deine Tags werden nicht mit anderen Benutzern geteilt"; - out.tags_duplicate = "Doppeltes Tag: {0}"; - out.tags_noentry = "Du kannst keine Tags zu einem gelöschten Pad hinzufügen!"; - - out.slideOptionsText = "Einstellungen"; - out.slideOptionsTitle = "Deine Folien anpassen"; - out.slideOptionsButton = "Speichern (Enter)"; - out.slide_invalidLess = "Benutzerdefinierter Stil ist ungültig"; - - out.languageButton = "Sprache"; - out.languageButtonTitle = "Wähle die Sprache für die Syntaxhervorhebung"; - out.themeButton = "Farbschema"; - out.themeButtonTitle = "Wähle das Farbschema für den Code- und Folieneditor"; - - out.editShare = "Link zum Bearbeiten teilen"; - out.editShareTitle = "Link zum Bearbeiten in die Zwischenablage kopieren"; - out.editOpen = "Den Link zum Bearbeiten in einem neuen Tab öffnen"; - out.editOpenTitle = "Öffne dieses Pad zum Bearbeiten in einem neuen Tab"; - out.viewShare = "Link zum schreibgeschützten Pad teilen"; - out.viewShareTitle = "Link zum schreibgeschützten Pad in die Zwischenablage kopieren"; - out.viewOpen = "In neuem Tab anzeigen"; - out.viewOpenTitle = "Pad schreibgeschützt in neuem Tab öffnen"; - out.fileShare = "Link kopieren"; - out.getEmbedCode = "Einbettungscode anzeigen"; - out.viewEmbedTitle = "Das Pad in eine externe Webseite einbetten"; - out.viewEmbedTag = "Um dieses Pad einzubetten, platziere diesen iframe an der gewünschten Stelle deiner HTML-Seite. Du kannst es mit CSS oder HTML-Attributen gestalten."; - out.fileEmbedTitle = "Die Datei in einer externen Seite einbetten"; - out.fileEmbedScript = "Um diese Datei einzubetten, füge dieses Skript einmal in deiner Webseite ein, damit das Media-Tag geladen wird:"; - out.fileEmbedTag = "Dann platziere das Media-Tag an der gewünschten Stelle der Seite:"; - - out.notifyJoined = "{0} ist in der Mitarbeitssitzung "; - out.notifyRenamed = "{0} ist jetzt als {1} bekannt"; - out.notifyLeft = "{0} hat die Mitarbeitssitzung verlassen"; - - out.ok = 'OK'; - out.okButton = 'OK (Enter)'; - - out.cancel = "Abbrechen"; - out.cancelButton = 'Abbrechen (Esc)'; - out.doNotAskAgain = "Nicht mehr fragen (Esc)"; - - out.show_help_button = "Hilfe anzeigen"; - out.hide_help_button = "Hilfe verbergen"; - out.help_button = "Hilfe"; - - out.historyText = "Verlauf"; - out.historyButton = "Den Dokumentverlauf anzeigen"; - out.history_next = "Neuere Version"; - out.history_prev = "Ältere Version"; - out.history_loadMore = "Weiteren Verlauf laden"; - out.history_closeTitle = "Verlauf schließen"; - out.history_restoreTitle = "Die gewählte Version des Dokuments wiederherstellen"; - out.history_restorePrompt = "Bist du sicher, dass du die aktuelle Version des Dokuments mit der angezeigten Version ersetzen möchtest?"; - out.history_restoreDone = "Version wiederhergestellt"; - out.history_version = "Version:"; - - // Ckeditor - out.openLinkInNewTab = "Link im neuen Tab öffnen"; - out.pad_mediatagTitle = "Einstellungen für Media-Tag"; - out.pad_mediatagWidth = "Breite (px)"; - out.pad_mediatagHeight = "Höhe (px)"; - out.pad_mediatagRatio = "Seitenverhältnis beibehalten"; - out.pad_mediatagBorder = "Rahmenbreite (px)"; - out.pad_mediatagPreview = "Vorschau"; - out.pad_mediatagImport = 'In deinem CryptDrive speichern'; - out.pad_mediatagOptions = 'Bildeigenschaften'; - - // Kanban - out.kanban_newBoard = "Neues Board"; - out.kanban_item = "Eintrag {0}"; // Item number for initial content - out.kanban_todo = "Zu erledigen"; - out.kanban_done = "Erledigt"; - out.kanban_working = "In Bearbeitung"; - out.kanban_deleteBoard = "Bist du sicher, dass du dieses Board löschen möchtest?"; - out.kanban_addBoard = "Ein Board hinzufügen"; - out.kanban_removeItem = "Diesen Eintrag entfernen"; - out.kanban_removeItemConfirm = "Bist du sicher, dass du diesen Eintrag löschen möchtest?"; - - // Polls - - out.poll_title = "Terminplaner ohne Preisgabe von Daten"; - out.poll_subtitle = "Planung in Echtzeit ohne Preisgabe von Daten"; - - out.poll_p_save = "Deine Einstellungen werden sofort aktualisiert. Du musst sie also nicht speichern."; - out.poll_p_encryption = "Alle Eingaben sind verschlüsselt, deshalb können nur Leute darauf zugreifen, die den Link kennen. Selbst der Server sieht nicht, was du änderst."; - - out.wizardLog = "Klicke auf die Schaltfläche links oben, um zu deiner Umfrage zurückzukehren."; - out.wizardTitle = "Nutze den Assistenten, um deine Umfrage zu erstellen."; - out.wizardConfirm = "Bist du wirklich bereit, die angegebenen Optionen zu deiner Umfrage hinzuzufügen?"; - - out.poll_publish_button = "Veröffentlichen"; - out.poll_admin_button = "Admin"; - out.poll_create_user = "Neuen Benutzer hinzufügen"; - out.poll_create_option = "Neue Option hinzufügen"; - out.poll_commit = "Einchecken"; - - out.poll_closeWizardButton = "Assistenten schließen"; - out.poll_closeWizardButtonTitle = "Assistenten schließen"; - out.poll_wizardComputeButton = "Optionen übernehmen"; - out.poll_wizardClearButton = "Tabelle leeren"; - out.poll_wizardDescription = "Erstelle die Optionen automatisch, indem du eine beliebige Anzahl von Daten und Zeiten eingibst."; - out.poll_wizardAddDateButton = "+ Daten"; - out.poll_wizardAddTimeButton = "+ Zeiten"; - - out.poll_optionPlaceholder = "Option"; - out.poll_userPlaceholder = "Dein Name"; - out.poll_removeOption = "Bist du sicher, dass du diese Option entfernen möchtest?"; - out.poll_removeUser = "Bist du sicher, dass du diesen Nutzer entfernen möchtest?"; - - out.poll_titleHint = "Titel"; - out.poll_descriptionHint = "Beschreibe deine Abstimmung und publiziere sie mit der Schaltfläche ✓ (Veröffentlichen), wenn du fertig bist."+ - " Bei der Beschreibung kann Markdown-Syntax verwendet werden und du kannst Medien-Elemente von deinem CryptDrive einbetten." + - " Jeder, der den Link kennt, kann die Beschreibung ändern. Dies wird aber nicht empfohlen."; - - out.poll_remove = "Entfernen"; - out.poll_edit = "Bearbeiten"; - out.poll_locked = "Gesperrt"; - out.poll_unlocked = "Editierbar"; - - out.poll_bookmark_col = 'Setze ein Lesezeichen auf diese Spalte, damit sie immer editierbar und ganz links angezeigt wird.'; - out.poll_bookmarked_col = 'Dies ist die Spalte mit deinem Lesezeichen. Sie wird immer editierbar und ganz links angezeigt.'; - out.poll_total = 'SUMME'; - - out.poll_comment_list = "Kommentare"; - out.poll_comment_add = "Einen Kommentar hinzufügen"; - out.poll_comment_submit = "Senden"; - out.poll_comment_remove = "Diesen Kommentar entfernen"; - out.poll_comment_placeholder = "Dein Kommentar"; - - out.poll_comment_disabled = "Diese Umfrage mit der Schaltfläche ✓ veröffentlichen, damit Kommentare möglich sind."; - - // OnlyOffice - out.oo_reconnect = "Die Serververbindung wurde wiederhergestellt. Klicke auf OK, um neu zu laden und die Bearbeitung fortzusetzen."; - - // Canvas - out.canvas_clear = "Löschen"; - out.canvas_delete = "Auswahl entfernen"; - out.canvas_disable = "Zeichnung deaktivieren"; - out.canvas_enable = "Zeichnung aktivieren"; - out.canvas_width = "Breite"; - out.canvas_opacity = "Deckkraft"; - out.canvas_opacityLabel = "Deckkraft: {0}"; - out.canvas_widthLabel = "Breite: {0}"; - out.canvas_saveToDrive = "Dieses Bild in deinem CryptDrive speichern"; - out.canvas_currentBrush = "Aktueller Pinsel"; - out.canvas_chooseColor = "Eine Farbe wählen"; - out.canvas_imageEmbed = "Ein Bild von deinem Computer einbetten"; - - // Profile - out.profileButton = "Profil"; // dropdown menu - out.profile_urlPlaceholder = 'URL'; - out.profile_namePlaceholder = 'Angezeigter Name'; - out.profile_avatar = "Avatar"; - out.profile_upload = " Einen neuen Avatar hochladen"; - out.profile_uploadSizeError = "Fehler: Dein Avatar muss kleiner als {0} sein"; - out.profile_uploadTypeError = "Fehler: Der Typ dieses Bildes wird nicht unterstützt. Unterstütze Typen sind: {0}"; - out.profile_error = "Fehler bei der Erstellung deines Profils: {0}"; - out.profile_register = "Du muss dich einloggen, um ein Profil zu erstellen!"; - out.profile_create = "Ein Profil erstellen"; - out.profile_description = "Beschreibung"; - out.profile_fieldSaved = 'Neuer Wert gespeichert: {0}'; - - out.profile_inviteButton = "Sich in Verbindung setzen"; - out.profile_inviteButtonTitle ='Einen Link erstellen, mit dem du diesen Benutzer einladen kannst, sich mit dir in Verbindung zu setzen.'; - out.profile_inviteExplanation = "Ein Klick auf OK wird einen Link erstellen, der eine sichere Chatsitzung nur mit {0} erlaubt.

    Dieser Link kann öffentlich geteilt werden."; - out.profile_viewMyProfile = "Mein Profil anzeigen"; - - // contacts/userlist - out.userlist_addAsFriendTitle = 'Benutzer "{0}" als Kontakt hinzufügen'; - out.userlist_thisIsYou = 'Das bist du ("{0}")'; - out.userlist_pending = "Warte..."; - out.contacts_title = "Kontakte"; - out.contacts_addError = 'Fehler bei dem Hinzufügen des Kontakts zur Liste'; - out.contacts_added = 'Verbindungseinladung angenommen.'; - out.contacts_rejected = 'Verbindungseinladung abgelehnt'; - out.contacts_request = 'Benutzer {0} möchte dich als Kontakt hinzufügen. Annehmen?'; - out.contacts_send = 'Senden'; - out.contacts_remove = 'Diesen Kontakt entfernen'; - out.contacts_confirmRemove = 'Bist du sicher, dass du {0} von der Kontaktliste entfernen möchtest?'; - out.contacts_typeHere = "Gib eine Nachricht ein..."; - out.contacts_warning = "Alles, was du hier eingibst, wird dauerhaft gespeichert und für alle aktuellen und zukünftigen Benutzer dieses Pads sichtbar sein. Sei sorgfältig mit sensiblen Informationen!"; - out.contacts_padTitle = "Chat"; - - out.contacts_info1 = "Dies sind deine Kontakte. Hier kannst du:"; - out.contacts_info2 = "Auf den Avatar eines Kontakts klicken, um mit diesem Benutzer zu chatten"; - out.contacts_info3 = "Auf den Avatar doppelklicken, um das entsprechende Profil anzuzeigen"; - out.contacts_info4 = "Jeder Teilnehmer kann den Chatverlauf endgültig löschen"; - - out.contacts_removeHistoryTitle = 'Den Chatverlauf löschen'; - out.contacts_confirmRemoveHistory = 'Bist du sicher, dass du den Chatverlauf endgültig löschen willst? Die Daten sind dann weg.'; - out.contacts_removeHistoryServerError = 'Es gab einen Fehler bei dem Löschen des Chatverlaufs. Versuche es später noch einmal'; - out.contacts_fetchHistory = "Den früheren Verlauf laden"; - - out.contacts_friends = "Kontakte"; - out.contacts_rooms = "Chaträume"; - out.contacts_leaveRoom = "Diesen Chatraum verlassen"; - out.contacts_online = "Ein anderer Benutzer dieses Raumes ist online"; - - // File manager - - out.fm_rootName = "Dokumente"; - out.fm_trashName = "Papierkorb"; - out.fm_unsortedName = "Unsortierte Dateien"; - out.fm_filesDataName = "Alle Dateien"; - out.fm_templateName = "Vorlagen"; - out.fm_searchName = "Suchen"; - out.fm_recentPadsName = "Zuletzt geöffnete Pads"; - out.fm_ownedPadsName = "Eigene"; - out.fm_tagsName = "Tags"; - out.fm_sharedFolderName = "Geteilter Ordner"; - out.fm_searchPlaceholder = "Suchen..."; - out.fm_newButton = "Neu"; - out.fm_newButtonTitle = "Ein neues Pad oder Ordner erstellen, oder eine Datei in den aktuellen Ordner importieren"; - out.fm_newFolder = "Neuer Ordner"; - out.fm_newFile = "Neues Pad"; - out.fm_folder = "Ordner"; - out.fm_sharedFolder = "Geteilter Ordner"; - out.fm_folderName = "Ordnername"; - out.fm_numberOfFolders = "# Ordner"; - out.fm_numberOfFiles = "# Dateien"; - out.fm_fileName = "Dateiname"; - out.fm_title = "Titel"; - out.fm_type = "Typ"; - out.fm_lastAccess = "Letzter Zugriff"; - out.fm_creation = "Erstellung"; - out.fm_forbidden = "Verbotene Aktion"; - out.fm_originalPath = "Ursprünglicher Pfad"; - out.fm_openParent = "Im Ordner zeigen"; - out.fm_noname = "Dokument ohne Titel"; - out.fm_emptyTrashDialog = "Soll der Papierkorb wirklich geleert werden?"; - out.fm_removeSeveralPermanentlyDialog = "Bist du sicher, dass du diese {0} Elemente endgültig aus deinem CryptDrive entfernen möchtest?"; - out.fm_removePermanentlyNote = "Wenn du fortfährst, werden deine eigenen Pads vom Server entfernt."; - out.fm_removePermanentlyDialog = "Bist du sicher, dass du dieses Element endgültig aus deinem CryptDrive entfernen möchtest?"; - out.fm_removeSeveralDialog = "Bist du sicher, dass du diese {0} Elemente in den Papierkorb verschieben möchtest?"; - out.fm_removeDialog = "Bist du sicher, dass du {0} in den Papierkorb verschieben möchtest?"; - out.fm_deleteOwnedPad = "Bist du sicher, dass du dieses Pad endgültig vom Server löschen möchtest?"; - out.fm_deleteOwnedPads = "Bist du sicher, dass du diese Pads endgültig vom Server entfernen möchtest?"; - out.fm_restoreDialog = "Bist du sicher, dass du {0} zurück in den ursprünglichen Ordner verschieben möchtest?"; - out.fm_unknownFolderError = "Der Ordner, der gerade gewählt oder zuletzt besucht wurde, existiert nicht mehr. Der übergeordnete Ordner wird geöffnet..."; - out.fm_contextMenuError = "Fehler beim Öffnen des Kontextmenü für dieses Element. Wenn dieses Problem wieder auftritt, versuche die Seite neu zu laden."; - out.fm_selectError = "Fehler bei der Auswahl des gewünschten Elements. Wenn dieses Problem wieder auftritt, versuche die Seite neu zu laden."; - out.fm_categoryError = "Fehler beim Öffnen der gewählten Kategorie. Der Stamm-Ordner wird angezeigt."; - out.fm_info_root = "Erstelle hier so viele Ordner, wie du willst, um deine Dateien und Dokumente zu organisieren."; - out.fm_info_unsorted = 'Hier sind alle besuchte Dateien enthalten, die noch nicht in "Dokumente" einsortiert oder in den Papierkorb verschoben wurden.'; - out.fm_info_template = 'Hier sind alle Dokumente enthalten, die als Vorlage gespeichert wurden und die du wiederverwenden kannst, um ein neues Pad zu erstellen.'; - out.fm_info_recent = "Hier werden die zuletzt geöffneten Dokumente aufgelistet."; - out.updated_0_fm_info_trash = 'Leere den Papierkorb, um mehr freien Platz in deinem CryptDrive zu erhalten.'; - out.fm_info_trash = out.updated_0_fm_info_trash; - out.fm_info_allFiles = 'Beinhaltet alle Dateien von "Dokumente", "Unsortierte Dateien" und "Papierkorb". Dateien können hier nicht verschoben oder entfernt werden.'; - out.fm_info_anonymous = 'Du bist nicht eingeloggt, daher laufen die Pads nach 3 Monaten aus (mehr dazu lesen). ' + - 'Der Zugang zu den Pads ist in deinem Browser gespeichert, daher wird das Löschen des Browserverlaufs sie möglicherweise verschwinden lassen.
    ' + - 'Registriere dich oder logge dich ein, um sie dauerhaft zugänglich zu machen.
    '; - out.fm_info_sharedFolder = 'Dieser Ordner ist geteilt. Da du aber nicht eingeloggt bist, hast du nur einen schreibgeschützen Zugriff.
    ' + - 'Registriere oder logge ich ein, damit du diesen Ordner in dein CryptDrive importieren und bearbeiten kannst.'; - out.fm_info_owned = "Diese Pads sind deine eigenen. Das heißt, dass du sie jederzeit vom Server entfernen kannst. Wenn du das machst, dann sind sie auch für andere Nutzer nicht mehr zugänglich."; - out.fm_alert_backupUrl = "Backup-Link für dieses CryptDrive.
    " + - "Es wird dringend empfohlen, diesen Link geheim zu halten.
    " + - "Du kannst ihn benutzen, um deine gesamten Dateien abzurufen, wenn dein Browserspeicher gelöscht wurde.
    " + - "Jede Person, die diesen Link hat, kann die Dateien in deinem CryptDrive bearbeiten oder löschen.
    "; - out.fm_alert_anonymous = "Hallo, du benutzt CryptPad anonym. Das ist in Ordnung, aber Dokumente können nach einer längerer Inaktivität gelöscht werden. " + - "Wir haben fortgeschrittene Funktionen in anonymen CryptDrives deaktiviert, weil wir deutlich machen wollen, dass es kein sicherer Platz zur Ablage von Daten ist." + - 'Du kannst lesen, weshalb wir das machen und weshalb du dich wirklich ' + - 'registrieren oder einloggen solltest.'; - out.fm_backup_title = 'Backup-Link'; - out.fm_nameFile = 'Wie soll diese Datei heißen?'; - out.fm_error_cantPin = "Interner Serverfehler. Bitte lade die Seite neu und versuche es erneut."; - out.fm_viewListButton = "Listenansicht"; - out.fm_viewGridButton = "Kachelansicht"; - out.fm_renamedPad = "Du hast einen benutzerdefinierten Name für dieses Pad gesetzt. Seine geteilter Titel ist:
    {0}"; - out.fm_canBeShared = "Dieser Ordner kann geteilt werden"; - out.fm_prop_tagsList = "Tags"; - out.fm_burnThisDriveButton = "Alle Informationen löschen, die CryptPad in deinem Browser speichert"; - out.fm_burnThisDrive = "Bist du sicher, dass du alles, was CryptPad in deinem Browser gespeichert hat, löschen möchtest?
    " + - "Das wird dein CryptDrive und seinen Verlauf in deinem Browser löschen, Pads werden weiterhin (verschlüsselt) auf unserem Server bleiben."; - out.fm_padIsOwned = "Du bist der Eigentümer dieses Pads"; - out.fm_padIsOwnedOther = "Dieses Pad gehört einem anderen Benutzer"; - out.fm_deletedPads = "Dieses Dokument existiert nicht mehr auf dem Server, es wurde von deinem CryptDrive gelöscht: {0}"; - out.fm_tags_name = "Name des Tags"; - out.fm_tags_used = "Anzahl der Dokumente"; - out.fm_restoreDrive = "Dein CryptDrive wird in einen früheren Zustand zurückversetzt. Damit es funktioniert, solltest du keine Änderungen während dieses Vorgangs machen."; - out.fm_moveNestedSF = "Du kannst keinen geteilten Ordner in einem anderen geteilten Ordner platzieren. Der Ordner {0} wurde nicht verschoben."; - - // File - Context menu - out.fc_newfolder = "Neuer Ordner"; - out.fc_newsharedfolder = "Neuer geteilter Ordner"; - out.fc_rename = "Umbenennen"; - out.fc_open = "Öffnen"; - out.fc_open_ro = "Öffnen (schreibgeschützt)"; - out.fc_delete = "In den Papierkorb verschieben"; - out.fc_delete_owned = "Vom Server löschen"; - out.fc_restore = "Wiederherstellen"; - out.fc_remove = "Aus deinem CryptDrive entfernen"; - out.fc_remove_sharedfolder = "Entfernen"; - out.fc_empty = "Den Papierkorb leeren"; - out.fc_prop = "Eigenschaften"; - out.fc_hashtag = "Tags"; - out.fc_sizeInKilobytes = "Größe in Kilobyte"; - // fileObject.js (logs) - out.fo_moveUnsortedError = "Du kannst einen Ordner nicht in die Liste der Vorlagen verschieben"; - out.fo_existingNameError = "Der Name wird in diesem Ordner bereits verwendet. Bitte wähle einen anderen Namen."; - out.fo_moveFolderToChildError = "Du kannst einen Ordner nicht in einen seiner Unterordner verschieben"; - out.fo_unableToRestore = "Die Datei konnte nicht an ihrem ursprünglichen Ort wiederhergestellt werden. Du kannst versuchen, sie an einen anderen Ort zu verschieben."; - out.fo_unavailableName = "Eine Datei oder ein Ordner mit diesem Namen existiert bereits in diesem Ordner. Bitte benenne das Element zuerst um und versuche es dann erneut."; - - out.fs_migration = "Dein CryptDrive wird gerade zu einer neueren Version aktualisiert. Daher muss die Seite neu geladen werden.
    Bitte lade die Seite neu, um sie weiter zu verwenden."; - - // login - out.login_login = "Einloggen"; - out.login_makeAPad = 'Ein Pad anonym erstellen'; - out.login_nologin = "Lokale Dokumente ansehen"; - out.login_register = "Registrieren"; - out.logoutButton = "Ausloggen"; - out.settingsButton = "Einstellungen"; - - out.login_username = "Benutzername"; - out.login_password = "Passwort"; - out.login_confirm = "Passwort bestätigen"; - out.login_remember = "Eingeloggt bleiben"; - - out.login_hashing = "Dein Passwort wird gerade durchgerechnet, das kann etwas dauern."; - - out.login_hello = 'Hallo {0},'; // {0} is the username - out.login_helloNoName = 'Hallo,'; - out.login_accessDrive = 'Dein CryptDrive ansehen'; - out.login_orNoLogin = 'oder'; - - out.login_noSuchUser = 'Ungültiger Benutzername oder Passwort. Versuche es erneut oder registriere dich'; - out.login_invalUser = 'Der Benutzername kann nicht leer sein'; - out.login_invalPass = 'Der Passwort kann nicht leer sein'; - out.login_unhandledError = 'Ein unerwarteter Fehler ist aufgetreten :('; - - out.register_importRecent = "Die Pads aus deiner anonymen Sitzung importieren"; - out.register_acceptTerms = "Ich bin mit den Nutzungsbedingungen einverstanden"; - out.register_passwordsDontMatch = "Passwörter stimmen nicht überein!"; - out.register_passwordTooShort = "Passwörter müssen mindestens {0} Zeichen haben."; - - out.register_mustAcceptTerms = "Du musst mit den Nutzungsbedingungen einverstanden sein."; - out.register_mustRememberPass = "Wir können dein Passwort nicht zurücksetzen, falls du es vergisst. Es ist sehr wichtig, dass du es dir merkst! Bitte markiere das Kästchen, um dies zu bestätigen."; - - out.register_whyRegister = "Wieso solltest du dich registrieren?"; - out.register_header = "Willkommen zu CryptPad"; - out.register_explanation = [ - "

    Lass uns ein paar Punkte überprüfen:

    ", - "
      ", - "
    • Dein Passwort ist dein Geheimnis, um alle deine Dokumente zu verschlüsseln. Wenn du es verlierst, können deine Daten nicht wiederhergestellt werden.
    • ", - "
    • Du kannst die Pads, die du zuletzt angesehen hast, importieren. Sie sind dann in deinem CryptDrive.
    • ", - "
    • Wenn du den Rechner mit anderen teilst, musst du dich ausloggen, wenn du fertig bist. Es ist nicht ausreichend, das Browserfenster oder den Browser zu schließen.
    • ", - "
    " - ].join(''); - - out.register_writtenPassword = "Ich habe meinen Benutzername und mein Passwort notiert. Weiter geht's."; - out.register_cancel = "Zurück"; - - out.register_warning = "\"Ohne Preisgabe von Daten\" bedeutet, dass niemand deine Daten wiederherstellen kann, wenn du dein Passwort verlierst."; - - out.register_alreadyRegistered = "Dieser Benutzer existiert bereits, möchtest du dich einloggen?"; - - // Settings - out.settings_cat_account = "Konto"; - out.settings_cat_drive = "CryptDrive"; - out.settings_cat_cursor = "Cursor"; - out.settings_cat_code = "Code"; - out.settings_cat_pad = "Rich Text"; - out.settings_cat_creation = "Neues Pad"; - out.settings_cat_subscription = "Abonnement"; - out.settings_title = "Einstellungen"; - out.settings_save = "Speichern"; - - out.settings_backupCategory = "Backup"; - out.settings_backupHint = "Erstelle ein Backup deiner Daten im CryptDrive oder stelle die Daten wieder her. Es wird nicht den Inhalt der Pads beinhalten, sondern nur die Schlüssel für den Zugriff."; - out.settings_backup = "Backup"; - out.settings_restore = "Wiederherstellen"; - - out.settings_backupHint2 = "Lade den Inhalt aller Pads herunter. Die Pads werden in einem lesbaren Format heruntergeladen, wenn dies möglich ist."; - out.settings_backup2 = "Mein CryptDrive herunterladen"; - out.settings_backup2Confirm = "Dies wird alle Pads und Dateien von deinem CryptDrive herunterladen. Wenn du fortfahren möchtest, wähle einen Namen und klicke auf OK."; - out.settings_exportTitle = "Dein CryptDrive exportieren"; - out.settings_exportDescription = "Bitte warte, während wir deine Dokumente herunterladen und entschlüsseln. Dies kann ein paar Minuten dauern. Wenn das Browserfenster geschlossen wird, wird der Vorgang unterbrochen."; - out.settings_exportFailed = "Wenn der Download eines Pads länger als 1 Minute dauert, wird dieses Pad nicht im Export enthalten sein. Für jedes nicht exportierte Pad wird der entsprechende Link angezeigt."; - out.settings_exportWarning = "Um eine erhöhte Leistung zu erhalten, empfehlen wir dieses Browserfenster im Vordergrund zu halten."; - out.settings_exportCancel = "Bist du sicher, dass du den Exportvorgang abbrechen möchtest? Der Vorgang muss das nächste Mal wieder von vorn beginnen."; - out.settings_export_reading = "Dein CryptDrive wird gelesen..."; - out.settings_export_download = "Deine Dokumente werden heruntergeladen und entschlüsselt..."; - out.settings_export_compressing = "Daten werden komprimiert..."; - out.settings_export_done = "Der Export ist bereit!"; - out.settings_exportError = "Fehlermeldungen ansehen"; - out.settings_exportErrorDescription = "Wir waren nicht in der Lage, die folgende Dokumente zu exportieren:"; - out.settings_exportErrorEmpty = "Dieses Dokument kann nicht exportiert werden (leerer oder ungültiger Inhalt)."; - out.settings_exportErrorMissing = "Dieses Dokument fehlt auf dem Server (es ist ausgelaufen oder von seinem Eigentümer gelöscht worden)"; - out.settings_exportErrorOther = "Es ist ein Fehler beim Export des folgenden Dokuments aufgetreten: {0}"; - - out.settings_resetNewTitle = "CryptDrive säubern"; - out.settings_resetButton = "Löschen"; - out.settings_reset = "Alle Dateien und Ordnern aus deinem CryptDrive löschen"; - out.settings_resetPrompt = "Diese Aktion wird alle Dokumente deines CryptDrives entfernen.
    "+ - "Bist du sicher, dass du das tun möchtest?
    " + - "Gib I love CryptPad ein, um zu bestätigen."; // TODO: I love CryptPad should be localized - out.settings_resetDone = "Dein CryptDrive ist jetzt leer!"; - out.settings_resetError = "Prüftext ist nicht korrekt. Dein CryptDrive wurde nicht verändert."; - - out.settings_resetTipsAction = "Zurücksetzen"; - out.settings_resetTips = "Tipps"; - out.settings_resetTipsButton = "Die Tipps für CryptDrive zurücksetzen"; - out.settings_resetTipsDone = "Alle Tipps sind wieder sichtbar."; - - out.settings_thumbnails = "Vorschaubilder"; - out.settings_disableThumbnailsAction = "Die Erstellung von Vorschaubildern in deinem CryptDrive deaktivieren"; - out.settings_disableThumbnailsDescription = "Vorschaubilder werden automatisch erstellt und in deinem Browser gespeichert, wenn du ein Pad besuchst. Du kannst diese Funktion hier deaktivieren."; - out.settings_resetThumbnailsAction = "Entfernen"; - out.settings_resetThumbnailsDescription = "Alle Vorschaubilder entfernen, die in deinem Browser gespeichert sind."; - out.settings_resetThumbnailsDone = "Alle Vorschaubilder wurden entfernt."; - - out.settings_importTitle = "Importiere die kürzlich besuchten Dokumente in dein CryptDrive"; - out.settings_import = "Importieren"; - out.settings_importConfirm = "Bist du sicher, dass du die kürzlich besuchten Pads in das CryptDrive deines Kontos importieren möchtest??"; - out.settings_importDone = "Import abgeschlossen"; - - out.settings_autostoreTitle = "Speichern von Pads im CryptDrive"; - out.settings_autostoreHint = "Automatisch: Alle Pads werden in deinem CryptDrive gespeichert.
    " + - "Manuell (immer nachfragen): Wenn du ein Pad noch nicht gespeichert hast, wirst du gefragt, ob du es im CryptDrive speichern willst.
    " + - "Manuell (nie nachfragen): Pads werden nicht automatisch im CryptDrive gespeichert. Die Option zum Speichern wird versteckt.
    "; - out.settings_autostoreYes = "Automatisch"; - out.settings_autostoreNo = "Manuell (nie nachfragen)"; - out.settings_autostoreMaybe = "Manuell (immer nachfragen)"; - - out.settings_userFeedbackTitle = "Rückmeldung"; - out.settings_userFeedbackHint1 = "CryptPad sendet grundlegende Rückmeldungen zum Server, um die Benutzererfahrung verbessern zu können."; - out.settings_userFeedbackHint2 = "Der Inhalt deiner Pads wird nie mit dem Server geteilt."; - out.settings_userFeedback = "Rückmeldungen aktivieren"; - - out.settings_deleteTitle = "Löschung des Kontos"; - out.settings_deleteHint = "Die Löschung eines Kontos ist endgültig. Dein CryptDrive und die Liste deiner Pads werden vom Server gelöscht. Deine restlichen Pads werden nach 90 Tage gelöscht, wenn niemand anderes sie in seinem CryptDrive gespeichert hat."; - out.settings_deleteButton = "Dein Konto löschen"; - out.settings_deleteModal = "Gib die folgenden Informationen an deinen CryptPad-Administrator weiter, damit er die Daten vom Server löschen kann."; - out.settings_deleteConfirm = "Wenn du auf OK klickst, wird dein Konto dauerhaft gelöscht. Bist du sicher?"; - out.settings_deleted = "Dein Konto ist jetzt gelöscht. Klicke auf OK, um zur Hauptseite zu gelangen."; - - out.settings_anonymous = "Du bist nicht eingeloggt. Die Einstellungen hier gelten nur für diesen Browser."; - out.settings_publicSigningKey = "Öffentlicher Schlüssel zum Unterschreiben"; - - out.settings_usage = "Verbrauch"; - out.settings_usageTitle = "Die Gesamtgröße deiner Pads in MB"; // TODO: pinned ?? - out.settings_pinningNotAvailable = "Gepinnte Pads sind nur für angemeldete Benutzer verfügbar."; - out.settings_pinningError = "Etwas ging schief"; - out.settings_usageAmount = "Deine gepinnten Pads belegen {0} MB"; - - out.settings_logoutEverywhereButton = "Ausloggen"; - out.settings_logoutEverywhereTitle = "Überall ausloggen"; - out.settings_logoutEverywhere = "Das Ausloggen in allen andere Websitzungen erzwingen"; - out.settings_logoutEverywhereConfirm = "Bist du sicher? Du wirst dich auf allen deinen Geräten wieder einloggen müssen."; - - out.settings_driveDuplicateTitle = "Duplizierte eigene Pads"; - out.settings_driveDuplicateHint = "Wenn du ein eigenes Pad in einem geteilten Ordner verschiebst, wird eine Kopie in deinem CryptDrive behalten, damit du die Kontrolle des Dokuments nicht verlierst. Du kannst duplizierte Dateien verbergen. Nur die Version in dem geteilten Ordner wird dann angezeigt, außer sie wurde gelöscht. In diesem Fall, wird sie wieder angezeigt."; - out.settings_driveDuplicateLabel = "Duplizierte Pads verbergen"; - - out.settings_codeIndentation = 'Einrückung im Code-Editor (Leerzeichen)'; - out.settings_codeUseTabs = "Mit Tabs einrücken (anstatt mit Leerzeichen)"; - out.settings_codeFontSize = "Schriftgröße im Code-Editor"; - - out.settings_padWidth = "Maximalgröße des Editors"; - out.settings_padWidthHint = "Rich-Text-Pads benutzen normalerweise die größte verfügbare Zeilenbreite, das kann manchmal schwer lesbar sein. Du kannst die Breite des Editors hier reduzieren."; - out.settings_padWidthLabel = "Die Breite des Editors reduzieren"; - out.settings_padSpellcheckTitle = "Rechtschreibprüfung"; - out.settings_padSpellcheckHint = "Mit dieser Option kann die Rechtschreibprüfung in Rich-Text-Pads aktiviert werden. Rechtschreibfehler werden rot unterstrichen. Halte die Strg- oder Meta-Taste gedrückt, um Verbesserungsvorschläge anzuzeigen."; - out.settings_padSpellcheckLabel = "Rechtschreibprüfung in Rich-Text-Pads aktivieren"; - - out.settings_creationSkip = "Dialog bei Erstellung neuer Pads überspringen"; - out.settings_creationSkipHint = "Dieser Dialog erlaubt Einstellungen für mehr Kontrolle und Sicherheit bei deinen Pads. Aber der zusätzliche Dialog verlangsamt die Arbeit. Mit dieser Option kannst du diesen Dialog überspringen und die Standard-Einstellungen wählen."; - out.settings_creationSkipTrue = "Überspringen"; - out.settings_creationSkipFalse = "Anzeigen"; - - out.settings_templateSkip = "Wahl der Vorlage überspringen"; - out.settings_templateSkipHint = "Wenn du ein neues Pad erstellst und passende Vorlagen vorhanden sind, erscheint ein Dialog zur Auswahl einer Vorlage. Hier kannst du diesen Dialog überspringen und somit keine Vorlage verwenden."; - - out.settings_ownDriveTitle = "Aktiviere die neuesten Funktionen für dein Konto"; - out.settings_ownDriveHint = "Aus technischen Gründen sind nicht alle neue Funktionen für ältere Konten verfügbar. Ein kostenloses Upgrade wird dein CryptDrive für zukünftige Funktionen vorbereiten, ohne deine Arbeit zu stören."; - out.settings_ownDriveButton = "Upgrade deines Kontos"; - out.settings_ownDriveConfirm = "Das Upgrade deines Kontos kann einige Zeit dauern. Du wirst dich auf allen Geräten neu einloggen müssen. Bist du sicher?"; - out.settings_ownDrivePending = "Das Upgrade deines Kontos läuft. Bitte schließe die Seite nicht und lade sie nicht neu, bis dieser Vorgang abgeschlossen ist."; - - out.settings_changePasswordTitle = "Dein Passwort ändern"; - out.settings_changePasswordHint = "Ändere das Passwort deines Kontos, ohne deine Daten zu verlieren. Du musst einmal das aktuelle Passwort eingeben und dann das gewünschte neue Passwort zweimal.
    " + - "Wir können das Passwort nicht zurücksetzen, wenn du es vergisst. Sei also besonders sorgfältig!"; - out.settings_changePasswordButton = "Passwort ändern"; - out.settings_changePasswordCurrent = "Aktuelles Passwort"; - out.settings_changePasswordNew = "Neues Passwort"; - out.settings_changePasswordNewConfirm = "Neues Passwort bestätigen"; - out.settings_changePasswordConfirm = "Bist du sicher? Du wirst dich auf allen Geräten neu einloggen müssen."; - out.settings_changePasswordError = "Ein Fehler ist aufgetreten. Wenn du dich nicht mehr einloggen oder dein Passwort ändern kannst, solltest du die Administratoren des CryptPad-Servers kontaktieren."; - out.settings_changePasswordPending = "Dein Passwort wird geändert. Bitte schließe die Seite nicht und lade sie nicht neu, bis dieser Vorgang abgeschlossen ist."; - out.settings_changePasswordNewPasswordSameAsOld = "Dein neues Passwort muss sich von deinem aktuellen Passwort unterscheiden."; - - out.settings_cursorColorTitle = "Cursorfarbe"; - out.settings_cursorColorHint = "Die Farbe deines Cursors in gemeinsam bearbeiteten Dokumente ändern."; - out.settings_cursorShareTitle = "Meine Cursorposition teilen"; - out.settings_cursorShareHint = "Du kannst wählen, ob andere Benutzer deinen Cursor in gemeinsam bearbeiteten Dokumenten sehen können."; - out.settings_cursorShareLabel = "Position teilen"; - out.settings_cursorShowTitle = "Position des Cursors von anderen Nutzern anzeigen"; - out.settings_cursorShowHint = "Du kannst wählen, ob die Cursor von anderen Nutzern in gemeinsam bearbeiteten Dokumenten sichtbar sind."; - out.settings_cursorShowLabel = "Cursor anzeigen"; - - out.upload_title = "Datei hochladen"; - out.upload_type = "Typ"; - out.upload_modal_title = "Uploadeinstellungen"; - out.upload_modal_filename = "Dateiname (die Dateierweiterung {0} wird automatisch hinzugefügt)"; - out.upload_modal_owner = "Eigene Datei"; - out.upload_serverError = "Serverfehler: Die Datei kann aktuell nicht hochgeladen werden."; - out.upload_uploadPending = "Ein anderer Hochladevorgang läuft gerade. Möchtest du diesen abbrechen und deine neue Datei hochladen?"; - out.upload_success = "Deine Datei ({0}) wurde erfolgreich hochgeladen und zu deinem CryptDrive hinzugefügt."; - out.upload_notEnoughSpace = "Der verfügbare Speicherplatz in deinem CryptDrive reicht leider nicht für diese Datei."; - out.upload_notEnoughSpaceBrief = "Unzureichender Speicherplatz"; - out.upload_tooLarge = "Diese Datei ist zu groß, um hochgeladen zu werden."; - out.upload_tooLargeBrief = 'Datei zu groß'; - out.upload_choose = "Eine Datei wählen"; - out.upload_pending = "In der Warteschlange"; - out.upload_cancelled = "Abgebrochen"; - out.upload_name = "Dateiname"; - out.upload_size = "Größe"; - out.upload_progress = "Fortschritt"; - out.upload_mustLogin = "Du muss eingeloggt sein, um Dateien hochzuladen"; - out.upload_up = "Hochladen"; - out.download_button = "Entschlüsseln und herunterladen"; - out.download_mt_button = "Herunterladen"; - out.download_resourceNotAvailable = "Diese Ressource war nicht verfügbar... Drücke Esc, um fortzufahren."; - out.download_dl = "Herunterladen"; - out.download_step1 = "Laden..."; - out.download_step2 = "Entschlüsselung..."; - - out.todo_title = "CryptTodo"; - out.todo_newTodoNamePlaceholder = "Die Aufgabe prüfen..."; - out.todo_newTodoNameTitle = "Diese Aufgabe zu deiner ToDo-Liste hinzufügen"; - out.todo_markAsCompleteTitle = "Diese Aufgabe als erledigt markieren"; - out.todo_markAsIncompleteTitle = "Diese Aufgabe als nicht erledigt markieren"; - out.todo_removeTaskTitle = "Diese Aufgabe aus deiner ToDo-Liste entfernen"; - - // pad - out.pad_showToolbar = "Werkzeugleiste anzeigen"; - out.pad_hideToolbar = "Werkzeugleiste verbergen"; - out.pad_base64 = "Dieses Pad enthält Bilder die nicht ressourcenschonend gespeichert sind. Sie werden die Größe des Pads im CryptDrive belasten und den Ladevorgang verlangsamen. Du kannst diese Bilder zum neuen Format migrieren. Sie werden dann separat in deinem CryptDrive gespeichert. Möchtest du die Bilder jetzt migrieren?"; - - // markdown toolbar - out.mdToolbar_button = "Die Markdown-Werkzeugleiste anzeigen oder verbergen"; - out.mdToolbar_defaultText = "Dein Text hier"; - out.mdToolbar_help = "Hilfe"; - out.mdToolbar_tutorial = "http://www.markdowntutorial.com/"; - out.mdToolbar_bold = "Fett"; - out.mdToolbar_italic = "Kursiv"; - out.mdToolbar_strikethrough = "Durchgestrichen"; - out.mdToolbar_heading = "Überschrift"; - out.mdToolbar_link = "Link"; - out.mdToolbar_quote = "Zitat"; - out.mdToolbar_nlist = "Nummerierte Liste"; - out.mdToolbar_list = "Aufzählung"; - out.mdToolbar_check = "Aufgabenliste"; - out.mdToolbar_code = "Code"; - - // index.html - - out.home_product = "CryptPad ist eine Alternative mit eingebautem Datenschutz zu verbreiteten Office- und Clouddiensten. Mit CryptPad wird der gesamte Inhalt verschlüsselt, bevor er an den Server gesendet wird. Das bedeutet, dass keiner auf den Inhalt zugreifen kann, es sei denn du gibst die Schlüssel weiter. Selbst wir haben diesen Zugriff nicht."; - out.home_host = "Dies ist eine unabhängige Installation der CrypPad-Software. Der Quellcode ist auf GitHub verfügbar."; - out.home_host_agpl = "CryptPad kann unter der Lizenz AGPL3 verbreitet werden"; - out.home_ngi = "Gewinner beim NGI Award"; - - //about.html - out.about_intro = 'CryptPad wurde erstellt im Forschungsteam von XWiki SAS, einem kleinen Unternehmen in Paris (Frankreich) und Iasi (Rumänien). Im Kernteam arbeiten 3 Mitglieder an CryptPad, außerdem gibt es einige Mitwirkende innerhalb und außerhalb von XWiki SAS.'; - out.about_core = 'Kernentwickler'; - out.about_contributors = 'Wichtige Mitwirkende'; - - // contact.html - out.main_about_p22 = 'Uns antweeten'; - out.main_about_p23 = 'Einen Fehlerbericht auf GitHub erstellen'; - out.main_about_p24 = 'Hallo sagen (Matrix)'; - out.main_about_p25 = 'Uns eine E-Mail schicken'; - out.main_about_p26 = 'Wenn du Fragen oder Kommentare hast, freuen wir uns, von dir zu hören!'; - - out.main_info = "

    Vertrauenswürdige Zusammenarbeit

    Lass deine Ideen gemeinsam wachsen, während die Zero-Knowledge-Technologie den Schutz deiner Daten sogar uns gegenüber sichert."; - out.main_catch_phrase = "Die Cloud ohne Preisgabe deiner Daten"; - - out.main_richText = 'Rich-Text-Editor'; - out.main_code = 'Code-Editor'; - out.main_slide = 'Folien-Editor'; - out.main_poll = 'Umfragen'; - out.main_drive = 'CryptDrive'; - - out.main_richTextPad = 'Rich-Text-Pad'; - out.main_codePad = 'Markdown/Code-Pad'; - out.main_sheetPad = 'Tabellen (Beta)'; - out.main_slidePad = 'Markdown-Präsentation'; - out.main_pollPad = 'Umfrage oder Terminabstimmung'; - out.main_whiteboardPad = 'Whiteboard'; - out.main_kanbanPad = 'Kanban-Board'; - out.main_localPads = 'Lokale Dokumente'; - out.main_yourCryptDrive = 'Dein CryptDrive'; - out.main_footerText = "Mit CryptPad kannst du schnell kollaborative Dokumente erstellen, um Notizen oder Ideen zusammen mit anderen zu bearbeiten."; - - out.footer_applications = "Anwendungen"; - out.footer_contact = "Kontakt"; - out.footer_aboutUs = "Über uns"; - - out.about = "Über uns"; - out.privacy = "Datenschutz"; - out.contact = "Kontakt"; - out.terms = "Nutzungsbedingungen"; - out.blog = "Blog"; - - out.topbar_whatIsCryptpad = "Was ist CryptPad"; - - // what-is-cryptpad.html - - out.whatis_title = 'Was ist CryptPad'; - out.whatis_collaboration = 'Effektive und und leichte Zusammenarbeit'; - out.whatis_collaboration_p1 = 'Mit CryptPad kannst du kollaborative Dokumente erstellen, um Notizen und Ideen gemeinsam zu bearbeiten. Wenn du dich registrierst und einloggst, bekommst du die Möglichkeit, Dateien hochzuladen und Ordner einzurichten, um alle deine Dokumente zu organisieren. Als registrierter Nutzer erhältst du kostenlos 50 MB Speicherplatz.'; - out.whatis_collaboration_p2 = 'Du kannst den Zugang zu einem CryptPad-Dokument teilen, indem du einfach den entsprechenden Link teilst. Du kannst auch einen schreibgeschützten Zugang erstellen, um die Ergebnisse deiner Arbeit zu teilen, während du sie noch bearbeitest.'; - out.whatis_collaboration_p3 = 'Du kannst Rich-Text Dokumente mit dem CKEditor erstellen. Außerdem kannst du Markdown-Dokumente erstellen, die in Echtzeit formatiert angezeigt werden, während du tippst. Du kannst auch die Umfrage-Anwendung verwenden, um Termine unter mehrere Teilnehmern zu abzustimmen.'; - out.whatis_zeroknowledge = 'Zero Knowledge - Ohne Preisgabe deiner Daten'; - out.whatis_zeroknowledge_p1 = "Wir wollen nicht wissen, was du gerade tippst. Und mit moderner Verschlüsselungstechnologie, kannst du sicher sein, dass wir es auch nicht können. CryptPad verwendet 100% clientseitige Verschlüsselung, um den Inhalt vor uns, den Hostern dieser Website, zu schützen."; - out.whatis_zeroknowledge_p2 = 'Wenn du dich registrierst und einloggst, werden dein Benutzername und dein Passwort in einen Schlüssel mit einer Scrypt Schlüssel-Ableitungsfunktion umgerechnet. Weder dieser Schlüssel noch der Benutzername oder das Passwort werden zum Server geschickt. Stattdessen werden sie clientseitig benutzt, um den Inhalt deines CryptDrives zu entschlüsseln. Dieses beinhaltet alle Dokumente, die dir zugänglich sind.'; - out.whatis_zeroknowledge_p3 = 'Wenn du Link zu einem Dokument teilst, teilst du auch den kryptografischen Schlüssel, der Zugang zu diesem Dokument gibt. Da dieser Schlüssel im Fragmentbezeichner liegt, wird er nie direkt zum Server geschickt. Bitte lies unsere Blogeintrag über Datenschutz, um mehr darüber zu erfahren, auf welche Typen von Metadaten wir zugreifen können und auf welche nicht.'; - out.whatis_drive = 'Organisieren mit CryptDrive'; - out.whatis_drive_p1 = 'Sobald auf ein Dokument mit CryptPad zugegriffen wird, wird es automatisch zum Stamm-Ordner deines CryptDrives hinzugefügt. Später kannst du diese Dokumente in eigenen Ordnern organisieren oder du kannst es in den Papierkorb verschieben. CryptDrive erlaubt die Suche nach deinen Dokumenten, wie und wann du willst.'; - out.whatis_drive_p2 = 'Mit einfachem Drag & Drop kannst du die Pads in deinem CryptDrive verschieben. Die Links zu diesen Pads bleiben erhalten, damit Mitarbeiter nie ihren Zugang verlieren.'; - out.whatis_drive_p3 = 'Du kannst auch Dateien in dein CryptDrive hochladen und mit deinen Kollegen teilen. Hochgeladene Dateien können genau so wie kollaborative Pads organisiert werden.'; - out.whatis_business = 'CryptPad im Business'; - out.whatis_business_p1 = 'Die Zero-Knowledge-Verschlüsselung von CryptPad multipliziert die Effektivität existierender Sicherheitsprotokolle durch Spiegelung der Zugangskontrollen von Organisationen in Kryptografie. Weil sensible Daten nur mit den Zugangsdaten des Nutzers entschlüsselt werden können, ist CryptPad ein weniger lohnendes Ziel verglichen mit traditionellen Cloud-Diensten. Lies das CryptPad-Whitepaper, um mehr darüber zu erfahren, wie CryptPad deinem Unternehmen helfen kann.'; - out.whatis_business_p2 = 'CryptPad kann auf eigenen Rechnern installiert werden. Entwickler der CryptPad-Software von XWiki SAS können kommerzielle Unterstützung, Anpassung und Entwicklung anbieten. Bitte schicke eine E-Mail an sales@cryptpad.fr, um mehr zu erfahren.'; - - // privacy.html - - out.policy_title = 'Datenschutzbestimmungen für CryptPad'; - out.policy_whatweknow = 'Was wir über dich wissen'; - out.policy_whatweknow_p1 = 'Als im Web gehostete Anwendung hat CryptPad Zugriff auf die Metadaten, die vom HTTP-Protokoll übertragen werden. Dies umfasst deine IP-Adresse und diverse andere HTTP-Header, die es ermöglichen, deinen Browser zu identifizieren. Um zu sehen, welche Daten dein Browser preisgibt, kannst du die Seite WhatIsMyBrowser.com besuchen.'; - out.policy_whatweknow_p2 = 'Wir nutzen Kibana, eine Open-Source-Analyseplattform, um mehr über unsere Nutzer zu erfahren. Kibana teilt uns mit, wie du Cryptpad gefunden hast — durch direkten Zugriff, mit Hilfe einer Suchmaschine oder über einen Link auf einer anderen Seite wie beispielsweise Reddit oder Twitter.'; - out.policy_howweuse = 'Wie wir das Wissen anwenden'; - out.policy_howweuse_p1 = 'Wir nutzen diese Informationen, um besser entscheiden zu können, wie CryptPad beworben werden kann und um derzeit genutzte Strategien zu evaluieren. Informationen über deinen Standort helfen uns bei der Abschätzung, welche Sprachen wir besser unterstützen sollten.'; - out.policy_howweuse_p2 = "Informationen zu deinem Browser (ob du auf einem Desktop oder Smartphone arbeitest) helfen uns bei der Entscheidung, welche Funktionen priorisiert werden sollen. Unser Entwicklerteam ist klein, deshalb ist es uns wichtig, Entscheidungen derart zu treffen, dass möglichst viele Nutzer davon profitieren."; - out.policy_whatwetell = 'Was wir anderen über dich (nicht) erzählen'; - out.policy_whatwetell_p1 = 'Wir reichen keine von uns gesammelten Daten weiter, außer im Falle einer gerichtlichen Anordnung.'; - out.policy_links = 'Links zu anderen Seiten'; - out.policy_links_p1 = 'Diese Seite beinhaltet Links zu anderen Seiten, teilweise werden diese von anderen Organisationen verwaltet. Wir sind nicht für den Umgang mit der Privatsphäre und die Inhalte der anderen Seiten verantwortlich. Generell werden Links zu externen Seiten in einem neuem Fenster geöffnet, um zu verdeutlichen, dass du CryptPad.fr verlässt.'; - out.policy_ads = 'Werbung'; - out.policy_ads_p1 = 'Wir zeigen keine Onlinewerbung, können aber zu Organisationen verlinken, die unsere Forschung finanzieren.'; - out.policy_choices = 'Deine Möglichkeiten'; - out.policy_choices_open = 'Unser Code ist frei, deshalb kannst du jederzeit deine eigene CryptPad-Instanz hosten.'; - out.policy_choices_vpn = 'Wenn du unsere gehostete Instanz nutzen möchtest, ohne deine IP-Adresse zu offenbaren, bitten wir dich darum, deine IP-Adresse zu verschleiern. Das ist zum Beispiel mit dem Tor Browser oder einem VPN-Zugang möglich.'; - out.policy_choices_ads = 'Wenn du unsere Analysesoftware blockieren möchtest, kannst du Blocker-Software wie Privacy Badger verwenden.'; - - // features.html - - out.features = "Funktionen"; - out.features_title = "Vergleich der Funktionen"; - out.features_feature = "Funktion"; - out.features_anon = "Anonymer Benutzer"; - out.features_registered = "Angemeldete Benutzer"; - out.features_premium = "Premium-Benutzer"; - out.features_notes = "Hinweise"; - - out.features_f_apps = "Zugang zu den wichtigsten Anwendungen"; - out.features_f_core = "Gemeinsame Funktionen der Anwendungen"; - out.features_f_core_note = "Bearbeiten, Importieren & Exportieren, Verlauf, Benutzerliste, Chat"; - out.features_f_file0 = "Dateien öffnen"; - out.features_f_file0_note = "Von anderen geteilte Dateien ansehen und herunterladen"; - out.features_f_cryptdrive0 = "Begrenzter Zugang zu CryptDrive"; - out.features_f_cryptdrive0_note = "Du kannst besuchte Dokumente in deinem Browser speichern, damit du sie später öffnen kannst"; - out.features_f_storage0 = "Speicherung für eine begrenzte Zeit"; - out.features_f_storage0_note = "Neue Dokumente könnten nach drei Monaten ohne Aktivität gelöscht werden"; - - out.features_f_anon = "Alle Funktionen für anonyme Benutzer"; - out.features_f_anon_note = "Mit einer besseren Benutzbarkeit und mehr Kontrolle über deine Dokumente"; - out.features_f_cryptdrive1 = "Alle Funktionen des CryptDrives"; - out.features_f_cryptdrive1_note = "Ordner, geteilte Ordner, Vorlagen, Tags"; - out.features_f_devices = "Deine Dokumente auf allen deinen Geräten"; - out.features_f_devices_note = "Überall Zugang zu deinem CryptDrive mit deinem Benutzerkonto"; - out.features_f_social = "Soziale Anwendungen"; - out.features_f_social_note = "Ein Profil erstellen, ein Profilbild verwenden, mit Kontakten chatten"; - out.features_f_file1 = "Dateien hochladen und teilen"; - out.features_f_file1_note = "Dateien mit Freunden teilen oder sie in Dokumenten einbetten"; - out.features_f_storage1 = "Langfristige Speicherung (50 MB)"; - out.features_f_storage1_note = "Dateien in deinem CryptDrive werden nicht wegen Inaktivität gelöscht"; - out.features_f_register = "Registrieren (kostenlos)"; - out.features_f_register_note = "Keine E-Mail-Adresse oder persönliche Informationen notwendig"; - - out.features_f_reg = "Alle Funktionen für angemeldete Benutzer"; - out.features_f_reg_note = "Du unterstützt die Entwicklung von CryptPad"; - out.features_f_storage2 = "Mehr Speicherplatz"; - out.features_f_storage2_note = "Zwischen 5 GB und 50 GB, abhängig vom gewählten Tarif"; - out.features_f_support = "Schnellerer Support"; - out.features_f_support_note = "Professioneller Support via E-Mail mit dem Team-Tarif"; - out.features_f_supporter = "Werde ein Unterstützer des Datenschutzes"; - out.features_f_supporter_note = "Hilf uns beweisen, dass Software mit eingebauten Datenschutz die Normalität sein sollte"; - out.features_f_subscribe = "Premium kaufen"; - out.features_f_subscribe_note = "Du muss zuerst in CryptPad eingeloggt sein"; - - // faq.html - - out.faq_link = "FAQ"; - out.faq_title = "Häufige Fragen"; - out.faq_whatis = "Was ist CryptPad?"; - out.faq = {}; - out.faq.keywords = { - title: 'Schlüsselkonzepte', - pad: { - q: "Was ist ein Pad?", - a: "Ein CryptPad-Dokument wird meist einfach Pad genannt. Dies wurde von Etherpad übernommen, einem kollaborativen Echtzeit-Editor.\n"+ - "Es beschreibt ein Dokument, das du in deinem Browser bearbeiten kannst, normalerweise mit der Möglichkeit für andere Personen, die Veränderungen nahezu in Echtzeit zu sehen." - }, - owned: { - q: "Was ist ein eigenes Pad?", - a: "Ein eigenes Pad ist ein Pad mit einem definierten Eigentümer, der anhand seiner Unterschrift mit öffentlichen Schlüssel erkannt wird." + - "Der Eigentümer eines Pads kann entscheiden, das Pad zu löschen. In diesem Fall ist das Pad auch für andere Nutzer nicht mehr verfügbar. Dabei spielt es keine Rolle, ob das Pad im CryptDrive der anderen Nutzer gespeichert war oder nicht." - }, - expiring: { - q: "Was sind ablaufende Pads?", - a: "Ein Pad kann mit einem Ablaufdatum versehen werden. Nach diesem Datum wird es automatisch vom Server gelöscht." + - " Das Ablaufdatum kann sowohl sehr bald sein (in ein paar Stunden) oder in weiter Zukunft liegen (in hunderten Monaten)." + - " Das Pad und sein gesamter Verlauf wird nach dem Ablaufdatum endgültig gelöscht, auch wenn es gerade noch bearbeitet wird.

    " + - "Wenn ein Dokument ein Ablaufdatum hat, kann man dieses Datum in den Eigenschaften sehen: entweder mit einem Rechtsklick im CryptDrive oder mit der Eigenschaften-Ansicht im geöffneten Pad." - }, - tag: { - q: "Wie kann ich Tags verwenden?", - a: "Du kannst Pads und im CryptDrive hochgeladene Dateien taggen. Dies bedeutet, sie mit einem Stichwort (Tag) zu versehen. Während der Bearbeitung gibt es dafür die Schaltfläche Tag () in der Werkzeugleiste." + - " Wenn du die Pads und Dateien in deinem CryptDrive nach einem Tag durchsuchen möchtest, beginne den Suchbegriff mit einem Hashtag, also beispielsweise #crypto." - }, - template: { - q: "Was ist eine Vorlage?", - a: "Eine Vorlage ist ein Pad, das dazu verwendet werden kann, um den Inhalt für neu erstellte Pads zu definieren." + - " Jedes existierende Pad kann in eine Vorlage umgewandelt werden, indem es in den Bereich Vorlagen des CryptDrives verschoben wird." + - " Du kannst auch eine Kopie eines Dokuments erstellen, die zur Vorlage wird, indem du auf die Vorlagen-Schaltfläche () der Werkzeugleiste des Editors klickst." - }, - abandoned: { - q: "Was ist ein verlassenes Pad?", - a: "Ein verlassenes Pad ist ein Pad, das kein registrierter Benutzer in seinem CryptDrive gespeichert hat und in den letzten sechs Monaten nicht bearbeitet wurde. Verlassene Pads werden automatisch vom Server gelöscht." - }, - }; - out.faq.privacy = { - title: 'Privatsphäre', - different: { - q: "Wie unterscheidet sich CryptPad von anderen Pad-Diensten?", - a: "CryptPad verschlüsselt Veränderungen deiner Dokumente, bevor diese Information zum Server gesendet wird. Somit können wir nicht lesen, was du getippt hast." - }, - me: { - q: "Welche Informationen hat der Server über mich?", - a: "Die Administratoren des Servers können die IP-Adresse der Personen sehen, die CryptPad besuchen." + - " Wir speichern nicht, welche Adresse welches Pad besucht, aber wir könnten es tun. Wir haben aber keinen Zugriff auf den entschlüsselten Inhalt der Pads." + - " Wenn du besorgt bist, dass wir diese Informationen auswerten, solltest du davon auszugehen, dass wir es tun. Denn wir können nicht beweisen, dass wir es nicht tun.

    " + - - " Wir sammeln grundlegende technische Informationen darüber, wie CryptPad benutzt wird. Dies umfasst beispielsweise die Größe des Bildschirms und welche Schaltflächen am häufigsten angeklickt werden." + - " Das hilft uns dabei, unsere Software besser zu machen. Aber diese Sammlung unterbleibt, wenn du den Haken bei Rückmeldung aktivieren entfernst.

    " + - - "Wir verfolgen, welche Pads im CryptDrive eines Nutzers gespeichert werden. Dies ist notwendig, um die Speicherbegrenzungen umzusetzen. Den Inhalt der Pads kennen wir nicht." + - " Die Speicherbegrenzungen sind mit dem öffentlichen Schlüssel eines Benutzers verbunden. Aber wir verbinden Namen oder E-Mail-Adressen nicht mit diesen öffentlichen Schlüsseln.

    " + - - " Du kannst mehr darüber in diesem Blogeintrag lesen." - }, - register: { - q: "Weisst der Server mehr über mich, wenn ich registriere?", - a: "Wir verlangen nicht Deine Emailadresse und der Server kennt Benutzername und Passwort auch dann nicht, wenn du dich registrierst. " + - " Statt dessen generiert das Registrierungs- und Anmeldeformular ein Schlüsselpaar mit deiner Eingabe. Nur der öffentliche Schlüssel dieses Schlüsselpaars wird zum Server geschickt." + - " Mit diesem öffentlichen Schlüssel könenn wir z.B. die Menge der Daten, die du benutzt, kontrollieren, denn jeder Benutzer hat eine beschränkte Quota.

    " + - - " Wir benutzen die Rückmeldungs-Funktion, um den Server zu informieren, dass jemand mit deiner IP ein Konto registriert hat." + - " Damit können wir messen, wie viele Benutzer CryptPad Konten registrieren und aus welchen Regionen. Somit können wir erfahren, welche Sprache besseren Support braucht.

    " + - - " Wenn Du registrierst, erstellst Du einen öffentlichen Schlüssel, der benutzt wird, um den Server zu informieren, dass er Dokumente auch dann nicht löschen sollte, wenn sie nicht aktiv benutzt werden." + - " Diese Information zeigt dem Server, wie Du CryptPad benutzt und dieses System erlaubt uns, die Dokumente zu löschen, wofür sich keiner mehr interessiert." - }, - other: { - q: "Was können andere Benutzer über mich erfahren?", - a: "Wenn du ein Pad mit jemand anderen bearbeitest, kommunizierst du mit dem Server. Nur wir kennen deine IP-Adresse." + - " Andere Benutzer sehen deinen Benutzernamen, dein Benutzerbild, den Link zu deinem Profils (wenn du eins hast) und deinen öffentlichen Schlüssel (um die Nachrichten zu diesen Benutzern zu verschlüsseln)." - }, - anonymous: { - q: "Macht mich CryptPad anonym?", - a: "Auch wenn CryptPad so konzipiert wurde, dass es so wenig wie möglich über dich weiß, liefert es keine strenge Anonymität." + - " Unsere Server kennen deine IP-Adresse, allerdings kannst du diese Information verbergen, indem du Tor verwendest." + - " Tor zu verwenden, ohne dein Verhalten zu ändern, garantiert auch keine Anonymität, da der Server Benutzer anhand ihrer einzigartigen öffentlichen Schlüssel identifizieren kann." + - " Wenn du denselben Schlüssel mit und ohne Tor benutzt, kann deine Sitzung de-anonymisiert werden.

    " + - - " Für Benutzer mit niedrigeren Ansprüchen an ihre Privatsphäre erfordert CryptPad im Gegenteil zu anderen Onlinediensten keine Identifikation mit Namen, Telefonnummer oder E-Mail-Adressen." - }, - policy: { - q: "Habt ihr eine Datenschutzerklärung?", - a: "Ja! Sie ist hier verfügbar." - } - }; - out.faq.security = { - title: 'Sicherheit', - proof: { - q: "Wie benutzt ihr Zero-Knowledge-Beweise?", - a: "Wir benutzen den Begriff Ohne Preisgabe von Daten (Zero Knowledge) nicht im Sinn eines Zero-Knowledge-Beweises, sondern im Sinn eines Zero-Knowledge-Webdienstes." + - " Ein Zero-Knowledge-Webdienst verschlüsselt die Benutzerdaten im Browser, ohne dass der Server je Zugang zu den unverschlüsselten Daten oder zu den Schlüsseln hat.

    " + - " Wir haben hier eine kurze Liste von Zero-Knowledge-Webdiensten erstellt." - }, - why: { - q: "Wieso sollte ich CryptPad verwenden?", - a: "Unsere Position ist, dass Clouddienste nicht Zugang zu deinen Daten verlangen sollten, damit du sie mit deinen Kontakten und Mitarbeitern teilen kannst." + - " Wenn du einen Webdienst benutzt, der nicht explizit angibt, dass kein Zugang zu deinen Information möglich ist, ist es sehr wahrscheinlich, dass deine Information für andere Zwecke verwertet werden." - }, - compromised: { - q: "Liefert mir CryptPad einen Schutz, wenn mein Gerät kompromittiert wird?", - a: "Für den Fall, dass dein Gerät gestohlen wird, ermöglicht CryptPad, das Ausloggen aller Geräte zu erzwingen - außer dem, das du gerade verwendest." + - " Gehe dazu zur Seite mit deinen Einstellungen und klicke auf Überall ausloggen." + - " Alle anderen Geräte, die mit diesem Konto verbunden sind, werden dann ausgeloggt. " + - " Alle früher verbundenen Geräte werden ausgeloggt, sobald sie CryptPad besuchen.

    " + - - "Die beschriebene Funktion ist derzeit im Browser implementiert und nicht im Server." + - " Somit schützt sie nicht vor staatlichen Akteuren. Aber sie sollte ausreichend sein, wenn du nach Verwendung eines öffentlichen Computers vergessen hast dich auszuloggen." - }, - crypto: { - q: "Welche Kryptografie benutzt ihr?", - a: "CryptPad basiert auf zwei quelloffenen Kryptografiebibliotheken: " + - "tweetnacl.js und scrypt-async.js.

    " + - - "Scrypt ist eine Passwort-basierte Schlüsselableitungsfunktion. Wir werden sie, um deinen Benutzernamen und dein Passwort in ein einzigartiges Schlüsselpaar umzuwandeln. Dieses sichert den Zugang zu deinem CryptDrive, so dass nur du auf die Liste deiner Pads zugreifen kannst.

    " + - - " Wir verwenden die Verschlüsselung xsalsa20-poly1305 und x25519-xsalsa20-poly1305 von tweetnacl, um Dokumente und den Chatverlauf zu verschlüsseln." - } - }; - out.faq.usability = { - title: 'Bedienung', - register: { - q: "Was kriege ich, wenn ich mich registriere?", - a: "Registrierte Benutzer können Funktionen verwenden, die anonyme Nutzer nicht verwenden können. Es gibt hier eine entsprechende Übersicht." - }, - share: { - q: "Wie kann ich den Zugang zu einem verschlüsselten Pad mit Freunden teilen?", - a: "CryptPad fügt den geheimen Schlüssel deines Pad nach dem Zeichen # zur URL hinzu." + - " Alles, was nach diesem Zeichen kommt, wird nicht zum Server gesendet. Also haben wir nie Zugang zu deinen Schlüsseln." + - " Wenn du den Link zu einem Pad teilst, teilst du auch die Fähigkeit zum Lesen und zum Bearbeiten." - }, - remove: { - q: "Ich habe ein Dokument aus meinem CryptDrive gelöscht, aber der Inhalt ist noch verfügbar. Wie kann ich es entfernen?", - a: "Nur eigene Pads, die im Februar 2018 eingeführt wurden, können gelöscht werden und zwar nur von deren Eigentümer " + - " (der Benutzer, der das Dokument ursprünglich erstellt hat). Wenn du nicht der Eigentümer des Pads bist, musst du den Eigentümer bitten, dass er dieses für dich löscht." + - " Bei Pads, deren Eigentümer du bist, kannst du auf das Pad in deinem CryptDrive rechtsklicken und Vom Server löschen wählen." - }, - forget: { - q: "Was passiert, wenn ich mein Passwort vergesse?", - a: " Wenn wir dein Passwort zurücksetzen könnten, könnten wir auch auf deine Daten zugreifen." + - " Wenn du dein Passwort nicht aufgeschrieben hast und dich auch nicht daran erinnern kannst, kannst du vielleicht deine Pads aus deinem Browserverlauf zurückgewinnen." - }, - change: { - q: "Was ist, wenn ich mein Passwort ändern möchte?", - a: "Du kannst dein CrypPad-Passwort in den Einstellungen ändern." - }, - devices: { - q: "Ich bin auf zwei Geräten eingeloggt und sehe zwei unterschiedliche CryptDrives. Wie ist das möglich?", - a: "Es ist möglich, dass du zweimal mit dem gleichen Benutzernamen registriert bist, aber mit unterschiedlichen Passwörtern." + - " Weil der CyrptPad-Server dich anhand deiner kryptografischen Unterschrift und nicht anhand deines Namens identifiziert, kann er nicht verhindern, dass der gleiche Name mehrmals verwendet wird." + - " Somit hat jedes Benutzerkonto eine einzigartige Kombination aus Benutzername und Passwort." + - " Angemeldete Benutzer können ihren Benutzernamen im oberen Teil der Einstellungsseite sehen." - }, - folder: { - q: "Kann ich ganze Ordner in CryptDrive teilen?", - a: "Ja, du kannst ganze Ordner und alle Pads darin teilen." - }, - feature: { - q: "Könnt ihr diese eine Funktion hinzufügen, die ich brauche?", - a: "Viele Funktionen wurden in CryptPad umgesetzt, weil Benutzer darum gebeten haben." + - " Auf unserer Kontaktseite haben wir die Möglichkeiten aufgelistet, wie man mit uns in Kontakt treten kann.

    " + - - "Leider können wir aber nicht garantieren, dass wir alle Funktionen umsetzen, um die Benutzer bitten." + - " Wenn eine Funktion kritisch für deine Organisation ist, kannst du die Entwicklung dieser Funktion sponsern und somit deren Realisierung sichern." + - " Bitte kontaktiere sales@cryptpad.fr für mehr Informationen.

    " + - - "Auch wenn du nicht die Entwicklung einer Funktion sponsorn kannst, sind wir an Rückmeldungen interessiert. Diese helfen uns dabei, CryptPad zu verbessern." + - " Kontaktiere uns jederzeit über einen der oben angegebenen Wege." - }, - }; - out.faq.other = { - title: "Andere Fragen", - pay: { - q: "Wieso soll ich zahlen, wenn so viele Funktionen sowieso kostenfrei sind?", - a: "Wir geben Unterstützern zusätzlichen Speicherplatz sowie die Möglichkeit, die Speicherplatzbegrenzung ihrer Freunde zu erhöhen (erfahre mehr).

    " + - - " Über diese diese kurzfristigen Vorteile hinaus kannst du, wenn du ein Premiumangebot annimmst, die aktive Weiterentwicklung von CryptPad fördern. Das beinhaltet, Fehler zu beseitigen, neue Funktionen zu umzusetzen und Installationen von CryptPad auf eigenen Servern zu erleichtern." + - " Zusätzlich hilfst du, anderen Anbietern zu beweisen, dass Leute datenschutzfreundliche Technologien unterstützen. Wir hoffen, dass Geschäftsmodelle, die auf dem Verkauf von Benutzerdaten basieren, letztendlich der Vergangenheit angehören werden.

    " + - - "Außerdem glauben wir, dass es gut ist, die Funktionen von CryptPad kostenfrei anzubieten. Denn jeder verdient persönlichen Datenschutz und nicht nur Personen mit hohem Einkommen." + - " Durch deine Unterstützung hilfst du uns, zu ermöglichen, dass auch Menschen mit geringerem Einkommen diese grundlegenden Funktionen genießen können, ohne dass ein Preisetikett daran klebt." - }, - goal: { - q: "Was ist euer Ziel?", - a: "Durch die Verbesserung von Technologien, die die Privatsphäre der Nutzer respektieren, möchten wir die Erwartungen der Benutzer an den Datenschutz auf Cloudplattformen erhöhen." + - " Wir hoffen, dass unsere Arbeit andere Dienstanbieter in allen Bereichen anspornt, ähnliche oder bessere Dienste anzubieten." + - " Wir wissen, dass ein großer Teil des Internets durch gezielte Werbung finanziert wird." + - " Es gibt in dieser Hinsicht viel mehr zu tun als wir jemals schaffen können. Wir freuen uns über die Förderung, Unterstützung und Beiträge aus unserer Community, um diesem Ziel näher zu kommen." - }, - jobs: { - q: "Sucht Ihr Mitarbeiter?", - a: "Ja! Bitte schicke eine kurze Vorstellung an jobs@xwiki.com." - }, - host: { - q: "Könnt ihr mir helfen, meine eigene Installation von CryptPad aufzubauen?", - a: "Wir bieten gerne Support für das Aufsetzen eines internen CryptPads in deiner Organisation. Setze dich bitte mit sales@cryptpad.fr in Verbindung für mehr Information.", - }, - revenue: { - q: "Wie kann ich meine Einnahmen mit den Entwicklern teilen?", - a: " Wenn du deine eigene Installation von CrytPad betreibst und die Einnahmen für deine bezahlten Konten mit Entwicklern teilen möchtest, muss dein Server als Partnerservice konfiguriert werden.

    " + - - "In deinem CryptPad-Verzeichnis befindet sich config.example.js. Darin wird erklärt, wie du deinen Server dafür konfigurieren musst. "+ - "Danach solltest du sales@cryptpad.fr kontaktieren, damit geprüft wird, dass dein Server richtig mit HTTPS konfiguriert ist, und die Zahlungsmethoden abgesprochen werden können. " - }, - }; - - // terms.html - - out.tos_title = "Nutzungsbedingungen für CryptPad"; - out.tos_legal = "Sei nicht bösartig oder missbrauchend und mache nichts illegales."; - out.tos_availability = "Wir hoffen, dass dir dieser Dienst nützt, aber Erreichbarkeit und Performanz können nicht garantiert werden. Bitte exportiere deine Daten regelmäßig."; - out.tos_e2ee = "CryptPad-Inhalte können von allen gelesen oder bearbeitet werden, die den Fragmentbezeichner des Dokuments erraten oder auf eine andere Art davon erfahren. Wir empfehlen dir Ende-Zu-Ende verschlüsselte Nachrichtentechnik (e2ee) zum Versenden der URLs zu nutzen. Wir übernehmen keine Haftung, falls eine URL erschlichen oder abgegriffen wird."; - out.tos_logs = "Metadaten, die dein Browser übermittelt, können geloggt werden, um den Dienst aufrechtzuerhalten."; - out.tos_3rdparties = "Wir geben keine persönlichen Daten an Dritte weiter, außer auf richterliche Anordnung."; - - // 404 page - out.four04_pageNotFound = "Wir konnten die Seite, die du angefordert hast, nicht finden."; - - // BottomBar.html - - //out.bottom_france = 'Hergestellt mit Liebe in Frankreich'; - //out.bottom_support = 'Ein Projekt von XWiki SAS Labs Project mit der Unterstützung von OpenPaaS-ng'; - - // Header.html - - out.updated_0_header_logoTitle = 'Zu deinem CryptDrive'; - out.header_logoTitle = out.updated_0_header_logoTitle; - out.header_homeTitle = 'Zur CryptPad-Hauptseite'; - - // Initial states - - out.help = {}; - - out.help.title = "Mit CryptPad anfangen"; - out.help.generic = { - more: 'Erfahre mehr über die Nutzung von CryptPad, indem du unsere FAQ liest.', - share: 'Benutze das Teilen-Menü (), um Links zu generieren, die Mitarbeiter zum Lesen oder Bearbeiten einladen.', - //stored: 'Jedes Dokument, das du besuchst, wird automatisch in deinem CryptDrive gespeichert.', - save: "Alle Änderungen werden automatisch synchronisiert. Du misst sie also nicht speichern." - }; - - out.help.text = { - formatting: 'Du kannst die Werkzeugleiste anzeigen oder verbergen, indem du auf oder klickst.', - embed: 'Registrierte Benutzer können mit Bilder oder Dateien einbetten, die in ihrem CryptDrive gespeichert sind.', - history: 'Du kannst das Menü Verlauf benutzen, um frühere Versionen anzusehen oder wiederherzustellen.', - }; - - out.help.pad = { - export: 'Du kannst Pads als PDF exportieren, indem du auf die Schaltfläche in der Werkzeugleiste klickst.', - }; - - out.help.code = { - modes: 'Benutze das Dropdown-Menü im Untermenü , um die Syntaxhervorhebung oder das Farbschema zu ändern.', - }; - - out.help.beta = { - warning: 'Dieser Editor ist noch experimentell, du kannst Fehler hier melden' - }; - out.help.oo = { - access: "Zugriff ist auf registrierte Nutzer beschränkt, Mitarbeiter werden sich einloggen müssen", - }; - - out.help.slide = { - markdown: 'Schreibe Folien in Markdown and trenne sie mit --- in einer Zeile.', - present: 'Starte die Präsentation mit der Schaltfläche .', - settings: 'Ändere die Einstellungen der Präsentation (Hintergrund, Übergang, Anzeige der Foliennummer etc.) über die Schaltfläche im Untermenü .', - colors: 'Ändere Text- und Hintergrundfarbe mit den Schaltflächen und .', - }; - - out.help.poll = { - decisions: 'Treffe Entscheidungen gemeinsam mit deinen Bekannten', - options: 'Mache Vorschläge und teile deine Präferenzen mit', - choices: 'Klicke in die Zellen in deiner Spalte, um zwischen ja (), viellecht (~), oder nein () zu wählen.', - submit: 'Klicke auf Senden, damit deine Auswahl für andere sichtbar wird.', - }; - - out.help.whiteboard = { - colors: 'Ein Doppelklick auf Farben erlaubt, die Palette zu verändern.', - mode: 'Deaktiviere den Zeichenmodus, um die vorhandenen Striche zu verschieben und zu verlängern.', - embed: 'Bette Bilder von deiner Festplatte oder von deinem CryptDrive ein und exportiere sie als PNG zu deiner Festplatte oder zu deinem CryptDrive .' - }; - - out.help.kanban = { - add: 'Füge ein neues Board hinzu mit der Schaltfläche in der rechten oberen Ecke.', - task: 'Verschiebe Einträge von einem Board zum anderen per Drag & Drop.', - color: 'Ändere die Farben durch Klicken auf den farbigen Teil neben den Boardtiteln.', - }; - - // Readme - - out.driveReadmeTitle = "Was ist CryptPad?"; - out.readme_welcome = "Willkommen zu CryptPad!"; - out.readme_p1 = "Willkommen zu CryptPad, hier kannst du deine Notizen aufschreiben, allein oder mit Bekannten."; - out.readme_p2 = "Dieses Dokument gibt dir einen kurzen Überblick, wie du CryptPad verwenden kannst, um Notizen zu schreiben, sie zu organisieren und mit anderen zusammen zu arbeiten."; - out.readme_cat1 = "Lerne dein CryptDrive kennen"; - out.readme_cat1_l1 = "Ein Pad erstellen: Klicke in deinem CryptDrive auf {0} und dann auf {1}."; // 0: New, 1: Rich Text - out.readme_cat1_l2 = "Ein Pad deines CryptDrives öffnen: Doppelklicke auf das Symbol eines Pads, um es zu öffnen."; - out.readme_cat1_l3 = "Deine Pads organisieren: Wenn du eingeloggt bist, wird jedes geöffnete Pad im Bereich {0} deines CryptDrives angezeigt."; - out.readme_cat1_l3_l1 = "Im Bereich {0} deines CryptDrives kannst du Dateien zwischen Ordnern verschieben oder neue Ordner anlegen."; // 0: Documents - out.readme_cat1_l3_l2 = "Ein Rechtsklick auf die Symbole zeigt zusätzliche Menüfunktionen."; - out.readme_cat1_l4 = "Verschiebe deine alten Pads in den Papierkorb: Du kannst deine Pads in den {0} verschieben, genauso wie du es bei einem Ordner machst."; // 0: Trash - out.readme_cat2 = "Pads wie ein Profi gestalten"; - out.edit = "Bearbeiten"; - out.view = "Ansehen"; - out.readme_cat2_l1 = "Die Schaltfläche {0} in deinem Pad erlaubt dir, anderen einen Zugang für die Mitarbeit zu geben (entweder zum {1} oder zum {2})."; - out.readme_cat2_l2 = "Der Titel eines Pads kann mit einem Klick auf den Stift geändert werden."; - out.readme_cat3 = "Entdecke CryptPad-Anwendungen"; - - out.readme_cat3_l1 = "Mit dem CryptPad Codeeditor kannst du Code wie JavaScript, Markdown oder HTML bearbeiten"; - out.readme_cat3_l2 = "Mit dem CryptPad Präsentationseditor kannst du schnell Vorträge mit Hilfe von Markdown gestalten"; - out.readme_cat3_l3 = "Mit der CryptPad Umfrage kannst du schnell Abstimmungen durchführen, insbesondere, um Meetings zu planen, die in den Kalender von allen passen."; - - // Tips - out.tips = {}; - out.tips.store = "Jedes Mal, wenn du ein Dokument besuchst und eingeloggt bist, wird es in deinem CryptDrive gespeichert."; - out.tips.marker = "Du kannst Text in einem Dokument mit \"Marker\" Menü in dem Stilmenü markieren."; - out.tips.driveUpload = "Registrierte Benutzer können verschlüsselte Dateien aus ihrer Festplatte hochladen, indem sie sie einfach verschieben und in ihrem CryptDrive ablegen."; - out.tips.filenames = "Du kannst Dateien in deinem CryptDrive neubenennen. Dieser Name ist nur für dich."; - out.tips.drive = "Eingeloggte Benutzern können ihre Dateien in ihrem CryptDrive organisieren. Dieses ist mit einem Klick auf das CryptPad Symbol oben links erreichbar, wenn man in einem Dokument ist."; - out.tips.profile = "Registrierte Benutzer können ihr Profil im Benutzer-Menü oben rechts bearbeiten."; - out.tips.avatars = "Du kannst ein Benutzerbild in dein Profil hochladen. Andere sehen es, wenn sie in einem Dokument zusammenarbeiten."; - out.tips.tags = "Bringe Tags auf deinen Dokumenten an und starte eine Suche-nach-Tags mit dem # Zeichen in der CryptDrive-Suche."; - out.tips.shortcuts = "Mit den Tastenkürzeln `Strg+b`, `Strg+i` und `Strg+u` formatierst du Text fett, kursiv oder unterstrichen."; - out.tips.indent = "In nummerierten Listen oder Aufzählungen kannst du mit Tab und Umschalt+Tab den Einzug erhöhen oder reduzieren."; - out.tips.store = "Jedes Mal, wenn du ein Pad besuchst und eingeloggt bist, wird es in deinem CryptDrive gespeichert."; - out.tips.marker = "Du kannst Text in einem Pad markieren, in dem du den Eintrag \"Marker\" aus dem Stil-Menü auswählst."; - out.tips.driveUpload = "Registrierte Benutzer können verschlüsselte Dateien von ihrer Festplatte hochladen, indem sie diese einfach per Drag & Drop in ihrem CryptDrive ablegen."; - out.tips.filenames = "Du kannst Dateien in deinem CryptDrive umbenennen. Dieser Name ist nur für dich."; - out.tips.drive = "Eingeloggte Benutzer können ihre Dateien in ihrem CryptDrive organisieren. Das CryptDrive ist in allen Pads mit einem Klick auf das CryptPad-Symbol oben links erreichbar."; - out.tips.profile = "Registrierte Benutzer können ihr Profil über das Benutzer-Menü oben rechts bearbeiten."; - out.tips.avatars = "Du kannst ein Profilbild hochladen. Andere Nutzer sehen es, wenn sie mit dir in einem Pad zusammenarbeiten."; - out.tips.tags = "Füge Tags zu deinen Pads hinzu und starte in deinem CryptDrive eine Suche mit dem Zeichen #, um sie zu finden."; - - out.feedback_about = "Wenn du das liest, fragst du dich wahrscheinlich, weshalb dein Browser bei der der Ausführung mancher Aktionen Anfragen an Webseiten sendet."; - out.feedback_privacy = "Wir respektieren deine Datenschutz, aber gleichzeitig wollen wir, dass die Benutzung von CryptPad sehr leicht ist. Deshalb wollen wir erfahren, welche Funktion am wichtigsten für unsere Benutzer ist, indem wir diese mit einer genauen Parameterbeschreibung anfordern."; - out.feedback_optout = "Wenn du das nicht möchtest, kannst du es in deinen Einstellungen deaktivieren."; - - // Creation page - out.creation_404 = "Dieses Pad existiert nicht mehr. Benutze das folgende Formular, um ein neues Pad zu gestalten."; - out.creation_ownedTitle = "Pad-Typ"; - out.creation_owned = "Eigenes Pad"; // Creation page - out.creation_ownedTrue = "Eigenes Pad"; // Settings - out.creation_ownedFalse = "Offenes Pad"; - out.creation_owned1 = "Ein eigenes Pad kann vom Server gelöscht werden, wenn der Eigentümer so entscheidet. Die Löschung eines eigenen Pads bewirkt die Löschung aus allen anderen CryptDrives."; - out.creation_owned2 = "Ein offenes Pad hat keinen Eigentümer. Es kann also nicht vom Server gelöscht werden, es sei denn es hat sein Ablaufdatum erreicht."; - out.creation_expireTitle = "Ablaufdatum"; - out.creation_expire = "Auslaufendes Pad"; - out.creation_expireTrue = "Ein Ablaufdatum hinzufügen"; - out.creation_expireFalse = "Unbegrenzt"; - out.creation_expireHours = "Stunde(n)"; - out.creation_expireDays = "Tag(e)"; - out.creation_expireMonths = "Monat(e)"; - out.creation_expire1 = "Ein unbegrenztes Pad wird nicht vom Server entfernt, solange der Eigentümer es nicht löscht."; - out.creation_expire2 = "Ein auslaufendes Pad hat eine begrenzte Lebensdauer, nach der es automatisch vom Server und aus den CryptDrives anderer Nutzer entfernt wird."; - out.creation_password = "Passwort hinzufügen"; - out.creation_noTemplate = "Keine Vorlage"; - out.creation_newTemplate = "Neue Vorlage"; - out.creation_create = "Erstellen"; - out.creation_saveSettings = "Dieses Dialog nicht mehr anzeigen"; - out.creation_settings = "Mehr Einstellungen anzeigen"; - out.creation_rememberHelp = "Gehe zu deinen Einstellungen, um diese Auswahl zurückzusetzen"; - // Properties about creation data - out.creation_owners = "Eigentümer"; - out.creation_ownedByOther = "Eigentum eines anderen Benutzers"; - out.creation_noOwner = "Kein Eigentümer"; - out.creation_expiration = "Ablaufdatum"; - out.creation_passwordValue = "Passwort"; - out.creation_propertiesTitle = "Verfügbarkeit"; - out.creation_appMenuName = "Fortgeschrittener Modus (Strg + E)"; - out.creation_newPadModalDescription = "Klicke auf einen Pad-Typ, um das entsprechende Pad zu erstellen. Du kannst auch die Tab-Taste für die Auswahl und die Enter-Taste zum Bestätigen benutzen."; - out.creation_newPadModalDescriptionAdvanced = "Du kannst das Kästchen markieren (oder den Wert mit der Leertaste ändern), um den Dialog bei der Pad-Erstellung anzuzeigen (für eigene oder auslaufende Dokumente etc.)."; - out.creation_newPadModalAdvanced = "Dialog bei der Pad-Erstellung anzeigen"; - - // Password prompt on the loading screen - out.password_info = "Das Pad, das du öffnen möchtest, ist mit einem Passwort geschützt. Gib das richtige Passwort ein, um den Inhalt anzuzeigen."; - out.password_error = "Pad nicht gefunden!
    Dieser Fehler kann zwei Ursachen haben: Entweder ist das Passwort ungültig oder das Pad wurde vom Server gelöscht."; - out.password_placeholder = "Gib das Passwort hier ein..."; - out.password_submit = "Abschicken"; - out.password_show = "Anzeigen"; - - // Change password in pad properties - out.properties_addPassword = "Passwort hinzufügen"; - out.properties_changePassword = "Passwort ändern"; - out.properties_confirmNew = "Bist du sicher? Das Hinzufügen eines Passworts wird die URL dieses Pads ändern und den Verlauf löschen. Benutzer ohne das Passwort werden den Zugang zu diesem Pad verlieren."; - out.properties_confirmChange = "Bist du sicher? Das Ändern des Passworts wird den Verlauf löschen. Benutzer ohne das neue Passwort werden den Zugang zu diesem Pad verlieren."; - out.properties_passwordSame = "Das neue Passwort muss sich von dem alten Passwort unterscheiden."; - out.properties_passwordError = "Beim Versuch das Passwort zu ändern ist ein Fehler aufgetreten. Bitte versuche es nochmal."; - out.properties_passwordWarning = "Das Passwort wurde erfolgreich geändert, aber dein CryptDrive konnte nicht aktualisiert werden. Du musst möglicherweise die alte Version des Pads manuell entfernen.
    Klicke auf OK, um die Seite neu zu laden und die Zugriffsrechte zu aktualisieren."; - out.properties_passwordSuccess = "Das Passwort wurde erfolgreich geändert.
    Klicke auf OK, um die Seite neu zu laden und die Zugriffsrechte zu aktualisieren."; - out.properties_changePasswordButton = "Absenden"; - - // New share modal - out.share_linkCategory = "Link teilen"; - out.share_linkAccess = "Zugriffsrechte"; - out.share_linkEdit = "Bearbeiten"; - out.share_linkView = "Ansehen"; - out.share_linkOptions = "Linkoptionen"; - out.share_linkEmbed = "Einbettungsmodus (Werkzeugleiste und Benutzerliste sind verborgen)"; - out.share_linkPresent = "Anzeigemodus (Bearbeitbare Abschnitte sind verborgen)"; - out.share_linkOpen = "In einem neuen Tab öffnen"; - out.share_linkCopy = "In die Zwischenablage kopieren"; - out.share_embedCategory = "Einbetten"; - out.share_mediatagCopy = "Media-Tag in die Zwischenablage kopieren"; - - // Loading info - out.loading_pad_1 = "Initialisiere Pad"; - out.loading_pad_2 = "Lade Pad-Inhalt"; - out.loading_drive_1 = "Lade Daten"; - out.loading_drive_2 = "Aktualisiere Datenformat"; - out.loading_drive_3 = "Verifiziere Datenintegrität"; - - // Shared folders - out.sharedFolders_forget = "Dieses Pad ist nur in einem geteilten Ordner gespeichert. Du kannst es nicht in den Papierkorb verschieben. Aber du kannst es in deinem CryptDrive löschen."; - out.sharedFolders_duplicate = "Einige zu verschiebende Pads waren schon im Zielordner geteilt."; - out.sharedFolders_create = "Erstelle einen geteilten Ordner"; - out.sharedFolders_create_name = "Neuer Ordner"; - out.sharedFolders_create_owned = "Eigener Ordner"; - out.sharedFolders_create_password = "Ordnerpasswort"; - out.sharedFolders_share = "Teile diese URL mit anderen registrierten Benutzern, um ihnen Zugriff auf den geteilten Ordner zu geben. Sobald sie diese URL öffnen, wird der geteilte Ordner zu ihrem CryptDrive hinzugefügt."; - - out.chrome68 = "Anscheinend benutzt du Chrome oder Chromium in Version 68. Ein darin enthaltener Fehler führt dazu, dass nach ein paar Sekunden die Seite komplett weiß wird oder nicht mehr auf Klicks reagiert. Um das Problem zu beheben, wechsle den Tab und kehre zu CryptPad zurück, oder versuche zu scrollen. Dieser Fehler sollte in der nächsten Version deines Browsers behoben sein."; - - // Manual pad storage popup - out.autostore_file = "Diese Datei"; - out.autostore_sf = "Dieser Ordner"; - out.autostore_pad = "Dieses Dokument"; - out.autostore_notstored = "{0} ist nicht in deinem CryptDrive. Möchtest du es jetzt dort speichern?"; - out.autostore_settings = "Du kannst die automatische Speicherung in deinen Einstellungen aktivieren!"; - out.autostore_store = "Speichern"; - out.autostore_hide = "Nicht speichern"; - out.autostore_error = "Unerwarteter Fehler: Wir konnten das Pad nicht speichern, bitte versuche es nochmal."; - out.autostore_saved = "Das Pad wurde erfolgreich in deinem CryptDrive gespeichert!"; - out.autostore_forceSave = "Speichere die Datei in deinem CryptDrive"; // File upload modal - out.autostore_notAvailable = "Du musst dieses Pad in deinem CryptDrive speichern, bevor du diese Funktion benutzen kannst."; // Properties/tags/move to trash - - // Crowdfunding messages - out.crowdfunding_home1 = "CryptPad braucht deine Hilfe!"; - out.crowdfunding_home2 = "Klicke auf die Schaltfläche, um mehr über die Crowdfunding-Kampagne zu erfahren."; - out.crowdfunding_button = "Unterstütze CryptPad"; - - out.crowdfunding_popup_text = "

    Wir brauchen deine Hilfe!

    " + - "Um sicherzustellen, dass CryptPad weiter aktiv entwickelt wird, unterstütze bitte das Projekt über die " + - 'OpenCollective Seite, wo du unsere Roadmap und Funding-Ziele lesen kannst.'; - out.crowdfunding_popup_yes = "OpenCollective besuchen"; - out.crowdfunding_popup_no = "Nicht jetzt"; - out.crowdfunding_popup_never = "Nicht mehr darum bitten."; - - return out; -}); diff --git a/www/common/translations/old/messages.el.js b/www/common/translations/old/messages.el.js deleted file mode 100644 index 2428a0425..000000000 --- a/www/common/translations/old/messages.el.js +++ /dev/null @@ -1,783 +0,0 @@ -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - - - - out.main_title = "CryptPad: Zero Knowledge, συνεργατική επεξεργασία σε πραγματικό χρόνο"; - out.main_slogan = "Ισχύς εν τη ενώσει - Η συνεργασία είναι η λύση"; // TODO remove? - - out.type = {}; - out.type.pad = 'Εμπλουτισμένο κείμενο'; - out.type.code = 'Κώδικας'; - out.type.poll = 'Δημοσκόπηση'; - out.type.slide = 'Παρουσίαση'; - out.type.drive = 'Αποθηκευτικός χώρος'; - out.type.whiteboard = 'Πίνακας σχεδιασμού'; - out.type.file = 'Αρχείο'; - out.type.media = 'Πολυμέσα'; - out.type.todo = "Εργασίες"; - out.type.contacts = 'Επαφές'; - - out.button_newpad = 'Νέο pad εμπλουτισμένου κειμένου'; - out.button_newcode = 'Νέο pad κώδικα'; - out.button_newpoll = 'Νέα δημοσκόπηση'; - out.button_newslide = 'Νέα παρουσίαση'; - out.button_newwhiteboard = 'Νέος πίνακας'; - - // NOTE: We want to update the 'common_connectionLost' key. - // Please do not add a new 'updated_common_connectionLostAndInfo' but change directly the value of 'common_connectionLost' - out.updated_0_common_connectionLost = "Η σύνδεση με τον διακομιστή χάθηκε
    Βρίσκεστε σε λειτουργία ανάγνωσης μόνο μέχρι να επανέλθει η σύνδεση."; - out.common_connectionLost = out.updated_0_common_connectionLost; - - out.websocketError = 'Αδυναμία σύνδεσης στον διακομιστή...'; - out.typeError = "Αυτό το pad δεν είναι συμβατό με την επιλεγμένη εφαρμογή"; - out.onLogout = 'Έχετε αποσυνδεθεί, {0}κάντε "κλικ" εδώ{1} για να συνδεθείτε
    ή πατήστε Escape για να προσπελάσετε το έγγραφο σε λειτουργία ανάγνωσης μόνο.'; - out.wrongApp = "Αδυναμία προβολής του περιεχομένου αυτής της συνεδρίας στον περιηγητή σας. Παρακαλώ δοκιμάστε επαναφόρτωση της σελίδας."; - - out.loading = "Φόρτωση..."; - out.error = "Σφάλμα"; - out.saved = "Αποθηκεύτηκε"; - out.synced = "Όλα έχουν αποθηκευτεί"; - out.deleted = "Το έγγραφο διαγράφηκε από τον αποθηκευτικό σας χώρο"; - - out.realtime_unrecoverableError = "Η μηχανή πραγματικού χρόνου αντιμετώπισε κάποιο ανεπανόρθωτο σφάλμα. Πατήστε OK για επαναφόρτωση."; - - out.disconnected = 'Έγινε αποσύνδεση'; - out.synchronizing = 'Γίνεται συγχρονισμός'; - out.reconnecting = 'Γίνεται επανασύνδεση...'; - out.typing = "Γίνεται επεξεργασία"; - out.initializing = "Γίνεται προετοιμασία..."; - out.forgotten = 'Μετακινήθηκε στον κάδο ανακύκλωσης'; - out.errorState = 'Κρίσιμο σφάλμα: {0}'; - out.lag = 'Αργή σύνδεση'; - out.readonly = 'Λειτουργία ανάγνωσης μόνο'; - out.anonymous = "Ανώνυμος/η"; - out.yourself = "Ο εαυτός σας"; - out.anonymousUsers = "Ανώνυμοι συντάκτες"; - out.anonymousUser = "Ανώνυμος συντάκτης"; - out.users = "Χρήστες"; - out.and = "Και"; - out.viewer = "Θεατής"; - out.viewers = "Θεατές"; - out.editor = "Συντάκτης"; - out.editors = "Συντάκτες"; - out.userlist_offline = "Είσαστε προς το παρόν εκτός σύνδεσης, η λίστα χρηστών δεν είναι διαθέσιμη."; - - out.language = "Γλώσσα"; - - out.comingSoon = "Έρχεται σύντομα..."; - - out.newVersion = 'To CryptPad αναβαθμίστηκε!
    ' + - 'Δείτε τι καινούριο υπάρχει στην πιο πρόσφατη έκδοση:
    '+ - 'Σημειώσεις κυκλοφορίας του CryptPad {0}'; - - out.upgrade = "Αναβάθμιση"; - out.upgradeTitle = "Αναβαθμίστε τον λογαριασμό σας για να αυξήσετε το όριο αποθηκευτικού χώρου"; - - out.upgradeAccount = "Αναβάθμιση λογαριασμού"; - out.MB = "MB"; - out.GB = "GB"; - out.KB = "KB"; - - out.supportCryptpad = "Υποστηρίξτε το CryptPad"; - - out.formattedMB = "{0} MB"; - out.formattedGB = "{0} GB"; - out.formattedKB = "{0} KB"; - - out.greenLight = "Όλα λειτουργούν σωστά"; - out.orangeLight = "Η αργή σύνδεση ίσως έχει αντίκτυπο στην διάδραση"; - out.redLight = "Έχετε αποσυνδεθεί από τη συνεδρία"; - - out.pinLimitReached = "Έχετε φτάσει το όριο αποθηκευτικού χώρου"; - out.updated_0_pinLimitReachedAlert = "Έχετε φτάσει το όριο αποθηκευτικού χώρου. Τα νέα pads δεν θα αποθηκευτούν στο CryptDrive σας.
    " + - 'Μπορείτε είτε να διαγράψετε αρχεία από το CryptDrive σας, είτε να αναβαθμισετε τον λογαριασμό σας για να αυξήσετε το όριο αποθήκευσης.'; - out.pinLimitReachedAlert = out.updated_0_pinLimitReachedAlert; - out.pinLimitReachedAlertNoAccounts = out.pinLimitReached; - out.pinLimitNotPinned = "Έχετε φτάσει το όριο αποθηκευτικού χώρου.
    "+ - "Αυτό το pad δεν θα αποθηκευτεί στο CryptDrive σας."; - out.pinLimitDrive = "Έχετε φτάσει το όριο αποθηκευτικού χώρου.
    " + - "Δεν μπορείτε να δημιουργήσετε νέα pads."; - - out.moreActions = "Περισσότερες επιλογές"; - - out.importButton = "Εισαγωγή"; - out.importButtonTitle = 'Εισάγετε ένα pad από τοπικό αρχείο'; - - out.exportButton = "Εξαγωγή"; - out.exportButtonTitle = 'Εξάγετε αυτό το pad σε τοπικό αρχείο'; - out.exportPrompt = 'Πως θα θέλατε να ονομάσετε το αρχείο σας;'; - - out.changeNamePrompt = 'Αλλάξτε το όνομα σας (αφήστε το κενό για ανωνυμία): '; - out.user_rename = "Αλλαγή εμφανιζόμενου ονόματος"; - out.user_displayName = "Εμφανιζόμενο όνομα"; - out.user_accountName = "Όνομα χρήστη"; - - out.clickToEdit = "Κάντε \"κλικ\" για επεξεργασία"; - out.saveTitle = "Αποθήκευση τίτλου (enter)"; - - out.forgetButton = "Διαγραφή"; - out.forgetButtonTitle = 'Μετακίνηση αυτού του pad στον κάδο'; - out.forgetPrompt = 'Πατώντας OK θα μετακινηθεί αυτό το pad στον κάδο ανακύκλωσης. Είστε σίγουρος;'; - out.movedToTrash = 'Το pad μετακινήθηκε στον κάδο.
    Μεταφερθείτε στο CryptDrive σας'; - - out.shareButton = 'Διαμοιρασμός'; - out.shareSuccess = 'Ο σύνδεσμος αντιγράφηκε στην προσωρινή μνήμη'; - - out.userListButton = "Λίστα χρηστών"; - - out.userAccountButton = "Ο λογαριασμός σας"; - - out.newButton = 'Νέο'; - out.newButtonTitle = 'Δημιουργία νέου pad'; - out.uploadButton = 'Μεταφόρτωση αρχείου'; - out.uploadButtonTitle = 'Μεταφόρτωση νέου αρχείου στον τρέχοντα φάκελο'; - - out.saveTemplateButton = "Αποθήκευση ως πρότυπο"; - out.saveTemplatePrompt = "Επιλέξτε τίτλο για αυτό το πρότυπο"; - out.templateSaved = "Το πρότυπο αποθηκεύτηκε!"; - out.selectTemplate = "Επιλέξτε ένα πρότυπο ή πατήστε escape"; - out.useTemplate = "Έχετε διαθέσιμα πρότυπα για αυτό το είδος pad. Θα θέλετε να χρησιμοποιήσετε κάποιο;"; //Would you like to "You have available templates for this type of pad. Do you want to use one?"; - out.useTemplateOK = 'Επιλέξτε ένα πρότυπο (Enter)'; - out.useTemplateCancel = 'Ξεκινήστε από το μηδέν (Esc)'; - - out.previewButtonTitle = "Προβολή ή απόκρυψη προεπισκόπησης της μορφοποίησης Markdown"; - - out.presentButtonTitle = "Είσοδος σε λειτουργία παρουσίασης"; - - out.backgroundButtonTitle = 'Αλλάξτε το χρώμα παρασκηνίου στην παρουσίαση'; - out.colorButtonTitle = 'Αλλάξτε το χρώμα κειμένου στην λειτουργία παρουσίασης'; - - out.printText = "Εκτύπωση"; - out.printButton = "Εκτύπωση (enter)"; - out.printButtonTitle = "Εκτυπώστε τις διαφάνειές σας ή εξάγετε τες ως αρχείο PDF"; - out.printOptions = "Επιλογές διάταξης"; - out.printSlideNumber = "Εμφάνιση του αριθμού διαφάνειας"; - out.printDate = "Εμφάνιση της ημερομηνίας"; - out.printTitle = "Εμφάνιση του τίτλου του pad"; - out.printCSS = "Προσαρμοσμένες ρυθμίσεις εμφάνισης (CSS):"; - out.printTransition = "Ενεργοποίηση κινούμενων μεταβάσεων"; - - out.filePickerButton = "Ενσωμάτωση αρχείου από το CryptDrive σας"; - out.filePicker_close = "Κλείσιμο"; - out.filePicker_description = "Επιλέξτε ένα αρχείο από το CryptDrive σας για ενσωμάτωση ή μεταφορτώστε ένα καινούριο"; - out.filePicker_filter = "Προβολή αρχείων κατά όνομα"; - out.or = 'ή'; - - out.tags_title = "Ετικέτες (για εσάς μόνο)"; - out.tags_add = "Ενημερώστε τις ετικέτες αυτής της σελίδας"; - out.tags_searchHint = "Βρείτε αρχεία από τις ετικέτες τους ψάχνωντας στο CryptDrive σας"; - out.tags_searchHint = "Ξεκινήστε μια αναζήτηση με το σύμβολο # στο CryptDrive σας για να βρείτε pads με ετικέτες."; - out.tags_notShared = "Οι ετικέτες σας δεν μοιράζονται με άλλους χρήστες"; - out.tags_duplicate = "Διπλή ετικέτα: {0}"; - out.tags_noentry = "Δεν μπορείτε να βάλετε ετικέτα σε διεγραμένο pad!"; - - out.slideOptionsText = "Επιλογές"; - out.slideOptionsTitle = "Προσαρμόστε τις διαφάνειες σας"; - out.slideOptionsButton = "Αποθήκευση (enter)"; - out.slide_invalidLess = "Μη έγκυρη προσαρμογή"; - - out.languageButton = "Γλώσσα"; - out.languageButtonTitle = "Επιλέξτε τη γλώσσα που θα χρησιμοποιήσετε για την επισήμανση σύνταξης"; - out.themeButton = "Θέμα"; - out.themeButtonTitle = "Επιλέξτε το θέμα που θα χρησιμοποιήσετε για την επεξεργασία κώδικα και διαφανειών"; - - out.editShare = "Σύνδεσμος επεξεργασίας"; - out.editShareTitle = "Αντιγραφή του συνδέσμου επεξεργασίας στην προσωρινή μνήμη"; - out.editOpen = "Άνοιγμα του συνδέσμου επεξεργασίας σε νέα καρτέλα"; - out.editOpenTitle = "Άνοιγμα αυτού του pad για επεξεργασία σε νέα καρτέλα"; - out.viewShare = "Σύνδεσμος μόνο για ανάγνωση"; - out.viewShareTitle = "Αντιγραφή του συνδέσμου μόνο για ανάγνωση στην προσωρινή μνήμη"; - out.viewOpen = "Άνοιγμα του συνδέσμου μόνο για ανάγνωση σε νέα καρτέλα"; - out.viewOpenTitle = "Άνοιγμα αυτού του pad μόνο για ανάγνωση σε νέα καρτέλα"; - out.fileShare = "Αντιγραφή συνδέσμου"; - out.getEmbedCode = "Κώδικας ενσωμάτωσης"; - out.viewEmbedTitle = "Ενσωματώστε αυτό το pad σε μία εξωτερική σελίδα"; - out.viewEmbedTag = "Για να ενσωματώσετε αυτό το pad, συμπεριλάβετε αυτό το iframe στη σελίδα σας, στο σημείο που θέλετε. Μπορείτε να το διαμορφώσετε χρησιμοποιώντας CSS η HTML παραμέτρους."; - out.fileEmbedTitle = "Ενσωματώστε το αρχείο σε μια εξωτερική σελίδα"; - out.fileEmbedScript = "Για να ενσωματώσετε αυτό το αρχείο, συμπεριλάβετε αυτό το script στη σελίδα σας για να φορτωθεί το Media Tag:"; - out.fileEmbedTag = "Έπειτα τοποθετήστε αυτό το Media Tag στο σημείο της σελίδας που επιθυμείτε να γίνει ενσωμάτωση:"; - - out.notifyJoined = "Ο/Η {0} εισήλθε στη συνεργατική συνεδρία"; - out.notifyRenamed = "Ο/Η {0} είναι τώρα γνωστός/η ως {1}"; - out.notifyLeft = "Ο/Η {0} αποχώρησε από τη συνεργατική συνεδρία"; - - out.okButton = 'OK (enter)'; - - out.cancel = "Ακύρωση"; - out.cancelButton = 'Ακύρωση (esc)'; - out.doNotAskAgain = "Να μην ρωτηθώ ξανά (Esc)"; - - out.historyText = "Ιστορικό"; - out.historyButton = "Εμφάνιση ιστορικού του εγγράφου"; - out.history_next = "Μετάβαση στην επόμενη έκδοση"; - out.history_prev = "Μετάβαση στην προηγούμενη έκδοση"; - out.history_goTo = "Μετάβαση στην επιλεγμένη έκδοση"; - out.history_close = "Επιστροφή"; - out.history_closeTitle = "Κλείσιμο ιστορικού"; - out.history_restore = "Επαναφορά"; - out.history_restoreTitle = "Επαναφορά της επιλεγμένης έκδοσης του εγγράφου"; - out.history_restorePrompt = "Είστε σίγουροι πως θέλετε να αντικαταστήσετε την τρέχουσα έκδοση του εγγράφου με την επιλεγμένη;"; - out.history_restoreDone = "Έγινε επαναφορά του εγγράφου"; - out.history_version = "Έκδοση:"; - - // Ckeditor - out.openLinkInNewTab = "Άνοιγμα συνδέσμου σε νέα καρτέλα"; - out.pad_mediatagTitle = "Ρυθμίσεις Media-Tag"; - out.pad_mediatagWidth = "Πλάτος (px)"; - out.pad_mediatagHeight = "Ύψος (px)"; - - // Polls - - out.poll_title = "Zero Knowledge επιλογή ημερομηνίας"; - out.poll_subtitle = "Zero Knowledge, πραγματικού χρόνου οργάνωση"; - - out.poll_p_save = "Οι ρυθμίσεις σας ενημερώνονται άμεσα, έτσι δεν χρειάζεται ποτέ να αποθηκεύσετε."; - out.poll_p_encryption = "Όλο το περιεχόμενο είναι κρυπτογραφημένο και έτσι μόνο τα άτομα που έχουν τον σύνδεσμο μπορούν να έχουν πρόσβαση σε αυτό. Ούτε ο διακομιστής δεν μπορεί να δει τι γράφετε."; - - out.wizardLog = "Πατήστε το κουμπί πάνω αριστερά για να επιστρέψετε στη δημοσκόπηση σας"; - out.wizardTitle = "Χρησιμοποιήστε τον οδηγό για να δημιουργήσετε τη δημοσκόπηση σας"; - out.wizardConfirm = "Είσαστε έτοιμοι να προσθέσετε αυτές τις επιλογές στη δημοσκόπηση σας;"; - - out.poll_publish_button = "Δημοσίευση"; - out.poll_admin_button = "Διαχείριση"; - out.poll_create_user = "Προσθέστε έναν νέο χρήστη"; - out.poll_create_option = "Προσθέστε μια νέα επιλογή"; - out.poll_commit = "Υποβολή"; - - out.poll_closeWizardButton = "Κλείσιμο οδηγού"; - out.poll_closeWizardButtonTitle = "Κλείσιμο οδηγού"; - out.poll_wizardComputeButton = "Υπολογισμός επιλογών"; - out.poll_wizardClearButton = "Εκκαθάριση πεδίων"; - out.poll_wizardDescription = "Αυτόματα δημιουργήστε έναν αριθμό επιλογών εισάγοντας όσες ημερομηνίες και χρόνους θέλετε"; - out.poll_wizardAddDateButton = "+ Ημερομηνίες"; - out.poll_wizardAddTimeButton = "+ Χρόνους"; - - out.poll_optionPlaceholder = "Επιλογή"; - out.poll_userPlaceholder = "Το όνομα σας"; - out.poll_removeOption = "Είστε σίγουροι πως θέλετε να αφαιρέσετε αυτή την επιλογή;"; - out.poll_removeUser = "Είστε σίγουροι πως θέλετε να αφαιρέσετε αυτόν τον χρήστη;"; - - out.poll_titleHint = "Τίτλος"; - out.poll_descriptionHint = "Περιγράψτε τη δημοσκόπηση σας και χρησιμοποιήστε το κουμπί ✓ (δημοσίευση) όταν έχετε τελειώσει.\n" + - "Η περιγραφή μπορεί να γραφτεί χρησιμοποιώντας μορφοποίηση markdown και μπορείτε να ενσωματώσετε γραφικά στοιχεία από το CryptDrive σας.\n" + - "Οποιοσδήποτε με τον σύνδεσμο της δημοσκόπησης μπορεί να αλλάξει την περιγραφή, αλλά αυτό δεν συνίσταται."; - - out.poll_remove = "Αφαίρεση"; - out.poll_edit = "Επεξεργασία"; - out.poll_locked = "Κλείδωμα"; - out.poll_unlocked = "Ξεκλείδωμα"; - - out.poll_show_help_button = "Εμφάνιση βοήθειας"; - out.poll_hide_help_button = "Απόκρυψη βοήθειας"; - - out.poll_bookmark_col = 'Αποθηκεύστε αυτή τη στήλη ώστε να είναι πάντα ξεκλείδωτη και εμφανής κατά την εκκίνηση για εσάς'; - out.poll_bookmarked_col = 'Αυτή είναι η στήλη σελιδοδεικτών σας. Θα είναι πάντα ξεκλείδωτη και εμφανής κατά την εκκίνηση για εσάς.'; - out.poll_total = 'Σύνολο'; - - out.poll_comment_list = "Σχόλια"; - out.poll_comment_add = "Κάντε ένα σχόλιο"; - out.poll_comment_submit = "Αποστολή"; - out.poll_comment_remove = "Διαγράψτε αυτό το σχόλιο"; - out.poll_comment_placeholder = "Το σχόλιό σας"; - - out.poll_comment_disabled = "Δημοσιεύστε αυτή τη δημοσκόπηση χρησημοποιώντας το κουμπί ✓ για να ενεργοποιηθεί ο σχολιασμός."; - - // Canvas - out.canvas_clear = "Εκκαθάριση"; - out.canvas_delete = "Διαγραφή επιλογής"; - out.canvas_disable = "Απενεργοποίηση σχεδιασμού"; - out.canvas_enable = "Ενεργοποίηση σχεδιασμού"; - out.canvas_width = "Πλάτος"; - out.canvas_opacity = "Αδιαφάνεια"; - out.canvas_opacityLabel = "Αδιαφάνεια: {0}"; - out.canvas_widthLabel = "Πλάτος: {0}"; - out.canvas_saveToDrive = "Αποθηκεύστε αυτή την εικόνα ως αρχείο στο CryptDrive σας"; - out.canvas_currentBrush = "Τρέχων πινέλο"; - out.canvas_chooseColor = "Επιλογή χρώματος"; - out.canvas_imageEmbed = "Εισάγετε μια εικόνα από τον υπολογιστή σας"; - - // Profile - out.profileButton = "Προφίλ"; // dropdown menu - out.profile_urlPlaceholder = 'Διεύθυνση'; - out.profile_namePlaceholder = 'Το όνομα που θα εμφανίζετε στο προφίλ σας'; - out.profile_avatar = "Αβατάρ"; - out.profile_upload = " Μεταφορτώστε ένα νέο αβατάρ"; - out.profile_uploadSizeError = "Σφάλμα: το αβατάρ σας πρέπει να είναι μικρότερο από {0}"; - out.profile_uploadTypeError = "Σφάλμα: αυτό το είδος αρχείου δεν επιτρέπεται. Επιτρεπόμενα αρχεία: {0}"; - out.profile_error = "Σφάλμα κατά τη δημιουργία του προφίλ σας: {0}"; - out.profile_register = "Πρέπει να εγγραφείτε για να δημιουργήσετε προφίλ!"; - out.profile_create = "Δημιουργήστε προφίλ"; - out.profile_description = "Περιγραφή"; - out.profile_fieldSaved = 'Η καινούρια καταχώρηση αποθηκεύτηκε: {0}'; - - out.profile_inviteButton = "Σύνδεση"; - out.profile_inviteButtonTitle ='Δημιουργήστε έναν σύνδεσμο για να προσκαλέσετε αυτόν το χρήστη να συνδεθεί μαζί σας.'; - out.profile_inviteExplanation = "Πατώντας OK θα δημιουργηθεί ένας σύνδεσμος προς μια ασφαλή συνεδρία επικοινωνίας όπου μόνο ο/η {0} θα μπορεί να ανοίξει.

    Ο σύνδεσμος θα αντιγραφεί στην προσωρινή μνήμη και μπορεί να διαμοιραστεί δημόσια."; - out.profile_viewMyProfile = "Προβολή του προφίλ μου"; - - // contacts/userlist - out.userlist_addAsFriendTitle = 'Προσθήκη του/της "{0}" ως επαφή'; - out.userlist_thisIsYou = 'Αυτός είστε εσείς ("{0}")'; - out.userlist_pending = "Εκρεμμεί..."; - out.contacts_title = "Επαφές"; - out.contacts_addError = 'Σφάλμα κατά την προσθήκη αυτής της επαφής στη λίστα'; - out.contacts_added = 'Η επαφή αποδέχτηκε την πρόσκληση.'; - out.contacts_rejected = 'Η επαφή απέρριψε την πρόσκληση'; - out.contacts_request = 'Ο/Η {0} Θα ήθελε να σας προσθέσει ως επαφή. Αποδοχή;'; - out.contacts_send = 'Αποστολή'; - out.contacts_remove = 'Αφαίρεση αυτής της επαφής'; - out.contacts_confirmRemove = 'Είσαστε σίγουροι πως θέλετε να αφαιρέσετε τον/την {0} από τις επαφές σας;'; - out.contacts_typeHere = "Πληκτρολογήστε ένα μήνυμα εδώ..."; - - out.contacts_info1 = "Αυτές είναι οι επαφές σας. Από εδώ, μπορείτε να:"; - out.contacts_info2 = "Πατήσετε στο εικονίδιο της επαφής για να συνομιλήσετε μαζί τους"; - out.contacts_info3 = "Κάνετε \"διπλό κλικ\" στο εικονίδιο για να δείτε το προφίλ τους"; - out.contacts_info4 = "Ο κάθε συμμετέχων μπορεί να διαγράψει μόνιμα το ιστορικό μιας συνομιλίας"; - - out.contacts_removeHistoryTitle = 'Εκκαθάριση του ιστορικού συνομιλίας'; - out.contacts_confirmRemoveHistory = 'Είστε σίγουροι πως θέλετε να διαγράψετε μόνιμα το ιστορικό; Τα δεδομένα δεν μπορούν να επαναφερθούν'; - out.contacts_removeHistoryServerError = 'Προέκυψε ένα σφάλμα κατά της εκκαθάριση του ιστορικού. Δοκιμάστε ξανά αργότερα'; - out.contacts_fetchHistory = "Ανάκτηση παλαιότερου ιστορικού"; - - // File manager - - out.fm_rootName = "Έγγραφα"; - out.fm_trashName = "Σκουπίδια"; - out.fm_unsortedName = "Αταξινόμητα"; - out.fm_filesDataName = "Όλα τα αρχεία"; - out.fm_templateName = "Πρότυπα"; - out.fm_searchName = "Αναζήτηση"; - out.fm_recentPadsName = "Πρόσφατα pads"; - out.fm_searchPlaceholder = "Αναζήτηση..."; - out.fm_newButton = "Νέο"; - out.fm_newButtonTitle = "Δημιουργήστε ένα νέο pad ή φάκελο, εισάγετε ένα αρχείο στον τρέχοντα φάκελο"; - out.fm_newFolder = "Νέος φάκελος"; - out.fm_newFile = "Νέο pad"; - out.fm_folder = "Φάκελος"; - out.fm_folderName = "Όνομα φακέλου"; - out.fm_numberOfFolders = "# φακέλων"; - out.fm_numberOfFiles = "# αρχείων"; - out.fm_fileName = "Όνομα αρχείου"; - out.fm_title = "Τίτλος"; - out.fm_type = "Τύπος"; - out.fm_lastAccess = "Τελευταία προσπέλαση"; - out.fm_creation = "Δημιουργία"; - out.fm_forbidden = "Απαγορευμένη ενέργεια"; - out.fm_originalPath = "Πρωτότυπη διαδρομή"; - out.fm_openParent = "Προβολή στον φάκελο"; - out.fm_noname = "Έγγραφο χωρίς τίτλο"; - out.fm_emptyTrashDialog = "Θέλετε σίγουρα να αδειάσετε τον κάδο;"; - out.fm_removeSeveralPermanentlyDialog = "Θέλετε σίγουρα να αφαιρέσετε αυτά τα {0} αντικείμενα από το CryptDrive σας μόνιμα;"; - out.fm_removePermanentlyDialog = "Θέλετε σίγουρα να αφαιρέσετε αυτό το αντικείμενο από το CryptDrive σας μόνιμα;"; - out.fm_removeSeveralDialog = "Θέλετε σίγουρα να μετακινήσετε αυτά τα {0} αντικείμενα στον κάδο;"; - out.fm_removeDialog = "Θέλετε σίγουρα να μετακινήσετε το {0} στον κάδο;"; - out.fm_restoreDialog = "Θέλετε σίγουρα να επαναφέρετε το {0} στην προηγούμενη τοποθεσία του;"; - out.fm_unknownFolderError = "Η επιλεγμένη ή πιο πρόσφατη τοποθεσία δεν υπάρχει πλέον. Γίνεται άνοιγμα του τρέχοντα φακέλου..."; - out.fm_contextMenuError = "Αδυναμία ανοίγματος μενού για αυτό το αντικείμενο. Αν το πρόβλημα επιμείνει, δοκιμάστε να επαναφορτώσετε τη σελίδα."; - out.fm_selectError = "Αδυναμία επιλογής του συγκεκριμένου αντικειμένου. Αν το πρόβλημα επιμείνει, δοκιμάστε να επαναφορτώσετε τη σελίδα."; - out.fm_categoryError = "Αδυναμία ανοίγματος της επιλεγμένης κατηγορίας, γίνεται προβολή του γονικού φακέλου."; - out.fm_info_root = "Δημιουργήστε εδώ όσους υποφακέλους θέλετε για να ταξινομήσετε τα αρχεία σας."; - out.fm_info_unsorted = 'Περιέχει όλα τα αρχεία που έχετε επισκεφτεί αλλά δεν έχουν ταξινομηθεί στα "Έγγραφα", ούτε έχουν μετακινηθεί στα "Σκουπίδια".'; // "My Documents" should match with the "out.fm_rootName" key, and "Trash" with "out.fm_trashName" - out.fm_info_template = 'Περιέχει όλα τα pads που έχουν αποθηκευτεί ως πρότυπα και μπορείτε να ξαναχρησιμοποιήσετε όταν δημιουργείτε ένα νέο pad.'; - out.fm_info_recent = "Λίστα των πρόσφατα τροποποιημένων ή ανοιγμένων pads."; - out.updated_0_fm_info_trash = 'Αδειάστε τον κάδο σας για να απελευθερώσετε χώρο στο CryptDrive σας.'; - out.fm_info_trash = out.updated_0_fm_info_trash; - out.fm_info_allFiles = 'Περιέχει όλα τα αρχεία από τα "Έγγραφα", "Αταξινόμητα" και "Σκουπίδια". Δεν μπορείτε να μετακινήσετε ή να αφαιρέσετε αρχεία από εδώ.'; // Same here - out.fm_info_anonymous = 'Δεν έχετε συνδεθεί, οπότε τα pads σας θα διαγραφούν μετά από 3 μήνες (μάθετε περισσότερα). ' + - 'Εγγραφείτε ή Συνδεθείτε για να τα κρατήσετε επ\' αόριστον.'; - out.fm_alert_backupUrl = "Σύνδεσμος ασφαλείας για αυτόν τον αποθηκευτικό χώρο.
    " + - "Συνίσταται ιδιαιτέρως να τον κρατήσετε μυστικό.
    " + - "Μπορείτε να τον χρησιμοποιήσετε για να ανακτήσετε όλα σας τα αρχεία σε περίπτωση που διαγραφεί η μνήμη του περιηγητή σας.
    " + - "Οποιοσδήποτε με αυτόν τον σύνδεσμο μπορεί να επεξεργαστεί ή να αφαιρέσει όλα τα αρχεία σας στον διαχειριστή αρχείων.
    "; - out.fm_alert_anonymous = "Γεια σας! Αυτή τη στιγμή χρησιμοποιείτε το CryptPad ανώνυμα, αυτό είναι ok αλλά τα pads σας ίσως διαγραφούν μετά από ένα διάστημα " + - "αδράνειας. Έχουμε απενεργοποιήσει προηγμένες λειτουργίες του αποθηκευτικού χώρου για τους ανώνυμους χρήστες επειδή θέλουμε να καταστήσουμε ξεκάθαρο πως " + - 'δεν είναι ένα ασφαλές μέρος για να αποθηκεύετε πράγματα. Μπορείτε να διαβάσετε περισσότερα σχετικά ' + - 'με το γιατί το κάνουμε αυτό και γιατί θα έπρεπε να Εγγραφείτε ή να Συνδεθείτε.'; - out.fm_backup_title = 'Σύνδεσμος ασφαλείας'; - out.fm_nameFile = 'Πως θα θέλατε να ονομάσετε αυτό το αρχείο;'; - out.fm_error_cantPin = "Εσωτερικό σφάλμα διακομιστή. Παρακαλούμε επαναφορτώστε τη σελίδα και προσπαθήστε ξανά."; - out.fm_viewListButton = "Προβολή λίστας"; - out.fm_viewGridButton = "Προβολή πλέγματος"; - out.fm_renamedPad = "Έχετε ορίσει ένα προσαρμοσμένο όνομα για αυτό το pad. Ο διαμοιραζόμενος τίτλος του είναι:
    {0}"; - out.fm_prop_tagsList = "Ετικέτες"; - out.fm_burnThisDriveButton = "Διαγραφή όλων των πληροφοριών που έχουν αποθηκευτεί από το CryptPad στον περιηγητή σας"; - out.fm_burnThisDrive = "Είστε σίγουροι πως θέλετε να διαγράψετε όλα όσα έχουν αποθηκευτεί από το CryptPad στον περιηγητή σας;
    " + - "Αυτό θα αφαιρέσει το CryptDrive σας και το ιστορικό του από τον περιηγητή σας, αλλά τα pads σας θα εξακολουθήσουν να υπάρχουν (κρυπτογραφημένα) στον διακομιστή μας."; - // File - Context menu - out.fc_newfolder = "Νέος φάκελος"; - out.fc_rename = "Μετονομασία"; - out.fc_open = "Άνοιγμα"; - out.fc_open_ro = "Άνοιγμα για προβολή μόνο"; - out.fc_delete = "Μετακίνηση στον κάδο"; - out.fc_restore = "Επαναφορά"; - out.fc_remove = "Αφαίρεση από το CryptDrive σας"; - out.fc_empty = "Άδειασμα του κάδου"; - out.fc_prop = "Ιδιότητες"; - out.fc_hashtag = "Ετικέτες"; - out.fc_sizeInKilobytes = "Μέγεθος σε Kilobytes"; - // fileObject.js (logs) - out.fo_moveUnsortedError = "Δεν μπορείτε να μετακινήσετε έναν φάκελο στη λίστα των αταξινόμητων pads"; - out.fo_existingNameError = "Το όνομα χρησμοποιείται ήδη σε αυτή την τοποθεσία. Παρακαλώ επιλέξτε ένα άλλο."; - out.fo_moveFolderToChildError = "Δεν μπορείτε να μετακινήσετε έναν φάκελο μέσα σε κάποιο από τα περιεχόμενα του"; - out.fo_unableToRestore = "Αδυναμία επαναφοράς αυτού του αρχείο στην αρχική τοποθεσία του. Μπορείτε να δοκιμάσετε να το μετακινήσετε σε μια νέα τοποθεσία."; - out.fo_unavailableName = "Ένα αρχείο ή ένας φάκελος με το ίδιο όνομα υπάρχει ήδη στη νέα τοποθεσία. Μετονομάστε το αρχείο και προσπαθήστε ξανά."; - - out.fs_migration = "Το CryptDrive σας αναβαθμίστηκε σε μια νεότερη έκδοση. Ως αποτέλεσμα, η τρέχουσα σελίδα θα πρέπει να επαναφορτωθεί.
    Παρακαλούμε επαναφορτώστε τη σελίδα για να συνεχίσετε να την χρησιμοποιείτε."; - - // login - out.login_login = "Σύνδεση"; - out.login_makeAPad = 'Δημιουργήστε ένα pad ανώνυμα'; - out.login_nologin = "Περιηγηθείτε στα τοπικά pads"; - out.login_register = "Εγγραφή"; - out.logoutButton = "Αποσύνδεση"; - out.settingsButton = "Ρυθμίσεις"; - - out.login_username = "Όνομα χρήστη"; - out.login_password = "Κωδικός"; - out.login_confirm = "Επιβεβαίωση κωδικού"; - out.login_remember = "Απομνημόνευση"; - - out.login_hashing = "Κρυπτογραφούμε τον κωδικό σας, αυτό μπορεί να πάρει λίγη ώρα."; - - out.login_hello = 'Καλησπέρα {0},'; // {0} is the username - out.login_helloNoName = 'Καλησπέρα,'; - out.login_accessDrive = 'Περιηγήθείτε στον αποθηκευτικό σας χώρο'; - out.login_orNoLogin = 'ή'; - - out.login_noSuchUser = 'Μη έγκυρο όνομα χρήστη ή λάθος κωδικός. Προσπαθήστε ξανά, ή εγγραφείτε'; - out.login_invalUser = 'Απαιτείται όνομα χρήστη'; - out.login_invalPass = 'Απαιτείται κωδικός'; - out.login_unhandledError = 'Προέκυψε ένα μη αναμενόμενο σφάλμα :('; - - out.register_importRecent = "Εισαγωγή ιστορικού (Συνίσταται)"; - out.register_acceptTerms = "Αποδέχομαι τους όρους χρήσης της υπηρεσίας"; - out.register_passwordsDontMatch = "Οι κωδικοί δεν ταιριάζουν!"; - out.register_passwordTooShort = "Οι κωδικοί πρέπει να αποτελούνται από τουλάχιστον {0} χαρακτήρες."; - - out.register_mustAcceptTerms = "Πρέπει να αποδεχτείτε τους όρους της υπηρεσίας."; - out.register_mustRememberPass = "Δεν μπορούμε να επαναφέρουμε τον κωδικό σας αν τον ξεχάσετε. Είναι πολύ σημαντικό να τον θυμάστε! Παρακαλούμε πατήστε στο κουτάκι για επιβεβαίωση."; - - out.register_header = "Καλώς ήρθατε στο CryptPad"; - out.register_explanation = [ - "

    Ας δούμε κάνα-δυο πράγματα πρώτα:

    ", - "
      ", - "
    • Ο κωδικός σας είναι το μυστικό κλειδί που κρυπτογραφεί όλα τα pads σας. Αν το χάσετε, δεν υπάρχει τρόπος να επαναφέρουμε τα δεδομένα σας.
    • ", - "
    • Μπορείτε να εισάγετε τα pads που ανοίξατε πρόσφατα στον περιηγητή σας ώστε να τα έχετε στον λογαριασμό σας.
    • ", - "
    • Αν χρησιμοποιείτε έναν κοινόχρηστο υπολογιστή, θα πρέπει να αποσυνδεθείτε όταν τελειώσετε, το να κλείσετε την καρτέλα δεν είναι αρκετό.
    • ", - "
    " - ].join(''); - - out.register_writtenPassword = "Έχω σημειώσει το όνομα χρήστη και τον κωδικό μου, συνέχεια"; - out.register_cancel = "Επιστροφή"; - - out.register_warning = "Zero Knowledge σημαίνει πως δεν μπορούμε να επαναφέρουμε τον λογαριασμό σας αν χάσετε τον κωδικό σας."; - - out.register_alreadyRegistered = "Αυτός ο χρήστης υπάρχει ήδη, μήπως θέλετε να συνδεθείτε;"; - - // Settings - out.settings_cat_account = "Λογαριασμός"; - out.settings_cat_drive = "CryptDrive"; - out.settings_cat_code = "Κώδικας"; - out.settings_title = "Ρυθμίσεις"; - out.settings_save = "Αποθήκευση"; - - out.settings_backupCategory = "Αντίγραφο ασφαλείας"; - out.settings_backupTitle = "Αποθηκεύστε ή επαναφέρετε όλα σας τα δεδομένα"; - out.settings_backup = "Δημιουργία αντιγράφου ασφαλείας"; - out.settings_restore = "Επαναφορά από αντίγραφο ασφαλείας"; - - out.settings_resetNewTitle = "Εκκαθάριση του CryptDrive"; - out.settings_resetButton = "Αφαίρεση"; - out.settings_reset = "Αφαίρεση όλων των αρχείων και φακέλων από το CryptDrive σας"; - out.settings_resetPrompt = "Αυτή η ενέργεια θα αφαιρέσει όλα τα pads από τον αποθηκευτικό σας χώρο.
    "+ - "Θέλετε σίγουρα να συνεχίσετε;
    " + - "Πληκτρολογήστε “I love CryptPad” για επιβεβαίωση."; - out.settings_resetDone = "Ο αποθηκευτικός σας χώρος είναι πλέον άδειος!"; - out.settings_resetError = "Λάθος κείμενο επιβεβαίωσης. Το CryptDrive σας δεν έχει αλλαχθεί."; - - out.settings_resetTipsAction = "Επαναφορά"; - out.settings_resetTips = "Συμβουλές"; - out.settings_resetTipsButton = "Επαναφέρετε όλες τις διαθέσιμες συμβουλές για το CryptDrive"; - out.settings_resetTipsDone = "Όλες οι συμβουλές είναι πάλι ορατές."; - - out.settings_thumbnails = "Μικρογραφίες"; - out.settings_disableThumbnailsAction = "Απενεργοποίηση μικρογραφιών στο CryptDrive σας"; - out.settings_disableThumbnailsDescription = "Οι μικρογραφίες δημιουργούνται αυτόματα και αποθηκεύονται στον περιηγητή σας όταν επισκέπτεστε ένα νέο pad. Μπορείτε να απενεργοποιήσετε αυτό το χαρακτηριστικό εδώ."; - out.settings_resetThumbnailsAction = "Εκκαθάριση"; - out.settings_resetThumbnailsDescription = "Εκκαθάριση όλων των μικρογραφιών που έχουν αποθηκευτεί στον περιηγητή σας."; - out.settings_resetThumbnailsDone = "Όλες οι μικρογραφίες έχουν διαγραφεί."; - - out.settings_importTitle = "Εισάγετε τα πρόσφατα pads αυτού του περιηγητή στο CryptDrive σας"; - out.settings_import = "Εισαγωγή"; - out.settings_importConfirm = "Είσαστε σίγουρος ότι θέλετε να εισάγετε τα πρόσφατα pads από αυτόν τον περιηγητή στον λογαριασμό χρήστη σας στο CryptDrive?"; - out.settings_importDone = "Εισαγωγή ολοκληρώθηκε"; - - out.settings_userFeedbackTitle = "Αναπληροφόρηση"; - out.settings_userFeedbackHint1 = "Το CryptPad αποστέλλει κάποιες πολύ βασικές πληροφορίες σ' εμάς, ώστε να μας ενημερώσει για το πως μπορούμε να βελτιώσουμε την εμπειρία σας."; - out.settings_userFeedbackHint2 = "Το περιεχόμενο των pads σας δεν διαμοιράζεται ποτέ μαζί μας."; - out.settings_userFeedback = "Ενεργοποίηση αναπληροφόρησης χρήστη"; - - out.settings_anonymous = "Δεν είσαστε συνδεδεμένος. Οι τρέχουσες ρυθμίσεις ισχύουν μόνο για τον συγκεκριμένο περιηγητή."; - out.settings_publicSigningKey = "Δημόσιο κλειδί κρυπτογράφησης"; - - out.settings_usage = "Χρήση"; - out.settings_usageTitle = "Δείτε ολόκληρο το μέγεθος των καρφιτσωμένων pads σας σε MB"; - out.settings_pinningNotAvailable = "Τα καρφιτσωμένα pads είναι διαθέσιμα μόνο σε εγγεγραμένους χρήστες."; - out.settings_pinningError = "Κάτι πήγε στραβά"; - out.settings_usageAmount = "Τα καρφιτσωμένα pads σας καταναλώνουν σε χώρο {0}MB"; - - out.settings_logoutEverywhereButton = "Αποσύνδεση"; - out.settings_logoutEverywhereTitle = "Αποσύνδεση παντού"; - out.settings_logoutEverywhere = "Εξαναγκασμός αποσύνδεσης όλων των άλλων διαδικτυακών συνεδριών."; - out.settings_logoutEverywhereConfirm = "Είσαστε σίγουροι; Θα χρειαστεί να επανασυνδεθείτε σε όλες σας τις συσκευές."; - - out.settings_codeIndentation = 'Εσοχές στον επεξεργαστή κώδικα (κενά)'; - out.settings_codeUseTabs = "Εισαγωγή εσoχών με χρήση του πλήκτρου tab, αντί κενών"; - - out.upload_title = "Μεταφόρτωση αρχείου"; - out.upload_rename = "Θέλετε να μετονομάσετε το {0} πριν το μεταφορτώσετε στον διακομιστή;
    " + - "Η κατάληξη του αρχείου ({1}) θα προστεθεί αυτόματα. "+ - "Αυτό το όνομα θα είναι μόνιμο και ορατό σε άλλους χρήστες."; - out.upload_serverError = "Λάθος Διακομιστή: δεν μπορούμε να μεταφορτώσουμε το αρχείο σας αυτή την στιγμή."; - out.upload_uploadPending = "Προσπαθείτε ήδη να μεταφορτώσετε κάτι αυτή την στιγμή. Ακύρωση και μεταφόρτωση του κανούριου σας αρχείου;"; - out.upload_success = "Το αρχείο σας ({0}) έχει μεταφορτωθεί επιτυχώς κι έχει προστεθεί στον αποθηκευτικό σας χώρο."; - out.upload_notEnoughSpace = "Δεν υπάρχει αρκετός αποθηκευτικός χώρος γι' αυτό το αρχείο στο CryptDrive σας."; - out.upload_tooLarge = "Αυτό το αρχείο ξεπερνάει το μέγιστο μέγεθος μεταφόρτωσης."; - out.upload_choose = "Επιλέξτε ένα αρχείο"; - out.upload_pending = "Εκρεμμεί"; - out.upload_cancelled = "Ακυρώθηκε"; - out.upload_name = "Όνομα αρχείου"; - out.upload_size = "Μέγεθος"; - out.upload_progress = "Εξέλιξη"; - out.upload_mustLogin = "Πρέπει να είσαστε συνδεδεμένος για να μεταφορτώσετε ένα αρχείο"; - out.download_button = " Αποκρυπτογράφηση & Κατέβασμα"; - out.download_mt_button = "Λήψη"; - - out.todo_title = "CryptTodo"; - out.todo_newTodoNamePlaceholder = "Περιγράψτε την εργασία σας..."; - out.todo_newTodoNameTitle = "Προσθέστε την εργασία σας στη λίστα εργασιών"; - out.todo_markAsCompleteTitle = "Σημειώστε αυτή την εργασία ως ολοκληρωμένη"; - out.todo_markAsIncompleteTitle = "Σημειώστε αυτή την εργασία ως ανολοκλήρωτη"; - out.todo_removeTaskTitle = "Αφαιρέστε αυτή την εργασία από την λίστα εργασιών σας"; - - // pad - out.pad_showToolbar = "Εμφάνιση γραμμής εργαλείων"; - out.pad_hideToolbar = "Απόκρυψη γραμμής εργαλείων"; - - // general warnings - out.warn_notPinned = "Αυτό το pad δεν είναι αποθηκευμένο σε κάποιο CryptDrive. Θα διαγραφεί σε 3 μήνες. Μάθετε περισσότερα..."; - - // markdown toolbar - out.mdToolbar_button = "Εμφάνιση ή απόκρυψη της γραμμής εργαλείων Markdown"; - out.mdToolbar_defaultText = "Το κείμενο σας εδώ"; - out.mdToolbar_help = "Βοήθεια"; - out.mdToolbar_tutorial = "http://www.markdowntutorial.com/"; - out.mdToolbar_bold = "Έντονα"; - out.mdToolbar_italic = "Πλάγια"; - out.mdToolbar_strikethrough = "Διεγραμμένα"; - out.mdToolbar_heading = "Επικεφαλίδα"; - out.mdToolbar_link = "Σύνδεσμος"; - out.mdToolbar_quote = "Παράθεση"; - out.mdToolbar_nlist = "Λίστα με αριθμούς"; - out.mdToolbar_list = "Λίστα με σημεία"; - out.mdToolbar_check = "Λίστα εργασιών"; - out.mdToolbar_code = "Κώδικας"; - - // index.html - - - //about.html - out.main_p2 = 'Αυτό το εγχείρημα χρησιμοποιεί τον γραφικό επεξεργαστή CKEditor, CodeMirror, και την μηχανή πραγματικού χρόνου ChainPad.'; - out.main_howitworks_p1 = 'Το CryptPad χρησιμοποιεί μια παραλλαγή του αλγόριθμου Operational transformation με τον οποίο καταφέρνει να πετύχει κατανεμημένη συναίνεση χρησιμοποιώντας Blockchain, μια δομή που έγινε δημοφιλής μέσω του Bitcoin. Με αυτό τον τρόπο ο αλγόριθμος αποφεύγει την ανάγκη ύπαρξης ενός κεντρικού διακομιστή για να επιλύσει συγκρούσεις ταυτόχρονης επεξεργασίας και χωρίς την ανάγκη επίλυσης αυτών των συγκρούσεων, ο διακομιστής δεν χρειάζεται να έχει γνώση του περιεχομένου που υπάρχει στο pad.'; - - // contact.html - out.main_about_p2 = 'Αν έχετε απορίες ή σχόλια, επικοινωνήστε μαζί μας!
    Μπορείτε να στείλετε ένα tweet, να δημιουργήσετε ένα θέμα στο GitHub. Ελάτε να πείτε "γεια" στο Matrix κανάλι μας ή στο IRC (#cryptpad on irc.freenode.net), ή στείλτε μας ένα email.'; - out.main_about_p22 = 'Στείλτε μας ένα tweet'; - out.main_about_p23 = 'Δημιουργήστε ένα θέμα στο GitHub'; - out.main_about_p24 = 'Πείτε "γεια" στο Matrix'; - out.main_about_p25 = 'Στείλτε μας ένα email'; - out.main_about_p26 = 'Αν έχετε απορίες ή σχόλια, επικοινωνήστε μαζί μας!'; - - out.main_info = "

    Συνεργαστείτε με ασφάλεια

    Αναπτύξτε τις ιδέες σας μαζί με κοινά αρχεία όσο η τεχνολογία Zero Knowledge εξασφαλίζει την ιδιωτικότητά σας; ακόμη κι από εμάς."; - out.main_catch_phrase = "Το Zero Knowledge σύννεφο"; - - out.main_howitworks = 'Πως Λειτουργεί'; - out.main_zeroKnowledge = 'Πρωτόκολλο Zero Knowledge'; - out.main_zeroKnowledge_p = "Δεν χρειάζεται να μας εμπιστευθείτε όταν σας λέμε πως δεν θα κοιτάξουμε τα pads σας, διότι με την επαναστατική τεχνολογία Zero Knowledge του CryptPad δεν μπορούμε να τα κοιτάξουμε. Μάθετε περισσότερα για το πως προστατεύουμε την Ασφάλεια και Ιδιωτικότητά σας."; - out.main_writeItDown = 'Σημειώστε το'; - - out.main_writeItDown_p = "Τα μεγαλύτερα έργα προέρχονται από τις μικρότερες ιδέες. Καταγράψτε τις στιγμές έμπνευσης και τις απροσδόκητες ιδέες σας διότι ποτέ δεν ξέρετε ποια από αυτές μπορεί να είναι η επόμενη μεγάλη ανακάλυψη."; - out.main_share = 'Μοιραστείτε τον σύνδεσμο, μοιραστείτε το pad'; - out.main_share_p = "Αναπτύξτε τις ιδέες σας μαζί: πραγματοποιήστε αποτελεσματικές συναντήσεις, συνεργαστείτε στις λίστες εργασιών και κάντε γρήγορες παρουσιάσεις με όλους τους φίλους σας και από όλες τις συσκευές σας."; - out.main_organize = 'Οργανωθείτε'; - out.main_organize_p = "Με το CryptPad Drive, μπορείτε να συγκεντρωθείτε στο τι είναι σημαντικό. Οι φάκελοι σας επιτρέπουν να ελέγχετε τα έργα σας και να έχετε μία συνολική εικόνα για το πως προχωράνε τα πράγματα."; - out.tryIt = 'Δοκιμάστε το!'; - out.main_richText = 'Επεξεργαστής Εμπλουτισμένου Κειμένου'; - out.main_richText_p = 'Επεξεργαστείτε pads εμπλουτισμένου κειμένου συνεργατικά με την πραγματικού χρόνου Zero Knowledge εφαρμογή μας CkEditor.'; - out.main_code = 'Επεξεργαστής κώδικα'; - out.main_code_p = 'Επεξεργαστείτε κώδικα συνεργατικά με την πραγματικού χρόνου Zero Knowledge εφαρμογή μας CodeMirror.'; - out.main_slide = 'Επεξεργαστής Slide'; - out.main_slide_p = 'Δημιουργείστε τις παρουσιάσεις σας χρησιμοποιώντας μορφοποίηση Markdown και προβάλλετέ τις στον περιηγητή σας.'; - out.main_poll = 'Δημοσκοπήσεις'; - out.main_poll_p = 'Προγραμματίστε την συνάντησή σας ή την δραστηριότητά σας, ή ψηφίστε την καλύτερη λύση σχετικά με το πρόβλημά σας.'; - out.main_drive = 'CryptDrive'; - - out.main_richTextPad = 'Pad εμπλουτισμένου κειμένου'; - out.main_codePad = 'Pad κώδικα'; - out.main_slidePad = 'Markdown παρουσίαση'; - out.main_pollPad = 'Δημοσκόπηση ή Χρονοδιάγραμμα'; - out.main_whiteboardPad = 'Πίνακας σχεδιασμού'; - out.main_localPads = 'Τοπικά pads'; - out.main_yourCryptDrive = 'Το CryptDrive σας'; - out.main_footerText = "Με το CryptPad, μπορείτε να δημιουργήσετε γρήγορα συνεργατικά έγγραφα για κοινόχρηστες σημειώσεις και καταγραφή ιδεών."; - - out.footer_applications = "Εφαρμογές"; - out.footer_contact = "Επικοινωνία"; - out.footer_aboutUs = "Σχετικά με εμάς"; - - out.about = "Σχετικά"; - out.privacy = "Ιδιωτικότητα"; - out.contact = "Επικοινωνία"; - out.terms = "Όροι χρήσης"; - out.blog = "Ιστολόγιο"; - - out.topbar_whatIsCryptpad = "Τι είναι το CryptPad"; - - // what-is-cryptpad.html - - out.whatis_title = 'Τι είναι το CryptPad'; - out.whatis_collaboration = 'Γρήγορη, εύκολη συνεργασία'; - out.whatis_collaboration_p1 = 'Με το CryptPad, μπορείτε να δημιουργείτε όλοι μαζί γρήγορα συνεργατικά έγγραφα για τις σημειώσεις σας και τις ιδέες που καταγράφετε. Όταν εγγραφείτε και συνδεθείτε, σας δίνεται άμεσα η δυνατότητα \'ανεβάσματος\' κι έναν \'αποθηκευτικό χώρο\' CryptDrive όπου μπορείτε να οργανώσετε όλα σας τα pads. Ως εγγεγραμένος χρήστης παίρνετε 50MB δωρεάν.'; - out.whatis_collaboration_p2 = 'Μπορείτε να μοιραστείτε την πρόσβαση σε ένα έγγραφο του CryptPad απλά δίνοντας τον σύνδεσμο σε κάποιον άλλο. Μπορείτε επίσης να μοιραστείτε ένα σύνδεσμο ο οποίος παρέχει πρόσβαση μόνο για ανάγνωση σε ένα pad, επιτρέποντάς σας να κοινοποιήσετε την συλλογική σας δουλειά ενώ ταυτόχρονα έχετε ακόμα τη δυνατότητα να το επεξεργαστείτε.'; - out.whatis_collaboration_p3 = 'Μπορείτε να δημιουργήσετε απλά εμπλουτισμένα κείμενα με το CKEditor όπως επίσης κείμενα με γλώσσα προγραμματισμού Markdown τα οποία τροποποιούνται σε πραγματικό χρόνο καθώς πληκτρολογείτε. Μπορείτε επίσης να χρησιμοποιήσετε την εφαρμογή δημοσκόπησης για να προγραμματίσετε δραστηριότητες με πολλαπλούς συμμετέχοντες.'; - out.whatis_zeroknowledge = 'Zero Knowledge'; - out.whatis_zeroknowledge_p1 = "Δεν θέλουμε να ξέρουμε τι πληκτρολογείτε και με τον σύγχρονο τρόπο κρυπτογράφησης μπορείτε να είσαστε σίγουροι ότι δεν μπορούμε να ξέρουμε. Το CryptPad χρησιμοποιεί 100% κρυπτογράφηση client side για να προστατεύσει το περιεχόμενο που πληκτρολογείτε από εμάς, τους ανθρώπους που φιλοξενούν τον διακομιστή."; - out.whatis_zeroknowledge_p2 = 'Όταν κάνετε εγγραφή και συνδέεστε, το όνομα χρήστη σας κι ο κωδικός σας μετατρέπονται σε ένα κρυπτογραφημένο κλειδί χρησιμοποιώντας το scrypt key derivation function. Το συγκεκριμένο κλειδί, το όνομα χρήστη κι ο κωδικός χρήστη δεν στέλνονται καν στον διακομιστή. Αντιθέτως χρησιμοποιούνται από το client side για να αποκρυπτογραφήσουν το περιεχόμενο του CryptDrive σας, το οποίο περιέχει όλα τα κλειδιά για όλα τα pads στα οποία μπορείτε να έχετε πρόσβαση.'; - out.whatis_zeroknowledge_p3 = 'Όταν μοιράζεστε έναν σύνδεσμο προς ένα έγγραφο, μοιράζεστε το κρυπτογραφημένο κλειδί για το συγκεκριμένο έγγραφο αλλά εφόσον το κλειδί είναι στο fragment identifier, δεν στέλνεται ποτέ απευθείας στον διακομιστή. Επισκεφθείτε το privacy blog post για να μάθετε περισσότερα σχετικά με το σε ποια μεταδεδομένα έχουμε πρόσβαση και σε ποια όχι.'; - out.whatis_drive = 'Οργάνωση με το CryptDrive'; - out.whatis_drive_p1 = 'Κάθε φορά που επισκέπτεσθε ένα pad στο CryptPad, το pad προστίθεται αυτόματα στο CryptDrive στον κυρίως φάκελο. Αργότερα μπορείτε να οργανώσετε αυτά τα pad σε φακέλους ή μπορείτε να τα μετακινήσετε στον κάδο ανακύκλωσης. Το CryptDrive σας επιτρέπει να περιηγηθείτε ανάμεσα στα pads σας και να τα οργανώνετε όποτε κι όπως θέλετε.'; - out.whatis_drive_p2 = 'Με το κλασικό drag-and-drop, μπορείτε να μεταφέρετε pads μέσα στον αποθηκευτικό σας χώρο και ο σύνδεσμος αυτών των pads θα παραμείνει ο ίδιος ώστε οι συνεργάτες σας να μην σταματήσουν ποτέ να έχουν πρόσβαση.'; - out.whatis_drive_p3 = 'Μπορείτε επίσης να ανεβάσετε αρχεία στο CryptDrive σας και να τα μοιραστείτε με συνεργάτες. Τα ανεβασμένα αρχεία μπορούν να οργανωθούν ακριβώς όπως τα συνεργατικά pads.'; - out.whatis_business = 'Το CryptPad για επιχειρήσεις'; - out.whatis_business_p1 = 'Το πρωτόκολλο κρυπτογράφησης Zero Knowledge του CryptPad είναι ιδανικό για να πολλαπλασιαστεί η αποτελεσματικότητα των ήδη υπάρχοντων πρωτοκόλλων ασφαλείας προστατεύοντας τα εταιρικά στοιχεία πρόσβασης με ισχυρή κρυπτογράφηση. Επειδή τα ευαίσθητα δεδομένα μπορούν να αποκρυπτογραφηθούν μόνο με την χρήση των στοιχείων των υπαλλήλων, το CryptPad εξαλείφει τον παράγοντα hacker ο οποίος ενυπάρχει σε παραδοσιακούς εταιρικούς διακομιστές. Διαβάστε το CryptPad Whitepaper για να μάθετε περισσότερα σχετικά με το πως μπορεί να βοηθήσει την επιχείρησή σας.'; - out.whatis_business_p2 = 'To CryptPad μπορεί να εγκατασταθεί τοπικά και οι προγραμματιστές του στην XWiki SAS είναι σε θέση να προσφέρουν εμπορική υποστήριξη, τροποποιήσεις και περαιτέρω ανάπτυξη. Επικοινωνήστε στο sales@cryptpad.fr για περισσότερες πληροφορίες.'; - - // privacy.html - - out.policy_title = 'Πολιτική απορρήτου του CryptPad'; - out.policy_whatweknow = 'Τι γνωρίζουμε για εσάς'; - out.policy_whatweknow_p1 = 'Ως εφαρμογή η οποία φιλοξενείται στο διαδίκτυο, το CryptPad έχει πρόσβαση στα μεταδεδομένα που είναι εκτεθειμένα από το πρωτόκολλο HTTP. Αυτό συμπεριλαμβάνει την διεύθυνση IP σας και ποικίλες HTTP κεφαλίδες που μπορούν να χρησιμοποιηθούν για να ταυτοποιήσουν τον συγκεκριμένο περιηγητή. Μπορείτε να δείτε τι πληροφορίες μοιράζεται ο περιηγητής σας με το να επισκεφθείτε WhatIsMyBrowser.com.'; - out.policy_whatweknow_p2 = 'Χρησιμοποιούμε το Kibana, μια πλατφόρμα ανάλυσης ανοιχτού κώδικα, για να μάθουμε περισσότερα για τους χρήστες μας. Το Κibana μας ενημερώνει για το πως βρήκατε το CryptPad, μέσω απευθείας σύνδεσης, μέσω μηχανής αναζήτησης, ή μέσω αναφοράς από άλλη διαδυκτιακή υπηρεσία όπως το Reddit ή το Twitter.'; - out.policy_howweuse = 'Πώς χρησιμοποιούμε αυτά που μαθαίνουμε'; - out.policy_howweuse_p1 = 'Χρησιμοποιούμε αυτές τις πληροφορίες για να παίρνουμε καλύτερες αποφάσεις σχετικά με την προώθηση του CryptPad, εξετάζοντας ποιες από τις προηγούμενες προσπάθειές μας υπήρξαν επιτυχείς. Οι πληροφορίες σχετικά με την τοποθεσία σας μας βοηθούν στο να σκεφτούμε αν θα έπρεπε να παρέχουμε καλύτερη υποστήριξη για γλώσσες εκτός των Αγγλικών.'; - out.policy_howweuse_p2 = "Οι πληροφορίες σχετικά με τον περιηγητή σας (είτε είναι επιτραπέζιου είτε φορητού λειτουργικού συστήματος) μας βοηθάνε να παίρνουμε αποφάσεις στο θέμα προτεραιοτήτων βελτίωσης χαρακτηριστικών. Η ομάδα προγραμματισμού μας είναι μικρή και προσπαθούμε να κάνουμε επιλογές οι οποίες θα βελτιώσουν την εμπειρία όσων το δυνατό περισσότερων χρηστών."; - out.policy_whatwetell = 'Τι λέμε σε άλλους για εσάς'; - out.policy_whatwetell_p1 = 'Δεν παρέχουμε σε τρίτους τις πληροφορίες που συλλέγουμε ή τις πληροφορίες που μας δίνετε εκτός κι αν είμαστε υποχρεωμένοι νομικά.'; - out.policy_links = 'Σύνδεσμοι σε άλλες σελίδες'; - out.policy_links_p1 = 'Αυτή η ιστοσελίδα περιέχει συνδέσμους προς άλλες σελίδες, συμπεριλαμβανομένων αυτών που δημιουργήθηκαν από άλλους οργανισμούς. Δεν είμαστε υπεύθυνοι για την πολιτική απορρήτου ή το περιεχόμενο μιας εξωτερικής σελίδας. Ως γενικό κανόνα έχουμε πως οι σύνδεσμοι σε διαφορετικές σελίδες ανοίγουν σε καινούριο παράθυρο για να είναι ξεκάθαρο ότι φεύγετε από το CryptPad.fr.'; - out.policy_ads_p1 = 'Δεν προβάλουμε διαφημίσεις εντός της υπηρεσίας, όμως μπορεί να παρέχουμε συνδέσμους στους ανθρώπους που ενισχύουν οικονομικά την έρευνά μας.'; - out.policy_choices = 'Οι επιλογές που έχετε'; - out.policy_choices_open = 'Ο κώδικάς μας διατίθεται ελεύθερα, οπότε έχετε πάντα την επιλογή να φιλοξενήσετε το Cryptpad σε δικό σας διακομιστή.'; - out.policy_choices_vpn = 'Εάν θέλετε να χρησιμοποιήσετε τη δική μας εκδοχή του Cryptpad, αλλά δεν θέλετε να φαίνεται η IP διεύθυνσή σας, μπορείτε να προστατέψετε την IP σας χρησιμοποιώντας το Tor browser bundle, ή ένα VPN.'; - out.policy_choices_ads = 'Εάν θα θέλατε απλά να εμποδίσετε την πλατφόρμα ανάλυσής μας, μπορείτε να χρησιμοποιήσετε εργαλεία απόκρυψης διαφημίσεων όπως το Privacy Badger.'; - - // terms.html - - out.tos_title = " Όροι και Προϋποθέσεις του CryptPad"; - out.tos_legal = "Παρακαλούμε μην κάνετε κακή χρήση ή/και κατάχρηση της υπηρεσίας ή οτιδήποτε παράνομο."; - out.tos_availability = "Ελπίζουμε να βρείτε χρήσιμη αυτή την υπηρεσία, αλλά η προσβασιμότητα κι η απόδοση δεν μπορούν να εγγυηθούν. Παρακαλούμε κάνετε εξαγωγή των δεδομένων σας συχνά."; - out.tos_e2ee = "Τα περιεχόμενα του CryptPad μπορούν να διαβαστούν ή να αλλαχθούν από οποιονδήποτε μπορεί να μαντέψει ή να αποκτήσει την ηλεκτρονική διεύθυνση του pad. Προτείνουμε να χρησιμοποιείτε τεχνολογία κρυπτογραφημένων μηνυμάτων από άκρη σε άκρη (e2ee) για να μοιράζεστε συνδέσμους και να μην αναλάβετε καμία ευθύνη σε περίπτωση που διαρρέυσει κάποιος τέτοιος σύνδεσμος."; - out.tos_logs = "Τα μεταδεδομένα που παρέχονται από τον περιηγητή σας στον διακομιστή μπορεί να καταγράφονται με σκοπό τη συντήρηση της υπηρεσίας."; - out.tos_3rdparties = "Δεν παρέχουμε προσωπικά δεδομένα σε τρίτους παρά μόνο εάν ζητηθεί από το νόμο."; - - // 404 page - out.four04_pageNotFound = "Η σελίδα που ψάχνετε, δεν βρέθηκε!"; - - // BottomBar.html - - //out.bottom_france = 'Δημιουργήθηκε με love στην Γαλλία'; - //out.bottom_support = 'Ένα XWiki SAS Labs Project με την υποστήριξη του OpenPaaS-ng'; - - // Header.html - - out.header_france = 'Με love στην Γαλλία από την XWiki SAS'; - - out.header_support = ' OpenPaaS-ng'; - out.updated_0_header_logoTitle = 'Μετάβαση στο CryptDrive σας'; - out.header_logoTitle = out.updated_0_header_logoTitle; - out.header_homeTitle = 'Μετάβαση στην αρχική σελίδα του CryptPad'; - - // Initial states - - out.initialState = [ - '

    ', - 'Αυτό είναι CryptPad, ο συνεργατικός επεξεργαστής πραγματικού χρόνου Zero Knowledge. Τα πάντα αποθηκεύονται καθώς πληκτρολογείτε.', - '
    ', - 'Μοιραστείτε τον σύνδεσμο σε αυτό το pad για να το επεξεργαστείτε με φίλους ή χρησιμοποιήστε το κουμπί για να μοιραστείτε ένα κείμενο με δικαιώματα read-only link το οποίο επιτρέπει να το αναγνώσει κάποιος αλλά όχι να το επεξεργαστεί.', - '

    ', - ].join(''); - - out.codeInitialState = [ - '# Ο συνεργατικός επεξεργαστής Zero Knowledge του CryptPad\n', - '\n', - '* Ό,τι πληκτρολογείτε εδώ είναι κρυπτογραφημένο έτσι ώστε μόνο οι άνθρωποι που έχουν τον σύνδεσμο να μπορούν να έχουν πρόσβαση.\n', - '* Μπορείτε να επιλέξετε την γλώσσα προγραμματισμού για να υπογραμμίζετε και το χρώμα του θέματος UI πάνω δεξιά.' - ].join(''); - - out.slideInitialState = [ - '# CryptSlide\n', - '1. Γράψτε τα περιεχόμενα των slides σας χρησιμοποιώντας σύνταξη markdown\n', - ' - Μάθετε περισσότερα για την σύνταξη markdown [εδώ](http://www.markdowntutorial.com/)\n', - '2. Διαχωρίστε τα slides σας με ---\n', - '3. Πατήστε το κουμπάκι "Play" για να δείτε το αποτέλεσμα', - ' - Τα slides σας ενημερώνονται σε πραγματικό χρόνο' - ].join(''); - - // Readme - - out.driveReadmeTitle = "Τι είναι το CryptPad;"; - out.readme_welcome = "Καλωσήρθατε στο CryptPad!"; - out.readme_p1 = "Καλωσήρθατε στο CryptPad, όπου μπορείτε να έχετε τις σημειώσεις σας μόνοι σας ή με φίλους."; - out.readme_p2 = "Αυτό το pad έχει έναν γρήγορο οδηγό χρήσης του πως να χρησιμοποιήσετε το CryptPad για να κρατάτε σημειώσεις, να τις έχετε οργανωμένες και να δουλέψετε πάνω τους συνεργατικά."; - out.readme_cat1 = "Μάθετε το CryptDrive σας"; - out.readme_cat1_l1 = "Δημιούργηστε ένα pad: Στο CryptDrive σας, κάντε \"κλικ\" στο {0} και έπειτα στο {1} και μπορείτε να δημιουργήσετε ένα pad."; // 0: New, 1: Rich Text - out.readme_cat1_l2 = "Ανοίξτε pads από το CryptDrive σας: κάντε διπλό \"κλικ\" σε ένα εικονίδιο pad για να το ανοίξετε."; - out.readme_cat1_l3 = "Οργάνωστε τα pads σας: Όταν είσαστε συνδεδεμένοι, κάθε pad στο οποίο έχετε πρόσβαση θα εμφανίζεται ως {0} στο τμήμα του δίσκου σας."; // 0: Unsorted files - out.readme_cat1_l3_l1 = "Μπορείτε να κάνετε \"κλικ\" και να σύρετε αρχεία μέσα σε φακέλους στον τομέα {0} του δίσκου σας και να δημιουργήσετε καινούρια αρχεία."; // 0: Documents - out.readme_cat1_l3_l2 = "Θυμηθείτε να δοκιμάζετε το δεξί \"κλικ\" στα εικονίδια διότι συχνά υπάρχουν επιπρόσθετα μενού."; - out.readme_cat1_l4 = "Πετάξτε τα παλιά pads στα σκουπίδια: Μπορείτε να κάνετε \"κλικ\" και να σύρετε τα pads μέσα στα {0} με τον ίδιο τρόπο που τα σύρετε μέσα στους φακέλους."; // 0: Trash - out.readme_cat2 = "Δημιουργείστε pads σαν επαγγελματίας"; - out.edit = "επεξεργασία"; - out.view = "προβολή"; - out.readme_cat2_l1 = "Το κουμπί {0} στο pad σας επιτρέπει να δίνετε πρόσβαση στους συνεργάτες σας είτε να κάνουν {1} είτε να κάνουν {2} το pad."; // 0: Share, 1: edit, 2: view - out.readme_cat2_l2 = "Αλλάξτε τον τίτλο του pad κάνοντας \"κλικ\" στο μολύβι"; - out.readme_cat3 = "Ανακαλύψτε CryptPad εφαρμογές"; - out.readme_cat3_l1 = "Με το CryptPad code editor, μπορείτε να συνεργαστείτε σε κώδικα όπως οι γλώσσες προγραμματισμού Javascript και markdown ή HTML και Markdown"; - out.readme_cat3_l2 = "Με το CryptPad slide editor, μπορείτε να κάνετε γρήγορες παρουσιάσεις χρησιμοποιώντας γλώσσα Markdown"; - out.readme_cat3_l3 = "Με το CryptPoll μπορείτε να ψηφίζετε γρήγορα, ειδικά για να ορίζετε συναντήσεις σε ημερομηνίες που ταιριάζουν με το πρόγραμμα όλων"; - - // Tips - out.tips = {}; - out.tips.shortcuts = "`ctrl+b`, `ctrl+i` και `ctrl+u` είναι γρήγορες συντομεύσεις για έντονα, πλάγια και υπογραμμισμένα γράμματα."; - out.tips.indent = "Σε αριθμημένες λίστες όπως και λίστες με τελείες, μπορείτε να χρησιμοποιήσετε tab ή shift+tab για να αυξήσετε ή να μειώσετε τις εσοχές με γρήγορο τρόπο."; - out.tips.store = "Κάθε φορά που επισκέπτεστε ένα pad, εάν είσαστε συνδεδεμένοι, θα σώζεται αυτόματα στο CryptDrive σας."; - out.tips.marker = "Μπορείτε να υπογραμμίσετε κείμενο σε ένα pad χρησιμοποιώντας τον \"μαρκαδόρο\" από το μενού μορφoποίησης."; - out.tips.driveUpload = "Οι εγγεγραμένοι χρήστες μπορούν να ανεβάσουν κρυπτογραφημένα αρχεία σύροντάς τα και πετώντας τα στο CryptDrive τους."; - out.tips.filenames = "Μπορείτε να μετονομάσετε αρχεία στο CryptDrive σας. Το όνομα που θα δώσετε είναι μόνο για εσάς."; - out.tips.drive = "Οι συνδεδεμένοι χρήστες μπορούν να οργανώσουν τα αρχεία τους στο CryptDrive τους, τα οποία είναι προσβάσιμα από το εικονίδιο CryptPad που είναι πάνω αριστερά σε όλα τα pads."; - out.tips.profile = "Οι εγγεγραμένοι χρήστες μπορούν να δημιουργήσουν ένα προφίλ από το μενού χρήστη πάνω δεξιά."; - out.tips.avatars = "Μπορείτε να ανεβάσετε ένα άβαταρ στο προφίλ σας. Θα το βλέπουν οι άλλοι όταν συνεργάζεστε σε ένα pad."; - out.tips.tags = "Βάλτε ετικέτες στα pads σας και ψάξτε με # στο CryptDrive σας για να τα βρείτε"; - - out.feedback_about = "Εάν το διαβάζετε αυτό, πιθανότατα ήσασταν περίεργοι για ποιο λόγο το CryptPad ζητά ιστοσελίδες όταν κάνετε συγκεκριμένες ενέργειες"; - out.feedback_privacy = "Ενδιαφερόμαστε για την ιδιωτικότητά σας και ταυτόχρονα θέλουμε το CryptPad να είναι πολύ εύκολο στην χρήση. Χρησιμοποιούμε αυτό το αρχείο για να καταλάβουμε ποια χαρακτηριστικά του περιβάλλοντος διάδρασης ενδιαφέρουν τους χρήστες μας, με το να το ζητήσουμε σε συνδυασμό με μια παράμετρο η οποία μας δείχνει συγκεκριμένα ποια ενέργεια έγινε."; - out.feedback_optout = "Εάν θα θέλατε να απέχετε, επισκεφθείτε τη σελίδα ρυθμίσεων του λογαριασμού σας, όπου θα βρείτε ένα κουτί στο οποίο μπορείτε να ενεργοποιήσετε ή να απενεργοποιήσετε την αναπληροφόρηση"; - - return out; -}); diff --git a/www/common/translations/old/messages.es.js b/www/common/translations/old/messages.es.js deleted file mode 100644 index 74f983e20..000000000 --- a/www/common/translations/old/messages.es.js +++ /dev/null @@ -1,583 +0,0 @@ -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - - out._languageName = 'Español'; - - out.main_title = "Cryptpad: Zero Knowledge, Editor Colaborativo en Tiempo Real"; - out.main_slogan = "La unidad es la fuerza - la colaboración es la clave"; - - out.type = {}; - out.type.pad = 'Pad'; - out.type.code = 'Código'; - out.type.poll = 'Encuesta'; - out.type.slide = 'Presentación'; - out.type.whiteboard = 'Pizarra'; - out.type.contacts = 'Contactos'; - - out.disconnected = "Desconectado"; - out.synchronizing = "Sincronización"; - out.reconnecting = "Reconectando..."; - out.lag = "Retraso"; - out.readonly = 'Sólo lectura'; - out.anonymous = 'Anónimo'; - out.yourself = "Tú mismo"; - out.anonymousUsers = "usuarios anónimos"; - out.anonymousUser = "usuario anónimo"; - out.users = "Usuarios"; - out.and = "y"; - out.viewer = "espectador"; - out.viewers = "espectadores"; - out.editor = "editor"; - out.editors = "editores"; - - out.greenLight = "Todo funciona bien"; - out.orangeLight = "La conexión es lenta y podría afectar la experiencia"; - out.redLight = "Has sido desconectado de la sesión"; - - out.importButtonTitle = 'Importar un documento de tus archivos locales'; - - out.exportButtonTitle = 'Exportar este documento a un archivo local'; - out.exportPrompt = '¿Cómo te gustaría llamar a este archivo?'; - - out.changeNamePrompt = 'Cambiar tu nombre (dejar vacío para ser anónimo): '; - - out.clickToEdit = "Haz clic para cambiar"; - - out.forgetButtonTitle = 'Eliminar este documento de la lista en la pagina de inicio'; - out.forgetPrompt = 'Pulsar OK eliminará este documento del almacenamiento local (localStorage), ¿estás seguro?'; - - out.shareButton = 'Compartir'; - out.shareSuccess = 'URL copiada al portapapeles'; - - out.presentButtonTitle = "Entrar en el modo presentación"; - - out.backgroundButtonTitle = 'Cambiar el color de fondo en el modo presentación'; - out.colorButtonTitle = 'Cambiar el color de texto en el modo presentación'; - - out.editShare = "URL de edición compartida"; - out.editShareTitle = "Copiar la URL de edición al portapapeles"; - out.viewShare = "Compartir URL de sólo lectura"; - out.viewShareTitle = "Copiar la URL de sólo lectura al portapapeles"; - out.viewOpen = "Ver en pestaña nueva"; - out.viewOpenTitle = "Abrir el documento en sólo lectura en una pestaña nueva"; - - out.notifyJoined = "{0} se ha unido a la sesión de colaboración"; - out.notifyRenamed = "{0} ahora se conoce como {1}"; - out.notifyLeft = "{0} ha dejado la sesión de colaboración"; - - out.tryIt = '¡Pruébalo!'; - - out.okButton = 'OK (Enter)'; - out.cancelButton = 'Cancelar (Esc)'; - - // Polls - - out.poll_title = "Selector de fecha Zero Knowledge"; - out.poll_subtitle = "Agenda en tiempo real Zero Knowledge"; - - out.poll_p_save = "Tus configuraciones se actualizan instantáneamente, no es necesario guardar cambios."; - out.poll_p_encryption = "Todos los datos entrados son cifrados, sólo las personas que poseen el enlace tienen acceso. Incluso el servidor no puede ver el contenido."; - - out.wizardLog = "Presiona el botón en la parte superior izquierda para volver a la encuesta"; - out.wizardTitle = "Utiliza el asistente para crear tu encuesta"; - out.wizardConfirm = "¿Estás realmente seguro de agregar estas opciones a tu encuesta?"; - - out.poll_closeWizardButton = "Cerrar el asistente"; - out.poll_closeWizardButtonTitle = "Cerrar el asistente"; - out.poll_wizardComputeButton = "Generar opciones"; - out.poll_wizardClearButton = "Limpiar tabla"; - out.poll_wizardDescription = "Crear opciones automáticamente ingresando cualquier cantidad de fechas y horas"; - out.poll_wizardAddDateButton = "+ Fechas"; - out.poll_wizardAddTimeButton = "+ Horas"; - - out.poll_optionPlaceholder = "Opción"; - out.poll_userPlaceholder = "Tu nombre"; - out.poll_removeOption = "¿Estás seguro de que quieres eliminar esta opción?"; - out.poll_removeUser = "¿Estás seguro de que quieres eliminar este usuario?"; - - out.poll_titleHint = "Título"; - out.poll_descriptionHint = "Descripción"; - - // index.html - - out.main_p2 = 'Este proyecto utiliza el editor de texto visual CKEditor, CodeMirror, y el motor en tiempo real ChainPad.'; - out.main_howitworks = '¿Cómo funciona?'; - out.main_howitworks_p1 = "CryptPad utiliza una variante del algoritmo de transformación operacional (página en inglés) que es capaz de encontrar un consenso distribuido usando un Blockchain Nakamoto (página en inglés), popularizado por Bitcoin. De esta manera el algoritmo puede evitar la necesidad de un servidor central para resolver conflictos de edición de la transformación operacional y sin necesidad de resolver conflictos, el servidor puede mantenerse inconsciente del contenido que se está editando en el pad."; - out.main_about_p2 = 'Si tienes preguntas o comentarios, puedes enviarnos un tweet, abrir un issue en GitHub. saludarnos en nuestro canal Matrix o en IRC (#cryptpad on irc.freenode.net), o envianos un email.'; - - out.button_newpad = 'Crear nuevo pad de texto enriquecido'; - out.button_newcode = 'Crear nuevo pad de código'; - out.button_newpoll = 'Crear nueva encuesta'; - out.button_newslide = 'Crear nueva presentación'; - - // privacy.html - - out.policy_title = 'Política de privacidad Cryptpad'; - out.policy_whatweknow = 'Qué sabemos sobre tí'; - out.policy_whatweknow_p1 = 'Como cualquier aplicación que está en la red, Cryptpad tiene acceso a los metadatos expuestos por el protocolo HTTP. Esto incluye tu dirección IP, y otros headers HTTP que pueden ser utilizados para identificar a tu navegador propio. Puedes ver la información que comparte tu navegador visitando WhatIsMyBrowser.com (página en inglés).'; - out.policy_whatweknow_p2 = 'Nosotros usamos Piwik, una plataforma de analítica de datos abierta, para conocer mejor a nuestros usuarios. Piwik nos dice como encontraste Cryptpad, en entrada manual, por un motor de búsqueda, or por referal de otra página como Reddit o Twitter. También aprendemos cuándo visitas, qué páginas ves en nuestra web, y cuánto tiempo te quedas en cada una.'; - out.policy_howweuse = 'Cómo usamos lo que aprendemos'; - out.policy_howweuse_p1 = 'Usamos esta información para tomar mejores decisiones para promocionar Cryptpad, para evaluar cuáles de nuestros esfuerzos han sido exitosos. La información sobre tu ubicación nos permite saber si deberíamos considerar mejor soporte para idiomas diferentes al inglés.'; - out.policy_howweuse_p2 = "La información sobre tu navegador (en escritorio o móvil) nos ayuda a saber qué características que debemos mejorar. Nuestro equipo de desarrollo es pequeño, e intentamos tomar decisiones que beneficien a la experiencia de la mayoría de nuestros usuarios."; - out.policy_whatwetell = 'Lo que decimos a otros sobre tí'; - out.policy_whatwetell_p1 = 'No suministramos la información que recolectamos a terceros a menos de estar legalmente obligados a hacerlo.'; - out.policy_links = 'Enlaces a otras páginas'; - out.policy_links_p1 = 'Esta web contiene enlaces a otros sitios, incluyendo algunos producidos por otras organizaciones. No somos responsables del tratamiento de la privacidad de los datos ni el contenido de páginas externas. Como regla general, los enlaces externos se abren en una nueva pestaña del navegador, para clarificar que estás abandonando a Cryptpad.fr.'; - out.policy_ads = 'Anuncios'; - out.policy_ads_p1 = 'Nosotros no mostramos anuncios, pero podemos poner enlaces a las organizaciones que financian nuestro trabajo de investigación.'; - out.policy_choices = 'Lo que puedes hacer'; - out.policy_choices_open = 'Nuestro código fuente es abierto para que siempre tengas la opción de desplegar tu propia instancia de Cryptpad.'; - out.policy_choices_vpn = 'Si deseas utilizar nuestra instancia, pero no deseas exponer tu dirección IP, puedes protegerla utilizando el navegador Tor, o un VPN.'; - out.policy_choices_ads = 'Si deseas no ser seguido por nuestra plataforma, puedes utilizar herramientas como Privacy Badger.'; - - // terms.html - - out.tos_title = "Condiciones de servicio Cryptpad"; - out.tos_legal = "Por favor, no seas malicioso, abusivo o hagas algo ilegal."; - out.tos_availability = "Esperamos que este servicio te parezca útil, pero nuestra disponibilidad o rendimiento no pueden ser garantizados. Por favor, exporta tus datos regularmente."; - out.tos_e2ee = "Los documentos Cryptpad pueden ser leídos o modificados por cualquiera que pueda adivinar o que pueda tener el enlace. Recomendamos que utilices mensajes cifrados de punto a punto (e2ee) para compartir URLs, no asumimos ninguna responsabilidad en el evento de alguna fuga."; - out.tos_logs = "Los metadatos entregados por el navegador al servidor pueden ser almacenados para la mantenencia del servicio."; - out.tos_3rdparties = "No proveemos datos individualizados a terceros a menos de ser obligados por la ley."; - - // BottomBar.html - - out.bottom_france = 'Hecho con amor en Francia'; - out.bottom_support = 'Un XWiki SASProyecto Labs con el soporte de OpenPaaS-ng'; - - // Header.html - - out.header_france = 'Con amor de Francia por XWiki SAS'; - out.header_support = ' OpenPaaS-ng'; - out.header_logoTitle = 'Ir a la página principal'; - - out.websocketError = "Error al conectarse al servidor WebSocket"; - out.typeError = "Este documento no es compatible con la aplicación seleccionada"; - out.onLogout = "Tu sesión está cerrada, {0}haz clic aquí{1} para iniciar sesión
    o pulsa Escape para acceder al documento en modo sólo lectura."; - out.loading = "Cargando..."; - out.error = "Error"; - out.language = "Idioma"; - out.user_rename = "Cambiar nombre"; - out.user_displayName = "Nombre visible"; - out.user_accountName = "Nombre de cuenta"; - out.newButton = "Nuevo"; - out.newButtonTitle = "Nuevo documento"; - out.cancel = "Cancelar"; - out.poll_publish_button = "Publicar"; - out.poll_admin_button = "Administrar"; - out.poll_create_user = "Añadir usuario"; - out.poll_create_option = "Añadir opción"; - out.poll_commit = "Validar"; - out.fm_rootName = "Documentos"; - out.fm_trashName = "Papelera"; - out.fm_unsortedName = "Sin organizar"; - out.fm_filesDataName = "Todos los archivos"; - out.fm_templateName = "Plantilla"; - out.fm_newButton = "Nuevo"; - out.fm_newFolder = "Nueva carpeta"; - out.fm_folder = "Carpeta"; - out.fm_folderName = "Nombre de carpeta"; - out.fm_numberOfFolders = "# de carpetas"; - out.fm_numberOfFiles = "# de archivos"; - out.fm_fileName = "Nombre"; - out.fm_title = "Título"; - out.fm_lastAccess = "Último acceso"; - out.fm_creation = "Creación"; - out.fm_forbidden = "Acción prohibida"; - out.fm_originalPath = "Enlace original"; - out.fm_noname = "Documento sin título"; - out.fm_emptyTrashDialog = "¿Seguro que quieres vaciar la papelera?"; - out.fm_removeSeveralPermanentlyDialog = "¿Seguro que quieres eliminar estos {0} elementos de la papelera para siempre?"; - out.fm_removePermanentlyDialog = "¿Seguro que quieres eliminar este elemento para siempre?"; - out.fm_removeSeveralDialog = "¿Seguro que quieres mover estos {0} elementos a la papelera?"; - out.fm_removeDialog = "¿Seguro que quieres mover {0} a la papelera?"; - out.fm_restoreDialog = "¿Seguro que quieres recuperar {0}?"; - out.fm_unknownFolderError = "La carpeta seleccionada ya no existe. Abriendo la carpeta anterior..."; - out.fm_contextMenuError = "No se pudo abrir el menú para este elemento. Si persiste el problema, recarga la página."; - out.fm_selectError = "No se pudo abrir el elemento. Si persiste el problema, recarga la página."; - out.fm_info_root = "Crea carpetas aquí para organizar tus documentos."; - out.fm_info_unsorted = "Contiene todos los documentos que has visitado que no están organizados en \"Documentos\" o movidos a la \"Papelera\"."; - out.fm_info_template = "Contiene todas las plantillas que puedes volver a usar para crear nuevos documentos."; - out.fm_info_allFiles = "Contiene todos los archivos de \"Documentos\", \"Sin organizar\" y \"Papelera\". No puedes mover o eliminar archivos aquí."; - out.fm_alert_backupUrl = "Enlace de copia de seguridad para este drive. Te recomendamos encarecidamente que lo guardes secreto.
    Lo puedes usar para recuperar todos tus archivos en el caso que la memoria de tu navegador se borre.
    Cualquiera con este enlace puede editar o eliminar todos los archivos en el explorador.
    "; - out.fm_backup_title = "Enlace de copia de seguridad"; - out.fm_nameFile = "¿Cómo quieres nombrar este archivo?"; - out.fc_newfolder = "Nueva carpeta"; - out.fc_rename = "Cambiar nombre"; - out.fc_open = "Abrir"; - out.fc_open_ro = "Abrir (sólo lectura)"; - out.fc_delete = "Eliminar"; - out.fc_restore = "Recuperar"; - out.fc_remove = "Eliminar para siempre"; - out.fc_empty = "Vaciar la papelera"; - out.fc_prop = "Propiedades"; - out.fo_moveUnsortedError = "No puedes mover una carpeta en la lista de documentos no organizados"; - out.fo_existingNameError = "Nombre ya utilizado en esta carpeta. Por favor elige otro."; - out.fo_moveFolderToChildError = "No puedes mover una carpeta en una de sus subcarpetas"; - out.fo_unableToRestore = "No se pudo restaurar este archivo a la localización de origen. Puedes intentar moverlo a otra localización."; - out.fo_unavailableName = "Un archivo o carpeta ya tiene este nombre. Cámbialo y vuelve a intentarlo."; - out.login_login = "Iniciar sesión"; - out.login_makeAPad = "Crear documento anónimo"; - out.login_nologin = "Ver documentos locales"; - out.login_register = "Registrarse"; - out.logoutButton = "Cerrar sesión"; - out.settingsButton = "Preferencias"; - out.login_username = "Nombre de usuario"; - out.login_password = "Contraseña"; - out.login_confirm = "Confirmar contraseña"; - out.login_remember = "Recuérdame"; - out.login_hashing = "Generando hash de tu contraseña, esto puede tardar un poco."; - out.login_hello = "Hola {0},"; - out.login_helloNoName = "Hola,"; - out.login_accessDrive = "Acceder a tu drive"; - out.login_orNoLogin = "o"; - out.login_noSuchUser = "Credenciales inválidos. Inténtalo de nuevo, o regístrate"; - out.login_invalUser = "Nombre de usuario requerido"; - out.login_invalPass = "Contraseña requerida"; - out.login_unhandledError = "Ha ocurrido un error inesperado :("; - out.register_importRecent = "Importe el historial de tu sesión anónima"; - - out.register_acceptTerms = "Acepto los términos de servicio"; - out.register_passwordsDontMatch = "Las contraseñas no corresponden"; - out.register_mustAcceptTerms = "Tienes que aceptar los términos de servicio"; - out.register_mustRememberPass = "No podemos reiniciar tu contraseña si la olvidas. ¡Es muy importante que la recuerdes! Marca la casilla para confirmarlo."; - out.register_header = "Bienvenido a CryptPad"; - out.register_explanation = ["

    Vamos a ver algunas cosas antes

    ", "
      ", "
    • Tu contraseña es tu clave secreta que cifra todos tus documentos. Si la pierdes no podremos recuperar tus datos.
    • ", "
    • Puedes importar documentos que has visto recientemente en tu navegador para tenerlos en tu cuenta.
    • ", "
    • Si estás usando un ordenador compartido, tienes que cerrar sesión cuando terminas, cerrar la pestaña no es suficiente.
    • ", "
    "].join(''); - out.settings_title = "Preferencias"; - out.settings_save = "Guardar"; - out.settings_backupTitle = "Copia de seguridad"; - out.settings_backup = "Copia de seguridad"; - out.settings_restore = "Recuperar datos"; - out.settings_reset = "Quita todos los documentos de tu CryptDrive"; - out.settings_resetPrompt = "Esta acción eliminará todos tus documentos.
    ¿Seguro que quieres continuar?
    Introduce “I love CryptPad” para confirmar."; - out.settings_resetDone = "¡Tu drive ahora está vacio!"; - out.settings_resetTips = "Consejos en CryptDrive"; - out.settings_resetTipsButton = "Restaurar consejos"; - out.settings_resetTipsDone = "Todos los consejos ahora están visibles"; - out.main_info = "

    Colabora con Confianza


    Cultiva ideas juntos con documentos compartidos con tecnología Zero Knowledge que protege tu privacidad."; - out.main_zeroKnowledge = "Zero Knowledge"; - out.main_zeroKnowledge_p = "No tienes que confiar en que no veremos tus documentos, con la tecnología Zero Knowledge de CryptPad no podemos. Aprende más sobre cómo protegemos tu Privacidad y Seguridad."; - out.main_writeItDown = "Escríbelo"; - out.main_writeItDown_p = "Los mejores proyectos vienen de las más pequeñas ideas. Escribe tus momentos de inspiración e ideas inesperadas porque nunca sabrás cuál será tu próximo descubrimiento."; - out.main_share = "Comparte el enlace, comparte el pad"; - out.main_share_p = "Cultiva ideas juntos: ten reuniones eficaces, colabora en listas y haz presentaciones rápidas en todos tus dispositivos."; - out.main_organize = "Organízate"; - out.main_organize_p = "Con CryptPad Drive, mantén tu atención en lo más importante. Las carpetas te permiten organizar tus proyectos y tener una visión global de dónde van las cosas."; - out.main_richText = "Editor de Texto Enriquecido"; - out.main_richText_p = "Colabora en texto enriquecido con nuestro editor Zero Knowledge en tiempo real CkEditor."; - out.main_code = "Editor de código"; - out.main_code_p = "Edita código fuente para tus programas con nuestro editor Zero Knowledge en tiempo real CodeMirror."; - out.main_slide = "Editor de presentación"; - out.main_slide_p = "Crea presentaciones utilizando Markdown, y visualízalos en tu navegador"; - out.main_poll = "Encuestas"; - out.main_poll_p = "Planifica tus reuniones y eventos, o vota para la mejor solución a un problema."; - out.main_drive = "CryptDrive"; - out.footer_applications = "Aplicaciones"; - out.footer_contact = "Contacto"; - out.footer_aboutUs = "Acerca de nosotros"; - out.about = "Acerca de nosotros"; - out.privacy = "Privacidad"; - out.contact = "Contacto"; - out.terms = "Términos de Servicio"; - - // 1.1.0 - Bunyip - out.movedToTrash = "Este pad fue movido a la papelera.
    Acceder a mi Drive"; - out.fm_newFile = "Nuevo pad"; - out.fm_type = "Tipo"; - out.fm_categoryError = "No se pudo abrir la categoría seleccionada, mostrando la raíz."; - out.settings_userFeedbackHint1 = "CryptPad suministra informaciones muy básicas al servidor, para ayudarnos a mejorar vuestra experiencia."; - out.settings_userFeedbackHint2 = "El contenido de tu pad nunca será compartido con el servidor."; - out.settings_userFeedback = "Activar feedback"; - out.settings_anonymous = "No has iniciado sesión. Tus ajustes se aplicarán sólo a este navegador."; - out.blog = "Blog"; - - out.initialState = [ - '

    ', - 'Esto es CryptPad, el editor colaborativo en tiempo real Zero Knowledge. Todo está guardado cuando escribes.', - '
    ', - 'Comparte el enlace a este pad para editar con amigos o utiliza el botón para obtener un enlace sólo lectura que permite leer pero no escribir.', - '

    ', - ].join(''); - - out.codeInitialState = "/*\n Esto es CryptPad, el editor colaborativo en tiempo real zero knowledge.\n Lo que escribes aquí está cifrado de manera que sólo las personas con el enlace pueden acceder a ello.\n Incluso el servidor no puede ver lo que escribes.\n Lo que ves aquí, lo que escuchas aquí, cuando sales, se queda aquí\n*/"; - out.slideInitialState = "# CryptSlide\n1. Escribe tu contenido en Markdown\n - Puedes aprender más sobre Markdown [aquí](http://www.markdowntutorial.com/)\n2. Separa tus diapositivas con ---\n3. Haz clic en \"Presentar\" para ver el resultado - Tus diapositivas se actualizan en tiempo real"; - out.driveReadmeTitle = "¿Qué es CryptPad?"; - out.readme_welcome = "¡Bienvenido a CryptPad!"; - out.readme_p1 = "Bienvenido a CryptPad, aquí podrás anotar cosas solo o con otra gente."; - out.readme_p2 = "Este pad es una guía rápida para aprender a usar a CryptPad para tomar notas, organizarlas y trabajar con más personas."; - out.readme_cat1 = "Conoce tu CryptDrive"; - out.readme_cat1_l1 = "Crea un pad: En CryptDrive, haz clic en {0} y luego en {1} para crear un pad."; - out.readme_cat1_l2 = "Abrir pads desde CryptDrive: haz doble clic en un icono para abrirlo."; - out.readme_cat1_l3 = "Organiza tus pads: Cuando has iniciado sesión, cada pad al que accedes se quedará en tu drive en {0}."; - out.readme_cat1_l3_l1 = "Puedes hacer clic y arrastrar archivos en carpetas desde {0}, y crear nuevas carpetas."; - out.readme_cat1_l3_l2 = "Recuerda hacer clic derecho en los iconos, ya que suele haber menús adicionales."; - out.readme_cat1_l4 = "Elimina tus viejos pads: Haz clic y arrastra tus pads en la {0} de la misma manera que lo harías con carpetas."; - out.readme_cat2 = "Haz pads como un pro"; - out.edit = "editar"; - out.view = "ver"; - out.readme_cat2_l1 = "El botón {0} en tu pad te permite dar acceso a colaboradores para {1} o {2} el pad."; - out.readme_cat2_l2 = "Cambia el título del pad haciendo clic en el lápiz"; - out.readme_cat3 = "Descubre las apps CryptPad"; - out.readme_cat3_l1 = "Con el editor de código CryptPad, puedes colaborar en código fuente, como por ejemplo JavaScript y Markdown"; - out.readme_cat3_l2 = "Con los slides CryptPad, puedes hacer presentaciones rápidas con Markdown"; - out.readme_cat3_l3 = "Con CryptPoll puedes hacer una encuesta rápida, especialmente útil para programar un horario que conviene a todo el mundo"; - - // 1.2.0 - Chupacabra - - out.settings_resetError = "Verificación no válida. Tu CryptDrive no fue cambiado."; - out.saved = "Guardado"; - out.printButton = "Imprimir"; - out.printButtonTitle = "Imprimir tu presentación o exportar a PDF"; - out.printOptions = "Opciones de impresión"; - out.printSlideNumber = "Mostrar el número de diapositiva"; - out.printDate = "Mostrar la fecha"; - out.printTitle = "Mostrar el título"; - out.printCSS = "CSS personalizado:"; - out.editOpen = "Abrir enlaces de edición en pestaña nueva"; - out.editOpenTitle = "Abrir en modo edición en pestaña nueva"; - out.settings_importTitle = "Importar pads recientes locales en CryptDrive"; - out.settings_import = "Importar"; - out.settings_importConfirm = "¿Seguro que quieres importar tus pads recientes a tu cuenta CryptDrive?"; - out.settings_importDone = "Importación terminada"; - - out.tips = {}; - out.tips.lag = "El icono verde en la parte superior derecha muestra la calidad de tu connexión a CryptPad."; - out.tips.shortcuts = "`ctrl+b`, `ctrl+i`, y `ctrl+u` son accesos rápidos para negrita, itálica y subrayado."; - out.tips.indent = "Cuando editas listas, puedes usar tab o shift+tab para incrementar o decrementar la sangría."; - out.tips.title = "Puedes cambiar el título de tus pads en la parte superior de la pantalla."; - out.tips.store = "Cada vez que visitas un pad con una sesión iniciada se guardará en tu CryptDrive."; - out.tips.marker = "Puedes resaltar texto en un pad utilizando el \"marcador\" en el menú de estílo."; - out.tips.driveUpload = "Los usuarios registrados pueden subir archivos cifrados arrastrándolos hacia CryptDrive."; - - out.feedback_about = "Si estas leyendo esto, quizás sientas curiosidad por saber por qué CryptPad solicita páginas cuando realizas algunas acciones"; - out.feedback_privacy = "Nos importa tu privacidad, y al mismo tiempo queremos que CryptPad sea muy fácil de usar. Utilizamos este archivo para conocer las funcionalidades que importan a nuestros usuarios, pidiéndolo con un parametro que nos dice qué acción fue realizada."; - out.feedback_optout = "Si quieres darte de baja, visita tus preferencias, donde podrás activar o desactivar el feedback"; - - out.fm_searchName = "Buscar"; - out.fm_searchPlaceholder = "Buscar..."; - out.fm_newButtonTitle = "Crear un nuevo pad o carpeta"; - out.fm_openParent = "Mostrar en carpeta"; - out.register_writtenPassword = "He escrito mi usuario y contraseña, continuar"; - out.register_cancel = "Volver"; - out.register_warning = "Zero Knowledge significa que no podemos recuperar tus datos si pierdes tu contraseña."; - out.register_alreadyRegistered = "Este usuario ya existe, ¿iniciar sesión?"; - - // 1.4.0 - Easter Bunny - - out.button_newwhiteboard = "Nueva Pizarra"; - out.wrongApp = "No se pudo mostrar el contenido de la sesión en tiempo real en tu navegador. Por favor, actualiza la página."; - out.synced = "Todo está guardado."; - out.saveTemplateButton = "Guardar como plantilla"; - out.saveTemplatePrompt = "Elige un título para la plantilla"; - out.templateSaved = "¡Plantilla guardada!"; - out.selectTemplate = "Elige una plantilla o pulsa ESC"; - out.slideOptionsTitle = "Personaliza tus diapositivas"; - out.slideOptionsButton = "Guardar (enter)"; - out.canvas_clear = "Limpiar"; - out.canvas_delete = "Borrar selección"; - out.canvas_disable = "No permitir dibujos"; - out.canvas_enable = "Permitir dibujos"; - out.canvas_width = "Talla"; - out.canvas_opacity = "Opacidad"; - out.settings_publicSigningKey = "Clave de Firma Pública"; - out.settings_usage = "Utilización"; - out.settings_usageTitle = "Ve el uso total de tus pads en MB"; - out.settings_pinningNotAvailable = "Los pads pegados sólo están disponibles para usuarios registrados."; - out.settings_pinningError = "Algo salió mal"; - out.settings_usageAmount = "Tus pads pegados utilizan {0}MB"; - out.historyButton = "Mostrar el historial del documento"; - out.history_next = "Ir a la versión anterior"; - out.history_prev = "Ir a la versión posterior"; - out.history_goTo = "Ir a la versión seleccionada"; - out.history_close = "Volver"; - out.history_closeTitle = "Cerrar el historial"; - out.history_restore = "Restaurar"; - out.history_restoreTitle = "Restaurar la versión seleccionada del documento"; - out.history_restorePrompt = "¿Estás seguro de que quieres cambiar la versión actual del documento por ésta?"; - out.history_restoreDone = "Documento restaurado"; - out.fc_sizeInKilobytes = "Tamaño en Kilobytes"; - - // 1.5.0/1.6.0 - Fenrir/Grootslang - - out.deleted = "El pad fue borrado de tu CryptDrive"; - out.upgrade = "Mejorar"; - out.upgradeTitle = "Mejora tu cuenta para obtener más espacio"; - out.upgradeAccount = "Mejorar cuenta"; - - out.MB = "MB"; - out.GB = "GB"; - out.KB = "KB"; - out.formattedMB = "{0} MB"; - out.formattedGB = "{0} GB"; - out.formattedKB = "{0} KB"; - - out.pinLimitReached = "Has llegado al límite de espacio"; - out.pinLimitNotPinned = "Has llegado al límite de espacio.
    Este pad no estará presente en tu CryptDrive."; - out.pinLimitDrive = "Has llegado al límite de espacio.
    No puedes crear nuevos pads."; - out.printTransition = "Activar transiciones"; - out.history_version = "Versión: "; - out.settings_logoutEverywhereTitle = "Cerrar sesión en todas partes"; - out.settings_logoutEverywhere = "Cerrar todas las otras sesiones"; - out.settings_logoutEverywhereConfirm = "¿Estás seguro? Tendrás que volver a iniciar sesión con todos tus dispositivos."; - out.upload_serverError = "Error: no se pudo subir tu archivo en este momento."; - out.upload_uploadPending = "Ya tienes una subida en progreso. ¿Cancelar y subir el nuevo archivo?"; - out.upload_success = "Tu archivo ({0}) ha sido subido con éxito y fue añadido a tu drive."; - - // 1.7.0 - Hodag - out.comingSoon = "Próximamente..."; - out.newVersion = ["CryptPad ha sido actualizado!", - "Puedes ver lo que ha cambiado aquí (en inglés):", - "Notas de versión para CryptPad {0}"].join("
    "); - out.pinLimitReachedAlertNoAccounts = "Has llegado a tu límite de espacio"; - out.previewButtonTitle = "Mostrar/esconder la vista previa Markdown"; - out.fm_info_anonymous = "No estás conectado, así que estos pads pueden ser borrados (¿por qué?). Regístrate o Inicia sesión para asegurarlos."; - out.fm_alert_anonymous = "Hola, estás usando CryptPad anónimamente. Está bien, pero tus pads pueden ser borrados después de un périodo de inactividad. Hemos desactivado funciones avanzadas de CryptDrive para usuarios anónimos porque queremos dejar claro que no es un lugar seguro para almacenar cosas. Puedes leer este articulo (en inglés) acerca de por qué hacemos esto y por qué deberías Registrarte e Iniciar sesión."; - out.fm_error_cantPin = "Error del servidor. Por favor, recarga la página e inténtalo de nuevo."; - out.upload_notEnoughSpace = "No tienes suficiente espacio para este archivo en tu CryptDrive"; - out.upload_tooLarge = "Este archivo supera el límite de carga."; - out.upload_choose = "Escoge un archivo"; - out.upload_pending = "Esperando"; - out.upload_cancelled = "Cancelado"; - out.upload_name = "Nombre"; - out.upload_size = "Tamaño"; - out.upload_progress = "Progreso"; - out.download_button = "Descifrar y descargar"; - out.warn_notPinned = "Este pad no está en ningún CryptDrive. Expirará después de 3 meses. Acerca de..."; - - out.poll_remove = "Quitar"; - out.poll_edit = "Editar"; - out.poll_locked = "Cerrado"; - out.poll_unlocked = "Abierto"; - - out.poll_show_help_button = "Mostrar ayuda"; - out.poll_hide_help_button = "Esconder ayuda"; - - // 1.8.0 - Idopogo - - out.common_connectionLost = "Conexión perdida
    El documento está ahora en modo sólo lectura hasta que la conexión vuelva."; - out.updated_0_common_connectionLost = out.common_connectionLost; - out.supportCryptpad = "Ayudar a CryptPad"; - out.pinLimitReachedAlert = ["Has llegado a tu límite de espacio. Los nuevos pads no serán guardados en tu CryptDrive.", - "Puedes eliminar pads de tu CryptDrive o suscribirte a una oferta premium para obtener más espacio."].join("
    "); - out.updated_0_pinLimitReachedAlert = out.pinLimitReachedAlert; - out.fm_info_trash = "Vacía tu papelera para liberar espacio en tu CryptDrive."; - out.updated_0_fm_info_trash = out.fm_info_trash; - - out.fs_migration = "Tu CryptDrive fue actualizado a una nueva versión.
    Por favor, recarga la página."; - out.login_notRegistered = "¿No estás registrado?"; - out.upload_mustLogin = "Tienes que estar conectado para subir archivos"; - - out.uploadButton = "Subir"; - out.uploadButtonTitle = "Subir un archivo a la carpeta"; - out.filePickerButton = "Incrustar un archivo"; - out.filePicker_close = "Cerrar"; - out.filePicker_description = "Elige un archivo de tu CryptDrive para incrustarlo o sube uno nuevo"; - out.filePicker_filter = "Filtrar por nombre"; - out.or = "o"; - out.languageButton = "Lenguaje"; - out.languageButtonTitle = "Elige el lenguaje para resaltado de sintaxis"; - out.themeButton = "Tema"; - out.themeButtonTitle = "Selecciona el tema de color para los editores de código y presentación"; - out.canvas_opacityLabel = "Opacidad: {0}"; - out.canvas_widthLabel = "Talla: {0}"; - - // 1.10.0 - Kraken - - out.moreActions = "Más acciones"; - out.importButton = "Importar"; - out.exportButton = "Exportar"; - out.saveTitle = "Guardar título (enter)"; - out.forgetButton = "Eliminar"; - out.printText = "Imprimir"; - out.slideOptionsText = "Opciones"; - out.historyText = "Historial"; - out.openLinkInNewTab = "Abrir enlace en pestaña nueva"; - out.profileButton = "Perfil"; - out.profile_urlPlaceholder = "URL"; - out.profile_namePlaceholder = "Nombre mostrado en su perfil"; - out.profile_avatar = "Imagen"; - out.profile_upload = "Subir una imagen"; - out.profile_error = "Error al crear tu perfil: {0}"; - out.profile_register = "Tienes que registrarte para crear un perfil"; - out.profile_create = "Crear perfil"; - out.profile_description = "Descripción"; - out.profile_fieldSaved = "Guardado: {0}"; - out.download_mt_button = "Descargar"; - out.updated_0_header_logoTitle = "Volver a tu CryptDrive"; - out.header_logoTitle = out.updated_0_header_logoTitle; - - // 1.11.0 - Lutin - - out.realtime_unrecoverableError = "El motor de tiempo real ha encontrado un error. Haga clic en OK para recargar la página."; - out.typing = "Escribiendo"; - out.profile_inviteButton = "Conectar"; - out.profile_inviteButtonTitle = "Crear un enlace de invitación para este usuario."; - out.profile_inviteExplanation = "Hacer clic en OK creará un enlace de mensaje seguro que sólo {0} podrá ver.

    El enlace será copiado a tu portapapeles y puede ser compartido públicamente."; - out.profile_viewMyProfile = "Ver mi perfil"; - out.userlist_addAsFriendTitle = 'Agregar "{0}" como contacto'; - out.userlist_thisIsYou = 'Tú mismo ("{0}")'; - out.contacts_title = "Contactos"; - out.contacts_addError = "Error al agregar este contacto a la lista"; - out.contacts_added = "Invitación aceptada"; - out.contacts_rejected = "Invitación denegada"; - out.contacts_request = "{0} quiere agregarte como contacto. ¿Aceptar?"; - out.contacts_send = "Enviar"; - out.contacts_remove = "Eliminar este contacto"; - out.contacts_confirmRemove = "¿Estás seguro de que quieres eliminar {0} de tus contactos?"; - out.contacts_info1 = "Estos son tus contactos. Desde aquí, puedes:"; - out.contacts_info2 = "Hacer clic en el icono de tu contacto para chatear"; - out.contacts_info3 = "Hacer doble-clic para ver su perfil"; - out.contacts_info4 = "Cualquier participante puede eliminar definitivamente el historial de chat"; - out.settings_cat_account = "Cuenta"; - out.settings_cat_drive = "CryptDrive"; - out.settings_backupCategory = "Copia de seguridad"; - out.settings_resetNewTitle = "Limpiar CryptDrive"; - out.settings_resetButton = "Eliminar"; - out.settings_resetTipsAction = "Reiniciar"; - out.settings_userFeedbackTitle = "Feedback"; - out.settings_logoutEverywhereButton = "Cerrar sesión"; - out.upload_title = "Subir archivo"; - - // 1.12.0 - Minotaur - out.userlist_pending = "Pendiente..."; - out.contacts_typeHere = "Escribe un mensaje aquí..."; - out.contacts_removeHistoryTitle = "Borrar el historial de chat"; - out.contacts_confirmRemoveHistory = "¿Estás seguro de que quieres borrar el historial de forma permanente? No se podrán recuparar los datos."; - out.contacts_removeHistoryServerError = "Hubo un error al borrar el historial. Inténtalo de nuevo más tarde."; - out.todo_title = "CryptTodo"; - out.todo_newTodoNamePlaceholder = "Describe tu tarea..."; - out.todo_newTodoNameTitle = "Añadir tarea a la lista"; - out.todo_markAsCompleteTitle = "Marcar esta tarea como completa"; - out.todo_markAsIncompleteTitle = "Marcar esta tarea como incompleta"; - out.todo_removeTaskTitle = "Borrar esta tarea de la lista"; - - // 1.13.0 - Naiad - out.topbar_whatIsCryptpad = "Qué es CryptPad"; - out.header_homeTitle = "Volver a la página de inicio"; - out.userListButton = "Lista de usuarios"; - out.userAccountButton = "Tu cuenta"; - out.canvas_saveToDrive = "Guardar esta imagen como archivo en tu CryptDrive"; - out.canvas_currentBrush = "Pincel actual"; - out.canvas_chooseColor = "Eligir un color"; - out.fm_viewListButton = "Lista"; - out.fm_viewGridButton = "Cuadrícula"; - out.settings_cat_code = "Código"; - out.settings_codeIndentation = "Indentación del editor de código (espacios)"; - out.settings_codeUseTabs = "Utilizar tabulaciones en vez de espacios"; - out.pad_showToolbar = "Mostrar la barra de herramientas"; - out.pad_hideToolbar = "Esconder la barra de herramientas"; - out.main_catch_phrase = "El Cloud Zero Knowledge"; - out.main_richTextPad = "Pad de Texto Enriquecido"; - out.main_codePad = "Pad de Código"; - out.main_slidePad = "Presentación Markdown"; - out.main_pollPad = "Encuesta"; - out.main_whiteboardPad = "Pizarra"; - out.main_localPads = "Pad Locales"; - out.main_yourCryptDrive = "Tu CryptDrive"; - - return out; -}); diff --git a/www/common/translations/old/messages.fr.js b/www/common/translations/old/messages.fr.js deleted file mode 100644 index b444f082f..000000000 --- a/www/common/translations/old/messages.fr.js +++ /dev/null @@ -1,1317 +0,0 @@ -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - - out.main_title = "CryptPad : Éditeur collaboratif en temps réel, zero knowledge"; - - out.type = {}; - out.type.pad = 'Texte'; - out.type.code = 'Code'; - out.type.poll = 'Sondage'; - out.type.kanban = 'Kanban'; - out.type.slide = 'Présentation'; - out.type.drive = 'CryptDrive'; - out.type.whiteboard = "Tableau Blanc"; - out.type.file = "Fichier"; - out.type.media = "Média"; - out.type.todo = "Todo"; - out.type.contacts = "Contacts"; - out.type.sheet = 'Tableur (Beta)'; - - out.button_newpad = 'Nouveau document texte'; - out.button_newcode = 'Nouvelle page de code'; - out.button_newpoll = 'Nouveau sondage'; - out.button_newslide = 'Nouvelle présentation'; - out.button_newwhiteboard = 'Nouveau tableau blanc'; - out.button_newkanban = 'Nouveau kanban'; - - out.updated_0_common_connectionLost = "Connexion au serveur perdue
    Vous êtes désormais en mode lecture seule jusqu'au retour de la connexion."; - out.common_connectionLost = out.updated_0_common_connectionLost; - - out.websocketError = 'Impossible de se connecter au serveur WebSocket...'; - out.typeError = "Ce pad n'est pas compatible avec l'application sélectionnée"; - out.onLogout = 'Vous êtes déconnecté de votre compte utilisateur, {0}cliquez ici{1} pour vous authentifier
    ou appuyez sur Échap pour accéder au pad en mode lecture seule.'; - out.wrongApp = "Impossible d'afficher le contenu de ce document temps-réel dans votre navigateur. Vous pouvez essayer de recharger la page."; - out.padNotPinned = 'Ce pad va expirer après 3 mois d\'inactivité, {0}connectez-vous{1} ou {2}enregistrez-vous{3} pour le préserver.'; - out.anonymousStoreDisabled = "L'administrateur de cette instance de CryptPad a désactivé le drive pour les utilisateurs non enregistrés. Vous devez vous connecter pour pouvoir utiliser CryptDrive."; - out.expiredError = "Ce pad a atteint sa date d'expiration est n'est donc plus disponible."; - out.deletedError = 'Ce pad a été supprimé par son propriétaire et n\'est donc plus disponible.'; - out.inactiveError = 'Ce pad a été supprimé en raison de son inactivité. Appuyez sur Échap pour créer un nouveau pad.'; - out.chainpadError = 'Une erreur critique est survenue lors de la mise à jour du contenu. Le pad est désormais en mode lecture seule afin de s\'assurer que vous ne perdiez pas davantage de données.
    ' + - 'Appuyez sur Échap pour voir le pad ou rechargez la page pour pouvoir le modifier à nouveau.'; - out.errorCopy = ' Vous pouvez toujours copier son contenu ailleurs en appuyant sur Échap.
    Dés que vous aurez quitté la page, il sera impossible de le récupérer.'; - out.errorRedirectToHome = 'Appuyez sur Échap pour retourner vers votre CryptDrive.'; - out.newVersionError = "Une nouvelle version de CryptPad est disponible.
    " + - "Rechargez la page pour utiliser la nouvelle version, ou appuyez sur Échap pour accéder au contenu actuel en mode hors-ligne."; - - out.loading = "Chargement..."; - out.error = "Erreur"; - out.saved = "Enregistré"; - out.synced = "Tout est enregistré"; - out.deleted = "Pad supprimé de votre CryptDrive"; - out.deletedFromServer = "Pad supprimé du serveur"; - - out.mustLogin = "Vous devez être enregistré pour avoir accès à cette page."; - out.disabledApp = "Cette application a été désactivée. Pour plus d'information, veuillez contacter l'administrateur de ce CryptPad."; - - out.realtime_unrecoverableError = "Une erreur critique est survenue. Cliquez sur OK pour recharger la page."; - - out.disconnected = 'Déconnecté'; - out.synchronizing = 'Synchronisation'; - out.reconnecting = 'Reconnexion'; - out.typing = "Édition"; - out.initializing = "Initialisation..."; - out.forgotten = 'Déplacé vers la corbeille'; - out.errorState = 'Erreur critique : {0}'; - out.lag = 'Latence'; - out.readonly = 'Lecture seule'; - out.anonymous = "Anonyme"; - out.yourself = "Vous-même"; - out.anonymousUsers = "éditeurs anonymes"; - out.anonymousUser = "éditeur anonyme"; - out.users = "Utilisateurs"; - out.and = "Et"; - out.viewer = "lecteur"; - out.viewers = "lecteurs"; - out.editor = "éditeur"; - out.editors = "éditeurs"; - out.userlist_offline = "Vous êtes actuellement hors-ligne, la liste des utilisateurs n'est pas disponible."; - - out.language = "Langue"; - - out.comingSoon = "Bientôt disponible..."; - - out.newVersion = 'CryptPad a été mis à jour !
    ' + - 'Découvrez les nouveautés de la dernière version :
    '+ - 'Notes de version pour CryptPad {0}'; - - out.upgrade = "Augmenter votre limite"; - out.upgradeTitle = "Améliorer votre compte pour augmenter la limite de stockage"; - - out.upgradeAccount = "Améliorer le compte"; - out.MB = "Mo"; - out.GB = "Go"; - out.KB = "Ko"; - - out.supportCryptpad = "Soutenir CryptPad"; - - out.formattedMB = "{0} Mo"; - out.formattedGB = "{0} Go"; - out.formattedKB = "{0} Ko"; - - out.greenLight = "Tout fonctionne bien"; - out.orangeLight = "Votre connexion est lente, ce qui réduit la qualité de l'éditeur"; - out.redLight = "Vous êtes déconnecté de la session"; - - out.pinLimitReached = "Vous avez atteint votre limite de stockage"; - out.updated_0_pinLimitReachedAlert = "Vous avez atteint votre limite de stockage. Les nouveaux pads ne seront pas enregistrés dans votre CryptDrive.
    " + - 'Vous pouvez soit supprimer des pads de votre CryptDrive, soit vous abonner à une offre premium pour augmenter la limite maximale.'; - out.pinLimitReachedAlert = out.updated_0_pinLimitReachedAlert; - out.pinLimitReachedAlertNoAccounts = out.pinLimitReached; - out.pinLimitNotPinned = "Vous avez atteint votre limite de stockage.
    "+ - "Ce pad n'est pas enregistré dans votre CryptDrive."; - out.pinLimitDrive = out.pinLimitReached+ ".
    " + - "Vous ne pouvez pas créer de nouveaux pads."; - - out.moreActions = "Autres actions"; - - out.importButton = "Importer"; - out.importButtonTitle = 'Importer un pad depuis un fichier local'; - - out.exportButton = "Exporter"; - out.exportButtonTitle = 'Exporter ce pad vers un fichier local'; - out.exportPrompt = 'Comment souhaitez-vous nommer ce fichier ?'; - - out.changeNamePrompt = 'Changer votre nom (laisser vide pour rester anonyme) : '; - out.user_rename = "Changer le nom affiché"; - out.user_displayName = "Nom affiché"; - out.user_accountName = "Nom d'utilisateur"; - - out.clickToEdit = 'Cliquer pour modifier'; - out.saveTitle = "Enregistrer le titre (Entrée)"; - - out.forgetButton = "Supprimer"; - out.forgetButtonTitle = 'Déplacer ce pad vers la corbeille'; - out.forgetPrompt = 'Cliquer sur OK déplacera ce pad vers la corbeille de votre CryptDrive, êtes-vous sûr ?'; - out.movedToTrash = 'Ce pad a été déplacé vers la corbeille.
    Accéder à mon Drive'; - - out.shareButton = 'Partager'; - out.shareSuccess = 'Lien copié dans le presse-papiers'; - - out.userListButton = "Liste d'utilisateurs"; - - out.chatButton = "Chat"; - - out.userAccountButton = "Votre compte"; - - out.newButton = 'Nouveau'; - out.newButtonTitle = 'Créer un nouveau pad'; - out.uploadButton = 'Importer des fichiers'; - out.uploadButtonTitle = 'Importer un nouveau fichier dans le dossier actuel'; - - out.saveTemplateButton = "Sauver en tant que modèle"; - out.saveTemplatePrompt = "Choisir un titre pour ce modèle"; - out.templateSaved = "Modèle enregistré !"; - out.selectTemplate = "Sélectionner un modèle ou appuyer sur Échap"; - out.useTemplate = "Commencer avec un modèle?"; - out.useTemplateOK = 'Choisir un modèle (Entrée)'; - out.useTemplateCancel = 'Document vierge (Échap)'; - out.template_import = "Importer un modèle"; - out.template_empty = "Aucun modèle disponible"; - - out.previewButtonTitle = "Afficher ou cacher la prévisualisation de Markdown"; - - out.presentButtonTitle = "Entrer en mode présentation"; - - out.backgroundButtonTitle = 'Changer la couleur de fond de la présentation'; - out.colorButtonTitle = 'Changer la couleur du texte en mode présentation'; - - out.propertiesButton = "Propriétés"; - out.propertiesButtonTitle = 'Voir les propriétés de ce pad'; - - out.printText = "Imprimer"; - out.printButton = "Imprimer (Entrée)"; - out.printButtonTitle2 = "Imprimer votre document ou l'enregistrer au format PDF"; - out.printOptions = "Options de mise en page"; - out.printSlideNumber = "Afficher le numéro des slides"; - out.printDate = "Afficher la date"; - out.printTitle = "Afficher le titre du pad"; - out.printCSS = "Personnaliser l'apparence (CSS):"; - out.printTransition = "Activer les animations de transition"; - out.printBackground = "Utiliser une image d'arrière-plan"; - out.printBackgroundButton = "Choisir une image"; - out.printBackgroundValue = "Arrière-plan actuel: {0}"; - out.printBackgroundNoValue = "Aucun arrière-plan affiché"; - out.printBackgroundRemove = "Supprimer cet arrière-plan"; - - out.filePickerButton = "Intégrer un fichier stocké dans CryptDrive"; - out.filePicker_close = "Fermer"; - out.filePicker_description = "Choisissez un fichier de votre CryptDrive pour l'intégrer ou importez-en un nouveau"; - out.filePicker_filter = "Filtrez les fichiers par leur nom"; - out.or = 'ou'; - - out.tags_title = "Mots-clés du pad (pour vous uniquement)"; - out.tags_add = "Modifier les mots-clés du pad"; - out.tags_searchHint = "Commencez une recherche par # dans votre CryptDrive pour retrouver vos pads par mot-clé."; - out.tags_notShared = "Vos mots-clés ne sont pas partagés avec les autres utilisateurs."; - out.tags_duplicate = "Mot-clé déjà présent : {0}"; - out.tags_noentry = "Vous ne pouvez pas ajouter de mots-clés à un pad supprimé!"; - - out.slideOptionsText = "Options"; - out.slideOptionsTitle = "Personnaliser la présentation"; - out.slideOptionsButton = "Enregistrer (Entrée)"; - out.slide_invalidLess = "Feuille de style non valide"; - - out.languageButton = "Langage"; - out.languageButtonTitle = "Sélectionner le langage à utiliser pour la coloration syntaxique"; - out.themeButton = "Thème"; - out.themeButtonTitle = "Sélectionner le thème de couleurs à utiliser pour les éditeurs de code et de présentations"; - - out.editShare = "Lien d'édition"; - out.editShareTitle = "Copier le lien d'édition dans le presse-papiers"; - out.editOpen = "Éditer dans un nouvel onglet"; - out.editOpenTitle = "Ouvrir le lien d'édition dans un nouvel onglet"; - out.viewShare = "Lien de lecture-seule"; - out.viewShareTitle = "Copier lien d'accès en lecture seule dans le presse-papiers"; - out.viewOpen = "Voir dans un nouvel onglet"; - out.viewOpenTitle = "Ouvrir le lien en lecture seule dans un nouvel onglet"; - out.fileShare = "Copier le lien"; - out.getEmbedCode = "Obtenir le code d'intégration"; - out.viewEmbedTitle = "Intégrer le pad dans une page web"; - out.viewEmbedTag = "Pour intégrer ce pad, veuillez inclure l'iframe suivant dans votre page là où vous souhaitez l'afficher. Vous pouvez changer sa taille en utilisant du code CSS ou des attributs HTML."; - out.fileEmbedTitle = "Intégrer le fichier dans une page web"; - out.fileEmbedScript = "Pour intégrer un fichier, veuillez inclure le script suivant une fois dans votre page afin de pouvoir charger le Media Tag :"; - out.fileEmbedTag = "Ensuite vous pouvez placer ce Media Tag où vous souhaitez dans votre page pour l'intégrer :"; - - out.notifyJoined = "{0} a rejoint la session collaborative"; - out.notifyRenamed = "{0} a changé son nom en {1}"; - out.notifyLeft = "{0} a quitté la session collaborative"; - - out.ok = 'OK'; - out.okButton = 'OK (Entrée)'; - - out.cancel = "Annuler"; - out.cancelButton = 'Annuler (Échap)'; - out.doNotAskAgain = "Ne plus demander (Échap)"; - - out.show_help_button = "Afficher l'aide"; - out.hide_help_button = "Cacher l'aide"; - out.help_button = "Aide"; - - out.historyText = "Historique"; - out.historyButton = "Afficher l'historique du document"; - out.history_next = "Version plus récente"; - out.history_prev = "Version plus ancienne"; - out.history_loadMore = "Charger davantage d'historique"; - out.history_closeTitle = "Fermer l'historique"; - out.history_restoreTitle = "Restaurer la version du document sélectionnée"; - out.history_restorePrompt = "Êtes-vous sûr de vouloir remplacer la version actuelle du document par la version affichée ?"; - out.history_restoreDone = "Document restauré"; - out.history_version = "Version :"; - - // Ckeditor - out.openLinkInNewTab = "Ouvrir le lien dans un nouvel onglet"; - out.pad_mediatagTitle = "Options du Media-Tag"; - out.pad_mediatagWidth = "Largeur (px)"; - out.pad_mediatagHeight = "Hauteur (px)"; - out.pad_mediatagRatio = "Préserver les proportions"; - out.pad_mediatagBorder = "Épaisseur de la bordure (px)"; - out.pad_mediatagPreview = "Aperçu"; - out.pad_mediatagImport = 'Sauver dans votre CryptDrive'; - out.pad_mediatagOptions = 'Propriétés de l\'image'; - - // Kanban - out.kanban_newBoard = "Nouveau tableau"; - out.kanban_item = "Élément {0}"; // Item number for initial content - out.kanban_todo = "À faire"; - out.kanban_done = "Terminé"; - out.kanban_working = "En cours"; - out.kanban_deleteBoard = "Êtes-vous sûr de vouloir supprimer ce tableau ?"; - out.kanban_addBoard = "Ajouter un tableau"; - out.kanban_removeItem = "Supprimer cet élément"; - out.kanban_removeItemConfirm = "Êtes-vous sûr de vouloir supprimer cet élément ?"; - - // Polls - - out.poll_title = "Sélecteur de date Zero Knowledge"; - out.poll_subtitle = "Planification de rendez-vous et sondages en temps-réel et Zero Knowledge"; - - out.poll_p_save = "Vos modifications sont mises à jour instantanément, donc vous n'avez jamais besoin de sauver le contenu."; - out.poll_p_encryption = "Tout ce que vous entrez est chiffré donc seules les personnes possédant le lien du sondage y ont accès. Même le serveur ne peut pas voir le contenu."; - - out.wizardLog = "Cliquez sur le bouton dans le coin supérieur gauche pour retourner au sondage"; - out.wizardTitle = "Utiliser l'assistant pour créer votre sondage"; - out.wizardConfirm = "Êtes-vous vraiment prêt à ajouter ces options au sondage ?"; - - out.poll_publish_button = "Publier"; - out.poll_admin_button = "Administrer"; - out.poll_create_user = "Ajouter un utilisateur"; - out.poll_create_option = "Ajouter une option"; - out.poll_commit = "Ajouter"; - - out.poll_closeWizardButton = "Fermer l'assistant"; - out.poll_closeWizardButtonTitle = "Fermer l'assistant"; - out.poll_wizardComputeButton = "Générer les options"; - out.poll_wizardClearButton = "Vider le tableau"; - out.poll_wizardDescription = "Créer automatiquement des options en entrant des dates et des horaires correspondant"; - out.poll_wizardAddDateButton = "+ Dates"; - out.poll_wizardAddTimeButton = "+ Horaires"; - - out.poll_optionPlaceholder = "Option"; - out.poll_userPlaceholder = "Votre nom"; - out.poll_removeOption = "Êtes-vous sûr de vouloir supprimer cette option ?"; - out.poll_removeUser = "Êtes-vous sûr de vouloir supprimer cet utilisateur ?"; - - out.poll_titleHint = "Titre"; - out.poll_descriptionHint = "Décrivez votre sondage puis cliquer sur le bouton ✓ (Publier).\n" + - "La description peut contenir de la syntaxe Markdown, et vous pouvez y ajouter des images stockées dans votre CryptDrive.\n" + - "Toutes les personnes possédant le lien d'édition de ce sondage peuvent modifier la description, bien que ce soit déconseillé."; - - out.poll_remove = "Supprimer"; - out.poll_edit = "Modifier"; - out.poll_locked = "Verrouillé"; - out.poll_unlocked = "Déverrouillé"; - - out.poll_bookmark_col = "Marquer cette colonne comme favorite pour qu'elle soit toujours déverrouillée et affichée en première position."; - out.poll_bookmarked_col = "Voici votre colonne favorite ; elle sera toujours déverrouillée et affichée en première position."; - out.poll_total = 'TOTAL'; - - out.poll_comment_list = "Commentaires"; - out.poll_comment_add = "Ajouter un commentaire"; - out.poll_comment_submit = "Envoyer"; - out.poll_comment_remove = "Supprimer ce commentaire"; - out.poll_comment_placeholder = "Votre commentaire"; - - out.poll_comment_disabled = "Publiez ce sondage en utilisant le bouton ✓ afin d'activer les commentaires."; - - // OnlyOffice - out.oo_reconnect = "La connexion au serveur est rétablie. Cliquez sur OK pour recharger la page et continuer l'édition."; - - // Canvas - out.canvas_clear = "Nettoyer"; - out.canvas_delete = "Supprimer la sélection"; - out.canvas_disable = "Désactiver le dessin"; - out.canvas_enable = "Activer le dessin"; - out.canvas_width = "Taille"; - out.canvas_opacity = "Opacité"; - out.canvas_opacityLabel = "Opacité : {0}"; - out.canvas_widthLabel = "Taille : {0}"; - out.canvas_saveToDrive = "Sauvegarder cette image en tant que fichier dans CryptDrive"; - out.canvas_currentBrush = "Pinceau actuel"; - out.canvas_chooseColor = "Choisir une couleur"; - out.canvas_imageEmbed = "Intégrer une image de votre ordinateur"; - - // Profile - out.profileButton = "Profil"; // dropdown menu - out.profile_urlPlaceholder = 'URL'; - out.profile_namePlaceholder = 'Nom ou pseudo pour le profil'; - out.profile_avatar = "Avatar"; - out.profile_upload = " Importer un nouvel avatar"; - out.profile_uploadSizeError = "Erreur : votre avatar doit avoir une taille inférieure à {0}"; - out.profile_uploadTypeError = "Erreur : le format de votre avatar est invalide. Les formats autorisés sont : {0}"; - out.profile_error = "Erreur lors de la création du profil : {0}"; - out.profile_register = "Vous devez vous inscrire pour pouvoir créer un profil !"; - out.profile_create = "Créer un profil"; - out.profile_description = "Description"; - out.profile_fieldSaved = 'Nouvelle valeur enregistrée : {0}'; - - out.profile_inviteButton = "Inviter"; - out.profile_inviteButtonTitle = 'Créer un lien pour inviter cet utilisateur à se connecter avec vous.'; - out.profile_inviteExplanation = "Cliquer sur OK créera un lien vers une session de messagerie sécurisée uniquement accessible par {0}.

    Le lien peut être copié et partagé de manière publique."; - out.profile_viewMyProfile = "Voir mon profil"; - - // contacts/userlist - out.userlist_addAsFriendTitle = 'Ajouter « {0} » comme contact'; - out.userlist_thisIsYou = 'Vous (« {0} »)'; - out.userlist_pending = "En attente..."; - out.contacts_title = "Contacts"; - out.contacts_addError = "Erreur lors de l'ajout de ce contact dans votre liste"; - out.contacts_added = 'Invitation de contact acceptée'; - out.contacts_rejected = 'Invitation de contact rejetée'; - out.contacts_request = '{0} souhaite vous ajouter en tant que contact. Accepter ?'; - out.contacts_send = 'Envoyer'; - out.contacts_remove = 'Supprimer ce contact'; - out.contacts_confirmRemove = 'Êtes-vous sûr de vouloir supprimer {0} de vos contacts ?'; - out.contacts_typeHere = "Entrez un message ici..."; - out.contacts_warning = "Tout ce que vous tapez ici est permanent et visible par tous les utilisateurs actuels et futurs de ce pad. Soyez prudent avec vos données confidentielles !"; - out.contacts_padTitle = "Chat"; - - out.contacts_info1 = "Voici vos contacts. Ici, vous pouvez :"; - out.contacts_info2 = "Cliquer sur le nom d'un contact pour discuter avec lui"; - out.contacts_info3 = "Double-cliquer sur son nom pour voir son profil"; - out.contacts_info4 = "Chaque participant peut nettoyer définitivement l'historique d'une discussion"; - - out.contacts_removeHistoryTitle = "Supprimer l'historique du chat"; - out.contacts_confirmRemoveHistory = 'Êtes-vous sûr de vouloir supprimer définitivement l\'historique de votre chat ? Les messages ne pourront pas être restaurés.'; - out.contacts_removeHistoryServerError = 'Une erreur est survenue lors de la supprimer de l\'historique du chat. Veuillez réessayer plus tard.'; - out.contacts_fetchHistory = "Récupérer l'historique plus ancien"; - - out.contacts_friends = "Amis"; - out.contacts_rooms = "Salons"; - out.contacts_leaveRoom = "Quitter ce salon"; - - out.contacts_online = "Un autre utilisateur est en ligne dans ce salon"; - - // File manager - - out.fm_rootName = "Documents"; - out.fm_trashName = "Corbeille"; - out.fm_unsortedName = "Fichiers non triés"; - out.fm_filesDataName = "Tous les fichiers"; - out.fm_templateName = "Modèles"; - out.fm_searchName = "Recherche"; - out.fm_recentPadsName = "Pads récents"; - out.fm_ownedPadsName = "Pads en votre possession"; - out.fm_tagsName = "Mots-clés"; - out.fm_sharedFolderName = "Dossier partagé"; - out.fm_searchPlaceholder = "Rechercher..."; - out.fm_newButton = "Nouveau"; - out.fm_newButtonTitle = "Créer un nouveau pad ou un dossier, importer un fichier dans le dossier courant"; - out.fm_newFolder = "Nouveau dossier"; - out.fm_newFile = "Nouveau pad"; - out.fm_folder = "Dossier"; - out.fm_sharedFolder = "Dossier partagé"; - out.fm_folderName = "Nom du dossier"; - out.fm_numberOfFolders = "# de dossiers"; - out.fm_numberOfFiles = "# de fichiers"; - out.fm_fileName = "Nom du fichier"; - out.fm_title = "Titre"; - out.fm_type = "Type"; - out.fm_lastAccess = "Dernier accès"; - out.fm_creation = "Création"; - out.fm_forbidden = "Action interdite"; - out.fm_originalPath = "Chemin d'origine"; - out.fm_openParent = "Montrer dans le dossier"; - out.fm_noname = "Document sans titre"; - out.fm_emptyTrashDialog = "Êtes-vous sûr de vouloir vider la corbeille ?"; - out.fm_removeSeveralPermanentlyDialog = "Êtes-vous sûr de vouloir supprimer ces {0} éléments de votre CryptDrive de manière permanente ?"; - out.fm_removePermanentlyNote = "Les pads dont vous êtes le propriétaire seront supprimés du serveur."; - out.fm_removePermanentlyDialog = "Êtes-vous sûr de vouloir supprimer cet élément de votre CryptDrive de manière permanente ?"; - out.fm_deleteOwnedPad = "Êtes-vous sûr de vouloir supprimer définitivement ce pad du serveur ?"; - out.fm_deleteOwnedPads = "Êtes-vous sûr de vouloir supprimer définitivement ces pads du serveur ?"; - out.fm_restoreDialog = "Êtes-vous sûr de vouloir restaurer {0} à son emplacement précédent ?"; - out.fm_removeSeveralDialog = "Êtes-vous sûr de vouloir déplacer ces {0} éléments vers la corbeille ?"; - out.fm_removeDialog = "Êtes-vous sûr de vouloir déplacer {0} vers la corbeille ?"; - out.fm_unknownFolderError = "Le dossier sélectionné ou le dernier dossier visité n'existe plus. Ouverture du dossier parent..."; - out.fm_contextMenuError = "Impossible d'ouvrir le menu contextuel pour cet élément. Si le problème persiste, essayez de rechercher la page."; - out.fm_selectError = "Impossible de sélectionner l'élément ciblé. Si le problème persiste, essayez de recharger la page."; - out.fm_categoryError = "Impossible d'afficher la catégorie sélectionnée, affichage de Documents"; - out.fm_info_root = "Créez ici autant de dossiers que vous le souhaitez pour trier vos fichiers."; - out.fm_info_unsorted = 'Contient tous les pads que vous avez ouvert et qui ne sont pas triés dans "Documents" ou déplacés vers la "Corbeille".'; // "My Documents" should match with the "out.fm_rootName" key, and "Trash" with "out.fm_trashName" - out.fm_info_template = "Contient tous les fichiers que vous avez sauvés en tant que modèle afin de les réutiliser lors de la création d'un nouveau pad."; - out.fm_info_recent = "Liste les derniers pads que vous avez modifiés ou ouverts."; - out.updated_0_fm_info_trash = "Vider la corbeille permet de libérer de l'espace dans votre CryptDrive"; - out.fm_info_trash = out.updated_0_fm_info_trash; - out.fm_info_allFiles = 'Contient tous les fichiers de "Documents", "Fichiers non triés" et "Corbeille". Vous ne pouvez pas supprimer ou déplacer des fichiers depuis cet endroit.'; // Same here - out.fm_info_anonymous = 'Vous n\'êtes pas connecté, ces pads seront donc supprimés après 3 mois d\'inactivité (découvrez pourquoi). ' + - 'Ils sont stockés dans votre navigateur donc nettoyer votre historique peut les faire disparaître.
    ' + - 'Inscrivez-vous ou connectez-vous pour les maintenir en vie.'; - out.fm_info_sharedFolder = "Voici le contenu d'un dossier partagé. Il n'est accessible qu'en lecture seule car vous n'êtes pas connecté.
    " + - 'Inscrivez-vous ou connectez-vous pour pouvoir l\'importer dans votre CryptDrive et le modifier.'; - out.fm_info_owned = "Vous êtes propriétaire des pads affichés dans cette catégorie. Cela signifie que vous pouvez choisir de les supprimer définitivement du serveur à n'importe quel moment. Ils seront alors inaccessibles pour tous les autres utilisateurs."; - out.fm_alert_backupUrl = "Lien de secours pour ce CryptDrive.
    " + - "Il est fortement recommandé de garder ce lien pour vous-même.
    " + - "Il vous servira en cas de perte des données de votre navigateur afin de retrouver vos fichiers.
    " + - "Quiconque se trouve en possession de celui-ci peut modifier ou supprimer tous les fichiers de ce gestionnaire.
    "; - out.fm_alert_anonymous = "Bonjour ! Vous utilisez actuellement CryptPad de manière anonyme, ce qui ne pose pas de problème mais vos pads peuvent être supprimés après un certain temps " + - "d'inactivité. Nous avons désactivé certaines fonctionnalités avancées de CryptDrive pour les utilisateurs anonymes afin de rendre clair le fait que ce n'est pas " + - 'un endroit sûr pour le stockage des documents. Vous pouvez en lire plus concernant ' + - 'nos raisons pour ces changements et pourquoi vous devriez vraiment vous enregistrer et vous connecter.'; - out.fm_backup_title = 'Lien de secours'; - out.fm_nameFile = 'Comment souhaitez-vous nommer ce fichier ?'; - out.fm_error_cantPin = "Erreur interne du serveur. Veuillez recharger la page et essayer de nouveau."; - out.fm_viewListButton = "Liste"; - out.fm_viewGridButton = "Grille"; - out.fm_renamedPad = "Vous avez renommé ce pad dans votre Drive. Son titre est:
    {0}"; - out.fm_canBeShared = "Ce dossier peut être partagé"; - out.fm_prop_tagsList = "Mots-clés"; - out.fm_burnThisDriveButton = "Effacer toutes les informations stockées par CryptPad dans votre navigateur"; - out.fm_burnThisDrive = "Êtes-vous sûr de vouloir supprimer tout ce qui est stocké par CryptPad dans votre navigateur ?
    " + - "Cette action supprimera votre CryptDrive et son historique de votre navigateur, mais les pads existeront toujours (de manière chiffrée) sur notre serveur."; - out.fm_padIsOwned = "Vous êtes le propriétaire de ce pad"; - out.fm_padIsOwnedOther = "Ce pad est la propriété d'un autre utilisateur"; - out.fm_deletedPads = "Ces pads n'existent plus sur le serveur, ils ont été supprimés de votre CryptDrive: {0}"; - out.fm_tags_name = "Mot-clé"; - out.fm_tags_used = "Nombre d'utilisations"; - out.fm_restoreDrive = "Restauration de votre CryptDrive à une version antérieure. Pour de meilleurs résultats, veuillez éviter de modifier votre CryptDrive avant que cette restauration ne soit terminée."; - out.fm_moveNestedSF = "Vous ne pouvez pas placer un dossier partagé dans un autre. Le dossier {0} n'a pas été déplacé."; - // File - Context menu - out.fc_newfolder = "Nouveau dossier"; - out.fc_newsharedfolder = "Nouveau dossier partagé"; - out.fc_rename = "Renommer"; - out.fc_open = "Ouvrir"; - out.fc_open_ro = "Ouvrir (lecture seule)"; - out.fc_delete = "Déplacer vers la corbeille"; - out.fc_delete_owned = "Supprimer du serveur"; - out.fc_restore = "Restaurer"; - out.fc_remove = "Supprimer de votre CryptDrive"; - out.fc_remove_sharedfolder = "Supprimer"; - out.fc_empty = "Vider la corbeille"; - out.fc_prop = "Propriétés"; - out.fc_hashtag = "Mots-clés"; - out.fc_sizeInKilobytes = "Taille en kilo-octets"; - // fileObject.js (logs) - out.fo_moveUnsortedError = "La liste des modèles ne peut pas contenir de dossiers."; - out.fo_existingNameError = "Ce nom est déjà utilisé dans ce répertoire. Veuillez en choisir un autre."; - out.fo_moveFolderToChildError = "Vous ne pouvez pas déplacer un dossier dans un de ses descendants"; - out.fo_unableToRestore = "Impossible de restaurer ce fichier à son emplacement d'origine. Vous pouvez essayer de le déplacer à un nouvel emplacement."; - out.fo_unavailableName = "Un fichier ou dossier avec le même nom existe déjà au nouvel emplacement. Renommez cet élément avant d'essayer à nouveau."; - - out.fs_migration = "Votre CryptDrive est en train d'être mis à jour vers une nouvelle version. Cela implique que cette page doive être rechargée.
    Veuillez recharger la page pour pouvoir continuer à l'utiliser."; - - // login - out.login_login = "Connexion"; - out.login_makeAPad = 'Créer un pad anonymement'; - out.login_nologin = "Voir les pads récents"; - out.login_register = "Inscription"; - out.logoutButton = "Déconnexion"; - out.settingsButton = "Préférences"; - - out.login_username = "Nom d'utilisateur"; - out.login_password = "Mot de passe"; - out.login_confirm = "Confirmer votre mot de passe"; - out.login_remember = "Se souvenir de moi"; - - out.login_hashing = "Traitement de vos identifiants, cela peut nécessiter quelques instants."; - - out.login_hello = 'Bonjour {0},'; // {0} is the username - out.login_helloNoName = 'Bonjour,'; - out.login_accessDrive = 'Accédez à votre drive'; - out.login_orNoLogin = 'ou'; - - out.login_noSuchUser = "Nom d'utilisateur ou mot de passe invalide. Veuillez vous inscrire ou réessayer."; - out.login_invalUser = "Nom d'utilisateur requis"; - out.login_invalPass = 'Mot de passe requis'; - out.login_unhandledError = "Une erreur inattendue s'est produite :("; - - out.register_importRecent = "Importer les pads de votre session anonyme"; - out.register_acceptTerms = "J'accepte les conditions d'utilisation"; - out.register_passwordsDontMatch = "Les mots de passe doivent être identiques!"; - out.register_passwordTooShort = "Les mots de passe doivent contenir au moins {0} caractères."; - - out.register_mustAcceptTerms = "Vous devez accepter les conditions d'utilisation."; - out.register_mustRememberPass = "Nous ne pouvons pas réinitialiser votre mot de passe si vous l'oubliez. C'est important que vous vous en souveniez! Veuillez cocher la case pour confirmer."; - out.register_writtenPassword = "J'ai bien noté mon nom d'utilisateur et mon mot de passe, continuer"; - out.register_cancel = "Retour"; - out.register_warning = "Zero Knowledge signifie que nous ne pouvons pas récupérer vos données si vous perdez vos identifiants."; - out.register_alreadyRegistered = "Cet utilisateur existe déjà, souhaitez-vous vous connecter ?"; - - out.register_whyRegister = "Pourquoi s'inscrire ?"; - out.register_header = "Bienvenue dans CryptPad"; - out.register_explanation = [ - "

    Faisons d'abord le point sur certaines choses

    ", - "
      ", - "
    • Votre mot de passe est la clé secrète de tous vos pads. Si vous le perdez, il n'y a aucun moyen de récupérer vos données.
    • ", - "
    • Vous pouvez importer les pads récents de ce navigateur pour les avoir dans votre compte utilisateur.
    • ", - "
    • Si vous utilisez un ordinateur partagé, vous devez vous déconnecter avant de partir, fermer l'onglet n'est pas suffisant.
    • ", - "
    " - ].join(''); - - // Settings - out.settings_cat_account = "Compte"; - out.settings_cat_drive = "CryptDrive"; - out.settings_cat_cursor = "Curseur"; - out.settings_cat_code = "Code"; - out.settings_cat_pad = "Documents texte"; - out.settings_cat_creation = "Nouveau pad"; - out.settings_cat_subscription = "Abonnement"; - out.settings_title = "Préférences"; - out.settings_save = "Sauver"; - - out.settings_backupCategory = "Sauvegarde"; - out.settings_backupHint = "Créer ou restaurer une sauvegarde de votre CryptDrive. Cette sauvegarde ne contient pas le contenu de vos pads mais uniquement les clés qui permettent d'y accéder."; - out.settings_backup = "Sauvegarder"; - out.settings_restore = "Restaurer"; - - out.settings_backupHint2 = "Télécharger le contenu actuel de tous vos pads. Ceux-ci seront téléchargés dans un format lisible si un tel format est disponible."; - out.settings_backup2 = "Télécharger mon CryptDrive"; - out.settings_backup2Confirm = "Vous allez télécharger tous les pads de votre CryptDrive. Si vous souhaitez continuer, choisissez un nom et appuyez sur OK."; - out.settings_exportTitle = "Téléchargement de votre CryptDrive"; - out.settings_exportDescription = "Veuillez patienter pendant que nous téléchargeons et déchiffrons vos documents. Cette opération peut prendre plusieurs minutes. Fermer l'onglet du navigateur interrompra le processus."; - out.settings_exportFailed = "Si un pad nécessite plus d'une minute pour être traité, il ne sera pas inclus dans l'archive. Une liste des pads n'ayant pas été exportés sera disponible à la fin."; - out.settings_exportWarning = "Note: cet outil est encore un prototype et peut rencontrer des difficultés lors de l'export. Pour de meilleures performances, il est recommandé de ne pas changer d'onglet pendant le téléchargement."; - out.settings_exportCancel = "Êtes-vous sûr de vouloir annuler ce téléchargement ? Vous devrez recommencer du début la prochaine fois."; - out.settings_export_reading = "Lecture de votre CryptDrive..."; - out.settings_export_download = "Téléchargement et déchiffrement des documents..."; - out.settings_export_compressing = "Compression des données..."; - out.settings_export_done = "Votre téléchargement est prêt !"; - out.settings_exportError = "Voir les erreurs"; - out.settings_exportErrorDescription = "Nous n'avons pas réussi à ajouter les documents suivant dans le téléchargement :"; - out.settings_exportErrorEmpty = "Ce document ne peut pas être exporté (document vide ou contenu invalide)"; - out.settings_exportErrorMissing = "Ce document n'est plus stocké sur nos serveurs (expiré ou supprimé par son propriétaire)"; - out.settings_exportErrorOther = "Une erreur est survenue lors de la récupération de ce document : {0}"; - - out.settings_resetNewTitle = "Vider CryptDrive"; - out.settings_resetButton = "Supprimer"; - out.settings_reset = "Supprimer tous les fichiers et dossiers de votre CryptDrive"; - out.settings_resetPrompt = "Cette action va supprimer tous les pads de votre drive.
    "+ - "Êtes-vous sûr de vouloir continuer ?
    " + - "Tapez « I love CryptPad » pour confirmer."; - out.settings_resetDone = "Votre drive est désormais vide!"; - out.settings_resetError = "Texte de vérification incorrect. Votre CryptDrive n'a pas été modifié."; - - out.settings_resetTipsAction ="Réinitialiser"; - out.settings_resetTips = "Astuces"; - out.settings_resetTipsButton = "Réinitialiser les astuces visibles dans CryptDrive"; - out.settings_resetTipsDone = "Toutes les astuces sont de nouveau visibles."; - - out.settings_thumbnails = "Miniatures"; - out.settings_disableThumbnailsAction = "Désactiver la création de miniatures dans CryptDrive"; - out.settings_disableThumbnailsDescription = "Des miniatures de vos pads sont automatiquement créées et stockées dans votre navigateur. Vous pouvez désactiver cette fonctionnalité."; - out.settings_resetThumbnailsAction = "Nettoyer"; - out.settings_resetThumbnailsDescription = "Nettoyer toutes les miniatures stockées dans votre navigateur."; - out.settings_resetThumbnailsDone = "Toutes les miniatures ont été effacées."; - - out.settings_importTitle = "Importer les pads récents de ce navigateur dans votre CryptDrive"; - out.settings_import = "Importer"; - out.settings_importConfirm = "Êtes-vous sûr de vouloir importer les pads récents de ce navigateur dans le CryptDrive de votre compte utilisateur ?"; - out.settings_importDone = "Importation terminée"; - - out.settings_autostoreTitle = "Stockage des pads dans CryptDrive"; - out.settings_autostoreHint = "Le stockage Automatique des pads permet de sauver tous les pads que vous visitez dans votre CryptDrive, sans action de votre part.
    " + - "Le stockage Manuel (toujours demander) permet de ne pas stocker automatiquement les pads, mais d'afficher un message vous demandant s'il faut le faire ou non.
    " + - "Le stockage Manuel (ne pas demander) permet de ne pas stocker les pads ni d'afficher le message. Une option permettant de les stocker sera toujours disponible, mais cachée."; - out.settings_autostoreYes = "Automatique"; - out.settings_autostoreNo = "Manuel (ne pas demander)"; - out.settings_autostoreMaybe = "Manuel (toujours demander)"; - - out.settings_userFeedbackTitle = "Retour d'expérience"; - out.settings_userFeedbackHint1 = "CryptPad peut envoyer des retours d'expérience très limités vers le serveur, de manière à nous permettre d'améliorer l'expérience des utilisateurs. "; - out.settings_userFeedbackHint2 = "Le contenu de vos pads et les clés de déchiffrement ne seront jamais partagés avec le serveur."; - out.settings_userFeedback = "Activer l'envoi de retours d'expérience"; - - out.settings_deleteTitle = "Suppression du compte"; - out.settings_deleteHint = "La suppression de votre compte utilisateur est permanente. Votre CryptDrive et votre liste de pads seront supprimés du serveur. Le reste de vos pads sera supprimé après 90 jours d'inactivité si personne ne les a stockés dans leur CryptDrive."; - out.settings_deleteButton = "Supprimer votre compte"; - out.settings_deleteModal = "Veuillez envoyer les informations suivantes à votre administrateur CryptPad afin que vos données soient supprimées du serveur."; - out.settings_deleteConfirm = "Êtes-vous sûr de vouloir supprimer votre compte utilisateur ? Cette action est irréversible."; - out.settings_deleted = "Votre compte utilisateur a été supprimé. Appuyez sur OK pour être redirigé(e) vers la page d'accueil."; - - out.settings_anonymous = "Vous n'êtes pas connecté. Ces préférences seront utilisées pour ce navigateur."; - out.settings_publicSigningKey = "Clé publique de signature"; - - out.settings_usage = "Utilisation"; - out.settings_usageTitle = "Voir la taille totale de vos pads épinglés en Mo"; - out.settings_pinningNotAvailable = "Les pads épinglés sont disponibles uniquement pour les utilisateurs enregistrés."; - out.settings_pinningError = "Un problème est survenu"; - out.settings_usageAmount = "Vos pads épinglés occupent {0} Mo"; - - out.settings_logoutEverywhereButton = "Se déconnecter"; - out.settings_logoutEverywhereTitle = "Se déconnecter partout"; - out.settings_logoutEverywhere = "Se déconnecter de force de toutes les autres sessions."; - out.settings_logoutEverywhereConfirm = "Êtes-vous sûr ? Vous devrez vous reconnecter sur tous vos autres appareils."; - - out.settings_driveDuplicateTitle = "Doublons des pads dont vous êtes propriétaire"; - out.settings_driveDuplicateHint = "Quand vous déplacez un pad dont vous êtes le propriétaire dans un dossier partagé, une copie est créée dans votre CryptDrive pour s'assurer que vous puissiez garder le contrôle de ce pad. Vous pouvez choisir de cacher ces doublons. Seules les versions partagées seront affichées, jusqu'à leur suppression, dans quels cas la version dans votre CryptDrive redeviendra visible."; - out.settings_driveDuplicateLabel = "Cacher les doublons"; - - out.settings_codeIndentation = "Indentation dans l'éditeur de code (nombre d'espaces)"; - out.settings_codeUseTabs = "Utiliser des tabulations au lieu d'espaces"; - out.settings_codeFontSize = "Taille de la police dans l'éditeur de code (px)"; - - out.settings_padWidth = "Largeur de l'éditeur de texte"; - out.settings_padWidthHint = "L'éditeur de documents texte occupe toute la largeur de l'écran disponible par défaut, ce qui peut rendre le texte difficile à lire. Vous pouvez ici réduire la largeur de l'éditeur."; - out.settings_padWidthLabel = "Réduire la largeur de l'éditeur"; - out.settings_padSpellcheckTitle = "Vérification orthographique"; - out.settings_padSpellcheckHint = "Cette option vous permet d'activer la vérification orthographique dans l'éditeur de Texte. Les fautes seront soulignées et des propositions correctes seront disponibles en effectuant un clic-droit avec la touche Ctrl ou Meta enfoncée."; - out.settings_padSpellcheckLabel = "Activer la vérification orthographique"; - - out.settings_creationSkip = "Passer l'écran de création de pad"; - out.settings_creationSkipHint = "L'écran de création de pad offre de nouvelles options pour créer un pad, permettant d'avoir plus de contrôle et de sécurité concernant vos données. Toutefois, il peut ralentir votre travail en ajoutant une étape supplémentaire et donc, ici, vous avez la possibilité de choisir de passer cet écran et d'utiliser les paramètres par défaut choisis au-dessus."; - out.settings_creationSkipTrue = "Passer"; - out.settings_creationSkipFalse = "Afficher"; - - out.settings_templateSkip = "Passer la fenêtre de choix d'un modèle"; - out.settings_templateSkipHint = "Quand vous créez un nouveau pad, et si vous possédez des modèles pour ce type de pad, une fenêtre peut apparaître pour demander si vous souhaitez importer un modèle. Ici vous pouvez choisir de ne jamais montrer cette fenêtre et donc de ne jamais utiliser de modèle."; - - out.settings_ownDriveTitle = "Activer les dernières fonctionnalités du compte"; - out.settings_ownDriveHint = "Pour des raisons techniques, les comptes utilisateurs les plus anciens n'ont pas accès à toutes les fonctionnalités. Une mise à niveau gratuite permet de préparer votre CryptDrive pour les nouveautés à venir sans perturber vos activités habituelles."; - out.settings_ownDriveButton = "Mettre à niveau votre compte"; - out.settings_ownDriveConfirm = "La mise à niveau peut prendre du temps. Vous devrez vous reconnecter sur tous vos appareils. Voulez-vous continuer?"; - out.settings_ownDrivePending = "Votre compte est en train d'être mis à jour. Veuillez ne pas fermer ou recharger cette page avant que le traitement soit terminé."; - - out.settings_changePasswordTitle = "Changer de mot de passe"; - out.settings_changePasswordHint = "Pour modifier le mot de passe de votre compte utilisateur, entrez votre mot de passe actuel et confirmez le nouveau mot de passe en la tapant deux fois.
    " + - "Nous ne pouvons pas réinitialiser votre mot de passe si vous le perdez, donc soyez très prudent !"; - out.settings_changePasswordButton = "Changer le mot de passe"; - out.settings_changePasswordCurrent = "Mot de passe actuel"; - out.settings_changePasswordNew = "Nouveau mot de passe"; - out.settings_changePasswordNewConfirm = "Confirmer le nouveau mot de passe"; - out.settings_changePasswordConfirm = "Êtes-vous sûr de vouloir changer votre mot de passe ? Vous devrez vous reconnecter sur tous vos appareils."; - out.settings_changePasswordError = "Une erreur est survenue. Si vous n'êtes plus en mesure de vous connecter à votre compte utilisateur ou de changer votre mot de passe, veuillez contacter l'administrateur de votre CryptPad."; - out.settings_changePasswordPending = "Votre mot de passe est en train d'être modifié. Veuillez ne pas fermer ou recharger cette page avant que le traitement soit terminé."; - out.settings_changePasswordNewPasswordSameAsOld = "Votre nouveau mot de passe doit être différent de votre mot de passe actuel."; - - out.settings_cursorColorTitle = "Couleur du curseur"; - out.settings_cursorColorHint = "Changer la couleur associée à votre utilisateur dans les documents collaboratifs"; - out.settings_cursorShareTitle = "Partager la position de mon curseur"; - out.settings_cursorShareHint = "Vous pouvez décider si vous souhaitez que les autres puissent voir la position de votre curseur dans les documents collaboratifs ou non."; - out.settings_cursorShareLabel = "Partager la position"; - out.settings_cursorShowTitle = "Afficher les curseurs des autres utilisateurs"; - out.settings_cursorShowHint = "Vous pouvez choisir si vous souhaitez voir les curseurs des autres utilisateurs dans les documents collaboratifs ou non."; - out.settings_cursorShowLabel = "Montrer les curseurs"; - - out.upload_title = "Hébergement de fichiers"; - out.upload_type = "Type"; - out.upload_modal_title = "Options d'importation du fichier"; - out.upload_modal_filename = "Nom (extension {0} ajoutée automatiquement)"; - out.upload_modal_owner = "Être propriétaire du fichier"; - out.upload_serverError = "Erreur interne: impossible d'importer le fichier pour l'instant."; - out.upload_uploadPending = "Vous avez déjà un fichier en cours d'importation. Souhaitez-vous l'annuler et importer ce nouveau fichier ?"; - out.upload_success = "Votre fichier ({0}) a été importé avec succès et ajouté à votre CryptDrive."; - out.upload_notEnoughSpace = "Il n'y a pas assez d'espace libre dans votre CryptDrive pour ce fichier."; - out.upload_notEnoughSpaceBrief = "Pas assez d'espace"; - out.upload_tooLarge = "Ce fichier dépasse la taille maximale autorisée."; - out.upload_tooLargeBrief = 'Fichier trop volumineux'; - out.upload_choose = "Choisir un fichier"; - out.upload_pending = "En attente"; - out.upload_cancelled = "Annulé"; - out.upload_name = "Nom du fichier"; - out.upload_size = "Taille"; - out.upload_progress = "État"; - out.upload_mustLogin = "Vous devez vous connecter pour importer un fichier"; - out.upload_up = "Envoyer"; - out.download_button = "Déchiffrer et télécharger"; - out.download_mt_button = "Télécharger"; - out.download_resourceNotAvailable = "Le fichier demandé n'est pas disponible... Appuyez sur Échap pour continuer."; - out.download_dl = "Télécharger"; - out.download_step1 = "Téléchargement"; - out.download_step2 = "Déchiffrement"; - - out.todo_title = "CryptTodo"; - out.todo_newTodoNamePlaceholder = "Décrivez votre tâche..."; - out.todo_newTodoNameTitle = "Ajouter cette tâche à votre liste"; - out.todo_markAsCompleteTitle = "Marquer cette tâche comme terminée"; - out.todo_markAsIncompleteTitle = "Marquer cette tâche comme incomplète"; - out.todo_removeTaskTitle = "Enlever cette tâche de votre liste"; - - // pad - out.pad_showToolbar = "Afficher la barre d'outils"; - out.pad_hideToolbar = "Cacher la barre d'outils"; - out.pad_base64 = "Ce pad contient des images stockées de manière inefficace. Ces images vont augmenter de manière significative la taille du pad dans votre CryptDrive, et le rendre plus lent à charger. Vous pouvez migrer ces fichiers afin de les stocker séparément dans votre CryptDrive. Voulez-vous commencer la migration maintenant?"; - - // markdown toolbar - out.mdToolbar_button = "Afficher ou cacher la barre d'outils Markdown"; - out.mdToolbar_defaultText = "Votre texte ici"; - out.mdToolbar_help = "Aide"; - out.mdToolbar_tutorial = "https://blog.wax-o.com/2014/04/tutoriel-un-guide-pour-bien-commencer-avec-markdown/"; - out.mdToolbar_bold = "Gras"; - out.mdToolbar_italic = "Italique"; - out.mdToolbar_strikethrough = "Barré"; - out.mdToolbar_heading = "Titre"; - out.mdToolbar_link = "Lien"; - out.mdToolbar_quote = "Citation"; - out.mdToolbar_nlist = "Liste ordonnée"; - out.mdToolbar_list = "Liste à puces"; - out.mdToolbar_check = "Liste de tâches"; - out.mdToolbar_code = "Code"; - - // index.html - - out.home_product = "CryptPad est une alternative respectant la vie privée aux outils office et aux services cloud populaires. Tout le contenu stocké dans CryptPad est chiffré avant d'être envoyé, ce qui signifie que personne ne peut accéder à vos données à moins que vous ne leur donniez les clés (même pas nous)."; - out.home_host = "Ceci est une instance communautaire et indépendante de CryptPad. Le code source du projet est disponible sur GitHub."; - out.home_host_agpl = "CryptPad est distribué sous les termes de la licence logicielle AGPL3"; - out.home_ngi = "Gagnant d'un prix NGI Awards"; - - //about.html - out.about_intro = 'CryptPad est développé au sein de l\'équipe Recherche d\'XWiki SAS, une petite entreprise située à Paris en France et à Iasi en Roumanie. Il y a 3 développeurs principaux qui travaillent sur CryptPad, ainsi que quelques contributeurs à la fois dans et en dehors d\'XWiki SAS'; - out.about_core = 'Développeurs principaux'; - out.about_contributors = 'Contributeurs clés'; - - //contact.html - out.main_about_p22 = 'Tweetez-nous'; - out.main_about_p23 = 'Ouvrez un ticket (GitHub)'; - out.main_about_p24 = 'Dites Bonjour (Matrix)'; - out.main_about_p25 = 'Envoyez-nous un email'; - out.main_about_p26 = 'Si vous avez une question ou des remarques, n\'hésitez pas à nous contacter !'; - - out.main_info = "

    Collaborez avec confiance


    Développez vos idées en groupe avec des documents partagés; la technologie Zero Knowledge sécurise vos données."; - out.main_catch_phrase = "Le Cloud Zero Knowledge"; - - out.main_richText = 'Éditeur de texte'; - out.main_code = 'Éditeur de code'; - out.main_slide = 'Présentations'; - out.main_poll = 'Sondages'; - out.main_drive = 'CryptDrive'; - - out.main_richTextPad = 'Éditeur de texte'; - out.main_codePad = 'Éditeur de code'; - out.main_sheetPad = 'Tableur (Beta)'; - out.main_slidePad = 'Éditeur de Présentations'; - out.main_pollPad = 'Sondage ou Planning'; - out.main_whiteboardPad = 'Tableau blanc'; - out.main_kanbanPad = 'Kanban'; - out.main_localPads = 'Pads Locaux'; - out.main_yourCryptDrive = 'Votre CryptDrive'; - out.main_footerText = "Avec CryptPad, vous pouvez créer des documents collaboratifs rapidement pour prendre des notes à plusieurs."; - - out.footer_applications = "Applications"; - out.footer_contact = "Contact"; - out.footer_aboutUs = "À propos"; - - out.about = "À propos"; - out.privacy = "Confidentialité"; - out.contact = "Contact"; - out.terms = "Conditions"; - out.blog = "Blog"; - - out.topbar_whatIsCryptpad = "Qu'est-ce que CryptPad"; - - // what-is-cryptpad.html - - out.whatis_title = "Qu'est-ce que CryptPad"; - out.whatis_collaboration = 'Collaboration rapide, facile'; - out.whatis_collaboration_p1 = "Avec CryptPad, vous pouvez créer rapidement des documents collaboratifs pour prendre des notes à plusieurs. Quand vous vous enregistrez et vous vous connectez, vous obtenez la possibilité d'importer des fichiers dans un CryptDrive où vous pouvez organiser tous vos pads (documents). En tant qu'utilisateur enregistré, vous possédez 50 Mo de stockage gratuit."; - out.whatis_collaboration_p2 = "Vous pouvez partager l'accès à un document simplement en partageant le lien. Vous pouvez aussi partager un lien spécial fournissant un accès en lecture seule au pad, permettant de publier des travaux collaboratifs tout en restant maître de l'édition."; - out.whatis_collaboration_p3 = "Vous pouvez créer des documents de texte avec CKEditor tout comme des documents Markdown qui sont rendus en temps-réel pendant que vous tapez. Vous pouvez aussi utiliser l'application de sondage pour planifier des évènements avec plusieurs participants."; - out.whatis_zeroknowledge = 'Zero Knowledge'; - out.whatis_zeroknowledge_p1 = "Nous ne souhaitons pas connaître ce que vous tapez et grâce à la cryptographie moderne, vous pouvez être assuré que nous ne le pouvons pas. CryptPad utilise un chiffrement à 100 % côté client pour protéger le contenu que vous tapez de nous, les personnes contrôlant le serveur."; - out.whatis_zeroknowledge_p2 = "Quand vous vous enregistrez et vous vous connectez, votre nom d'utilisateur et votre mot de passe sont transformés en une clé secrète grâce à la fonction de dérivation de clé Scrypt. Ni cette clé, ni le nom d'utilisateur ou le mot de passe, ne sont envoyés au serveur. À la place, elle est utilisée côté client pour chiffrer et déchiffrer le contenu de votre CryptDrive, qui contient toutes les clés permettant d'accéder à vos pads."; - out.whatis_zeroknowledge_p3 = "Quand vous partagez le lien vers un document, vous partagez la clé cryptographique permettant de déchiffrer le document, mais puisque cette clé se trouve dans l'identificateur de fragment, elle n'est jamais envoyée au serveur. Venez lire notre article de blog sur la vie privée pour en apprendre davantage sur le type de métadonnées auxquelles nous avons ou n'avons pas accès."; - out.whatis_drive = "Organisation avec CryptDrive"; - out.whatis_drive_p1 = "Dès que vous accédez à un pad dans CryptPad, celui-ci est automatiquement ajouté à votre CryptDrive, dans le dossier principal. Vous pouvez alors ranger ce pad dans un dossier ou le déplacer vers la corbeille. CryptDrive vous permet de rechercher parmi vos pads et de les organiser quand vous le souhaitez, comme vous le souhaitez."; - out.whatis_drive_p2 = "Avec le glisser-déposer intuitif, vous pouvez déplacer vos pads dans votre drive tout en conservant les liens vers ces pads pour que vos collaborateurs n'en perdent pas l'accès"; - out.whatis_drive_p3 = "Vous pouvez également importer des fichiers dans votre CryptDrive et les partager avec des collègues. Les fichiers importés peuvent être rangés de la même manière que vos pads collaboratifs."; - out.whatis_business = 'CryptPad for Business'; - out.whatis_business_p1 = "Le chiffrement Zero Knowledge de CryptPad excelle pour accroître l'efficacité des protocoles de sécurité existants en les recréant de manière cryptographique. Puisque les données sensibles ne peuvent être déchiffrées qu'en utilisant les identifiants d'un utilisateur, CryptPad empêche d'éventuels hackers ayant réussi à s'introduire dans le serveur d'avoir accès en clair à ces données. Découvrez-en plus sur la manière dont CryptPad peut aider votre entreprise en lisant le CryptPad Whitepaper."; - out.whatis_business_p2 = "CryptPad est déployable sur site et les développeurs CryptPad chez XWiki SAS peuvent effectuer du développement, des personnalisations et du support commercial. Contactez-nous à sales@cryptpad.fr pour plus d'informations."; - - // privacy.html - - out.policy_title = 'Politique de confidentialité de CryptPad'; - out.policy_whatweknow = 'Ce que nous savons de vous'; - out.policy_whatweknow_p1 = 'En tant qu\'application hébergée sur le web, CryptPad a accès aux meta-données exposées par le protocole HTTP. Ceci inclus votre adresse IP et d\'autres en-têtes HTTP qui peuvent être utilisées pour identifier votre propre navigateur. Vous pouvez voir quelles informations votre navigateur partage en visitant WhatIsMyBrowser.com.'; - out.policy_whatweknow_p2 = 'Nous utilisons Piwik, une plateforme open source d\'analytique, afin d\'en apprendre plus sur nos utilisateurs. Piwik nous indique comment vous avez trouvé CryptPad, que ce soit par une entrée directe, par un moteur de recherche ou depuis un lien provenant d\'un autre site web tel que Reddit ou Twitter. Nous savons également quand vous visitez le site, sur quels liens vous cliquez dans les pages informatives et combien de temps vous restez sur une page donnée.'; - out.policy_howweuse = 'Comment nous utilisons ce que nous apprenons'; - out.policy_howweuse_p1 = 'Nous utilisons ces informations pour prendre de meilleures décisions concernant la communication autour de CryptPad, en évaluant le succès de ce qui a été réalisé par le passé. Les informations concernant votre localisation nous permettent de savoir si nous devons considérer l\'ajout de traductions de CryptPad dans d\'autres langues que l\'anglais.'; - out.policy_howweuse_p2 = "Les informations concernant votre navigateur (que ce soit un système d\'exploitation de bureau ou d\'appareil portable) nous aident à prendre des décisions lors de la priorisation des ajouts et améliorations de fonctionnalités. Notre équipe de développement est petite, et nous essayons de prendre des décisions qui amélioreront l\'expérience du plus grand nombre d\'utilisateurs possible."; - out.policy_whatwetell = 'Ce que nous dévoilons à d\'autres à propos de vous'; - out.policy_whatwetell_p1 = 'Nous ne fournissons aucune information que nous récoltons ou que vous nous fournissez à des tierces parties à moins d\'y être contraints par la loi.'; - out.policy_links = 'Liens vers d\'autres sites'; - out.policy_links_p1 = 'Ce site contient des liens vers d\'autres sites, certains étant produits par d\'autres organisations. Nous ne sommes responsables des pratiques de confidentialité ou du contenu d\'aucun site externe. De manière générale, les liens vers des sites externes sont lancés dans une nouvelle fenêtre (ou onglet) du navigateur, pour rendre clair le fait que vous quittez CryptPad.fr.'; - out.policy_ads = 'Publicité'; - out.policy_ads_p1 = 'Nous n\'affichons pas de publicité en ligne, bien que nous puissions afficher des liens vers les sites des organisations qui financent nos recherches.'; - out.policy_choices = 'Vos choix'; - out.policy_choices_open = 'Notre code est open source, ce qui signifie que vous avez toujours la possibilité d\'héberger votre propre instance de CryptPad.'; - out.policy_choices_vpn = 'Si vous souhaitez utiliser notre instance hébergée (cryptpad.fr) mais que vous ne souhaitez pas exposer votre adresse IP, vous pouvez la protéger en utilisant le navigateur Tor, ou un VPN.'; - out.policy_choices_ads = 'Si vous souhaitez uniquement bloquer notre plateforme d\'analytique, vous pouvez utiliser un bloqueur de publicités tel que Privacy Badger.'; - - // features.html - - out.features = "Fonctionnalités"; - out.features_title = "Comparaison des fonctionnalités"; - out.features_feature = "Fonctionnalité"; - out.features_anon = "Utilisateur anonyme"; - out.features_registered = "Utilisateur enregistré"; - out.features_premium = "Utilisateur premium"; - out.features_notes = "Notes"; - - out.features_f_apps = "Accès aux applications principales"; - out.features_f_core = "Fonctions communes des applications"; - out.features_f_core_note = "Édition, Export, Historique, Liste d'utilisateurs, Chat"; - out.features_f_file0 = "Ouvrir des fichiers"; - out.features_f_file0_note = "Voir et télécharger des fichiers partagés par d'autres utilisateurs"; - out.features_f_cryptdrive0 = "Accès limité à CryptDrive"; - out.features_f_cryptdrive0_note = "Stockage dans votre navigateur des pads visités afin de pouvoir les retrouver plus tard."; - out.features_f_storage0 = "Durée de stockage limitée"; - out.features_f_storage0_note = "Les pads créés risquent d'être supprimés après trois mois d'inactivité."; - - out.features_f_anon = "Avantages des utilisateurs anonymes"; - out.features_f_anon_note = "Avec une meilleure ergonomie et plus de contrôle sur vos pads"; - out.features_f_cryptdrive1 = "Accès complet à CryptDrive"; - out.features_f_cryptdrive1_note = "Dossiers, dossiers partagés, modèles, tags"; - out.features_f_devices = "Vos pads sur tous vos appareils"; - out.features_f_devices_note = "Accéder à votre CryptDrive de partout grâce à votre compte utilisateur"; - out.features_f_social = "Applications sociales"; - out.features_f_social_note = "Créer un profil, utiliser un avatar, chat avec les contacts"; - out.features_f_file1 = "Importer et partager des fichiers"; - out.features_f_file1_note = "Partager des fichiers avec vos amis ou les intégrer dans vos pads"; - out.features_f_storage1 = "Stockage permanent (50Mo)"; - out.features_f_storage1_note = "Les pads stockés dans votre CryptDrive ne seront jamais supprimés pour cause d'inactivité."; - out.features_f_register = "S'enregistrer gratuitement"; - out.features_f_register_note = "Pas d'email ou d'information personnelle requis"; - - out.features_f_reg = "Avantages des utilisateurs enregistrés"; - out.features_f_reg_note = "Et aider au développement de CryptPad"; - out.features_f_storage2 = "Espace de stockage supplémentaire"; - out.features_f_storage2_note = "De 5 Go à 50 Go en fonction du plan sélectionné"; - out.features_f_support = "Support plus rapide"; - out.features_f_support_note = "Support email professionnel avec le plan Équipe"; - out.features_f_supporter = "Devenir un défenseur de la vie privée"; - out.features_f_supporter_note = "Nous aider à montrer que les logiciels protégeant les données personnelles devraient être la norme"; - out.features_f_subscribe = "S'abonner à un compte premium"; - out.features_f_subscribe_note = "Vous devez d'abord vous connecter à un compte CryptPad"; - - // faq.html - - out.faq_link = "FAQ"; - out.faq_title = "Foire Aux Questions"; - out.faq_whatis = "Qu'est-ce que CryptPad ?"; - out.faq = {}; - out.faq.keywords = { - title: 'Termes spéciaux', - pad: { - q: "Qu'est-ce qu'un pad ?", - a: 'Pad est un terme popularisé par Etherpad un éditeur collaboratif en temps-réel. ' + - 'Il désigne un document que vous pouvez modifier dans votre navigateur et, en général, vous pouvez voir les modifications effectuées par les autres utilisateurs de manière quasiment instantanée.' - }, - owned: { - q: "Qu'est-ce qu'un pad avec propriétaire ?", - a: "Être propriétaire d'un pad signifie que vous êtes identifié comme tel par le serveur avec à votre clé de signature publique.
    " + - "Le propriétaire d'un pad peut décider de supprimer ce pad du serveur de manière permanente, afin de le rendre inaccessible aux autres collaborateurs même s'ils possèdent le lien dans leur CryptDrive." - }, - expiring: { - q: "Qu'est-ce qu'un pad à durée de vie ?", - a: "Un pad à durée de vie est un pad créé avec une date définie à partir de laquelle il sera supprimé automatiquement du serveur. Ils peuvent être configurés pour avoir une durée de vie comprise entre une heure et cent mois. Le pad et tout son historique sera alors inaccessible, de manière permanente, même s'il est en cours d'édition à sa date d'expiration.
    " + - "Si un pad possède une date d'expiration, vous pouvez la vérifier en regardant les propriétés du pad, soit avec un clic-droit sur le pad dans votre CryptDrive, ou soit en cliquant sur Propriétés dans le sous-menu de la barre d'outils de l'application." - }, - tag: { - q: "Comment utiliser les mots-clés ?", - a: "Vous pouvez ajouter des mots-clés aux pads ou aux fichiers depuis votre CryptDrive et depuis le document en utilisant le bouton (Mots-clés) de la barre d'outils des éditeurs.
    " + - "Il est ensuite possible de rechercher des pads et des fichiers dans votre CryptDrive en tapant un mot-clé, précédé de #, dans la barre de recherche (exemple: #crypto)." - }, - template: { - q: "Qu'est-ce qu'un modèle ?", - a: "Un modèle est un pad qui peut être utilisé pour définir le contenu initial d'un nouveau pad du même type quand vous le créez.
    " + - "Les pads existant dans votre CryptDrive peuvent être transformés en tant que modèle en les déplaçant dans la catégorie Modèles du CryptDrive.
    " + - "Il est également possible de créer une copie d'un pad en tant que modèle en cliquant sur le bouton (Sauver en tant que modèle) dans la barre d'outils des éditeurs." - }, - abandoned: { - q: "Qu'est-ce qu'un pad abandonné?", - a: "Un pad abandonné est un pad qui n'est stocké dans le CryptDrive d'aucun utilisateur enregistré et qui n'a pas été modifié depuis 6 mois. Les documents abandonnés sont automatiquement supprimés du serveur." - }, - }; - out.faq.privacy = { - title: 'Confidentialité', - different: { - q: "Comment CryptPad est-il différent des autres services de pads ?", - a: "CryptPad chiffre les changements effectués dans vos pads avant de les envoyer au serveur pour qu'ils soient stockés, nous ne pouvons donc pas lire le contenu que vous avez tapé." - }, - me: { - q: "Quelles informations le serveur possède-t-il sur moi ?", - a: "Les administrateurs du serveur peuvent voir les adresses IP des utilisateurs de CryptPad.
    " + - "Nous n'enregistrons pas les pads visités par chaque adresse IP, mais nous le pouvons, bien que nous n'aurions pas accès au contenu déchiffré de ces pads.
    " + - "Si vous avez des inquiétudes à ce sujet, il est préférable de considérer que nous collectons ces informations puisque nous n'avons aucun moyen de prouver que ce n'est pas le cas.

    " + - "Nous collectons toutefois certaines données de télémétrie concernant la façon dont les gens utilisent CryptPad, par exemple la résolution de l'écran utilisé ou l'utilisation des boutons de la barre d'outils. Ces données nous aident à améliorer le produit, mais il est possible de désactiver l'envoi de telles informations au serveur en décochant la case Activer l'envoi de retours d'expérience dans vos Préférences.

    " + - "Enfin, nous gardons une trace des pads stockés dans le CryptDrive des utilisateurs afin de pouvoir imposer les limites de stockage, mais nous n'avons, encore une fois, pas accès au contenu ou au type de ces pads. Ces limites sont toutefois associées à la clé publique des utilisateurs, nous ne pouvons donc pas les relier à un nom ou une adresse email.

    " + - "Nous avons écrit un article de blog (en anglais) à ce sujet si vous souhaitez en apprendre davantage." - }, - register: { - q: "Qu'est-ce que le serveur apprend à mon sujet si je m'inscris ?", - a: "Nous ne demandons pas aux utilisateurs d'entrer une adresse email pour s'enregistrer, et le serveur ne connaît pas votre nom d'utilisateur ni votre mot de passe.
    " + - "Les formulaires d'inscription et de connexion génèrent à la place un ensemble de clés uniques, créées à partir de vos identifiants, et le serveur ne connaît donc que votre signature cryptographique.
    " + - "Nous utilisons cette information principalement pour mesurer combien de données vous avez stocké sur nos serveurs, afin de pouvoir limiter chaque utilisateur à son quota.

    " + - "Nous utilisons également notre fonctionnalité de retour d'expérience pour indiquer au serveur que quelqu'un avec votre adresse IP a créé un compte utilisateur, bien que nous ne sachions pas lequel. Cela nous permet de mesurer le nombre d'inscriptions sur CryptPad mais aussi de voir dans quelles régions du monde se trouvent les utilisateurs, afin de déterminer les langues dans lesquelles traduire CryptPad.

    " + - "Enfin, les utilisateurs enregistrés indiquent au serveur quels pads sont dans leur CryptDrive, afin que ces pads ne soient pas considérés comme abandonnés et ne soient donc pas supprimés pour inactivité." - }, - other: { - q: "Que peuvent apprendre les autres collaborateurs à mon sujet ?", - a: "Quand vous éditez un pad avec quelqu'un d'autre, vous communiquez en passant par notre serveur, nous sommes donc les seuls à connaître votre adresse IP.
    " + - "Les autres utilisateurs ont accès à votre pseudonyme, votre avatar, le lien vers votre profil (si vous en avez un) et votre clé publique (qui est utilisée pour le chiffrement des communications entre utilisateurs)." - }, - anonymous: { - q: "CryptPad me rend-il anonyme ?", - a: "Bien que CryptPad soit conçu pour en savoir le moins possible à votre sujet, il ne fournit pas un anonymat complet.
    " + - "Nos serveurs ont accès à votre adresse IP, mais vous pouvez la cacher en utilisant, par exemple, Tor pour accéder à CryptPad.
    " + - "Utiliser Tor sans changer votre comportement ne garantira toutefois pas votre anonymat, puisque notre serveur est en mesure d'identifier des utilisateurs avec leur identifiant cryptographique unique. Si vous utilisez le même compte utilisateur avec et sans Tor, il serait donc possible de désanonymiser votre session.

    " + - "Pour les utilisateurs qui n'ont pas besoin d'un niveau de confidentialité aussi élevé, Tor n'est pas nécessaire puisque CryptPad ne nécessite pas la saisie d'un nom réel, d'un numéro de téléphone ou même d'une adresse email comme de nombreux autres services." - }, - policy: { - q: "Avez-vous une politique de confidentialité des données ?", - a: 'Oui ! Elle est disponible ici.' - }, - }; - out.faq.security = { - title: 'Sécurité', - proof: { - q: "Comment utilisez-vous les preuves à divulgation nulle de connaissance (Zero Knowledge proofs) ?", - a: "Quand nous utilisons le terme Zero Knowledge, ce n'est pas une référence aux Zero Knowledge proofs, mais aux Services Web Zero Knowledge.
    " + - "Les Services Web Zero Knowledge chiffrent les données des utilisateurs dans le navigateur, de manière à ce que le serveur n'aie pas accès au contenu déchiffré ni aux clés de chiffrement.

    " + - "Nous avons établi une courte liste de Services Zero Knowledge sur notre blog." - }, - why: { - q: "Pourquoi devrais-je utiliser CryptPad ?", - a: "Notre position est que les services cloud ne devraient pas nécessiter l'accès à vos données afin que vous puissiez les partager avec vos amis ou vos collègues. Si vous utilisez un autre service pour le travail collaboratif et qu'il n'indique pas clairement que le serveur n'a pas accès aux informations, il est très probable que vos données soient utilisées pour faire du profit." - }, - compromised: { - q: "CryptPad me protège-t-il si mon ordinateur est compromis ?", - a: "Dans le cas où votre ordinateur ou téléphone serait volé, CryptPad vous permet de déclencher une déconnexion à distance de votre compte CryptPad sur tous les appareils, excepté celui sur lequel vous vous trouvez. Pour ce faire, vous pouvez cliquer sur Se déconnecter partout dans votre page de Préférences.
    " + - "Tous les appareils qui sont actuellement connectés sur CryptPad à votre compte seront déconnectés. Tous les appareils qui se sont connectés au compte et ne vous demandent plus vos identifiants vous forceront à vous identifier de nouveau lorsque vous visiterez CryptPad.
    " + - "Actuellement, la déconnexion à distance est implémentée dans votre navigateur et non avec le serveur. Cela signifie que cette fonction devrait être suffisante pour protéger vos données si vous oubliez de vous déconnecter après l'utilisation sur un ordinateur partagé, mais elle ne vous protègera pas des agences gouvernementales." - }, - crypto: { - q: "Quelle cryptographie utilisez-vous ?", - a: 'CryptPad est basé sur deux librairies open-source de cryptographie : tweetnacl.js et scrypt-async.js.
    ' + - 'Scrypt est une fonction de dérivation de clé basée sur un mot de passe. Nous l\'utilisons pour transformer votre nom d\'utilisateur et votre mot de passe en un unique ensemble de clés qui sécurise l\'accès à votre CryptDrive afin que vous seul puissiez accéder à votre liste de pads.
    ' + - 'Nous utilisons les outils de chiffrement xsalsa20-poly1305 et x25519-xsalsa20-poly1305 fournis par tweetnacl pour chiffrer vos pads et l\'historique du chat respectivement.' - } - }; - out.faq.usability = { - title: 'Utilisation', - register: { - q: "Qu'est-ce que je gagne en créant un compte utilisateur ?", - a: 'Les utilisateurs enregistrés ont accès à un certain nombre de nouvelles fonctionnalités inaccessibles aux utilisateurs non connectés. Un tableau récapitulatif est disponible ici.' - }, - share: { - q: "Comment partager des pads chiffrés avec mes amis ?", - a: "CryptPad stocke la clé secrète de chiffrement des pads après le symbole `#` dans l'URL. " + - "Tout ce qui se trouve après ce symbole n'est jamais envoyé au serveur, ainsi nous n'avons pas accès à vos clés de chiffrement. " + - "Partager le lien d'un pad revient donc à permettre la lecture ou la modification du contenu." - }, - remove: { - q: "J'ai supprimé un pad ou un fichier de mon CryptDrive, mais le contenu est encore disponible. Comment le supprimer ?", - a: "Seuls les pads avec propriétaire (introduits en février 2018) peuvent être supprimés du serveur. Ils ne peuvent d'ailleurs être supprimés du serveur que par leur propriétaire (l'utilisateur ayant créé le pad).
    " + - "Si vous n'êtes pas le créateur du pad, vous devrez demander au propriétaire de le supprimer pour vous.
    " + - "Pour les pads dont vous êtes le propriétaire, vous pouvez effectuer un clic-droit sur le pad dans votre CryptDrive, et sélectionner Supprimer du serveur." - }, - forget: { - q: "Que faire si j'oublie mon mot de passe ?", - a: "Malheureusement, si nous avions la possibilité de retrouver ou de modifier votre mot de passe, cela signifierait que nous avons accès à vos pads, ce n'est donc pas le cas.
    " + - "Si vous n'avez pas noté votre nom d'utilisateur et votre mot de passe, et que vous ne vous en souvenez pas, il est peut-être possible de retrouver l'accès à certains pads grâce à l'historique de votre navigateur." - }, - change: { - q: "Que faire si je souhaite changer de mot de passe ?", - a: "Il n'est actuellement pas possible de changer votre mot de passe sur CryptPad, mais nous comptons développer cette fonctionnalité très bientôt." - }, - devices: { - q: "Je suis connecté sur deux appareils mais avec deux CryptDrive différents, comment est-ce possible ?", - a: "Il est possible que vous ayez enregistré le même nom d'utilisateur 2 fois, mais avec des mots de passe différents.
    " + - "Puisque le serveur de CryptPad vous identifie avec une clé cryptographique et non avec votre nom d'utilisateur, il ne peut pas empêcher la création d'autres comptes avec le même nom. Ainsi, chaque utilisateur possède une combinaison nom d'utilisateur / mot de passe unique.
    " + - "Les utilisateurs enregistrés peuvent voir leur nom de compte en haut de la page de préférences." - }, - folder: { - q: "Puis-je partager des dossiers complets de mon CryptDrive ?", - a: "Nous travaillons sur l'ajout d'une fonctionnalité workgroups (ou groupes de travail), qui permettrait aux collaborateurs de partager une structure de type dossier, avec tous les pads contenus dans cette structure." - }, - feature: { - q: "Pouvez-vous ajouter une fonctionnalité particulière dont j'ai besoin ?", - a: 'Beaucoup de fonctionnalités de CryptPad existent parce que des utilisateurs les ont demandées.
    ' + - 'Notre page de contact liste les différentes manières de nous joindre.

    ' + - 'Malheureusement, nous ne pouvons pas garantir que nous allons implémenter toutes les fonctionnalités demandées.
    ' + - 'Si une fonctionnalité particulière est nécessaire pour votre organisation, vous pouvez sponsoriser son développement pour s\'assurer de sa réalisation. Veuillez contacter sales@cryptpad.fr pour plus d\'informations.

    ' + - "Si vous n'avez pas la possibilité de sponsoriser du développement, nous sommes toujours intéressés par de nouvelles idées et des retours d'expérience qui peuvent nous aider à améliorer CryptPad. N'hésitez pas à nous contacter, avec les méthodes données précédemment, à n'importe quel moment." - }, - }; - out.faq.other = { - title: "Autres questions", - pay: { - q: "Pourquoi payer alors que toutes les fonctionnalités sont gratuites ?", - a: "Un compte premium permet d'augmenter la limite de stockage dans le CryptDrive, ainsi que celle de ses amis (en savoir plus).
    " + - "En plus de ces avantages directs, l'abonnement premium permet aussi de financer le développement actif et de manière continue de CryptPad. Cela comprend la correction de bugs, l'ajout de nouvelles fonctionnalités et rendre plus facile l'hébergement de CryptPad par d'autres personnes.
    " + - "Avec un abonnement, vous aidez aussi à prouver aux autres fournisseurs de services que les gens sont prêts à supporter les technologies améliorant le respect de leur vie privée. Nous espérons qu'un jour, les entreprises ayant pour revenu principal la revente de données des utilisateurs soient de l'histoire ancienne.
    " + - "Enfin, nous offrons la plupart des fonctionnalités gratuitement parce que nous croyons que tout le monde mérite le respect de la vie privée. En souscrivant à un compte premium, vous nous aider à maintenir ces fonctionnalités basiques accessibles aux populations défavorisées." - }, - goal: { - q: "Quel est votre objectif ?", - a: "En développant une technologie de collaboration qui respecte la vie privée, nous espérons augmenter les attentes des utilisateurs en ce qui concerne les plateformes de services \"cloud\" et leur politique de confidentialité. Nous souhaitons que notre travail conduise les autres fournisseurs de services, quel que soit leur domaine, à égaler voire dépasser nos efforts.
    " + - "Malgré notre optimisme, nous savons que la plupart du Web est financé par les publicités ciblées. Il y a encore beaucoup de travail à effectuer que l'on peut faire de nous-mêmes, et nous apprécions le support, la promotion et les contributions de notre communauté envers cet objectif." - }, - jobs: { - q: "Est-ce que vous embauchez ?", - a: 'Oui ! Vous pouvez envoyer un email à jobs@xwiki.com.' - }, - host: { - q: "Pouvez-vous m'aider à installer ma propre instance de CryptPad ?", - a: 'Nous serions heureux de fournir du support pour l\'installation de CryptPad au sein de votre organisation. Veuillez contacter sales@cryptpad.fr pour plus d\'informations.' - }, - revenue: { - q: "Comment participer au système de partage des revenus ?", - a: "Si vous possédez votre propre instance de CryptPad et que vous souhaitez activer les comptes payant et partager les revenus avec les développeurs, votre serveur devra être configuré comme un service partenaire.
    " + - 'Dans votre répertoire CryptPad, le fichier config.example.js devrait contenir des explications concernant les étapes à suivre pour configurer votre serveur. Vous devrez aussi contacter sales@cryptpad.fr pour vérifier que votre serveur est configuré correctement et pour discuter des méthodes de paiement.' - }, - }; - // terms.html - - out.tos_title = "Conditions d'utilisation de CryptPad"; - out.tos_legal = "Veuillez ne pas être malveillant, abusif, ou faire quoi que ce soit d'illégal."; - out.tos_availability = "Nous espérons que vous trouvez ce service utile, mais nous ne pouvons garantir ses performances et disponibilités. Nous vous recommandons d'exporter vos données régulièrement."; - out.tos_e2ee = "Le contenu sur CryptPad peuvent être lus et modifiés par quiconque est en mesure de deviner ou d'obtenir de quelque manière que ce soit l'identificateur de fragment du pad. Nous vous recommandons d'utiliser des technologies de messagerie chiffrées de bout à bout (end-to-end encryption ou e2ee) pour partager les liens, et déclinons toute responsabilité dans le cas ou un tel lien serait divulgué."; - out.tos_logs = "Les meta-données fournies par votre navigateur au serveur peuvent être enregistrées dans le but de maintenir le service."; - out.tos_3rdparties = "Nous ne fournissons aucune donnée individuelle à des tierces parties à moins d'y être contraints par la loi."; - - // 404 page - out.four04_pageNotFound = "Nous n'avons pas trouvé la page que vous cherchez."; - - // Header.html - - out.updated_0_header_logoTitle = 'Retourner vers votre CryptDrive'; - out.header_logoTitle = out.updated_0_header_logoTitle; - out.header_homeTitle = "Aller sur la page d'accueil"; - - // Initial states - - out.help = {}; - - out.help.title = "Pour bien démarrer"; - out.help.generic = { - more: 'Apprenez-en davantage sur le fonctionnement de CryptPad en lisant notre FAQ', - share: 'Utilisez le menu partage () pour générer un lien d\'accès ou d\'édition pad', - //stored: 'Chaque pad que vous visitez est stocké automatiquement dans votre CryptDrive', - save: "Tous les changements effectués sont enregistrés automatiquement" - }; - - out.help.text = { - formatting: 'Vous pouvez afficher ou cacher la barre d\'outils de texte en cliquant sur les boutons ou ', - embed: 'Les utilisateurs enregistrés peuvent intégrer un fichier de leur CryptDrive en utilisant le bouton ', - history: 'Vous pouvez utiliser l\'historique () pour voir ou restaurer les versions précédentes du pad' - }; - - out.help.pad = { - export: 'Vous pouvez exporter le contenu en tant que PDF avec le bouton de la barre d\'outils de mise en forme du texte' - }; - - out.help.code = { - modes: 'Utilisez le sous-menu pour changer le mode de coloration syntaxique ou le thème de couleur' - }; - - out.help.beta = { - warning: 'Cet éditeur est encore expérimental, vous pouvez signaler tout problème rencontré sur GitHub' - }; - out.help.oo = { - access: "L'accès à cette application est restreint aux utilisateurs enregistrés", - }; - - out.help.slide = { - markdown: 'Rédigez vos slides en Markdown et séparez les avec une ligne contenant ---', - present: 'Démarrez la présentation en utilisant le bouton ', - settings: 'Modifiez les préférences de la présentation (image de fond, transitions, numéro de pages, ...) avec le bouton dans le sous-menu ', - colors: 'Modifiez la couleur du texte ou du fond en utilisant les boutons et ' - }; - - out.help.poll = { - decisions: 'Prenez des décisions en privé avec des personnes de confiance', - options: 'Proposez des options et exprimez vos préférences', - choices: 'Cliquez sur les cellules de votre colonne pour modifier leur valeur entre oui (), peut-être (~) ou non ()', - submit: 'Cliquez sur Ajouter pour rendre vos choix visibles aux autres' - }; - - out.help.whiteboard = { - colors: 'Double-cliquez sur les couleurs pour changer la palette', - mode: 'Vous pouvez désactiver le mode dessin pour déplacer, redimensionner, ou supprimer des éléments du dessin', - embed: 'Intégrez des images de votre disque ou de votre CryptDrive et exporter le contenu en tant que PNG sur votre disque ou votre CryptDrive ' - }; - - out.help.kanban = { - add: 'Ajoutez un tableau en utilisant le bouton dans le coin supérieur-droit', - task: 'Déplacez les éléments en les faisant glisser d\'un tableau à l\'autre', - color: 'Modifiez les couleurs en cliquant sur les parties colorées à côté du titre de chaque tableau' - }; - - out.initialState = [ - '

    ', - 'Voici CryptPad, l\'éditeur collaboratif en temps-réel Zero Knowledge. Tout est sauvegardé dés que vous le tapez.', - '
    ', - 'Partagez le lien vers ce pad avec des amis ou utilisez le bouton pour obtenir le lien de lecture-seule, qui permet la lecture mais non la modification.', - '

    ', - ].join(''); - - out.codeInitialState = [ - '# Éditeur de code collaboratif et Zero Knowledge de CryptPad\n', - '\n', - '* Ce que vous tapez ici est chiffré de manière que seules les personnes avec le lien peuvent y accéder.\n', - '* Vous pouvez choisir le langage de programmation pour la coloration syntaxique, ainsi que le thème de couleurs, dans le coin supérieur droit.' - ].join(''); - - out.slideInitialState = [ - '# CryptSlide\n', - '1. Écrivez le contenu de votre présentation avec la syntaxe Markdown\n', - ' - Apprenez à utiliser Markdown en cliquant [ici](http://www.markdowntutorial.com/)\n', - '2. Séparez vos slides avec ---\n', - '3. Cliquez sur la bouton "lecture" pour afficher le résultat en mode présentation', - ' - La présentation est mise à jour en temps-réel' - ].join(''); - - out.driveReadmeTitle = "Qu'est-ce que CryptPad ?"; - out.readme_welcome = "Bienvenue dans CryptPad !"; - out.readme_p1 = "Bienvenue dans CryptPad, le lieu où vous pouvez prendre des notes seul ou avec des amis."; - out.readme_p2 = "Ce pad va vous donner un aperçu de la manière dont vous pouvez utiliser CryptPad pour prendre des notes, les organiser et travailler en groupe sur celles-ci."; - out.readme_cat1 = "Découvrez votre CryptDrive"; - out.readme_cat1_l1 = "Créer un pad : Dans votre CryptDrive, cliquez sur {0} puis {1} et vous obtenez un nouveau pad."; // 0: New, 1: Rich Text - out.readme_cat1_l2 = "Ouvrir des pads depuis votre CryptDrive : Double-cliquez sur l'icone d'un pad pour l'ouvrir."; - out.readme_cat1_l3 = "Organiser vos pads : Quand vous êtes connecté, tous les pads auquel vous accédez sont ajoutés dans la section {0} de votre CryptDrive."; // 0: Unsorted files - out.readme_cat1_l3_l1 = "Vous pouvez cliquer et faire glisser des fichiers dans des dossiers dans la section {0} de votre CryptDrive, et créer de nouveaux dossiers."; // 0: Documents - out.readme_cat1_l3_l2 = "N'hésitez pas à utiliser le clic droit sur les icones puisque des menus sont souvent disponibles."; - out.readme_cat1_l4 = "Déplacer des pads vers la corbeille : Vous pouvez cliquer et faire glisser vos pads dans la {0} de la même manière que vous pouvez les déposer dans des dossiers."; // 0: Trash - out.readme_cat2 = "Créer des pads comme un pro"; - out.edit = "éditer"; - out.view = "voir"; - out.readme_cat2_l1 = "Le bouton {0} dans votre pad vous permet de donner l'accès à vos collaborateurs que ce soit pour l'{1} ou pour le {2}."; // 0: Share, 1: edit, 2: view - out.readme_cat2_l2 = "Vous pouvez changer le titre d'un pad en cliquant sur le crayon"; - out.readme_cat3 = "Découvrez les autres applications CryptPad"; - out.readme_cat3_l1 = "Avec l'éditeur de code de CryptPad, vous pouvez collaborer sur du code comme Javascript ou des langages comme HTML ou Markdown."; - out.readme_cat3_l2 = "Avec l'éditeur de présentations de CryptPad, vous pouvez réaliser des présentations rapides en utilisant Markdown"; - out.readme_cat3_l3 = "Avec CryptPoll vous pouvez créer rapidement des sondages, et en particulier plannifier des meetings qui rentrent dans l'agenda de tout ceux qui souhaitent participer."; - - // Tips - out.tips = {}; - out.tips.shortcuts = "`ctrl+b`, `ctrl+i` et `ctrl+u` sont des raccourcis rapides pour mettre en gras, en italique ou souligner."; - out.tips.indent = "Dans les listes à puces ou numérotées, vous pouvez utiliser `Tab` ou `Maj+Tab` pour augmenter ou réduire rapidement l'indentation."; - out.tips.store = "Dès que vous ouvrez un nouveau pad, il est automatiquement stocké dans votre CryptDrive si vous êtes connecté."; - out.tips.marker = "Vous pouvez surligner du texte dans un pad en utilisant l'option \"marker\" dans le menu déroulant des styles."; - out.tips.driveUpload = "Les utilisateurs enregistrés peuvent importer des fichiers en les faisant glisser et en les déposant dans leur CryptDrive."; - out.tips.filenames = "Vous pouvez renommer les fichiers de votre CryptDrive, ce nom ne sera visible que par vous."; - out.tips.drive = "Les utilisateurs enregistrés peuvent organiser leurs fichiers dans leur CryptDrive, accessible depuis l'icône CryptPad dans le coin supérieur gauche des pads."; - out.tips.profile = "Les utilisateurs enregistrés peuvent créer un profil depuis le menu utilisateur, dans le coin supérieur droit."; - out.tips.avatars = "Vous pouvez uploader un avatar dans votre profil. Les autres personnes le verront dans la liste d'utilisateurs des pads."; - out.tips.tags = "Ajoutez des mots-clés aux pads et effectuer une recherche commençant par # dans votre CryptDrive pour les retrouver."; - - out.feedback_about = "Si vous lisez ceci, vous vous demandez probablement pourquoi CryptPad envoie des requêtes vers des pages web quand vous réalisez certaines actions."; - out.feedback_privacy = "Nous prenons au sérieux le respect de votre vie privée, et en même temps nous souhaitons rendre CryptPad très simple à utiliser. Nous utilisons cette page pour comprendre quelles fonctionnalités dans l'interface comptent le plus pour les utilisateurs, en l'appelant avec un paramètre spécifiant quelle action a été réalisée."; - out.feedback_optout = "Si vous le souhaitez, vous pouvez désactiver ces requêtes en vous rendant dans votre page de préférences, où vous trouverez une case à cocher pour désactiver le retour d'expérience."; - - // Creation page - out.creation_404 = "Ce pad n'existe plus. Vous pouvez créer un nouveau pad en utilisant le formulaire suivant."; - out.creation_ownedTitle = "Type de pad"; - out.creation_owned = "Être propriétaire de ce pad"; - out.creation_ownedTrue = "Être propriétaire"; - out.creation_ownedFalse = "Pas de propriétaire"; - out.creation_owned1 = "Être propriétaire d'un pad signifie que vous pouvez le supprimer du serveur à tout moment. Une fois supprimé, il disparaît du CryptDrive des autres utilisateurs."; - out.creation_owned2 = "Un pad sans propriétaire ne peut pas être supprimé du serveur à moins d'avoir dépassé son éventuelle date d'expiration."; - out.creation_expireTitle = "Durée de vie"; - out.creation_expire = "Ajouter une durée de vie"; - out.creation_expireTrue = "Ajouter durée de vie"; - out.creation_expireFalse = "Illimité"; - out.creation_expireHours = "Heure(s)"; - out.creation_expireDays = "Jour(s)"; - out.creation_expireMonths = "Mois"; - out.creation_expire1 = "Un pad illimité ne sera pas supprimé du serveur à moins que son propriétaire ne le décide."; - out.creation_expire2 = "Un pad à durée de vie sera supprimé automatiquement du serveur et du CryptDrive des utilisateurs lorsque cette durée sera dépassée."; - out.creation_password = "Ajouter un mot de passe"; - out.creation_noTemplate = "Pas de modèle"; - out.creation_newTemplate = "Nouveau modèle"; - out.creation_create = "Créer"; - out.creation_saveSettings = "Ne plus me demander"; - out.creation_settings = "Voir davantage de préférences"; - out.creation_rememberHelp = "Ouvrez votre page de Préférences pour voir ce formulaire à nouveau."; - // Properties about creation data - out.creation_owners = "Propriétaires"; - out.creation_ownedByOther = "Appartient à un autre utilisateur"; - out.creation_noOwner = "Pas de propriétaire"; - out.creation_expiration = "Date d'expiration"; - out.creation_passwordValue = "Mot de passe"; - out.creation_propertiesTitle = "Disponibilité"; - out.creation_appMenuName = "Mode avancé (Ctrl + E)"; - out.creation_newPadModalDescription = "Cliquez sur un type de pad pour le créer. Vous pouvez aussi appuyer sur Tab pour sélectionner un type et appuyer sur Entrée pour valider."; - out.creation_newPadModalDescriptionAdvanced = "Cochez la case si vous souhaitez voir l'écran de création de pads (pour les pads avec propriétaire ou à durée de vie). Vous pouvez appuyer sur Espace pour changer sa valeur."; - out.creation_newPadModalAdvanced = "Afficher l'écran de création de pads"; - - // Password prompt on the loadind screen - out.password_info = "Le pad auquel vous essayez d'accéder est protégé par un mot de passe. Entrez le bon mot de passe pour accéder à son contenu."; - out.password_error = "Pad introuvable !
    Cette erreur peut provenir de deux facteurs. Soit le mot de passe est faux, soit le pad a été supprimé du serveur."; - out.password_placeholder = "Tapez le mot de passe ici..."; - out.password_submit = "Valider"; - out.password_show = "Afficher"; - - // Change password in pad properties - out.properties_addPassword = "Ajouter un mot de passe"; - out.properties_changePassword = "Modifier le mot de passe"; - out.properties_confirmNew = "Êtes-vous sûr ? Ajouter un mot de passe changera l'URL de ce pad et supprimera son historique. Les utilisateurs ne connaissant pas le nouveau mot de passe perdront l'accès au pad."; - out.properties_confirmChange = "Êtes-vous sûr ? Changer le mot de passe supprimera l'historique de ce pad. Les utilisateurs ne connaissant pas le nouveau mot de passe perdront l'accès au pad."; - out.properties_passwordSame = "Le nouveau mot de passe doit être différent de celui existant."; - out.properties_passwordError = "Une erreur est survenue lors de la modification du mot de passe. Veuillez réessayer."; - out.properties_passwordWarning = "Le mot de passe a été modifié avec succès mais nous n'avons pas réussi à mettre à jour votre CryptDrive avec les nouvelles informations. Vous devrez peut-être supprimer manuellement l'ancienne version de ce pad.
    Appuyez sur OK pour recharger le pad et mettre à jour vos droits d'accès."; - out.properties_passwordSuccess = "Le mot de passe a été modifié avec succès.
    Appuyez sur OK pour mettre à jour vos droits d'accès."; - out.properties_changePasswordButton = "Valider"; - - // New share modal - out.share_linkCategory = "Partage"; - out.share_linkAccess = "Droits d'accès"; - out.share_linkEdit = "Édition"; - out.share_linkView = "Lecture-seule"; - out.share_linkOptions = "Options du lien"; - out.share_linkEmbed = "Mode intégration (barre d'outils cachée)"; - out.share_linkPresent = "Mode présentation (sections d'édition cachées)"; - out.share_linkOpen = "Ouvrir le lien"; - out.share_linkCopy = "Copier le lien"; - out.share_embedCategory = "Intégration"; - out.share_mediatagCopy = "Copier le mediatag"; - - // Loading info - out.loading_pad_1 = "Initialisation du pad"; - out.loading_pad_2 = "Chargement du contenu du pad"; - out.loading_drive_1 = "Chargement des données"; - out.loading_drive_2 = "Mise à jour du format des données"; - out.loading_drive_3 = "Vérification de l'intégrité des données"; - - // Shared folders - out.sharedFolders_forget = "Ce pad est stocké uniquement dans un dossier partagé. Vous ne pouvez pas le déplacer dans votre corbeille. Si vous souhaitez le supprimer, vous pouvez utiliser l'application CryptDrive."; - out.sharedFolders_duplicate = "Certains pads que vous essayez de déplacer sont déjà partagés dans le dossier de destination."; - out.sharedFolders_create = "Créer un dossier partagé"; - out.sharedFolders_create_name = "Nom du dossier"; - out.sharedFolders_create_owned = "Être propriétaire du dossier"; - out.sharedFolders_create_password = "Mot de passe du dossier"; - out.sharedFolders_share = "Partager cette URL avec d'autres utilisateurs enregistrés leur donne accès au dossier partagé. Une fois l'URL ouverte, le dossier partagé sera ajouté au répertoire racine de leur CryptDrive."; - - out.chrome68 = "Il semblerait que vous utilisiez le navigateur Chrome version 68. Ce navigateur contient un bug rendant certaines pages entièrement blanches après quelques secondes ou bloquant les clics. Pour corriger ce problème, vous pouvez vous déplacer vers un nouvel onglet et revenir ou vous pouvez essayer de faire défiler la page. Ce bug devrait être corrigé dans la prochaine version du navigateur."; - - // Manual pad storage popup - out.autostore_file = "fichier"; - out.autostore_sf = "dossier"; - out.autostore_pad = "pad"; - out.autostore_notstored = "Ce {0} n'est pas dans votre CryptDrive. Souhaitez-vous le stocker ?"; - out.autostore_settings = "Vous pouvez activer le stockage automatique des pads dans vos Préférences !"; - out.autostore_store = "Stocker"; - out.autostore_hide = "Ne pas stocker"; - out.autostore_error = "Erreur : nous n'avons pas réussi à stocker ce pad, veuillez ré-essayer."; - out.autostore_saved = "Ce pad a été stocké avec succès dans votre CryptDrive !"; - out.autostore_forceSave = "Stocker le fichier dans votre CryptDrive"; // File upload modal - out.autostore_notAvailable = "Vous devez stocker ce pad dans votre CryptDrive avant de pouvoir utiliser cette fonctionnalité."; - - // Crowdfunding messages - out.crowdfunding_home1 = "CryptPad a besoin d'aide !"; - out.crowdfunding_home2 = "Cliquez sur le bouton pour découvrir notre campagne de financement participatif."; - out.crowdfunding_button = "Soutenir CryptPad"; - - out.crowdfunding_popup_text = "

    Aider CryptPad

    " + - "Pour vous assurer que CryptPad soit activement développé, nous vous invitons à supporter le projet via la " + - 'page OpenCollective, où vous pouvez trouver notre Roadmap et nos objectifs de financement.'; - out.crowdfunding_popup_yes = "Voir la page"; - out.crowdfunding_popup_no = "Pas maintenant"; - out.crowdfunding_popup_never = "Ne plus demander"; - - return out; -}); diff --git a/www/common/translations/old/messages.js b/www/common/translations/old/messages.js deleted file mode 100644 index 2d6036232..000000000 --- a/www/common/translations/old/messages.js +++ /dev/null @@ -1,1363 +0,0 @@ -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - - out.main_title = "CryptPad: Zero Knowledge, Collaborative Real Time Editing"; - - out.type = {}; - out.type.pad = 'Rich text'; - out.type.code = 'Code'; - out.type.poll = 'Poll'; - out.type.kanban = 'Kanban'; - out.type.slide = 'Presentation'; - out.type.drive = 'CryptDrive'; - out.type.whiteboard = 'Whiteboard'; - out.type.file = 'File'; - out.type.media = 'Media'; - out.type.todo = "Todo"; - out.type.contacts = 'Contacts'; - out.type.sheet = 'Spreadsheet (Beta)'; - //out.type.ooslide = 'OnlyOffice Slide'; - //out.type.oodoc = 'OnlyOffice Doc'; - - out.button_newpad = 'New Rich Text pad'; - out.button_newcode = 'New Code pad'; - out.button_newpoll = 'New Poll'; - out.button_newslide = 'New Presentation'; - out.button_newwhiteboard = 'New Whiteboard'; - out.button_newkanban = 'New Kanban'; - - // NOTE: Remove updated_0_ if we need an updated_1_ - out.updated_0_common_connectionLost = "Server Connection Lost
    You're now in read-only mode until the connection is back."; - out.common_connectionLost = out.updated_0_common_connectionLost; - - out.websocketError = 'Unable to connect to the websocket server...'; - out.typeError = "This pad is not compatible with the selected application"; - out.onLogout = 'You are logged out, {0}click here{1} to log in
    or press Escape to access your pad in read-only mode.'; - out.wrongApp = "Unable to display the content of that realtime session in your browser. Please try to reload that page."; - out.padNotPinned = 'This pad will expire after 3 months of inactivity, {0}login{1} or {2}register{3} to preserve it.'; - out.anonymousStoreDisabled = "The webmaster of this CryptPad instance has disabled the store for anonymous users. You have to log in to be able to use CryptDrive."; - out.expiredError = 'This pad has reached its expiration time and is no longer available.'; - out.deletedError = 'This pad has been deleted by its owner and is no longer available.'; - out.inactiveError = 'This pad has been deleted due to inactivity. Press Esc to create a new pad.'; - out.chainpadError = 'A critical error occurred when updating your content. This page is in read-only mode to make sure you won\'t lose your work.
    ' + - 'Hit Esc to continue to view this pad, or reload to try editing again.'; - out.errorCopy = ' You can still copy the content to another location by pressing Esc.
    Once you leave this page, it will disappear forever!'; - out.errorRedirectToHome = 'Press Esc to be redirected to your CryptDrive.'; - out.newVersionError = "A new version of CryptPad is available.
    " + - "Reload to use the new version, or press escape to access your content in offline mode."; - - out.loading = "Loading..."; - out.error = "Error"; - out.saved = "Saved"; - out.synced = "Everything is saved"; - out.deleted = "Pad deleted from your CryptDrive"; - out.deletedFromServer = "Pad deleted from the server"; - - out.mustLogin = "You must be logged in to access this page"; - out.disabledApp = "This application has been disabled. Contact the administrator of this CryptPad for more information."; - - out.realtime_unrecoverableError = "An unrecoverable error has occurred. Click OK to reload."; - - out.disconnected = 'Disconnected'; - out.synchronizing = 'Synchronizing'; - out.reconnecting = 'Reconnecting'; - out.typing = "Editing"; - out.initializing = "Initializing..."; - out.forgotten = 'Moved to the trash'; - out.errorState = 'Critical error: {0}'; - out.lag = 'Lag'; - out.readonly = 'Read only'; - out.anonymous = "Anonymous"; - out.yourself = "Yourself"; - out.anonymousUsers = "anonymous editors"; - out.anonymousUser = "anonymous editor"; - out.users = "Users"; - out.and = "And"; - out.viewer = "viewer"; - out.viewers = "viewers"; - out.editor = "editor"; - out.editors = "editors"; - out.userlist_offline = "You're currently offline, the user list is not available."; - - out.language = "Language"; - - out.comingSoon = "Coming soon..."; - - out.newVersion = 'CryptPad has been updated!
    ' + - 'Check out what\'s new in the latest version:
    '+ - 'Release notes for CryptPad {0}'; - - out.upgrade = "Upgrade"; - out.upgradeTitle = "Upgrade your account to increase the storage limit"; - - out.upgradeAccount = "Upgrade account"; - out.MB = "MB"; - out.GB = "GB"; - out.KB = "KB"; - - out.supportCryptpad = "Support CryptPad"; - - out.formattedMB = "{0} MB"; - out.formattedGB = "{0} GB"; - out.formattedKB = "{0} KB"; - - out.greenLight = "Everything is working fine"; - out.orangeLight = "Your slow connection may impact your experience"; - out.redLight = "You are disconnected from the session"; - - out.pinLimitReached = "You've reached your storage limit"; - out.updated_0_pinLimitReachedAlert = "You've reached your storage limit. New pads won't be stored in your CryptDrive.
    " + - 'You can either remove pads from your CryptDrive or subscribe to a premium offer to increase your limit.'; - out.pinLimitReachedAlert = out.updated_0_pinLimitReachedAlert; - out.pinLimitReachedAlertNoAccounts = out.pinLimitReached; - out.pinLimitNotPinned = "You've reached your storage limit.
    "+ - "This pad is not stored in your CryptDrive."; - out.pinLimitDrive = "You've reached your storage limit.
    " + - "You can't create new pads."; - - out.moreActions = "More actions"; - - out.importButton = "Import"; - out.importButtonTitle = 'Import a pad from a local file'; - - out.exportButton = "Export"; - out.exportButtonTitle = 'Export this pad to a local file'; - out.exportPrompt = 'What would you like to name your file?'; - - out.changeNamePrompt = 'Change your name (leave empty to be anonymous): '; - out.user_rename = "Change display name"; - out.user_displayName = "Display name"; - out.user_accountName = "Account name"; - - out.clickToEdit = "Click to edit"; - out.saveTitle = "Save the title (enter)"; - - out.forgetButton = "Delete"; - out.forgetButtonTitle = 'Move this pad to the trash'; - out.forgetPrompt = 'Clicking OK will move this pad to your trash. Are you sure?'; - out.movedToTrash = 'That pad has been moved to the trash.
    Access my Drive'; - - out.shareButton = 'Share'; - out.shareSuccess = 'Copied link to clipboard'; - - out.userListButton = "User list"; - - out.chatButton = "Chat"; - - out.userAccountButton = "Your account"; - - out.newButton = 'New'; - out.newButtonTitle = 'Create a new pad'; - out.uploadButton = 'Upload files'; - out.uploadButtonTitle = 'Upload a new file to the current folder'; - - out.saveTemplateButton = "Save as template"; - out.saveTemplatePrompt = "Choose a title for the template"; - out.templateSaved = "Template saved!"; - out.selectTemplate = "Select a template or press escape"; - out.useTemplate = "Start with a template?"; //Would you like to "You have available templates for this type of pad. Do you want to use one?"; - out.useTemplateOK = 'Pick a template (Enter)'; - out.useTemplateCancel = 'Start fresh (Esc)'; - out.template_import = "Import a template"; - out.template_empty = "No template available"; - - out.previewButtonTitle = "Display or hide the Markdown preview mode"; - - out.presentButtonTitle = "Enter presentation mode"; - - out.backgroundButtonTitle = 'Change the background color in the presentation'; - out.colorButtonTitle = 'Change the text color in presentation mode'; - - out.propertiesButton = "Properties"; - out.propertiesButtonTitle = 'Get pad properties'; - - out.printText = "Print"; - out.printButton = "Print (enter)"; - out.printButtonTitle2 = "Print your document or export it as a PDF file"; - out.printOptions = "Layout options"; - out.printSlideNumber = "Display the slide number"; - out.printDate = "Display the date"; - out.printTitle = "Display the pad title"; - out.printCSS = "Custom style rules (CSS):"; - out.printTransition = "Enable transition animations"; - out.printBackground = "Use a background image"; - out.printBackgroundButton = "Pick an image"; - out.printBackgroundValue = "Current background: {0}"; - out.printBackgroundNoValue = "No background image displayed"; - out.printBackgroundRemove = "Remove this background image"; - - out.filePickerButton = "Embed a file stored in CryptDrive"; - out.filePicker_close = "Close"; - out.filePicker_description = "Choose a file from your CryptDrive to embed it or upload a new one"; - out.filePicker_filter = "Filter files by name"; - out.or = 'or'; - - out.tags_title = "Tags (for you only)"; - out.tags_add = "Update this page's tags"; - out.tags_searchHint = "Find files by their tags by searching in your CryptDrive"; - out.tags_searchHint = "Start a search with # in your CryptDrive to find your tagged pads."; - out.tags_notShared = "Your tags are not shared with other users"; - out.tags_duplicate = "Duplicate tag: {0}"; - out.tags_noentry = "You can't tag a deleted pad!"; - - out.slideOptionsText = "Options"; - out.slideOptionsTitle = "Customize your slides"; - out.slideOptionsButton = "Save (enter)"; - out.slide_invalidLess = "Invalid custom style"; - - out.languageButton = "Language"; - out.languageButtonTitle = "Select the language to use for the syntax highlighting"; - out.themeButton = "Theme"; - out.themeButtonTitle = "Select the color theme to use for the code and slide editors"; - - out.editShare = "Editing link"; - out.editShareTitle = "Copy the editing link to clipboard"; - out.editOpen = "Open editing link in a new tab"; - out.editOpenTitle = "Open this pad in editing mode in a new tab"; - out.viewShare = "Read-only link"; - out.viewShareTitle = "Copy the read-only link to clipboard"; - out.viewOpen = "Open read-only link in a new tab"; - out.viewOpenTitle = "Open this pad in read-only mode in a new tab"; - out.fileShare = "Copy link"; - out.getEmbedCode = "Get embed code"; - out.viewEmbedTitle = "Embed the pad in an external page"; - out.viewEmbedTag = "To embed this pad, include this iframe in your page wherever you want. You can style it using CSS or HTML attributes."; - out.fileEmbedTitle = "Embed the file in an external page"; - out.fileEmbedScript = "To embed this file, include this script once in your page to load the Media Tag:"; - out.fileEmbedTag = "Then place this Media Tag wherever in your page you would like to embed:"; - - out.notifyJoined = "{0} has joined the collaborative session"; - out.notifyRenamed = "{0} is now known as {1}"; - out.notifyLeft = "{0} has left the collaborative session"; - - out.ok = 'OK'; - out.okButton = 'OK (enter)'; - - out.cancel = "Cancel"; - out.cancelButton = 'Cancel (esc)'; - out.doNotAskAgain = "Don't ask me again (Esc)"; - - out.show_help_button = "Show help"; - out.hide_help_button = "Hide help"; - out.help_button = "Help"; - - out.historyText = "History"; - out.historyButton = "Display the document history"; - out.history_next = "Newer version"; - out.history_prev = "Older version"; - out.history_loadMore = "Load more history"; - out.history_closeTitle = "Close the history"; - out.history_restoreTitle = "Restore the selected version of the document"; - out.history_restorePrompt = "Are you sure you want to replace the current version of the document by the displayed one?"; - out.history_restoreDone = "Document restored"; - out.history_version = "Version:"; - - // Ckeditor - out.openLinkInNewTab = "Open Link in New Tab"; - out.pad_mediatagTitle = "Media-Tag settings"; - out.pad_mediatagWidth = "Width (px)"; - out.pad_mediatagHeight = "Height (px)"; - out.pad_mediatagRatio = "Keep ratio"; - out.pad_mediatagBorder = "Border width (px)"; - out.pad_mediatagPreview = "Preview"; - out.pad_mediatagImport = 'Save in your CryptDrive'; - out.pad_mediatagOptions = 'Image properties'; - - // Kanban - out.kanban_newBoard = "New board"; - out.kanban_item = "Item {0}"; // Item number for initial content - out.kanban_todo = "To Do"; - out.kanban_done = "Done"; - out.kanban_working = "In progress"; - out.kanban_deleteBoard = "Are you sure you want to delete this board?"; - out.kanban_addBoard = "Add a board"; - out.kanban_removeItem = "Remove this item"; - out.kanban_removeItemConfirm = "Are you sure you want to delete this item?"; - - // Polls - - out.poll_title = "Zero Knowledge Date Picker"; - out.poll_subtitle = "Zero Knowledge, realtime scheduling"; - - out.poll_p_save = "Your settings are updated instantly, so you never need to save."; - out.poll_p_encryption = "All your input is encrypted so only people who have the link can access it. Even the server cannot see what you change."; - - out.wizardLog = "Click the button in the top left to return to your poll"; - out.wizardTitle = "Use the wizard to create your poll"; - out.wizardConfirm = "Are you really ready to add these options to your poll?"; - - out.poll_publish_button = "Publish"; - out.poll_admin_button = "Admin"; - out.poll_create_user = "Add a new user"; - out.poll_create_option = "Add a new option"; - out.poll_commit = "Submit"; - - out.poll_closeWizardButton = "Close wizard"; - out.poll_closeWizardButtonTitle = "Close wizard"; - out.poll_wizardComputeButton = "Compute Options"; - out.poll_wizardClearButton = "Clear Table"; - out.poll_wizardDescription = "Automatically create a number of options by entering any number of dates and times segments"; - out.poll_wizardAddDateButton = "+ Dates"; - out.poll_wizardAddTimeButton = "+ Times"; - - out.poll_optionPlaceholder = "Option"; - out.poll_userPlaceholder = "Your name"; - out.poll_removeOption = "Are you sure you'd like to remove this option?"; - out.poll_removeUser = "Are you sure you'd like to remove this user?"; - - out.poll_titleHint = "Title"; - out.poll_descriptionHint = "Describe your poll, and use the ✓ (publish) button when you're done.\n" + - "The description can be written using markdown syntax and you can embed media elements from your CryptDrive.\n" + - "Anyone with the link can change the description, but this is discouraged."; - - out.poll_remove = "Remove"; - out.poll_edit = "Edit"; - out.poll_locked = "Locked"; - out.poll_unlocked = "Unlocked"; - - out.poll_bookmark_col = 'Bookmark this column so that it is always unlocked and displayed at the beginning for you'; - out.poll_bookmarked_col = 'This is your bookmarked column. It will always be unlocked and displayed at the beginning for you.'; - out.poll_total = 'TOTAL'; - - out.poll_comment_list = "Comments"; - out.poll_comment_add = "Add a comment"; - out.poll_comment_submit = "Send"; - out.poll_comment_remove = "Delete this comment"; - out.poll_comment_placeholder = "Your comment"; - - out.poll_comment_disabled = "Publish this poll using the ✓ button to enable the comments."; - - // OnlyOffice - out.oo_reconnect = "The server connection is back. Click OK to reload and continue the edition."; - - // Canvas - out.canvas_clear = "Clear"; - out.canvas_delete = "Delete selection"; - out.canvas_disable = "Disable draw"; - out.canvas_enable = "Enable draw"; - out.canvas_width = "Width"; - out.canvas_opacity = "Opacity"; - out.canvas_opacityLabel = "Opacity: {0}"; - out.canvas_widthLabel = "Width: {0}"; - out.canvas_saveToDrive = "Save this image as a file in your CryptDrive"; - out.canvas_currentBrush = "Current brush"; - out.canvas_chooseColor = "Choose a color"; - out.canvas_imageEmbed = "Embed an image from your computer"; - - // Profile - out.profileButton = "Profile"; // dropdown menu - out.profile_urlPlaceholder = 'URL'; - out.profile_namePlaceholder = 'Name displayed in your profile'; - out.profile_avatar = "Avatar"; - out.profile_upload = " Upload a new avatar"; - out.profile_uploadSizeError = "Error: your avatar must be smaller than {0}"; - out.profile_uploadTypeError = "Error: your avatar type is not allowed. Allowed types are: {0}"; - out.profile_error = "Error while creating your profile: {0}"; - out.profile_register = "You have to sign up to create a profile!"; - out.profile_create = "Create a profile"; - out.profile_description = "Description"; - out.profile_fieldSaved = 'New value saved: {0}'; - - out.profile_inviteButton = "Connect"; - out.profile_inviteButtonTitle ='Create a link that will invite this user to connect with you.'; - out.profile_inviteExplanation = "Clicking OK will create a link to a secure messaging session that only {0} will be able to redeem.

    The link will be copied to your clipboard and can be shared publicly."; - out.profile_viewMyProfile = "View my profile"; - - // contacts/userlist - out.userlist_addAsFriendTitle = 'Add "{0}" as a contact'; - out.userlist_thisIsYou = 'This is you ("{0}")'; - out.userlist_pending = "Pending..."; - out.contacts_title = "Contacts"; - out.contacts_addError = 'Error while adding that contact to the list'; - out.contacts_added = 'Contact invite accepted.'; - out.contacts_rejected = 'Contact invite rejected'; - out.contacts_request = '{0} would like to add you as a contact. Accept?'; - out.contacts_send = 'Send'; - out.contacts_remove = 'Remove this contact'; - out.contacts_confirmRemove = 'Are you sure you want to remove {0} from your contacts?'; - out.contacts_typeHere = "Type a message here..."; - out.contacts_warning = "Everything you type here is persistent and available to all the existing and future users of this pad. Be careful with sensitive information!"; - out.contacts_padTitle = "Chat"; - - out.contacts_info1 = "These are your contacts. From here, you can:"; - out.contacts_info2 = "Click your contact's icon to chat with them"; - out.contacts_info3 = "Double-click their icon to view their profile"; - out.contacts_info4 = "Either participant can clear permanently a chat history"; - - out.contacts_removeHistoryTitle = 'Clean the chat history'; - out.contacts_confirmRemoveHistory = 'Are you sure you want to permanently remove your chat history? Data cannot be restored'; - out.contacts_removeHistoryServerError = 'There was an error while removing your chat history. Try again later'; - out.contacts_fetchHistory = "Retrieve older history"; - - out.contacts_friends = "Friends"; - out.contacts_rooms = "Rooms"; - out.contacts_leaveRoom = "Leave this room"; - - out.contacts_online = "Another user from this room is online"; - - // File manager - - out.fm_rootName = "Documents"; - out.fm_trashName = "Trash"; - out.fm_unsortedName = "Unsorted files"; - out.fm_filesDataName = "All files"; - out.fm_templateName = "Templates"; - out.fm_searchName = "Search"; - out.fm_recentPadsName = "Recent pads"; - out.fm_ownedPadsName = "Owned"; - out.fm_tagsName = "Tags"; - out.fm_sharedFolderName = "Shared folder"; - out.fm_searchPlaceholder = "Search..."; - out.fm_newButton = "New"; - out.fm_newButtonTitle = "Create a new pad or folder, import a file in the current folder"; - out.fm_newFolder = "New folder"; - out.fm_newFile = "New pad"; - out.fm_folder = "Folder"; - out.fm_sharedFolder = "Shared folder"; - out.fm_folderName = "Folder name"; - out.fm_numberOfFolders = "# of folders"; - out.fm_numberOfFiles = "# of files"; - out.fm_fileName = "File name"; - out.fm_title = "Title"; - out.fm_type = "Type"; - out.fm_lastAccess = "Last access"; - out.fm_creation = "Creation"; - out.fm_forbidden = "Forbidden action"; - out.fm_originalPath = "Original path"; - out.fm_openParent = "Show in folder"; - out.fm_noname = "Untitled Document"; - out.fm_emptyTrashDialog = "Are you sure you want to empty the trash?"; - out.fm_removeSeveralPermanentlyDialog = "Are you sure you want to permanently remove these {0} elements from your CryptDrive?"; - out.fm_removePermanentlyNote = "Owned pads will be removed from the server if you continue."; - out.fm_removePermanentlyDialog = "Are you sure you want to permanently remove that element from your CryptDrive?"; - out.fm_removeSeveralDialog = "Are you sure you want to move these {0} elements to the trash?"; - out.fm_removeDialog = "Are you sure you want to move {0} to the trash?"; - out.fm_deleteOwnedPad = "Are you sure you want to permanently remove this pad from the server?"; - out.fm_deleteOwnedPads = "Are you sure you want to permanently remove these pads from the server?"; - out.fm_restoreDialog = "Are you sure you want to restore {0} to its previous location?"; - out.fm_unknownFolderError = "The selected or last visited directory no longer exist. Opening the parent folder..."; - out.fm_contextMenuError = "Unable to open the context menu for that element. If the problem persist, try to reload the page."; - out.fm_selectError = "Unable to select the targeted element. If the problem persists, try to reload the page."; - out.fm_categoryError = "Unable to open the selected category, displaying root."; - out.fm_info_root = "Create as many nested folders here as you want to sort your files."; - out.fm_info_unsorted = 'Contains all the files you\'ve visited that are not yet sorted in "Documents" or moved to the "Trash".'; // "My Documents" should match with the "out.fm_rootName" key, and "Trash" with "out.fm_trashName" - out.fm_info_template = 'Contains all the pads stored as templates and that you can re-use when you create a new pad.'; - out.fm_info_recent = "List the recently modified or opened pads."; - out.updated_0_fm_info_trash = 'Empty your trash to free space in your CryptDrive.'; - out.fm_info_trash = out.updated_0_fm_info_trash; - out.fm_info_allFiles = 'Contains all the files from "Documents", "Unsorted" and "Trash". You can\'t move or remove files from here.'; // Same here - out.fm_info_anonymous = 'You are not logged in so your pads will expire after 3 months (find out more). ' + - 'They are stored in your browser so clearing history may make them disappear.
    ' + - 'Sign up or Log in to keep them alive.
    '; - out.fm_info_sharedFolder = "This is a shared folder. You're not logged in so you can only access it in read-only mode.
    " + - 'Sign up or Log in to be able to import it to your CryptDrive and to modify it.'; - out.fm_info_owned = "You are the owner of the pads displayed here. This means you can remove them permanently from the server whenever you want. If you do so, other users won't be able to access them anymore."; - out.fm_alert_backupUrl = "Backup link for this drive.
    " + - "It is highly recommended that you keep it secret.
    " + - "You can use it to retrieve all your files in case your browser memory got erased.
    " + - "Anybody with that link can edit or remove all the files in your file manager.
    "; - out.fm_alert_anonymous = "Hello there, you are currently using CryptPad anonymously, that's ok but your pads may be deleted after a period of " + - "inactivity. We have disabled advanced features of the drive for anonymous users because we want to be clear that it is " + - 'not a safe place to store things. You can read more about ' + - 'why we are doing this and why you really should Sign up and Log in.'; - out.fm_backup_title = 'Backup link'; - out.fm_nameFile = 'How would you like to name that file?'; - out.fm_error_cantPin = "Internal server error. Please reload the page and try again."; - out.fm_viewListButton = "List view"; - out.fm_viewGridButton = "Grid view"; - out.fm_renamedPad = "You've set a custom name for this pad. Its shared title is:
    {0}"; - out.fm_canBeShared = "This folder can be shared"; - out.fm_prop_tagsList = "Tags"; - out.fm_burnThisDriveButton = "Erase all information stored by CryptPad in your browser"; - out.fm_burnThisDrive = "Are you sure you want to remove everything stored by CryptPad in your browser?
    " + - "This will remove your CryptDrive and its history from your browser, but your pads will still exist (encrypted) on our server."; - out.fm_padIsOwned = "You are the owner of this pad"; - out.fm_padIsOwnedOther = "This pad is owned by another user"; - out.fm_deletedPads = "These pads no longer exist on the server, they've been removed from your CryptDrive: {0}"; - out.fm_tags_name = "Tag name"; - out.fm_tags_used = "Number of uses"; - out.fm_restoreDrive = "Resetting your drive to an earlier state. For best results, avoid making changes to your drive until this process is complete."; - out.fm_moveNestedSF = "You can't place one shared folder within another. The folder {0} was not moved."; - // File - Context menu - out.fc_newfolder = "New folder"; - out.fc_newsharedfolder = "New shared folder"; - out.fc_rename = "Rename"; - out.fc_open = "Open"; - out.fc_open_ro = "Open (read-only)"; - out.fc_delete = "Move to trash"; - out.fc_delete_owned = "Delete from the server"; - out.fc_restore = "Restore"; - out.fc_remove = "Remove from your CryptDrive"; - out.fc_remove_sharedfolder = "Remove"; - out.fc_empty = "Empty the trash"; - out.fc_prop = "Properties"; - out.fc_hashtag = "Tags"; - out.fc_sizeInKilobytes = "Size in Kilobytes"; - // fileObject.js (logs) - out.fo_moveUnsortedError = "You can't move a folder to the list of templates"; - out.fo_existingNameError = "Name already used in that directory. Please choose another one."; - out.fo_moveFolderToChildError = "You can't move a folder into one of its descendants"; - out.fo_unableToRestore = "Unable to restore that file to its original location. You can try to move it to a new location."; - out.fo_unavailableName = "A file or a folder with the same name already exist at the new location. Rename the element and try again."; - - out.fs_migration = "Your CryptDrive is being updated to a new version. As a result, the current page has to be reloaded.
    Please reload this page to continue to use it."; - - // login - out.login_login = "Log in"; - out.login_makeAPad = 'Create a pad anonymously'; - out.login_nologin = "Browse local pads"; - out.login_register = "Sign up"; - out.logoutButton = "Log out"; - out.settingsButton = "Settings"; - - out.login_username = "Username"; - out.login_password = "Password"; - out.login_confirm = "Confirm your password"; - out.login_remember = "Remember me"; - - out.login_hashing = "Hashing your password, this might take some time."; - - out.login_hello = 'Hello {0},'; // {0} is the username - out.login_helloNoName = 'Hello,'; - out.login_accessDrive = 'Access your drive'; - out.login_orNoLogin = 'or'; - - out.login_noSuchUser = 'Invalid username or password. Try again, or sign up'; - out.login_invalUser = 'Username required'; - out.login_invalPass = 'Password required'; - out.login_unhandledError = 'An unexpected error occurred :('; - - out.register_importRecent = "Import pads from your anonymous session"; - out.register_acceptTerms = "I accept the terms of service"; - out.register_passwordsDontMatch = "Passwords do not match!"; - out.register_passwordTooShort = "Passwords must be at least {0} characters long."; - - out.register_mustAcceptTerms = "You must accept the terms of service."; - out.register_mustRememberPass = "We cannot reset your password if you forget it. It's very important that you remember it! Please check the checkbox to confirm."; - - out.register_whyRegister = "Why sign up?"; - out.register_header = "Welcome to CryptPad"; - out.register_explanation = [ - "

    Lets go over a couple things first:

    ", - "
      ", - "
    • Your password is your secret key which encrypts all of your pads. If you lose it there is no way we can recover your data.
    • ", - "
    • You can import pads which were recently viewed in your browser so you have them in your account.
    • ", - "
    • If you are using a shared computer, you need to log out when you are done, closing the tab is not enough.
    • ", - "
    " - ].join(''); - - out.register_writtenPassword = "I have written down my username and password, proceed"; - out.register_cancel = "Go back"; - - out.register_warning = "Zero Knowledge means that we can't recover your data if you lose your password."; - - out.register_alreadyRegistered = "This user already exists, do you want to log in?"; - - // Settings - out.settings_cat_account = "Account"; - out.settings_cat_drive = "CryptDrive"; - out.settings_cat_cursor = "Cursor"; - out.settings_cat_code = "Code"; - out.settings_cat_pad = "Rich text"; - out.settings_cat_creation = "New pad"; - out.settings_cat_subscription = "Subscription"; - out.settings_title = "Settings"; - out.settings_save = "Save"; - - out.settings_backupCategory = "Backup"; - out.settings_backupHint = "Backup or restore all your CryptDrive's content. It won't contain the content of your pads, just the keys to access them."; - out.settings_backup = "Backup"; - out.settings_restore = "Restore"; - - out.settings_backupHint2 = "Download the current content of all your pads. Pads will be downloaded in an readable format if such a format is available."; - out.settings_backup2 = "Download my CryptDrive"; - out.settings_backup2Confirm = "This will download all the pads and files from your CryptDrive. If you want to continue, pick a name and press OK"; - out.settings_exportTitle = "Export your CryptDrive"; - out.settings_exportDescription = "Please wait while we're downloading and decrypting your documents. This may take a few minutes. Closing the tab will interrupt the process."; - out.settings_exportFailed = "If a pad requires more than 1 minute to be downloaded, it won't be included in the export. A link to any pad that has not been exported will be displayed."; - out.settings_exportWarning = "Note: this tool is still in a beta version and it might have scalability issues. For better performance, it is recommended to leave this tab focused."; - out.settings_exportCancel = "Are you sure you want to cancel the export? You will have to start again from the beginning next time."; - out.settings_export_reading = "Reading your CryptDrive..."; - out.settings_export_download = "Downloading and decrypting your documents..."; - out.settings_export_compressing = "Compressing data..."; - out.settings_export_done = "Your download is ready!"; - out.settings_exportError = "View errors"; - out.settings_exportErrorDescription = "We weren't able to add the following documents into the export:"; - out.settings_exportErrorEmpty = "This document can't be exported (empty or invalid content)."; - out.settings_exportErrorMissing = "This document is missing from our servers (expired or deleted by its owner)"; - out.settings_exportErrorOther = "An error occurred while trying to export this document: {0}"; - - out.settings_resetNewTitle = "Clean CryptDrive"; - out.settings_resetButton = "Remove"; - out.settings_reset = "Remove all the files and folders from your CryptDrive"; - out.settings_resetPrompt = "This action will remove all the pads from your drive.
    "+ - "Are you sure you want to continue?
    " + - "Type “I love CryptPad” to confirm."; - out.settings_resetDone = "Your drive is now empty!"; - out.settings_resetError = "Incorrect verification text. Your CryptDrive has not been changed."; - - out.settings_resetTipsAction = "Reset"; - out.settings_resetTips = "Tips"; - out.settings_resetTipsButton = "Reset the available tips in CryptDrive"; - out.settings_resetTipsDone = "All the tips are now visible again."; - - out.settings_thumbnails = "Thumbnails"; - out.settings_disableThumbnailsAction = "Disable thumbnails creation in your CryptDrive"; - out.settings_disableThumbnailsDescription = "Thumbnails are automatically created and stored in your browser when you visit a new pad. You can disable this feature here."; - out.settings_resetThumbnailsAction = "Clean"; - out.settings_resetThumbnailsDescription = "Clean all the pads thumbnails stored in your browser."; - out.settings_resetThumbnailsDone = "All the thumbnails have been erased."; - - out.settings_importTitle = "Import this browser's recent pads in your CryptDrive"; - out.settings_import = "Import"; - out.settings_importConfirm = "Are you sure you want to import recent pads from this browser to your user account's CryptDrive?"; - out.settings_importDone = "Import completed"; - - out.settings_autostoreTitle = "Pad storage in CryptDrive"; - out.settings_autostoreHint = "Automatic All the pads you visit are stored in your CryptDrive.
    " + - "Manual (always ask) If you have not stored a pad yet, you will be asked if you want to store them in your CryptDrive.
    " + - "Manual (never ask) Pads are not stored automatically in your CryptDrive. The option to store them will be hidden."; - out.settings_autostoreYes = "Automatic"; - out.settings_autostoreNo = "Manual (never ask)"; - out.settings_autostoreMaybe = "Manual (always ask)"; - - out.settings_userFeedbackTitle = "Feedback"; - out.settings_userFeedbackHint1 = "CryptPad provides some very basic feedback to the server, to let us know how to improve your experience. "; - out.settings_userFeedbackHint2 = "Your pad's content will never be shared with the server."; - out.settings_userFeedback = "Enable user feedback"; - - out.settings_deleteTitle = "Account deletion"; - out.settings_deleteHint = "Account deletion is permanent. Your CryptDrive and your list of pads will be deleted from the server. The rest of your pads will be deleted in 90 days if nobody else has stored them in their CryptDrive."; - out.settings_deleteButton = "Delete your account"; - out.settings_deleteModal = "Share the following information with your CryptPad administrator in order to have your data removed from their server."; - out.settings_deleteConfirm = "Clicking OK will delete your account permanently. Are you sure?"; - out.settings_deleted = "Your user account is now deleted. Press OK to go to the home page."; - - out.settings_anonymous = "You are not logged in. Settings here are specific to this browser."; - out.settings_publicSigningKey = "Public Signing Key"; - - out.settings_usage = "Usage"; - out.settings_usageTitle = "See the total size of your pinned pads in MB"; - out.settings_pinningNotAvailable = "Pinned pads are only available to registered users."; - out.settings_pinningError = "Something went wrong"; - out.settings_usageAmount = "Your pinned pads occupy {0}MB"; - - out.settings_logoutEverywhereButton = "Log out"; - out.settings_logoutEverywhereTitle = "Log out everywhere"; - out.settings_logoutEverywhere = "Force log out of all other web sessions"; - out.settings_logoutEverywhereConfirm = "Are you sure? You will need to log in with all your devices."; - - out.settings_driveDuplicateTitle = "Duplicated owned pads"; - out.settings_driveDuplicateHint = "When you move your owned pads to a shared folder, a copy is kept in your CryptDrive to ensure that you retain your control over it. You can hide duplicated files. Only the shared version will be visible, unless deleted, in which case the original will be displayed in its previous location."; - out.settings_driveDuplicateLabel = "Hide duplicates"; - - out.settings_codeIndentation = 'Code editor indentation (spaces)'; - out.settings_codeUseTabs = "Indent using tabs (instead of spaces)"; - out.settings_codeFontSize = "Font size in the code editor"; - - out.settings_padWidth = "Editor's maximum width"; - out.settings_padWidthHint = "Rich text pads use by default the maximum available width on your screen and it can be difficult to read. You can reduce the editor's width here."; - out.settings_padWidthLabel = "Reduce the editor's width"; - out.settings_padSpellcheckTitle = "Spellcheck"; - out.settings_padSpellcheckHint = "This option allows you to enable spellcheck in rich text pads. Spelling errors will be underlined in red and you'll have to hold your Ctrl or Meta key while right-clicking to see the correct options."; - out.settings_padSpellcheckLabel = "Enable spellcheck in rich text pads"; - - out.settings_creationSkip = "Skip the pad creation screen"; - out.settings_creationSkipHint = "The pad creation screen offers new options to create a pad, providing you more control and security over your data. However, it may slow down your workflow by adding one additional step so, here, you have the option to skip this screen and use the default settings selected above."; - out.settings_creationSkipTrue = "Skip"; - out.settings_creationSkipFalse = "Display"; - - out.settings_templateSkip = "Skip the template selection modal"; - out.settings_templateSkipHint = "When you create a new empty pad, if you have stored templates for this type of pad, a modal appears to ask if you want to use a template. Here you can choose to never show this modal and so to never use a template."; - - out.settings_ownDriveTitle = "Enable latest account features"; - out.settings_ownDriveHint = "For technical reasons, older accounts do not have access to all of our latest features. A free upgrade to a new account will prepare your CryptDrive for upcoming features without disrupting your usual activities."; - out.settings_ownDriveButton = "Upgrade your account"; - out.settings_ownDriveConfirm = "Upgrading your account may take some time. You will need to log back in on all your devices. Are you sure?"; - out.settings_ownDrivePending = "Your account is being upgraded. Please do not close or reload this page until the process has completed."; - - out.settings_changePasswordTitle = "Change your password"; - out.settings_changePasswordHint = "Change your account's password. Enter your current password, and confirm the new password by typing it twice.
    " + - "We can't reset your password if you forget it, so be very careful!"; - out.settings_changePasswordButton = "Change password"; - out.settings_changePasswordCurrent = "Current password"; - out.settings_changePasswordNew = "New password"; - out.settings_changePasswordNewConfirm = "Confirm new password"; - out.settings_changePasswordConfirm = "Are you sure you want to change your password? You will need to log back in on all your devices."; - out.settings_changePasswordError = "An unexpected error occurred. If you are unable to login or change your password, contact your CryptPad administrators."; - out.settings_changePasswordPending = "Your password is being updated. Please do not close or reload this page until the process has completed."; - out.settings_changePasswordNewPasswordSameAsOld = "Your new password must be different than your current password."; - - out.settings_cursorColorTitle = "Cursor color"; - out.settings_cursorColorHint = "Change the color associated with your user in collaborative documents."; - out.settings_cursorShareTitle = "Share my cursor position"; - out.settings_cursorShareHint = "You can decide if you want other users to see your cursor position in collaborative documents."; - out.settings_cursorShareLabel = "Share the position"; - out.settings_cursorShowTitle = "Display other users' cursor position"; - out.settings_cursorShowHint = "You can choose if you want to see the other users' cursor in collaborative documents."; - out.settings_cursorShowLabel = "Show cursors"; - - out.upload_title = "File upload"; - out.upload_type = "Type"; - out.upload_modal_title = "File upload options"; - out.upload_modal_filename = "File name (extension {0} added automatically)"; - out.upload_modal_owner = "Owned file"; - out.upload_serverError = "Server Error: unable to upload your file at this time."; - out.upload_uploadPending = "You already have an upload in progress. Cancel it and upload your new file?"; - out.upload_success = "Your file ({0}) has been successfully uploaded and added to your drive."; - out.upload_notEnoughSpace = "There is not enough space for this file in your CryptDrive."; - out.upload_notEnoughSpaceBrief = "Not enough space"; - out.upload_tooLarge = "This file exceeds the maximum upload size."; - out.upload_tooLargeBrief = 'File too large'; - out.upload_choose = "Choose a file"; - out.upload_pending = "Pending"; - out.upload_cancelled = "Cancelled"; - out.upload_name = "File name"; - out.upload_size = "Size"; - out.upload_progress = "Progress"; - out.upload_mustLogin = "You must be logged in to upload files"; - out.upload_up = "Upload"; - out.download_button = "Decrypt & Download"; - out.download_mt_button = "Download"; - out.download_resourceNotAvailable = "The requested resource was not available... Press Esc to continue."; - out.download_dl = "Download"; - out.download_step1 = "Downloading"; - out.download_step2 = "Decrypting"; - - out.todo_title = "CryptTodo"; - out.todo_newTodoNamePlaceholder = "Describe your task..."; - out.todo_newTodoNameTitle = "Add this task to your todo list"; - out.todo_markAsCompleteTitle = "Mark this task as complete"; - out.todo_markAsIncompleteTitle = "Mark this task as incomplete"; - out.todo_removeTaskTitle = "Remove this task from your todo list"; - - // pad - out.pad_showToolbar = "Show toolbar"; - out.pad_hideToolbar = "Hide toolbar"; - out.pad_base64 = "This pad contains images stored in an inefficient way. These images will significantly increase the size of the pad in your CryptDrive, and make it slower to load. You can migrate these files to a new format which will be stored separately in your CryptDrive. Do you want to migrate these images now?"; - - // markdown toolbar - out.mdToolbar_button = "Show or hide the Markdown toolbar"; - out.mdToolbar_defaultText = "Your text here"; - out.mdToolbar_help = "Help"; - out.mdToolbar_tutorial = "http://www.markdowntutorial.com/"; - out.mdToolbar_bold = "Bold"; - out.mdToolbar_italic = "Italic"; - out.mdToolbar_strikethrough = "Strikethrough"; - out.mdToolbar_heading = "Heading"; - out.mdToolbar_link = "Link"; - out.mdToolbar_quote = "Quote"; - out.mdToolbar_nlist = "Ordered list"; - out.mdToolbar_list = "Bullet list"; - out.mdToolbar_check = "Task list"; - out.mdToolbar_code = "Code"; - - // index.html - - out.home_product = "CryptPad is a private-by-design alternative to popular office tools and cloud services. All the content stored on CryptPad is encrypted before being sent, which means nobody can access your data unless you give them the keys (not even us)."; - out.home_host = "This is an independent community instance of CryptPad. Its source code is available on GitHub."; - out.home_host_agpl = "CryptPad is distributed under the terms of the AGPL3 software license"; - out.home_ngi = "NGI Award winner"; - - //about.html - out.about_intro = 'CryptPad is created inside of the Research Team at XWiki SAS, a small business located in Paris France and Iasi Romania. There are 3 core team members working on CryptPad plus a number of contributors both inside and outside of XWiki SAS.'; - out.about_core = 'Core Developers'; - out.about_contributors = 'Key Contributors'; - - // contact.html - out.main_about_p22 = 'Tweet us'; - out.main_about_p23 = 'open an issue on GitHub'; - out.main_about_p24 = 'say Hello (Matrix)'; - out.main_about_p25 = 'send us an email'; - out.main_about_p26 = 'If you have any questions or comments, feel free to reach out!'; - - out.main_info = "

    Collaborate in Confidence

    Grow your ideas together with shared documents while Zero Knowledge technology secures your privacy; even from us."; - out.main_catch_phrase = "The Zero Knowledge Cloud"; - - out.main_richText = 'Rich Text editor'; - out.main_code = 'Code editor'; - out.main_slide = 'Slide editor'; - out.main_poll = 'Polls'; - out.main_drive = 'CryptDrive'; - - out.main_richTextPad = 'Rich Text Pad'; - out.main_codePad = 'Markdown/Code Pad'; - out.main_sheetPad = 'Spreadsheets (Beta)'; - out.main_slidePad = 'Markdown Presentation'; - out.main_pollPad = 'Poll or Schedule'; - out.main_whiteboardPad = 'Whiteboard'; - out.main_kanbanPad = 'Kanban'; - out.main_localPads = 'Local Pads'; - out.main_yourCryptDrive = 'Your CryptDrive'; - out.main_footerText = "With CryptPad, you can make quick collaborative documents for taking notes and writing down ideas together."; - - out.footer_applications = "Applications"; - out.footer_contact = "Contact"; - out.footer_aboutUs = "About us"; - - out.about = "About"; - out.privacy = "Privacy"; - out.contact = "Contact"; - out.terms = "ToS"; - out.blog = "Blog"; - - out.topbar_whatIsCryptpad = "What is CryptPad"; - - // what-is-cryptpad.html - - out.whatis_title = 'What is CryptPad'; - out.whatis_collaboration = 'Fast, Easy Collaboration'; - out.whatis_collaboration_p1 = 'With CryptPad, you can make quick collaborative documents for taking notes and writing down ideas together. When you sign up and log in, you get file upload capability and a CryptDrive where you can organize all of your pads. As a registered user you get 50MB of space for free.'; - out.whatis_collaboration_p2 = 'You can share access to a CryptPad document simply by sharing the link. You can also share a link which provides read only access to a pad, allowing you to publicise your collaborative work while still being able to edit it.'; - out.whatis_collaboration_p3 = 'You can make simple rich text documents with CKEditor as well as Markdown documents which are rendered in realtime while you type. You can also use the poll app for scheduling events with multiple participants.'; - out.whatis_zeroknowledge = 'Zero Knowledge'; - out.whatis_zeroknowledge_p1 = "We don't want to know what you're typing and with modern cryptography, you can be sure that we can't know. CryptPad uses 100% client side encryption to protect the content that you type from us, the people who host the server."; - out.whatis_zeroknowledge_p2 = 'When you sign up and log in, your username and password are computed into a secret key using scrypt key derivation function. Neither this key, nor the username and password are ever sent to the server. Instead they are used on the client side to decrypt the content of your CryptDrive, which contains the keys to all pads that you are able to access.'; - out.whatis_zeroknowledge_p3 = 'When you share the link to a document, you\'re sharing the cryptographic key for accessing that document but since the key is in the fragment identifier, it is never directly sent to the server. Check out our privacy blog post to learn more about what types of metadata we do and do not have access to.'; - out.whatis_drive = 'Organization with CryptDrive'; - out.whatis_drive_p1 = 'Whenever you access a pad in CryptPad, the pad is automatically added to your CryptDrive in the main folder. Later on, you can organize these pads into folders or you can put them in the trash bin. CryptDrive allows you to search through your pads and to organize them whenever you want, however you want.'; - out.whatis_drive_p2 = 'With intuitive drag-and-drop, you can move pads around in your drive and the link to these pads will stay the same so your collaborators will never lose access.'; - out.whatis_drive_p3 = 'You can also upload files in your CryptDrive and share them with colleagues. Uploaded files can be organized just like collaborative pads.'; - out.whatis_business = 'CryptPad for Business'; - out.whatis_business_p1 = "CryptPad\'s Zero Knowledge encryption multiplies the effectiveness of existing security protocols by mirroring organizational access controls in cryptography. Because sensitive assets can only be decrypted using user access credentials, CryptPad is less valuable as a target when compared to traditional cloud services. Read the CryptPad Whitepaper to learn more about how it can help your business."; - out.whatis_business_p2 = 'CryptPad is deployable on premises and the CryptPad developers at XWiki SAS are able to offer commercial support, customization and development. Reach out to sales@cryptpad.fr for more information.'; - - // privacy.html - - out.policy_title = 'CryptPad Privacy Policy'; - out.policy_whatweknow = 'What we know about you'; - out.policy_whatweknow_p1 = 'As an application that is hosted on the web, CryptPad has access to metadata exposed by the HTTP protocol. This includes your IP address, and various other HTTP headers that can be used to identify your particular browser. You can see what information your browser is sharing by visiting WhatIsMyBrowser.com.'; - out.policy_whatweknow_p2 = 'We use Kibana, an open source analytics platform, to learn more about our users. Kibana tells us about how you found CryptPad, via direct entry, through a search engine, or via a referral from another web service like Reddit or Twitter.'; - out.policy_howweuse = 'How we use what we learn'; - out.policy_howweuse_p1 = 'We use this information to make better decisions about promoting CryptPad, by evaluating which of our past efforts were successful. Information about your location lets us know whether we should consider providing better support for languages other than English.'; - out.policy_howweuse_p2 = "Information about your browser (whether it's a desktop or mobile operating system) helps us make decisions when prioritizing feature improvements. Our development team is small, and we try to make choices that will improve as many users' experience as possible."; - out.policy_whatwetell = 'What we tell others about you'; - out.policy_whatwetell_p1 = 'We do not furnish to third parties the information that we gather or that you provide to us unless we are legally required to do so.'; - out.policy_links = 'Links to other sites'; - out.policy_links_p1 = 'This site contains links to other sites, including those produced by other organizations. We are not responsible for the privacy practices or the contents of any outside sites. As a general rule, links to outside sites are launched in a new browser window, to make clear that you are leaving CryptPad.fr.'; - out.policy_ads = 'Advertisement'; - out.policy_ads_p1 = 'We do not display any online advertising, though we may link to the bodies which are financing our research.'; - out.policy_choices = 'Choices you have'; - out.policy_choices_open = 'Our code is open source, so you always have the option of hosting your own instance of CryptPad.'; - out.policy_choices_vpn = 'If you want to use our hosted instance, but don\'t want to expose your IP address, you can protect your IP using the Tor browser bundle, or a VPN.'; - out.policy_choices_ads = 'If you just want to block our analytics platform, you can use adblocking tools like Privacy Badger.'; - - // features.html - - out.features = "Features"; - out.features_title = "Feature comparison"; - out.features_feature = "Feature"; - out.features_anon = "Anonymous user"; - out.features_registered = "Registered user"; - out.features_premium = "Premium user"; - out.features_notes = "Notes"; - - out.features_f_apps = "Access to the main applications"; - out.features_f_core = "Common features for the applications"; - out.features_f_core_note = "Edit, Import & Export, History, Userlist, Chat"; - out.features_f_file0 = "Open files"; - out.features_f_file0_note = "View and download files shared by other users"; - out.features_f_cryptdrive0 = "Limited access to CryptDrive"; - out.features_f_cryptdrive0_note = "Ability to store visited pads in your browser to be able to open them later"; - out.features_f_storage0 = "Limited storage time"; - out.features_f_storage0_note = "Created pads risk deletion after 3 months of inactivity"; - - out.features_f_anon = "All anonymous user features"; - out.features_f_anon_note = "With better usability and more power over your pads"; - out.features_f_cryptdrive1 = "Complete CryptDrive functionality"; - out.features_f_cryptdrive1_note = "Folders, shared folders, templates, tags"; - out.features_f_devices = "Your pads on all your devices"; - out.features_f_devices_note = "Access your CryptDrive everywhere with your user account"; - out.features_f_social = "Social applications"; - out.features_f_social_note = "Create a profile, use an avatar, chat with contacts"; - out.features_f_file1 = "Upload and share files"; - out.features_f_file1_note = "Share files with your friends or embed them in your pads"; - out.features_f_storage1 = "Permanent storage (50MB)"; - out.features_f_storage1_note = "Pads stored in your CryptDrive are never deleted for inactivity"; - out.features_f_register = "Register for free"; - out.features_f_register_note = "No email or personal information required"; - - out.features_f_reg = "All registered user features"; - out.features_f_reg_note = "And help CryptPad's development"; - out.features_f_storage2 = "Extra storage space"; - out.features_f_storage2_note = "From 5GB to 50GB depending on the selected plan"; - out.features_f_support = "Faster support"; - out.features_f_support_note = "Professional email support with the Team plan"; - out.features_f_supporter = "Become a privacy supporter"; - out.features_f_supporter_note = "Help us show that privacy-enhancing software should be the norm"; - out.features_f_subscribe = "Subscribe to premium"; - out.features_f_subscribe_note = "You need to be logged in to CryptPad first"; - - // faq.html - - out.faq_link = "FAQ"; - out.faq_title = "Frequently Asked Questions"; - out.faq_whatis = "What is CryptPad?"; - out.faq = {}; - out.faq.keywords = { - title: 'Keywords', - pad: { - q: "What is a pad?", - a: "Pad is a term popularized by Etherpad, a real-time collaborative editor.\n" + - "It refers to a document that you can edit in your browser, generally with other people's changes visible nearly instantly." - }, - owned: { - q: "What is an owned Pad?", - a: "An owned pad is a pad created with an explicit owner, identified to the server by their public signing key." + - " A pad's owner may choose to delete their pads from the server, making it unavailable to other collaborators in the future, whether they had it in their CryptDrive or not." - }, - expiring: { - q: "What is an expiring Pad?", - a: "An expiring pad is a pad created with a set time at which it will be automatically removed from the server." + - " Expiring pads can be configured to last anywhere from one hour to one hundred months." + - " The pad and all of its history will become permanently unavailable even if it is being edited at the time that it expires.

    " + - "If a pad is set to expire, you can check its expiration time by viewing its properties, either by right-clicking the pad in your CryptDrive, or by using the properties sub-menu from an application's toolbar." - }, - tag: { - q: "How can I use tags?", - a: "You can tag pads and uploaded files via your CryptDrive, or using the tag button () in any editor's toolbar." + - " Search for pads and files in your CryptDrive using the search bar with a term beginning with hashtag, like #crypto." - }, - template: { - q: "What is a template?", - a: "A template is a pad which can be used to define to initial content for another pad of the same type when you create it." + - " Any existing pad can be turned into a template by moving it into the Templates section in your CryptDrive." + - " You can also create a copy of a pad to be used as a template by clicking the template button () in the editor's toolbar." - }, - abandoned: { - q: "What is an abandoned pad?", - a: "An abandoned pad is a pad that is not pinned in any registered user's CryptDrive and that hasn't been changed for six months. Abandoned documents will be automatically removed from the server." - }, - }; - out.faq.privacy = { - title: 'Privacy', - different: { - q: "How is CryptPad different from other Pad services?", - a: "CryptPad encrypts changes to your pads before sending that information to be stored on the server, so we can't read what you're typing." - }, - me: { - q: "What information does the server know about me?", - a: "Server administrators are able to see the IP addresses of people who visit the CryptPad." + - " We don't record which addresses visit which pads, but we could, even though we don't have access to the decrypted content of those pads." + - " If you are worried about us analyzing that information, it's safest to assume that we do collect it, since we can't prove that we don't.

    " + - - "We collect some basic telemetry about how people use CryptPad, such as the size of the screen on their device, and which buttons they click the most." + - "This helps us improve the software, but if you'd prefer not to send such information to the server, you can opt out by unchecking the Enable user feedback checkbox.

    " + - - "We do keep track of which pads are in a user's CryptDrive so that we can impose storage limits, but we don't know the content or type of those pads." + - " Storage quotas are associated with a user's public key, but we don't associate names or emails with those public keys.

    " + - - " For more information, you can read this blog post which we wrote about the topic." - }, - register: { - q: "Does the server know more about me if I register?", - a: "We don't require users to verify their email address, and the server does not even learn your username or password when you register." + - " Instead, the register and login forms generate a unique keyring from your input, and the server only learns your cryptographic signature." + - " We use this information to track details like how much data you are using, which allows us to restrict each user to a quota.

    " + - - "We use our feedback functionality to inform the server that someone with your IP has registered an account." + - " We use this to measure how many people register for CryptPad accounts, and to see what regions they are in so that we can guess which languages may need better support.

    " + - - "Registered users inform the server which pads are in their CryptDrive so that such pads are not considered abandoned, and are removed from the server due to inactivity." - }, - other: { - q: "What can other collaborators learn about me?", - a: "When you edit a pad with someone else, you communicate through the server, so only we learn your IP address." + - " Other users can see your display name, avatar, the link to your profile (if you have one), and your public key (which is used for encrypting communications between each other)." - }, - anonymous: { - q: "Does CryptPad make me anonymous?", - a: "Even though CryptPad is designed to know as little about you as possible, it does not provide strong anonymity." + - " Our servers have access to your IP address, however, you can hide this information by using Tor to access CryptPad." + - " Using Tor without changing your behaviour will not guarantee you anonymity, as the server is also able to identify users by their unique cryptographic identifier." + - " If you use the same account when you're not using Tor, it will be possible to deanonymize your session.

    " + - - "For users who require a lesser degree of privacy, CryptPad does not require users to identify themselves by name, phone number, or email address like many other services." - }, - policy: { - q: "Do you have a data privacy policy?", - a: "Yes! It is available here." - } - }; - out.faq.security = { - title: 'Security', - proof: { - q: "How do you use Zero Knowledge Proofs?", - a: "When we use the term Zero Knowledge, we are not referring to Zero Knowledge proofs, but to Zero Knowledge Web Services." + - " Zero Knowledge Web Services encrypt user data in the user's browser, without the server ever having access to the unencrypted data, or the encryption keys.

    " + - "We've compiled a short list of Zero Knowledge services here." - }, - why: { - q: "Why should I use CryptPad?", - a: "Our position is that cloud services should not require access to your data in order for you to share it with your friends and colleagues." + - " If you are using another service to collaborate, and they do not explicitly say that they can't access your information, it is very likely that they are leveraging it for profit." - }, - compromised: { - q: "Does CryptPad protect me if my device is compromised?", - a: "In the event that your device is stolen, CryptPad allows you to trigger a remote logout of all devices except the one you are currently using." + - " To do so, go to your settings page and click Log out everywhere." + - " All other devices which are currently connected to the account will log out." + - " Any previously connected devices which visit CryptPad will log out as soon as they load the page.

    " + - - "Currently, remote logout is implemented in the browser, not in conjunction with the server." + - " As such, it may not protect you from government agencies, but it should be sufficient if you forgot to log out after using CryptPad from a shared computer." - }, - crypto: { - q: "What cryptography do you use?", - a: "CryptPad is based upon two open-source cryptography libraries: tweetnacl.js and scrypt-async.js.

    " + - - "Scrypt is a password-based key derivation algorithm. We use it to turn your username and password into a unique keyring which secures access to your CryptDrive such that only you can access your list of pads.

    " + - - "We use the xsalsa20-poly1305 and x25519-xsalsa20-poly1305 cyphers provided by tweetnacl to encrypt pads and chat history, respectively." - } - }; - out.faq.usability = { - title: 'Usability', - register: { - q: "What do I get by registering?", - a: "Registered users have access to a number of features unavailable to unregistered users. There's a chart here." - }, - share: { - q: "How can I share encrypted pads with my friends?", - a: "CryptPad puts the secret encryption key to your pad after the # character in the URL." + - " Anything after this character is not sent to the server, so we never have access to your encryption keys." + - " By sharing the link to a pad, you share the ability to read and access it." - }, - remove: { - q: "I removed a pad or file from my CryptDrive, but the content is still available. How can I remove it?", - a: "Only owned pads (introduced in February 2018) can be deleted. Additionally, these pads can only be deleted by their owners (the person that originally created the pad)." + - " If you are not the creator of the pad, you will have to ask its owner to delete it for you." + - " For pads you do own, you can right-click the pad in your CryptDrive, and choose Delete from the server." - }, - forget: { - q: "What if I forget my password?", - a: "Unfortunately, if we could recover access to your encrypted pads for you, we'd be able to access them ourselves." + - " If you did not record your username and password anywhere, and cannot remember either, you may be able to recover your pads by filtering your browser's history." - }, - change: { - q: "What if I want to change my password?", - a: "You can change your CryptPad password in your account settings page." - }, - devices: { - q: "I am logged in on two devices, and see two different CryptDrives, how is this possible?", - a: "It's probable that you registered the same name twice, using different passwords." + - " Because the CryptPad server identifies you by your cryptographic signature and not your name, it cannot prevent others from registering with the same name." + - " As such, each user account has a unique username and password combination." + - " Logged in users can see their username at the top of the settings page." - }, - folder: { - q: "Can I share entire folders from my CryptDrive?", - a: "Yes, you can share folders and all the pads in them." - }, - feature: { - q: "Can you add a very special feature which I need?", - a: "Many of the features in CryptPad exist because users asked for them." + - " Our contacts page lists the ways that you can reach us.

    " + - - "Unfortunately, we cannot guarantee that we will implement everything that people ask for." + - " If a particular feature is critical for your organization, you can sponsor development time to ensure its completion." + - " Please contact sales@cryptpad.fr for more information.

    " + - - "Even if you cannot afford to sponsor development, we're interested in feedback that can help us improve CryptPad." + - " Feel free to contact us with via the above methods any time." - }, - }; - out.faq.other = { - title: "Other questions", - pay: { - q: "Why should I pay when so many features are free?", - a: "We give supporters additional storage and the ability to increase their friends' quotas (learn more).

    " + - - "Beyond these short term benefits, by subscribing with a premium account you help to fund continued, active development of CryptPad. That includes fixing bugs, adding new features, and making it easier for others to help host CryptPad themselves." + - " Additionally, you help to prove to other service providers that people are willing to support privacy enhancing technologies. It is our hope that eventually business models based on selling user data will become a thing of the past.

    " + - - "Finally, we offer most of CryptPad's functionality for free because we believe everyone deserves personal privacy, not just those with disposable income." + - " By supporting us, you help us continue to make it possible for underprivileged populations to access these basic features without a price tag attached." - }, - goal: { - q: "What is your goal?", - a: "By developing privacy-respecting collaboration technology, we wish to raise users' expectations of privacy from cloud-computing platforms." + - " We hope that our work drives other service providers in all domains to match or exceed our efforts." + - " Despite our optimism, we know that much of the web is funded by revenue from targeted advertising." + - " There is much more work to be done than we can manage ourselves, and we appreciate the promotion, support, and contributions of our community towards this goal." - }, - jobs: { - q: "Are you hiring?", - a: "Yes! Please introduce yourself with an email to jobs@xwiki.com." - }, - host: { - q: "Can you help me set up my own instance of CryptPad?", - a: "We are happy to provide support for your organization's internal CryptPad installation. Please contact sales@cryptpad.fr for more information." - }, - revenue: { - q: "How can I participate in the revenue sharing?", - a: " If you are running your own instance of CryptPad, and would like to enable paid accounts and split the revenue with the developers, your server will need to be configured as a partner service.

    " + - - "In your CryptPad directory, config.example.js should contain an explanation of what you need to configure on your server." + - " You will need to contact sales@cryptpad.fr to verify that your server is configured to use HTTPS correctly, and discuss payment methods." - }, - }; - - // terms.html - - out.tos_title = "CryptPad Terms of Service"; - out.tos_legal = "Please don't be malicious, abusive, or do anything illegal."; - out.tos_availability = "We hope you find this service useful, but availability or performance cannot be guaranteed. Please export your data regularly."; - out.tos_e2ee = "CryptPad contents can be read or modified by anyone who can guess or otherwise obtain the pad's fragment identifier. We recommend that you use end-to-end-encrypted (e2ee) messaging technology to share links, and assume no liability in the event that such a link is leaked."; - out.tos_logs = "Metadata provided by your browser to the server may be logged for the purpose of maintaining the service."; - out.tos_3rdparties = "We do not provide individualized data to third parties unless required to by law."; - - // 404 page - out.four04_pageNotFound = "We couldn't find the page you were looking for."; - - // BottomBar.html - - //out.bottom_france = 'Made with love in France'; - //out.bottom_support = 'An XWiki SAS Labs Project with the support of OpenPaaS-ng'; - - // Header.html - - out.updated_0_header_logoTitle = 'Go to your CryptDrive'; - out.header_logoTitle = out.updated_0_header_logoTitle; - out.header_homeTitle = 'Go to CryptPad homepage'; - - // Initial states - - out.help = {}; - - out.help.title = "Getting started"; - out.help.generic = { - more: 'Learn more about how CryptPad can work for you by reading our FAQ', - share: 'Use the share menu () to generate a link so collaborators can view or edit this pad', - //stored: 'Every pad you visit is automatically stored in your CryptDrive', - save: "All your changes are synced automatically so you never need to save" - }; - - out.help.text = { - formatting: 'You can display or hide the text formatting toolbar by clicking the or buttons', - embed: 'Registered users can embed an image or a file stored in their CryptDrive using ', - history: 'You can use history to view or restore previous versions', - }; - - out.help.pad = { - export: 'You can export the content as PDF using the button in the text formatting toolbar', - }; - - out.help.code = { - modes: 'Use the dropdown menus in the submenu to change syntax highlighting modes or color themes', - }; - - out.help.beta = { - warning: 'This editor is still experimental, you can report bugs on our issue tracker' - }; - out.help.oo = { - access: "Access is restricted to registered users, collaborators will need to log in", - }; - - out.help.slide = { - markdown: 'Write slides in Markdown and separate them with a line containing ---', - present: 'Start the presentation using the button', - settings: 'Change the slide settings (background, transitions, page numbers, etc.) with the button in the submenu', - colors: 'Change the text and background colors using the and buttons', - }; - - out.help.poll = { - decisions: 'Make decisions in private among trusted friends', - options: 'Propose options, and express your preferences', - choices: 'Click cells in your column to cycle through yes (), maybe (~), or no ()', - submit: 'Click submit to make your choices visible to others', - }; - - out.help.whiteboard = { - colors: 'Double-click colors to modify your palette', - mode: 'Disable draw mode to drag and stretch strokes', - embed: 'Embed images from your disk or your CryptDrive and export them as PNG to your disk or your CryptDrive ' - }; - - out.help.kanban = { - add: 'Add new boards using the button in the top-right corner', - task: 'Move items by dragging and dropping them from one board to another', - color: 'Change the colors by clicking on the colored part next to the board titles', - }; - - out.initialState = [ - '

    ', - 'This is CryptPad, the Zero Knowledge realtime collaborative editor. Everything is saved as you type.', - '
    ', - 'Share the link to this pad to edit with friends or use the button to share a read-only link which allows viewing but not editing.', - '

    ', - ].join(''); - - out.codeInitialState = [ - '# CryptPad\'s Zero Knowledge collaborative code editor\n', - '\n', - '* What you type here is encrypted so only people who have the link can access it.\n', - '* You can choose the programming language to highlight and the UI color scheme in the upper right.' - ].join(''); - - out.slideInitialState = [ - '# CryptSlide\n', - '1. Write your slides content using markdown syntax\n', - ' - Learn more about markdown syntax [here](http://www.markdowntutorial.com/)\n', - '2. Separate your slides with ---\n', - '3. Click on the "Play" button to see the result', - ' - Your slides are updated in realtime' - ].join(''); - - // Readme - - out.driveReadmeTitle = "What is CryptPad?"; - out.readme_welcome = "Welcome to CryptPad!"; - out.readme_p1 = "Welcome to CryptPad, this is where you can take note of things alone and with friends."; - out.readme_p2 = "This pad will give you a quick walk through of how you can use CryptPad to take notes, keep them organized and work together on them."; - out.readme_cat1 = "Get to know your CryptDrive"; - out.readme_cat1_l1 = "Make a pad: In your CryptDrive, click {0} then {1} and you can make a pad."; // 0: New, 1: Rich Text - out.readme_cat1_l2 = "Open Pads from your CryptDrive: double-click on a pad icon to open it."; - out.readme_cat1_l3 = "Organize your pads: When you are logged in, every pad you access will be shown as in the {0} section of your drive."; // 0: Unsorted files - out.readme_cat1_l3_l1 = "You can click and drag files into folders in the {0} section of your drive and make new folders."; // 0: Documents - out.readme_cat1_l3_l2 = "Remember to try right clicking on icons because there are often additional menus."; - out.readme_cat1_l4 = "Put old pads in the trash: You can click and drag your pads into the {0} the same way you drag them into folders."; // 0: Trash - out.readme_cat2 = "Make pads like a pro"; - out.edit = "edit"; - out.view = "view"; - out.readme_cat2_l1 = "The {0} button in your pad allows you to give access to collaborators to either {1} or to {2} the pad."; // 0: Share, 1: edit, 2: view - out.readme_cat2_l2 = "Change the title of the pad by clicking on the pencil"; - out.readme_cat3 = "Discover CryptPad apps"; - out.readme_cat3_l1 = "With CryptPad code editor, you can collaborate on code like JavaScript, HTML and Markdown"; - out.readme_cat3_l2 = "With CryptPad slide editor, you can make quick presentations using Markdown"; - out.readme_cat3_l3 = "With CryptPoll you can take quick votes, especially for scheduling meetings which fit with everybody's calendar"; - - // Tips - out.tips = {}; - out.tips.shortcuts = "`ctrl+b`, `ctrl+i` and `ctrl+u` are quick shortcuts for bold, italic and underline."; - out.tips.indent = "In numbered and bulleted lists, you can use tab or shift+tab to quickly increase or decrease indentation."; - out.tips.store = "Every time you visit a pad, if you're logged in it will be saved to your CryptDrive."; - out.tips.marker = "You can highlight text in a pad using the \"marker\" item in the styles dropdown menu."; - out.tips.driveUpload = "Registered users can upload encrypted files by dragging and dropping them into their CryptDrive."; - out.tips.filenames = "You can rename files in your CryptDrive, this name is just for you."; - out.tips.drive = "Logged in users can organize their files in their CryptDrive, accessible from the CryptPad icon at the top left of all pads."; - out.tips.profile = "Registered users can create a profile from the user menu in the top right."; - out.tips.avatars = "You can upload an avatar in your profile. People will see it when you collaborate in a pad."; - out.tips.tags = "Tag your pads and start a search with # in your CryptDrive to find them"; - - out.feedback_about = "If you're reading this, you were probably curious why CryptPad is requesting web pages when you perform certain actions"; - out.feedback_privacy = "We care about your privacy, and at the same time we want CryptPad to be very easy to use. We use this file to figure out which UI features matter to our users, by requesting it along with a parameter specifying which action was taken."; - out.feedback_optout = "If you would like to opt out, visit your user settings page, where you'll find a checkbox to enable or disable user feedback"; - - // Creation page - out.creation_404 = "This pad not longer exists. Use the following form to create a new pad."; - out.creation_ownedTitle = "Type of pad"; - out.creation_owned = "Owned pad"; // Creation page - out.creation_ownedTrue = "Owned pad"; // Settings - out.creation_ownedFalse = "Open pad"; - out.creation_owned1 = "An owned pad can be deleted from the server whenever the owner wants. Deleting an owned pad removes it from other users' CryptDrives."; - out.creation_owned2 = "An open pad doesn't have any owner and thus, it can't be deleted from the server unless it has reached its expiration time."; - out.creation_expireTitle = "Life time"; - out.creation_expire = "Expiring pad"; - out.creation_expireTrue = "Add a life time"; - out.creation_expireFalse = "Unlimited"; - out.creation_expireHours = "Hour(s)"; - out.creation_expireDays = "Day(s)"; - out.creation_expireMonths = "Month(s)"; - out.creation_expire1 = "An unlimited pad will not be removed from the server until its owner deletes it."; - out.creation_expire2 = "An expiring pad has a set lifetime, after which it will be automatically removed from the server and other users' CryptDrives."; - out.creation_password = "Add a password"; - out.creation_noTemplate = "No template"; - out.creation_newTemplate = "New template"; - out.creation_create = "Create"; - out.creation_saveSettings = "Don't show this again"; - out.creation_settings = "View more settings"; - out.creation_rememberHelp = "Visit your Settings page to reset this preference"; - // Properties about creation data - out.creation_owners = "Owners"; - out.creation_ownedByOther = "Owned by another user"; - out.creation_noOwner = "No owner"; - out.creation_expiration = "Expiration time"; - out.creation_passwordValue = "Password"; - out.creation_propertiesTitle = "Availability"; - out.creation_appMenuName = "Advanced mode (Ctrl + E)"; - out.creation_newPadModalDescription = "Click on a pad type to create it. You can also press Tab to select the type and press Enter to confirm."; - out.creation_newPadModalDescriptionAdvanced = "You can check the box (or press Space to change its value) if you want to display the pad creation screen (for owned pads, expiring pads, etc.)."; - out.creation_newPadModalAdvanced = "Display the pad creation screen"; - - // Password prompt on the loading screen - out.password_info = "The pad you're trying to open is protected with a password. Enter the correct password to access its content."; - out.password_error = "Pad not found!
    This error can be caused by two factors: either the password in invalid, or the pad has been deleted from the server."; - out.password_placeholder = "Type the password here..."; - out.password_submit = "Submit"; - out.password_show = "Show"; - - // Change password in pad properties - out.properties_addPassword = "Add a password"; - out.properties_changePassword = "Change the password"; - out.properties_confirmNew = "Are you sure? Adding a password will change this pad's URL and remove its history. Users without the password will lose access to this pad"; - out.properties_confirmChange = "Are you sure? Changing the password will remove its history. Users without the new password will lose access to this pad"; - out.properties_passwordSame = "New passwords must differ from the current one."; - out.properties_passwordError = "An error occurred while trying to change the password. Please try again."; - out.properties_passwordWarning = "The password was successfully changed but we were unable to update your CryptDrive with the new data. You may have to remove the old version of the pad manually.
    Press OK to reload and update your access rights."; - out.properties_passwordSuccess = "The password was successfully changed.
    Press OK to reload and update your access rights."; - out.properties_changePasswordButton = "Submit"; - - // New share modal - out.share_linkCategory = "Share link"; - out.share_linkAccess = "Access rights"; - out.share_linkEdit = "Edit"; - out.share_linkView = "View"; - out.share_linkOptions = "Link options"; - out.share_linkEmbed = "Embed mode (toolbar and userlist hidden)"; - out.share_linkPresent = "Present mode (editable sections hidden)"; - out.share_linkOpen = "Open in new tab"; - out.share_linkCopy = "Copy to clipboard"; - out.share_embedCategory = "Embed"; - out.share_mediatagCopy = "Copy mediatag to clipboard"; - - // Loading info - out.loading_pad_1 = "Initializing pad"; - out.loading_pad_2 = "Loading pad content"; - out.loading_drive_1 = "Loading data"; - out.loading_drive_2 = "Updating data format"; - out.loading_drive_3 = "Verifying data integrity"; - - // Shared folders - out.sharedFolders_forget = "This pad is only stored in a shared folder, you can't move it to the trash. You can use your CryptDrive if you want to delete it."; - out.sharedFolders_duplicate = "Some of the pads you were trying to move were already shared in the destination folder."; - out.sharedFolders_create = "Create a shared folder"; - out.sharedFolders_create_name = "Folder name"; - out.sharedFolders_create_owned = "Owned folder"; - out.sharedFolders_create_password = "Folder password"; - out.sharedFolders_share = "Share this URL with other registered users to give them access to the shared folder. Once they open this URL, the shared folder will be added to the root directory of their CryptDrive."; - - out.chrome68 = "It seems that you're using the browser Chrome or Chromium version 68. It contains a bug resulting in the page turning completely white after a few seconds or the page being unresponsive to clicks. To fix this issue, you can switch to another tab and come back, or try to scroll in the page. This bug should be fixed in the next version of your browser."; - - // Manual pad storage popup - out.autostore_file = "file"; - out.autostore_sf = "folder"; - out.autostore_pad = "pad"; - out.autostore_notstored = "This {0} is not in your CryptDrive. Do you want to store it now?"; - out.autostore_settings = "You can enable automatic pad storage in your Settings page!"; - out.autostore_store = "Store"; - out.autostore_hide = "Don't store"; - out.autostore_error = "Unexpected error: we were unable to store this pad, please try again."; - out.autostore_saved = "The pad was successfully stored in your CryptDrive!"; - out.autostore_forceSave = "Store the file in your CryptDrive"; // File upload modal - out.autostore_notAvailable = "You must store this pad in your CryptDrive before being able to use this feature."; // Properties/tags/move to trash - - // Crowdfunding messages - out.crowdfunding_home1 = "CryptPad needs your help!"; - out.crowdfunding_home2 = "Click on the button to learn about our crowdfunding campaign."; - out.crowdfunding_button = "Support CryptPad"; - - out.crowdfunding_popup_text = "

    We need your help!

    " + - "To ensure that CryptPad is actively developed, consider supporting the project via the " + - 'OpenCollective page, where you can see our Roadmap and Funding goals.'; - out.crowdfunding_popup_yes = "Go to OpenCollective"; - out.crowdfunding_popup_no = "Not now"; - out.crowdfunding_popup_never = "Don't ask me again"; - - return out; -}); diff --git a/www/common/translations/old/messages.pl.js b/www/common/translations/old/messages.pl.js deleted file mode 100644 index d21abd491..000000000 --- a/www/common/translations/old/messages.pl.js +++ /dev/null @@ -1,167 +0,0 @@ -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - - // translations must set this key for their language to be available in - // the language dropdowns that are shown throughout Cryptpad's interface - out._languageName = 'Polish'; - - out.main_title = "Cryptpad: Wspólne edytowanie w czasie rzeczywistym, bez wiedzy specjalistycznej"; - out.main_slogan = "Jedność siłą - Współpraca kluczem"; - - out.type = {}; - out.type.pad = 'Pad'; - out.type.code = 'Kod'; - out.type.poll = 'Balot'; - out.type.slide = 'Prezentacja'; - - out.common_connectionLost = 'Przerwano połączenie z serwerem'; - - out.disconnected = 'Rozłączony'; - out.synchronizing = 'Synchronizacja'; - out.reconnecting = 'Wznawianie połączenia...'; - out.lag = 'Lag'; - out.readonly = 'Tylko do odczytu'; - out.anonymous = "Anonimowy"; - out.yourself = "Ty"; - out.anonymousUsers = "użytkownicy anonimowi"; - out.anonymousUser = "użytkownik anonimowy"; - out.users = "Użytkownicy"; - out.and = "i"; - out.viewer = "czytający"; - out.viewers = "czytających"; - out.editor = "edytujący"; - out.editors = "edytujących"; - - out.greenLight = "Wszystkie systemy działają poprawnie"; - out.orangeLight = "Słabe łącze może wpłynąć na działanie aplikacji"; - out.redLight = "Zostałeś rozłączony z sesją"; - - out.importButtonTitle = 'Importuj dokument z pliku lokalnego'; - - out.exportButtonTitle = 'Zapisz ten dokument do pliku'; - out.exportPrompt = 'Jak chciałbyś nazwać swój plik?'; - - out.changeNamePrompt = 'Zmień swoją nazwę (Pozostaw puste, by być anonimowym): '; - - out.clickToEdit = "Naciśnij by edytować"; - - out.forgetButtonTitle = 'Usuń ten dokument z listy wyświetlanej na stronie głównej'; - out.forgetPrompt = 'Wciskając OK usuniesz ten URL z pamięci lokalnej, jesteś tego pewien?'; - - out.shareButton = 'Udostępnij'; - out.shareSuccess = 'Pomyślnie skopiowano URL'; - - out.presentButtonTitle = "Otwórz tryb prezentacji"; - - out.backgroundButtonTitle = 'Zmień kolor tła dla tej prezentacji'; - out.colorButtonTitle = 'Zmień kolor tekstu dla tej prezentacji'; - - - out.editShare = "Udostępnij URL do edycji"; - out.editShareTitle = "Zapisz URL do edycji w schowku"; - out.viewShare = "Udostępnij URL tylko do odczytu"; - out.viewShareTitle = "Zapisz URL tylko do odczytu w schowku"; - out.viewOpen = "Otwórz podgląd w nowej karcie"; - out.viewOpenTitle = "Otwórz ten dokument w nowej karcie, tylko do odczytu"; - - out.notifyJoined = "{0} dołączył do sesji współpracy"; - out.notifyRenamed = "{0} jest teraz znany jako {1}"; - out.notifyLeft = "{0} opuścił sesję współpracy"; - - out.tryIt = 'Wypróbuj!'; - - out.okButton = 'OK (enter)'; - out.cancelButton = 'Anuluj (esc)'; - - // Polls - - out.poll_title = "Prosty koordynator spotkań"; // Choice of "Koordynator" can be discussed - out.poll_subtitle = "Proste planowanie spotkań, w czasie rzeczywistym"; - - out.poll_p_save = "Twoje ustawienia aktualizowane są na bieżąco. Nie martw się zapisywaniem."; - out.poll_p_encryption = "Wszystko co robisz jest szyfrowane, więc tylko osoby z linkiem mają tu dostęp. Nawet serwer nie widzi co kombinujesz."; - - out.wizardLog = "Naciśnij przycisk w lewym-górnym rogu by wrócić do planu"; - out.wizardTitle = "Uzyj kreatora by stworzyć opcje do głosowania"; - out.wizardConfirm = "Jesteś pewny, że chcesz dodać te opcje do głosowania?"; - - out.poll_closeWizardButton = "Zamknij kreator"; - out.poll_closeWizardButtonTitle = "Zamyka kreator"; - out.poll_wizardComputeButton = "Ustawienia kalkulacji"; - out.poll_wizardClearButton = "Wyczyść tabelę"; - out.poll_wizardDescription = "Automatycznie stwórz część opcji poprzez wpisanie ilości dat i godzin"; - out.poll_wizardAddDateButton = "+ Daty"; - out.poll_wizardAddTimeButton = "+ Godziny"; - - out.poll_optionPlaceholder = "Opcja"; - out.poll_userPlaceholder = "Twoje imię"; - out.poll_removeOption = "Jesteś pewien, że chcesz usunąć tę opcję?"; - out.poll_removeUser = "Jesteś pewien, że chcesz usunąć tego użytkownika?"; - - out.poll_titleHint = "Tytuł"; - out.poll_descriptionHint = "Opis"; - - // index.html - - out.main_p2 = 'Ten projekt wykorzystuje wizualny edytor CKEditor , CodeMirror, oraz silnik czasu rzeczywistego ChainPad.'; - out.main_howitworks = 'Jak to działa'; - out.main_howitworks_p1 = 'CryptPad wykorzystuje wariant algorytmu Transformacji operacyjnej który jest wstanie odnaleźć rozdzielony konsensus wprowadzanych danych. Używa do tego Łańcuch blokowy Nakamoto, twór zpopularyzowany przez Bitcoin. W ten sposób algorytm może pominąć potrzebę centralnego serwera do rozwiązywania Konfliktów Operacji Przekształcania poprzez Edycję. Bez potrzeby rozwiązywania konfliktów, serwer może pozostać w niewiedzy o zawartości która jest edytowana w dokumencie.'; - - out.main_about_p2 = 'Jeżeli masz jakieś pytania lub komentarze, możesz napisać na tweeterze, otworzyć problem na githubie, przywitać się na ircu (irc.freenode.net), lub wysłać nam email.'; - - out.button_newpad = 'STWÓRZ PAD WYSIWYG'; - out.button_newcode = 'STWÓRZ PAD DO KODU'; - out.button_newpoll = 'STWÓRZ GŁOSOWANIE'; - out.button_newslide = 'STWÓRZ PREZENTACJĘ'; - - // privacy.html - - out.policy_title = 'Polityka prywatności CryptPad'; - out.policy_whatweknow = 'Co o tobie wiemy'; - out.policy_whatweknow_p1 = 'Jako aplikacja udostępniana w internecie, CryptPad ma dostęp do metadanych wystawianych przez protokół HTTP. W skład tych danych wchodzi adres IP oraz różne inne nagłówki HTTP które pozwalają na identyfikację twojej przeglądarki. Możesz podejrzeć jakie informacje udostępnia twoja przeglądarka odwiedzając WhatIsMyBrowser.com.'; - out.policy_whatweknow_p2 = 'Używamy Piwik, Open Sourcowej platformy analitycznej, aby dowiedzieć się czegoś o naszych użytkownikach. Piwik mówi nam, skąd dowiedziałeś się o Cryptpad. Bezpośrednio przez adres, silnik wyszukiwany, czy z polecenia innej usługi internetowej jak Reddit czy Twitter. Uczymy się również gdy nas odwiedzasz, jakie linki odwiedzasz z naszej strony informacyjnej i jak długo pozostajesz na konkretnych stronach.'; - out.policy_howweuse = 'Jak wykorzystujemy zebraną wiedzę'; - out.policy_howweuse_p1 = 'Dzieki tym informacjom możemy podejmować lepsze decyzje przy promocji CryptPad, poprzez ocenę które z podjętych przez nas prób okazały się udane. Informacja o twojej lokalizacji daje nam znać, czy powinniśmy zapewnić lepsze wsparcie dla języków poza Angielskim.'; - out.policy_howweuse_p2 = "Informacje o twojej przeglądarce (czy jest to aplikacja desktopowa, czy działająca na systemie mobilnym) pozwalają nam na decydowanie przy priorytezowaniu ulepszeń funkcji. Nasz zespół deweloperski jest mały, a my staramy się dokonywać wyborów które poprawią doświadczenia jak największej liczby użytkowników."; - out.policy_whatwetell = 'Jakie dane przekazujemy innym'; - out.policy_whatwetell_p1 = 'Nie dostarczamy osobom trzecim żadnych danych które udało się nam zebrać, lub tych które nam przekazałeś sam, dopóki nie jesteśmy do tego zobligowani prawnie.'; - out.policy_links = 'Adresy innych stron'; - out.policy_links_p1 = 'Ta witryna zawiera łącza do innych stron, włączając w to te stworzone przez inne organizacje. Nie jesteśmy odpowiedzialni za praktyki dotyczące prywatności oraz zawartość usługodawców poza tą witryną. Jako główną zasadę przyjmujemy, że łącza do stron zewnętrznych uruchamiane są w nowej karcie lub oknie, aby upewnić cię iż opuszczasz Cryptpad.'; - out.policy_ads = 'Promocja i reklama'; - out.policy_ads_p1 = 'Nie wyświetlamy żadnej zawartości promocyjnej online, choć możemy udostępniać łącza do podmiotów finansujących nasze badania.'; - out.policy_choices = 'Co możesz zrobić'; - out.policy_choices_open = 'Nasz kod jest open source, więc zawsze masz możliwość hostowania swojej własnej wersji Cryptpad.'; - out.policy_choices_vpn = 'Jeżeli chcesz korzystać z wersji udostępnianej przez nas, lecz nie chcesz pokazywać swojego adresu IP, możesz chronić swój adres wykorzystując przeglądarki Tor, lub VPN.'; - out.policy_choices_ads = 'Masz również możliwość blokady naszej platformy analitycznej wykorzystując narzędzia adblock, takie jak Privacy Badger.'; - - // terms.html - - out.tos_title = "Warunki korzystania z usług Cryptpad"; - out.tos_legal = "Prosimy abyś nie był złośliwy, obelżywy i nie wykorzystywał tego oprogramowania do celow niezgodnych z prawem."; - out.tos_availability = "Mamy nadzieję iż uznasz tę usługę za przydatną, lecz dostępność i wydajność nie mogą być przez nas gwarantowane. Prosimy, abyś eksportował swoje dane regularnie."; - out.tos_e2ee = "Dokumenty Cryptpad mogą być odczytywane i modyfikowane przez każdego kto może zgadnąć lub w inny sposób uzyskać identyfikator dokumentu. Polecamy korzystania z oprogramowania szyfrującego end-to-end (e2ee) do udostępniania linków URL. Nie będziesz rościł sobie żadnych wierzytelności w wypadku gdy taki URL dostanie się w niepowołane ręce."; - out.tos_logs = "Metadane dostarczane przez twoją przeglądarkę do serwera mogą być zapisywane i przechowywane w celu utrzymywania serwisu."; - out.tos_3rdparties = "Nie dostarczamy indywidualizowanych danych do osób trzecich, poza sytuacjami dyktowanymi prawnie."; - - // BottomBar.html - - out.bottom_france = 'Stworzone z we '; - out.bottom_support = 'Projekt XWiki SAS Labs we wspolpracy z OpenPaaS-ng'; - - // Header.html - - out.header_france = 'Pełne z France od XWiki SAS'; - - - // TODO Hardcode cause YOLO - //out.header_xwiki = 'XWiki SAS'; - out.header_support = ' OpenPaaS-ng'; - out.header_logoTitle = 'Przejdź na stronę główną'; - - return out; -}); diff --git a/www/common/translations/old/messages.pt-br.js b/www/common/translations/old/messages.pt-br.js deleted file mode 100644 index 24cccdea0..000000000 --- a/www/common/translations/old/messages.pt-br.js +++ /dev/null @@ -1,552 +0,0 @@ -// Tradução para protuguês brasileiro efetuada por Gustavo Henrique Machado da Silva (www.linkedin.com/in/gustavohmsilva) -// Embora o software original possa não possuir as mesmas licenças, a tradução produzida por mim é protegida sob termos -// Creative Commons, Attribution-ShareAlike 4.0 International -// Contate-me via email no endereço gustavohmsilva@member.fsf.org -// Translation to brazilian portuguese done by Gustavo Henrique Machado da Silva (www.linkedin.com/in/gustavohmsilva) -// Even though this software may not share the same licenses, the translation produced by me is protected under -// Creative commons, Attribution-ShareAlike 4.0 International -// You can contact me over email on gustavohmsilva@member.fsf.org - -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - - out._languageName = 'Brazilian Portuguese'; - - out.main_title = "Cryptpad: Zero Knowledge, Edição Colaborativa em Tempo Real"; - out.main_slogan = "União é Força - Colaboração é a Chave"; - - out.type = {}; - out.type.pad = 'Notas'; - out.type.code = 'Código'; - out.type.poll = 'votação'; - out.type.slide = 'Apresentação'; - - out.type.drive = 'Drive'; - out.type.whiteboard = 'Whiteboard'; - out.type.file = 'File'; - out.type.media = 'Media'; - - out.button_newpad = 'Novo bloco RTF'; - out.button_newcode = 'Novo bloco de código'; - out.button_newpoll = 'Novo questionário'; - out.button_newslide = 'Nova apresentação'; - out.button_newwhiteboard = 'Novo quadro branco'; - - // NOTE: We want to update the 'common_connectionLost' key. - // Please do not add a new 'updated_common_connectionLostAndInfo' but change directly the value of 'common_connectionLost' - out.updated_0_common_connectionLost = "Conexão com o Servidor Perdida
    Você agora está em modo somente leitura até a conexão ser restaurada."; - out.common_connectionLost = out.updated_0_common_connectionLost; - - out.websocketError = 'Incapaz de se conectar com o servidor websocket...'; - out.typeError = "Este bloco não é compatível com a aplicação selecionada"; - out.onLogout = 'você foi desconectado, {0}clique aqui{1} para se conectar,
    ou pressione ESC para acessar seu bloco em modo somente leitura.'; - out.wrongApp = "Incapaz de mostrar o conteúdo em tempo real no seu navegador. Por favor tente recarregar a página."; - - out.loading = "Carregando..."; - out.error = "Erro"; - out.saved = "Salvo"; - out.synced = "Tudo foi salvo"; - out.deleted = "Bloco deletado do seu CryptDrive"; - - - out.disconnected = 'Desconectado'; - out.synchronizing = 'Sincronizando'; - out.reconnecting = 'Reconectando...'; - out.lag = 'Lag'; - out.readonly = 'Somente leitura'; - out.anonymous = "Anonimo"; - out.yourself = "Você"; - out.anonymousUsers = "Usuários anônimos"; - out.anonymousUser = "Usuário anônimo"; - out.users = "Usuários"; - out.and = "e"; - out.viewer = "vizualizações"; - out.viewers = "leitores"; - out.editor = "editor"; - out.editors = "editores"; - - out.language = "Lingua"; - - out.comingSoon = "Em breve..."; - - out.newVersion = 'O CryptPad foi atualizado!
    ' + - 'Cheque as novidades na última versão:
    '+ - 'Notas da atualização do CryptPad {0}'; - - out.upgrade = "Upgrade"; - out.upgradeTitle = "Faça um upgrade na sua conta para aumentar o limite de armazenamento"; - out.MB = "MB"; - out.GB = "GB"; - out.KB = "KB"; - - out.formattedMB = "{0} MB"; - out.formattedGB = "{0} GB"; - out.formattedKB = "{0} KB"; - - out.greenLight = "Tudo está funcionando bem"; - out.orangeLight = "Sua conexão lenta pode impactar sua experiência"; - out.redLight = "Você está desconectado da sua sessão"; - - - out.pinLimitReached = "Você alcançou o limite de armazenamento"; - out.updated_0_pinLimitReachedAlert = "Você alcançou o limite de armazenamento. Novos blocos não serão mais salvos no seu CryptDrive.
    " + - 'Você pode deletar blocos do seu CryptDrive ou se inscrever como premium para aumentar o limite de espaço.'; - out.pinLimitReachedAlert = out.updated_0_pinLimitReachedAlert; - out.pinAboveLimitAlert = 'A partir desta atualização, nós estamos impondo um limite de 50MB no armazenamento gratuito. Você está atualmente usando {0}. Você irá precisar deletar alguns blocos ou se inscrever no accounts.cryptpad.fr. Sua contribuição irá nos ajudar a melhorar o CryptPad e expandir a metodologia Zero Knowledge. Por favor contacte o suporte se você possui outras dúvidas.'; - out.pinLimitNotPinned = "Você alcançou o limite de armazenamento.
    "+ - "Este bloco não está armazenado no seu CryptDrive."; - out.pinLimitDrive = "Você alcançou o limite de armazenamento.
    " + - "Você não pode criar novos blocos."; - - out.importButtonTitle = 'Importar um documento de um arquivo local'; - - out.exportButtonTitle = 'Exportar esta sesão para um arquivo local'; - out.exportPrompt = 'Como deseja nomear seu arquivo?'; - - - out.changeNamePrompt = 'Mude seu nome (deixe em branco para se manter anônimo): '; - out.user_rename = "Mudar nome de exibição"; - out.user_displayName = "Nome visível"; - out.user_accountName = "Nome da Conta"; - - out.clickToEdit = "Clique para Editar"; - - out.forgetButtonTitle = 'Remova este documento da listagem da sua página'; - out.forgetPrompt = 'Clicando OK você irá remover o endereço deste bloco de notas do armazenamento local, você tem certeza?'; - out.movedToTrash = 'That pad has been moved to the trash.
    Access my Drive'; - - out.shareButton = 'Compartilhar'; - out.shareSuccess = 'Endereço copiado para o clipboard'; - - out.newButton = 'Novo'; - out.newButtonTitle = 'Criar um novo bloco'; - - out.saveTemplateButton = "Salvar como modelo"; - out.saveTemplatePrompt = "Escolha o nome do modelo"; - out.templateSaved = "Modelo salvo!"; - out.selectTemplate = "Selecione um modelo ou pressione ESC"; - - out.previewButtonTitle = "Mostrar ou esconder o modo de visualização markdown"; - - out.presentButtonTitle = "Entrar no modo apresentação"; - - out.backgroundButtonTitle = 'Mudar cor do fundo da apresentação'; - out.colorButtonTitle = 'Mudar a cor do texto no modo apresentação'; - - out.printButton = "Imprimir (Enter)"; - out.printButtonTitle = "Imprimir seus slides ou exportá-los como PDF"; - out.printOptions = "Opções de leiaute"; - out.printSlideNumber = "Mostrar o número do slide"; - out.printDate = "Mostrar a data"; - out.printTitle = "Mostrar título do bloco"; - out.printCSS = "Custom style rules (CSS):"; - out.printTransition = "Ativar animações de transição"; - - out.slideOptionsTitle = "Personalizar seus slides"; - out.slideOptionsButton = "Salvar (Enter)"; - - - out.editShare = "Compartilhar endereço editável"; - out.editShareTitle = "Copiar endereço editável"; - out.editOpen = "Abrir endereço editável em nova aba"; - out.editOpenTitle = "Abrir este bloco em modo editável em nova aba"; - out.viewShare = "Compartilhar endereço de visualização"; - out.viewShareTitle = "Copiar o endereço somente leitura"; - - out.notifyJoined = "{0} entraram na sessão colaborativa"; - out.notifyRenamed = "{0} agora é conhecido como {1}"; - out.notifyLeft = "{0} deixou essa sessão colaborativa"; - - - out.okButton = 'OK (Enter)'; - - out.cancel = "Cancelar"; - out.cancelButton = 'Cancelar (ESC)'; - - out.historyButton = "Exibir histórico do documento"; - out.history_next = "Ir para próxima versão"; - out.history_prev = "Ir para versão anterior"; - out.history_goTo = "Ir para versão selecionada"; - out.history_close = "Voltar"; - out.history_closeTitle = "Fechar o histórico"; - out.history_restore = "Restaurar"; - out.history_restoreTitle = "Restaurar a versão selecionada do documento"; - out.history_restorePrompt = "Você tem certeza que deseja substituir a versão atual do documento pela que está sendo exibida agora?"; - out.history_restoreDone = "Documento restaurado"; - out.history_version = "Versão:"; - out.tryIt = 'Experimente!'; - - // Polls - - out.poll_title = "Seletor de dados zero knowledge"; - out.poll_subtitle = "Zero Knowledge, agendamento em tempo real"; - - out.poll_p_save = "Suas configurações são atualizadas instantaneamente, assim você nunca terá de salvá-las"; - out.poll_p_encryption = "Tudo que der entrada é encriptado para que apenas as pessoas com o link possam acessá-las. Nem mesmo o servidor pode ver suas mudanças."; - - out.wizardLog = "Clique no botão no topo esquerdo para voltar para sua enquete"; - out.wizardTitle = "Use o assistente para criar sua enquete"; - out.wizardConfirm = "Você está realmente pronto para adicionar estas opções em sua enquete?"; - - out.poll_publish_button = "Publicar"; - out.poll_admin_button = "Admin"; - out.poll_create_user = "Adicionar novo usuário"; - out.poll_create_option = "Adicionar nova opção"; - out.poll_commit = "Submeter"; - - out.poll_closeWizardButton = "Fechar assistente"; - out.poll_closeWizardButtonTitle = "Fechar assistente"; - out.poll_wizardComputeButton = "Computar opções"; - out.poll_wizardClearButton = "Limpar tabela"; - out.poll_wizardDescription = "Automaticamente criar um número de opções entrando qualquer número de seguimentos de datas e horários"; - out.poll_wizardAddDateButton = "+ Datas"; - out.poll_wizardAddTimeButton = "+ Horários"; - - out.poll_optionPlaceholder = "Alternativa"; - out.poll_userPlaceholder = "Seu nome"; - - out.poll_removeOption = "Você tem certeza que deseja remover esta opção?"; - - out.poll_removeUser = "Você tem certeza que quer remover este usuário?"; - - out.poll_titleHint = "Título"; - out.poll_descriptionHint = "Descrição"; - - - // Canvas - out.canvas_clear = "Limpar"; - out.canvas_delete = "Deletar seleção"; - out.canvas_disable = "Desabilitar desenho"; - out.canvas_enable = "Habilitar desenho"; - out.canvas_width = "Largura"; - out.canvas_opacity = "Opacidade"; - - // File manager - - out.fm_rootName = "Documentos"; - out.fm_trashName = "Lixeira"; - out.fm_unsortedName = "Arquivos não organizados"; - out.fm_filesDataName = "Todos os Arquivos"; - out.fm_templateName = "Temas"; - out.fm_searchName = "Busca"; - out.fm_searchPlaceholder = "Buscar..."; - out.fm_newButton = "Novo"; - out.fm_newButtonTitle = "Criar um novo bloco ou diretório"; - out.fm_newFolder = "Novo diretório"; - out.fm_newFile = "Novo bloco"; - out.fm_folder = "Diretório"; - out.fm_folderName = "Nome do diretório"; - out.fm_numberOfFolders = "# de diretórios"; - out.fm_numberOfFiles = "# de arquivos"; - out.fm_fileName = "Nome do arquivo"; - out.fm_title = "Título"; - out.fm_type = "Tipo"; - out.fm_lastAccess = "Último acesso"; - out.fm_creation = "Criação"; - out.fm_forbidden = "Ação não permitida"; - out.fm_originalPath = "Caminho original"; - out.fm_openParent = "Exibir no diretório"; - out.fm_noname = "Documento sem título"; - out.fm_emptyTrashDialog = "Você tem certeza que deseja limpar a lixeira??"; - out.fm_removeSeveralPermanentlyDialog = "Você tem certeza que deseja deletar estes {0} elementos da lixeira permanentemente?"; - out.fm_removePermanentlyDialog = "Você tem certeza que deseja deletar este elemento da lixeira permanentemente?"; - out.fm_removeSeveralDialog = "Você tem certeza que deseja mover estes {0} elementos para a lixeira?"; - out.fm_removeDialog = "Você tem certeza que deseja mover {0} para a lixeira?"; - out.fm_restoreDialog = "Você tem certeza que deseja restaurar {0} de volta para seu diretório original?"; - out.fm_unknownFolderError = "O diretório selecionado ou visitado por último não existe mais. Abrindo diretório superior..."; - out.fm_contextMenuError = "Incapaz de abrir o menu de contextualização para este elementos. Se o problema persistir, tente recarregar a página."; - out.fm_selectError = "Incapaz de selecionar o elemento marcado. Se o problema persistir, tente recarregar a página."; - out.fm_categoryError = "Incapaz de abrir a categoria selecionada, Exibindo diretório raiz"; - out.fm_info_root = "Crie quantos diretórios aninhados aqui desejar para organizar seus arquivos.."; - out.fm_info_unsorted = "Contém todos os arquivos que você visitou e não estão ainda organizados na pasta Documentos ou foram movidos para a pasta lixeira"; // "My Documents" should match with the "out.fm_rootName" key, and "Trash" with "out.fm_trashName" out.fm_info_template = 'Contains all the pads stored as templates and that you can re-use when you create a new pad.'; - out.updated_0_fm_info_trash = 'Empty your trash to free space in your CryptDrive.'; - out.fm_info_trash = out.updated_0_fm_info_trash; - out.fm_info_allFiles = 'Contém todos os arquivos de "Documentos", "Não organizados" e "Lixeira". Não é possível mover ou remover arquivos daqui.'; // Same here - out.fm_info_anonymous = 'Você não está logado, então estes blocos podem ser deletados! (Descubra o porque). ' + - 'Cadastre-se or Entre Para deixá-los salvos.'; - out.fm_alert_backupUrl = "Link de backup desta conta.
    " + - "É fortemente recomendado que você deixe para você e somente você.
    " + - "Você pode usá-lo para resgatar os seus dados caso a memória do seu navegador se perca.
    " + - "Qualquer um com este link pode editar ou apagar todos os arquivos no gerenciador da conta.
    "; - out.fm_alert_anonymous = "Ola! Você está utilizando o CryptPad anonimamente, isto é ok, mas seus blocos podem ser apagados " + - "se ficarem muito tempo inativo. Nós desativamos as funções avançadas nas contas anônimas para que isto fique claro para você " + - 'Este não é um bom lugar apra salvar senhas! Entenda: Clicando aqui! ' + - 'Porque estamos fazendo isso e porque você deveria criar uma onta? Sign up and Clique e entenda!.'; - out.fm_backup_title = 'Link de restauração'; - out.fm_nameFile = 'Como deseja nomear este arquivo?'; - out.fm_error_cantPin = "Erro interno do servidor. Por favor recarregue a página e tente novamente."; - // File - Context menu - out.fc_newfolder = "Nova pasta"; - out.fc_rename = "Renomear"; - out.fc_open = "Abrir"; - out.fc_open_ro = "Abrir (somente leitura)"; - out.fc_delete = "Deletar"; - out.fc_restore = "Restaurar"; - out.fc_remove = "Deletar permanentemente"; - out.fc_empty = "Esvaziar lixeira"; - out.fc_prop = "Propriedades"; - out.fc_sizeInKilobytes = "tamanho em Kilobytes"; - // fileObject.js (logs) - out.fo_moveUnsortedError = "Você não pode mover uma pasta na lista de notas não organizadas"; - out.fo_existingNameError = "Nome já em uso neste diretório. Por favor escolha outro."; - out.fo_moveFolderToChildError = "Você não pode mover uma sub-diretório para dentro de um de seus sub-diretórios"; - out.fo_unableToRestore = "Fomos incapazes de restaurar este arquivo para sua posição original. Você pode tentar move-lo para o local de destino porém."; - out.fo_unavailableName = "Um arquivo ou diretório com o mesmo nome já existe no novo locao. Renomeie-o e tente novamente."; - - // login - out.login_login = "Entrar"; - out.login_makeAPad = 'Criar bloco anonimamente'; - out.login_nologin = "Navegar nos blocos locais"; - out.login_register = "Cadastro"; - out.logoutButton = "Sair"; - out.settingsButton = "Configurações"; - - out.login_username = "Usuário"; - out.login_password = "Senha"; - out.login_confirm = "Confirme sua senha"; - out.login_remember = "Memorize-me"; - - out.login_hashing = "Encriptando sua senha, isto pode tomar algum tempo."; - - out.login_hello = 'Ola {0},'; // {0} is the username - out.login_helloNoName = 'Ola,'; - out.login_accessDrive = 'Acesse seu diretório'; - out.login_orNoLogin = 'ou'; - - out.login_noSuchUser = 'Usuário ou senha inválido. Tente nocamente ou cadastre-se'; - out.login_invalUser = 'É necessário um usuário'; - out.login_invalPass = 'É necessário uma senha'; - out.login_unhandledError = 'Um erro não esperado ocorreu :('; - - out.register_importRecent = "Importar histórico de blocos (Recomendado)"; - out.register_acceptTerms = "Eu aceito os termos de serviço"; - out.register_passwordsDontMatch = "Senhas não coincidem!"; - out.register_mustAcceptTerms = "Você precisa aceitar os termos de serviço."; - out.register_mustRememberPass = "Nós não podemos restaurar sua senha caso você a esqueça. É muito importante que você lembre-se dela! Clique nesta caixa de seleção para confirmar que você compreendeu isto."; - - out.register_header = "Bem vindo ao CryptPad"; - out.register_explanation = [ - "

    Lets go over a couple things first

    ", - "
      ", - "
    • Your password is your secret key which encrypts all of your pads. If you lose it there is no way we can recover your data.
    • ", - "
    • You can import pads which were recently viewed in your browser so you have them in your account.
    • ", - "
    • If you are using a shared computer, you need to log out when you are done, closing the tab is not enough.
    • ", - "
    " - ].join(''); - - - out.register_writtenPassword = "I have written down my username and password, proceed"; - out.register_cancel = "Go back"; - - out.register_warning = "Zero Knowledge means that we can't recover your data if you lose your password."; - - out.register_alreadyRegistered = "This user already exists, do you want to log in?"; - - // Settings - out.settings_title = "Settings"; - out.settings_save = "Save"; - out.settings_backupTitle = "Backup or restore all your data"; - out.settings_backup = "Backup"; - out.settings_restore = "Restore"; - out.settings_resetTitle = "Clean your drive"; - out.settings_reset = "Remove all the files and folders from your CryptDrive"; - out.settings_resetPrompt = "This action will remove all the pads from your drive.
    "+ - "Are you sure you want to continue?
    " + - "Type “I love CryptPad” to confirm."; - out.settings_resetDone = "Your drive is now empty!"; - out.settings_resetError = "Incorrect verification text. Your CryptDrive has not been changed."; - out.settings_resetTips = "Tips in CryptDrive"; - out.settings_resetTipsButton = "Reset the available tips in CryptDrive"; - out.settings_resetTipsDone = "All the tips are now visible again."; - - out.settings_importTitle = "Import this browser's recent pads in my CryptDrive"; - out.settings_import = "Import"; - out.settings_importConfirm = "Are you sure you want to import recent pads from this browser to your user account's CryptDrive?"; - out.settings_importDone = "Import completed"; - - out.settings_userFeedbackHint1 = "CryptPad provides some very basic feedback to the server, to let us know how to improve your experience."; - out.settings_userFeedbackHint2 = "Your pad's content will never be shared with the server."; - out.settings_userFeedback = "Enable user feedback"; - - out.settings_anonymous = "You are not logged in. Settings here are specific to this browser."; - out.settings_publicSigningKey = "Public Signing Key"; - - out.settings_usage = "Usage"; - out.settings_usageTitle = "See the total size of your pinned pads in MB"; - out.settings_pinningNotAvailable = "Pinned pads are only available to registered users."; - out.settings_pinningError = "Something went wrong"; - out.settings_usageAmount = "Your pinned pads occupy {0}MB"; - - out.settings_logoutEverywhereTitle = "Log out everywhere"; - out.settings_logoutEverywhere = "Log out of all other web sessions"; - out.settings_logoutEverywhereConfirm = "Are you sure? You will need to log in with all your devices."; - - out.upload_serverError = "Server Error: unable to upload your file at this time."; - out.upload_uploadPending = "You already have an upload in progress. Cancel it and upload your new file?"; - out.upload_success = "Your file ({0}) has been successfully uploaded and added to your drive."; - out.upload_notEnoughSpace = "There is not enough space for this file in your CryptDrive."; - out.upload_tooLarge = "This file exceeds the maximum upload size."; - out.upload_choose = "Choose a file"; - out.upload_pending = "Pending"; - out.upload_cancelled = "Cancelled"; - out.upload_name = "File name"; - out.upload_size = "Size"; - out.upload_progress = "Progress"; - out.download_button = "Decrypt & Download"; - - // general warnings - out.warn_notPinned = "This pad is not in anyone's CryptDrive. It will expire after 3 months. Learn more..."; - - - // index.html - - //about.html - out.main_p2 = 'This project uses the CKEditor Visual Editor, CodeMirror, and the ChainPad realtime engine.'; - out.main_howitworks_p1 = 'CryptPad uses a variant of the Operational transformation algorithm which is able to find distributed consensus using a Nakamoto Blockchain, a construct popularized by Bitcoin. This way the algorithm can avoid the need for a central server to resolve Operational Transform Edit Conflicts and without the need for resolving conflicts, the server can be kept unaware of the content which is being edited on the pad.'; - - // contact.html - out.main_about_p2 = 'If you have any questions or comments, you can tweet us, open an issue on github, come say hi on irc (irc.freenode.net), or send us an email.'; - - out.main_info = "

    Collaborate in Confidence


    Grow your ideas together with shared documents while Zero Knowledge technology secures your privacy; even from us."; - - out.main_howitworks = 'How It Works'; - out.main_zeroKnowledge = 'Zero Knowledge'; - out.main_zeroKnowledge_p = "You don't have to trust that we won't look at your pads, with CryptPad's revolutionary Zero Knowledge Technology we can't. Learn more about how we protect your Privacy and Security."; - out.main_writeItDown = 'Write it down'; - out.main_writeItDown_p = "The greatest projects come from the smallest ideas. Take down the moments of inspiration and unexpected ideas because you never know which one might be a breakthrough."; - out.main_share = 'Share the link, share the pad'; - out.main_share_p = "Grow your ideas together: conduct efficient meetings, collaborate on TODO lists and make quick presentations with all your friends and all your devices."; - out.main_organize = 'Get organized'; - out.main_organize_p = "With CryptPad Drive, you can keep your sights on what's important. Folders allow you to keep track of your projects and have a global vision of where things are going."; - out.tryIt = 'Try it out!'; - out.main_richText = 'Rich Text editor'; - out.main_richText_p = 'Edit rich text pads collaboratively with our realtime Zero Knowledge CkEditor application.'; - out.main_code = 'Code editor'; - out.main_code_p = 'Edit code from your software collaboratively with our realtime Zero Knowledge CodeMirror application.'; - out.main_slide = 'Slide editor'; - out.main_slide_p = 'Create your presentations using the Markdown syntax, and display them in your browser.'; - out.main_poll = 'Polls'; - out.main_poll_p = 'Plan your meeting or your event, or vote for the best solution regarding your problem.'; - out.main_drive = 'CryptDrive'; - - out.footer_applications = "Applications"; - out.footer_contact = "Contact"; - out.footer_aboutUs = "About us"; - - out.about = "About"; - out.privacy = "Privacy"; - out.contact = "Contact"; - out.terms = "ToS"; - out.blog = "Blog"; - - - // privacy.html - - out.policy_title = 'Política de privacidade do Cryptpad'; - out.policy_whatweknow = 'O que nós sabemos sobre você'; - out.policy_whatweknow_p1 = 'Por ser uma aplicação hospedada na web, O Cryptpad tem acesso aos metadados expostos pelo protocolo HTTP. Isso inclui seu endereço IP, e vários cabeçalhos do HTTP que podem ser usados para identificar seu browser particular. Você pode ver que informações seu navegador está compartilhando ao visitar WhatIsMyBrowser.com.'; - out.policy_whatweknow_p2 = 'Nós usamos a plataforma de análise Piwik, uma plataforma analítica open source, para aprender mais sobre nossos usos. Piwik nos informa como você encontrou o Cryptpad, via digitação direta, através de mecanismos de busca, ou via link de outro serviço web como o Reddit ou o Twitter. Nós também aprendemos com suas visitas, que links você clica enquanto está em nossas páginas de informações, e quanto tempo você fica nestas páginas.'; - out.policy_howweuse = 'Como utilizamos o que nós aprendemos'; - out.policy_howweuse_p1 = 'Nos utilizamos estas informações para tomar melhores decisões sobre como promover o Cryptpad, ao avaliar quais dos nosso esforços passados foram mais bem sucedidos. Informações sobre sua localização nos ajudam a decidir se nós devemos considerar prover melhor suporte para idiomas além do inglês.'; - out.policy_howweuse_p2 = "As informações sobre o seu navegador de internet (não importando se é um desktop ou um equipamento móvel) nos ajudam a tomar melhores decisões ao priorizar melhorias futuras. Nossa equipe de desenvolvimento é pequena, e nós tentamos fazer as melhores escolhas em pró de auxiliar a experiência de utilização do máximo de nossos usuários possíveis."; - out.policy_whatwetell = 'O que contamos a terceiros sobre você'; - out.policy_whatwetell_p1 = 'Nós não informamos terceiros a informação que armazenamos ou que provemos a você, salvo caso sejamos legalmente requisitados a faze-lo.'; - out.policy_links = 'Links para outros sites'; - out.policy_links_p1 = 'Este site contém ligações para outros sites, incluindo aqueles produzidos por terceiros. Nós não nos responsabilizamos pelas práticas de privacidade ou o conteúdo destes sites. Como regra geral, links para páginas fora de nosso domínio são lançadas em novas janelas ou abas, para deixar claro a todos os visitantes que eles estão deixando o site Cryptpad.fr.'; - out.policy_ads = 'Publicidade'; - out.policy_ads_p1 = 'Nós não disponibilizamos publicidade online, porém podemos prover links de acesso para obtenção de financiamento para auxiliar em nossa pesquisa e desenvolvimento.'; - out.policy_choices = 'As escolhas que você tem'; - out.policy_choices_open = 'Nosso código fonte é open source, portanto você sempre tem a opção de hospedar sua própria instância do Cryptpad.'; - out.policy_choices_vpn = 'Se você deseja usar nosso site principal, porém não deseja expor seu endereço IP, Você pode se proteger utilizando o Navegador seguro Tor, ou uma VPN.'; - out.policy_choices_ads = 'Se você deseja apenas bloquear nossa plataforma analítica, você pode utilizar ferramentas de bloqueio de propagandas como o Privacy Badger.'; - - // terms.html - - out.tos_title = "Termos de serviço doCryptpad"; - out.tos_legal = "Pedimos encarecidamente que, como usuário desta plataforma, você evite a prática de quaisquer atos ilegais e que evite a utilização maliciosa e/ou abusiva desta plataforma."; - out.tos_availability = "Nós esperamos que você ache este serviço útil, porém nós não podemos garantir a disponibilidade constante ou a alta performance do mesmo. Por favor, mantenha um backup dos seus dados como forma de segurança adicional."; - out.tos_e2ee = "Os documentos do CryptPad podem ser modificados por qualquer um que conseguir adivinhar ou obter de qualquer forma o seu identificador único. Nós recomendamos que você utilize criptografia ponto a ponto de mensagens (e2ee) sempre que possível para compartilhar suas URL's. Nós não assumimos qualquer responsabilidade sobre chaves e/ou URL’s e seus respectivos conteúdos vazadas para o público."; - out.tos_logs = "Os Metadados providos pelo seu navegador para nosso servidor podem ser armazenados com o propósito de manter o serviço em funcionamento"; - out.tos_3rdparties = "Nós não disponibilizamos dados individuais para terceiros, salvo quando requisitado legalmente."; - - // BottomBar.html - - out.bottom_france = 'Feito com na '; - out.bottom_support = 'Um projeto do laboratório XWiki SAS com o suporte da OpenPaaS-ng'; - - // Header.html - - out.header_france = 'Com da France por XWiki SAS'; - - out.header_support = ' OpenPaaS-ng'; - out.header_logoTitle = 'Go to the main page'; - - // Initial states - - out.initialState = [ - '

    ', - 'This is CryptPad, the Zero Knowledge realtime collaborative editor. Everything is saved as you type.', - '
    ', - 'Share the link to this pad to edit with friends or use the button to share a read-only link which allows viewing but not editing.', - '

    ', - ].join(''); - - out.codeInitialState = [ - '# CryptPad\'s Zero Knowledge collaborative code editor\n', - '\n', - '* What you type here is encrypted so only people who have the link can access it.\n', - '* You can choose the programming language to highlight and the UI color scheme in the upper right.' - ].join(''); - - out.slideInitialState = [ - '# CryptSlide\n', - '1. Write your slides content using markdown syntax\n', - ' - Learn more about markdown syntax [here](http://www.markdowntutorial.com/)\n', - '2. Separate your slides with ---\n', - '3. Click on the "Play" button to see the result', - ' - Your slides are updated in realtime' - ].join(''); - - // Readme - - out.driveReadmeTitle = "What is CryptPad?"; - out.readme_welcome = "Welcome to CryptPad !"; - out.readme_p1 = "Welcome to CryptPad, this is where you can take note of things alone and with friends."; - out.readme_p2 = "This pad will give you a quick walk through of how you can use CryptPad to take notes, keep them organized and work together on them."; - out.readme_cat1 = "Get to know your CryptDrive"; - out.readme_cat1_l1 = "Make a pad: In your CryptDrive, click {0} then {1} and you can make a pad."; // 0: New, 1: Rich Text - out.readme_cat1_l2 = "Open Pads from your CryptDrive: double-click on a pad icon to open it."; - out.readme_cat1_l3 = "Organize your pads: When you are logged in, every pad you access will be shown as in the {0} section of your drive."; // 0: Unsorted files - out.readme_cat1_l3_l1 = "You can click and drag files into folders in the {0} section of your drive and make new folders."; // 0: Documents - out.readme_cat1_l3_l2 = "Remember to try right clicking on icons because there are often additional menus."; - out.readme_cat1_l4 = "Put old pads in the trash: You can click and drag your pads into the {0} the same way you drag them into folders."; // 0: Trash - out.readme_cat2 = "Make pads like a pro"; - out.edit = "edit"; - out.view = "view"; - out.readme_cat2_l1 = "The {0} button in your pad allows you to give access to collaborators to either {1} or to {2} the pad."; // 0: Share, 1: edit, 2: view - out.readme_cat2_l2 = "Change the title of the pad by clicking on the pencil"; - out.readme_cat3 = "Discover CryptPad apps"; - out.readme_cat3_l1 = "With CryptPad code editor, you can collaborate on code like Javascript and markdown like HTML and Markdown"; - out.readme_cat3_l2 = "With CryptPad slide editor, you can make quick presentations using Markdown"; - out.readme_cat3_l3 = "With CryptPoll you can take quick votes, especially for scheduling meetings which fit with everybody's calendar"; - - // Tips - out.tips = {}; - out.tips.lag = "The green icon in the upper right shows the quality of your internet connection to the CryptPad server."; - out.tips.shortcuts = "`ctrl+b`, `ctrl+i` and `ctrl+u` are quick shortcuts for bold, italic and underline."; - out.tips.indent = "In numbered and bulleted lists, you can use tab or shift+tab to quickly increase or decrease indentation."; - out.tips.title = "You can set the title of your pad by clicking the top center."; - out.tips.store = "Every time you visit a pad, if you're logged in it will be saved to your CryptDrive."; - out.tips.marker = "You can highlight text in a pad using the \"marker\" item in the styles dropdown menu."; - - out.feedback_about = "If you're reading this, you were probably curious why CryptPad is requesting web pages when you perform certain actions"; - out.feedback_privacy = "We care about your privacy, and at the same time we want CryptPad to be very easy to use. We use this file to figure out which UI features matter to our users, by requesting it along with a parameter specifying which action was taken."; - out.feedback_optout = "If you would like to opt out, visit your user settings page, where you'll find a checkbox to enable or disable user feedback"; - - return out; -}); diff --git a/www/common/translations/old/messages.ro.js b/www/common/translations/old/messages.ro.js deleted file mode 100644 index c20896f3f..000000000 --- a/www/common/translations/old/messages.ro.js +++ /dev/null @@ -1,365 +0,0 @@ -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - - out.main_title = "CryptPad: Zero Knowledge, Colaborare în timp real"; - out.main_slogan = "Puterea stă în cooperare - Colaborarea este cheia"; - - out.button_newpad = "Filă Text Nouă"; - out.button_newcode = "Filă Cod Nouă"; - out.button_newpoll = "Sondaj Nou"; - out.button_newslide = "Prezentare Nouă"; - out.button_newwhiteboard = "Fila Desen Nouă"; - out.updated_0_common_connectionLost = "Conexiunea la server este pierdută
    Până la revenirea conexiunii, vei fi în modul citire"; - out.common_connectionLost = out.updated_0_common_connectionLost; - out.websocketError = "Conexiune inexistentă către serverul websocket..."; - out.typeError = "Această filă nu este compatibilă cu aplicația aleasă"; - out.onLogout = "Nu mai ești autentificat, {0}apasă aici{1} să te autentifici
    sau apasă Escapesă accesezi fila în modul citire."; - out.wrongApp = "Momentan nu putem arăta conținutul sesiunii în timp real în fereastra ta. Te rugăm reîncarcă pagina."; - out.loading = "Încarcă..."; - out.error = "Eroare"; - - out.saved = "Salvat"; - out.synced = "Totul a fost salvat"; - out.deleted = "Pad șters din CryptDrive-ul tău"; - out.disconnected = "Deconectat"; - out.synchronizing = "Se sincronizează"; - out.reconnecting = "Reconectare..."; - out.lag = "Decalaj"; - out.readonly = "Mod citire"; - out.anonymous = "Anonim"; - out.yourself = "Tu"; - out.anonymousUsers = "editori anonimi"; - out.anonymousUser = "editor anonim"; - out.users = "Utilizatori"; - out.and = "Și"; - out.viewer = "privitor"; - out.viewers = "privitori"; - out.editor = "editor"; - out.editors = "editori"; - out.language = "Limbă"; - out.upgrade = "Actualizare"; - out.upgradeTitle = "Actualizează-ți contul pentru a mări limita de stocare"; - out.MB = "MB"; - out.greenLight = "Totul funcționează corespunzător"; - out.orangeLight = "Conexiunea lentă la internet îți poate afecta experiența"; - out.redLight = "Ai fost deconectat de la sesiune"; - out.pinLimitReached = "Ai atins limita de stocare"; - out.pinLimitReachedAlert = "Ai atins limita de stocare. Noile pad-uri nu vor mai fi stocate în CryptDrive.
    Pentru a rezolva această problemă, poți să nlături pad-uri din CryptDrive-ul tău (incluzând gunoiul) sau să subscrii la un pachet premium pentru a-ți extinde spațiul de stocare."; - out.pinLimitNotPinned = "Ai atins limita de stocare.
    Acest pad nu va fi stocat n CryptDrive-ul tău."; - out.pinLimitDrive = "Ai atins limita de stocare.
    Nu poți să creezi alte pad-uri."; - out.importButtonTitle = "Importă un pad dintr-un fișier local"; - out.exportButtonTitle = "Exportă pad-ul acesta către un fișier local"; - out.exportPrompt = "Cum ai vrea să îți denumești fișierul?"; - out.changeNamePrompt = "Schimbă-ți numele (lasă necompletat dacă vrei să fii anonim): "; - out.user_rename = "Schimbă numele afișat"; - out.user_displayName = "Nume afișat"; - out.user_accountName = "Nume cont"; - out.clickToEdit = "Click pentru editare"; - out.forgetButtonTitle = "Mută acest pad la gunoi"; - out.forgetPrompt = "Click-ul pe OK va muta acest pad la gunoi. Ești sigur?"; - out.movedToTrash = "Acest pad a fost mutat la gunoi.
    Acesează-mi Drive-ul"; - out.shareButton = "Distribuie"; - out.shareSuccess = "Link copiat în clipboard"; - out.newButton = "Nou"; - out.newButtonTitle = "Crează un nou pad"; - out.saveTemplateButton = "Salvează ca șablon"; - out.saveTemplatePrompt = "Alege un titlu pentru șablon"; - out.templateSaved = "Șablon salvat!"; - out.selectTemplate = "Selectează un șablon sau apasă escape"; - out.presentButtonTitle = "Intră în modul de prezentare"; - out.backgroundButtonTitle = "Schimbă culoarea de fundal din prezentare"; - out.colorButtonTitle = "Schimbă culoarea textului în modul de prezentare"; - out.printButton = "Printează (enter)"; - out.printButtonTitle = "Printează-ți slide-urile sau exportă-le ca fișier PDF"; - out.printOptions = "Opțiuni schemă"; - out.printSlideNumber = "Afișează numărul slide-ului"; - out.printDate = "Afișează data"; - out.printTitle = "Afișează titlul pad-ului"; - out.printCSS = "Reguli de stil personalizate (CSS):"; - out.printTransition = "Permite tranziția animațiilor"; - out.slideOptionsTitle = "Personalizează-ți slide-urile"; - out.slideOptionsButton = "Salvează (enter)"; - out.editShare = "Editează link-ul"; - out.editShareTitle = "Copiază link-ul de editare în clipboard"; - out.editOpen = "Deschide link-ul de editare într-o nouă filă"; - out.editOpenTitle = "Deschide acest pad în modul de editare într-o nouă filă"; - out.viewShare = "Link în modul citire"; - out.viewShareTitle = "Copiază link-ul în modul de citire în clipboard"; - out.viewOpen = "Deschide link-ul în modul de citire într-o filă nouă"; - out.viewOpenTitle = "Deschide acest pad în modul de citire într-o nouă filă"; - out.notifyJoined = "{0} s-au alăturat sesiunii colaborative"; - out.notifyRenamed = "{0} e cunoscut ca {1}"; - out.notifyLeft = "{0} au părăsit sesiunea colaborativă"; - out.okButton = "OK (enter)"; - out.cancel = "Anulează"; - out.cancelButton = "Anulează (esc)"; - out.historyButton = "Afișează istoricul documentului"; - out.history_next = "Mergi la versiunea următoare"; - out.history_prev = "Mergi la versiunea trecută"; - out.history_goTo = "Mergi la sesiunea selectată"; - out.history_close = "Înapoi"; - out.history_closeTitle = "Închide istoricul"; - out.history_restore = "Restabilește"; - out.history_restoreTitle = "Restabilește versiunea selectată a documentului"; - out.history_restorePrompt = "Ești sigur că vrei să înlocuiești versiunea curentă a documentului cu cea afișată?"; - out.history_restoreDone = "Document restabilit"; - out.history_version = "Versiune:"; - out.poll_title = "Zero Knowledge Selector Dată"; - out.poll_subtitle = "Zero Knowledge, realtime programare"; - out.poll_p_save = "Setările tale sunt actualizate instant, așa că tu nu trebuie să salvezi."; - out.poll_p_encryption = "Tot conținutul tău este criptat ca doar persoanele cărora tu le dai link-ul să aibă acces. Nici serverul nu poate să vadă ce modifici."; - out.wizardLog = "Click pe butonul din dreapta sus pentru a te ntoarce la sondajul tău"; - out.wizardTitle = "Folosește wizard-ul pentru a crea sondajul tău"; - out.wizardConfirm = "Ești pregătit să adaugi aceste opțiuni la sondajul tău?"; - out.poll_publish_button = "Publică"; - out.poll_admin_button = "Admin"; - out.poll_create_user = "Adaugă un nou utilizator"; - out.poll_create_option = "Adaugă o nouă opțiune"; - out.poll_commit = "Comite"; - out.poll_closeWizardButton = "Închide wizard-ul"; - out.poll_closeWizardButtonTitle = "Închide wizard-ul"; - out.poll_wizardComputeButton = "Calculează Opțiunile"; - out.poll_wizardClearButton = "Curăță Tabelul"; - out.poll_wizardDescription = "Crează automat un număr de opțiuni întroducând orice număr de zile sau intervale orare"; - - out.poll_wizardAddDateButton = "+ Zi"; - out.poll_wizardAddTimeButton = "+ Ore"; - out.poll_optionPlaceholder = "Opțiune"; - out.poll_userPlaceholder = "Numele tău"; - out.poll_removeOption = "Ești sigur că vrei să îndepărtezi această opțiune?"; - out.poll_removeUser = "Ești sigur că vrei să îndepărtezi aceast utilizator?"; - out.poll_titleHint = "Titlu"; - out.poll_descriptionHint = "Descrie sondajul, și apoi folosește butonul 'publică' când ai terminat. Orice utilizator care are link-ul poate modifica descrierea, dar descurajăm această practică."; - out.canvas_clear = "Curăță"; - out.canvas_delete = "Curăță selecția"; - out.canvas_disable = "Dezactivează modul desen"; - out.canvas_enable = "Activează modul desen"; - out.canvas_width = "Lățime"; - out.canvas_opacity = "Opacitate"; - out.fm_rootName = "Documente"; - out.fm_trashName = "Gunoi"; - out.fm_unsortedName = "Fișiere nesortate"; - out.fm_filesDataName = "Toate fișierele"; - out.fm_templateName = "Șabloane"; - out.fm_searchName = "Caută"; - out.fm_searchPlaceholder = "Caută..."; - out.fm_newButton = "Nou"; - out.fm_newButtonTitle = "Crează un nou pad sau folder"; - out.fm_newFolder = "Folder nou"; - out.fm_newFile = "Pad nou"; - out.fm_folder = "Folder"; - out.fm_folderName = "Numele folderului"; - out.fm_numberOfFolders = "# de foldere"; - out.fm_numberOfFiles = "# of files"; - out.fm_fileName = "Nume filă"; - out.fm_title = "Titlu"; - out.fm_type = "Tip"; - out.fm_lastAccess = "Ultima accesare"; - out.fm_creation = "Creare"; - out.fm_forbidden = "Acțiune interzisă"; - out.fm_originalPath = "Ruta inițială"; - out.fm_openParent = "Arată în folder"; - out.fm_noname = "Document nedenumit"; - out.fm_emptyTrashDialog = "Ești sigur că vrei să golești coșul de gunoi?"; - out.fm_removeSeveralPermanentlyDialog = "Ești sigur că vrei să ștergi pentru totdeauna aceste {0} elemente din coșul de gunoi?"; - out.fm_removePermanentlyDialog = "Ești sigur că vrei să ștergi acest element pentru totdeauna?"; - out.fm_removeSeveralDialog = "Ești sigur că vrei să muți aceste {0} elemente la coșul de gunoi?"; - out.fm_removeDialog = "Ești sigur că vrei să muți {0} la gunoi?"; - out.fm_restoreDialog = "Ești sigur că vrei să restabilești {0} în locația trecută?"; - out.fm_unknownFolderError = "Ultima locație vizitată sau cea selectată nu mai există. Deschidem fișierul părinte..."; - out.fm_contextMenuError = "Nu putem deschide meniul de context pentru acest element. Dacă problema persistă, reîncarcă pagina."; - out.fm_selectError = "Nu putem selecta elementul vizat. Dacă problema persistă, reîncarcă pagina."; - out.fm_categoryError = "Nu putem deschide categoria selectată, afișează sursa."; - out.fm_info_root = "Crează câte foldere tip cuib ai nevoie pentru a-ți sorta fișierele."; - out.fm_info_unsorted = "Conține toate fișierele pe care le-ai vizitat și nu sunt sortate în \"Documente\" sau mutate în \"Gunoi\"."; - out.fm_info_template = "Conține toate pad-urile stocate ca șabloane și pe care le poți refolosi atunci când creezi un nou pad."; - out.fm_info_trash = "Fișierele șterse din gunoi vor fi șterse și din \"Toate fișierele\", făcând imposibilă recuperarea fișierelor din managerul de fișiere."; - out.fm_info_allFiles = "Conține toate fișierele din \"Documente\", \"Nesortate\" și \"Gunoi\". Poți să muți sau să ștergi fișierele aici."; - out.fm_info_login = "Loghează-te"; - out.fm_info_register = "Înscrie-te"; - out.fm_info_anonymous = "Nu ești logat cu un cont valid așa că aceste pad-uri vor fi șterse (află de ce). Înscrie-te sau Loghează-te pentru a le salva."; - out.fm_alert_backupUrl = "Link copie de rezervă pentru acest drive.
    Este foarte recomandat să o păstrezi pentru tine.
    Poți să o folosești pentru a recupera toate fișierele în cazul în care memoria browserului tău este șterge..
    Oricine are linkul poate să editeze sau să îndepărteze toate fișierele din managerul tău de documente.
    "; - out.fm_alert_anonymous = "Salut, momentan folosești CryptPad în mod anonim. Este ok, doar că fișierele tale vor fi șterse după o perioadă de inactivitate. Am dezactivat caracteristicile avansate ale drive-ului pentru utilizatorii anonimi pentru a face clar faptul că stocare documentelor acolo nu este o metodă sigură. Poți să citești mai multe despre motivarea noastră și despre ce de trebuie să te Înregistrezi si sa te Loghezi."; - out.fm_backup_title = "Link de backup"; - out.fm_nameFile = "Cum ai vrea să numești fișierul?"; - out.fc_newfolder = "Folder nou"; - out.fc_rename = "Redenumește"; - out.fc_open = "Deschide"; - out.fc_open_ro = "Deschide (modul citire)"; - out.fc_delete = "Șterge"; - out.fc_restore = "Restaurează"; - out.fc_remove = "Șterge permanent"; - out.fc_empty = "Curăță coșul"; - out.fc_prop = "Proprietăți"; - out.fc_sizeInKilobytes = "Dimensiune n Kilobytes"; - out.fo_moveUnsortedError = "Nu poți să muți un folder la lista de pad-uri nesortate"; - out.fo_existingNameError = "Numele ales este deja folosit în acest director. Te rugăm să alegi altul."; - out.fo_moveFolderToChildError = "Nu poți să muți un folder într-unul dintre descendenții săi"; - out.fo_unableToRestore = "Nu am reușit să restaurăm fișierul în locația de origine. Poți să ncerci să îl muți într-o nouă locație."; - out.fo_unavailableName = "Un fișier sau un folder cu același nume există deja în locația nouă. Redenumește elementul și încearcă din nou."; - out.login_login = "Loghează-te"; - out.login_makeAPad = "Crează un pad în modul anonim"; - out.login_nologin = "Răsfoiește pad-urile locale"; - out.login_register = "Înscrie-te"; - out.logoutButton = "Deloghează-te"; - out.settingsButton = "Setări"; - out.login_username = "Nume utilizator"; - out.login_password = "Parolă"; - out.login_confirm = "Confirmă parola"; - out.login_remember = "Ține-mă minte"; - out.login_hashing = "Încriptăm parola, o să mai dureze."; - out.login_hello = "Salut {0},"; - out.login_helloNoName = "Salut,"; - out.login_accessDrive = "Acesează-ți drive-ul"; - out.login_orNoLogin = "sau"; - out.login_noSuchUser = "Nume de utilizator sau parolă invalide. Încearcă din nou sau înscrie-te."; - out.login_invalUser = "Nume utilizator cerut"; - out.login_invalPass = "Parolă cerută"; - out.login_unhandledError = "O eroare neașteptată a avut loc emoticon_unhappy"; - out.register_importRecent = "Importă istoricul pad-ului (Recomandat)"; - out.register_acceptTerms = "Accept termenii serviciului"; - out.register_passwordsDontMatch = "Parolele nu se potrivesc!"; - out.register_mustAcceptTerms = "Trebuie să accepți termenii serviciului"; - out.register_mustRememberPass = "Nu putem să îți resetăm parola dacă o uiți. Este foarte important să o ții minte! Bifează căsuța pentru a confirma."; - out.register_header = "Bine ai venit în CryptPad"; - out.register_explanation = "

    Hai să stabilim câteva lucruri, mai întâi

    • Parola ta este cheia secretă care criptează toate pad-urile tale. Dacă pierzi/uiți parola nu există nici-o metodă prin care îți putem recupera datele.
    • Poți importa pad-uri care au fost vizionate recent în browser pentru a le avea în cont.
    • Dacă folosești un computer împărțit, trebuie să te deloghezi, închiderea taburilor nu este de ajuns.
    "; - out.register_writtenPassword = "Mi-am notat numele de utilizator și parola, înaintează."; - out.register_cancel = "Întoarce-te"; - out.register_warning = "Zero Knowledge înseamnă că noi nu îți putem recupera datele dacă îți pierzi parola."; - out.register_alreadyRegistered = "Acest user există deja, vrei să te loghezi?"; - out.settings_title = "Setări"; - out.settings_save = "Salvează"; - out.settings_backupTitle = "Fă o copie de rezervă sau restaurează toate datele"; - out.settings_backup = "Copie de rezervă"; - out.settings_restore = "Restaurează"; - out.settings_resetTitle = "Curăță-ți drive-ul"; - out.settings_reset = "Îndepărtează toate fișierele și folderele din CryptPad-ul tău."; - out.settings_resetPrompt = "Această acțiune va indepărta toate pad-urile din drive-ul tău.
    Ești sigur că vrei să continui?
    Tastează “Iubesc CryptPad” pentru a confirma."; - out.settings_resetDone = "Drive-ul tău este acum gol!"; - out.settings_resetError = "Text de verificare incorect. CryptPad-ul tău nu a fost schimbat."; - out.settings_resetTips = "Sfaturi în CryptDrive"; - out.settings_resetTipsButton = "Resetează sfaturile disponibile în CryptDrive"; - out.settings_resetTipsDone = "Toate sfaturile sunt vizibile din nou."; - out.settings_importTitle = "Importă pad-urile recente ale acestui browser n CryptDrive-ul meu"; - out.settings_import = "Importă"; - out.settings_importConfirm = "Ești sigur că vrei să imporți pad-urile recente ale acestui browser în contul tău de CryptDrive?"; - out.settings_importDone = "Import complet"; - out.settings_userFeedbackHint1 = "CryptPad oferă niște feedback foarte simplu serverului, pentru a ne informa cum putem să îți îmbunătățim experiența voastră."; - out.settings_userFeedbackHint2 = "Conținutul pad-ului tău nu va fi împărțit cu serverele."; - out.settings_userFeedback = "Activează feedback"; - out.settings_anonymous = "Nu ești logat. Setările sunt specifice browser-ului."; - out.settings_publicSigningKey = "Cheia de semnătură publică"; - out.settings_usage = "Uzaj"; - out.settings_usageTitle = "Vezi dimensiunea totală a pad-urilor fixate în MB"; - out.settings_pinningNotAvailable = "Pad-urile fixate sunt disponibile doar utilizatorilor înregistrați."; - out.settings_pinningError = "Ceva nu a funcționat"; - out.settings_usageAmount = "Pad-urile tale fixate ocupă {0}MB"; - out.settings_logoutEverywhereTitle = "Deloghează-te peste tot"; - out.settings_logoutEverywhere = "Deloghează-te din toate sesiunile web"; - out.settings_logoutEverywhereConfirm = "Ești sigur? Va trebui să te loghezi, din nou, pe toate device-urile tale."; - out.upload_serverError = "Eroare de server: fișierele tale nu pot fi încărcate la momentul acesta."; - out.upload_uploadPending = "Ai deja o încărcare în desfășurare. Anulezi și încarci noul fișier?"; - out.upload_success = "Fișierul tău ({0}) a fost ncărcat și adăugat la drive-ul tău cu succes."; - out.main_p2 = "Acest proiect folosește CKEditor Visual Editor, CodeMirror, și ChainPad un motor în timp real."; - out.main_howitworks_p1 = "CryptPad folosește o variantă a algoritmului de Operational transformation care este capabil să găsescă consens distribuit folosind Nakamoto Blockchain, o construcție popularizată de Bitcoin. Astfel algoritmul poate evita nevoia ca serverul central să rezove conflicte, iar serverul nu este interesat de conținutul care este editat în pad."; - out.main_about_p2 = "Dacă ai orice fel de întrebare sau comentariu, poți să ne dai un tweet, semnalezi o problemă on github, spui salut pe IRC (irc.freenode.net), sau trimiți un email."; - out.main_info = "

    Colaborează în siguranță


    Dezvoltă-ți ideile împreună cu documentele partajate în timp ce tehnologia Zero Knowledge îți păstrează securitatea; chiar și de noi."; - out.main_howitworks = "Cum funcționează"; - out.main_zeroKnowledge = "Zero Knowledge"; - out.main_zeroKnowledge_p = "Nu trebuie să ne crezi că nu ne uităm la pad-urile tale, cu tehnologia revoluționară Zero Knowledge a CryptPad nu putem. Învață mai multe despre cum îți protejăm Intimitate și Securitate."; - out.main_writeItDown = "Notează"; - out.main_writeItDown_p = "Cele mai importante proiecte vin din idei mici. Notează-ți momentele de inspirație și ideile neașteptate pentru că nu știi niciodată care ar putea fi noua mare descoperire."; - out.main_share = "Partajează link-ul, partajează pad-ul"; - out.main_share_p = "Dezvoltă-ți ideile împreună: organizează întâlniri eficiente, colaborează pe liste TODO și fă prezentări scurte cu toți prietenii tăi și device-urile tale."; - out.main_organize = "Organizează-te"; - out.main_organize_p = "Cu CryptPad Drive, poți să stai cu ochii pe ce este important. Folderele îți permit să ții evidența proiectelor tale și să ai o viziune globală asupra evoluției lucrurilor."; - out.tryIt = "Testează!"; - out.main_richText = "Rich Text editor"; - out.main_richText_p = "Editează texte complexe în mod colaborativ cu Zero Knowledge în timp real. CkEditor application."; - out.main_code = "Editor cod"; - out.main_code_p = "Editează cod din softul tău, în mod colaborativ, cu Zero Knowledge în timp real.CodeMirror application."; - out.main_slide = "Editor slide-uri"; - out.main_slide_p = "Crează-ți prezentări folosind sintaxa Markdown, și afișează-le în browser-ul tău."; - out.main_poll = "Sondaj"; - out.main_poll_p = "Plănuiește întâlniri sau evenimente, sau votează pentru cea mai bună soluție pentru problema ta."; - out.main_drive = "CryptDrive"; - out.footer_applications = "Aplicații"; - out.footer_contact = "Contact"; - out.footer_aboutUs = "Despre noi"; - out.about = "Despre"; - out.privacy = "Privacy"; - out.contact = "Contact"; - out.terms = "ToS"; - out.blog = "Blog"; - out.policy_title = "Politica de confidențialitate CryptPad"; - out.policy_whatweknow = "Ce știm despre tine"; - out.policy_whatweknow_p1 = "Ca o aplicație care este găzduită online, CryptPad are acces la metadatele expuse de protocolul HTTP. Asta include adresa IP-ului tău, și alte titluri HTTP care pot fi folosite ca să identifice un browser. Poți să vezi ce informații împărtășește browser-ul tău vizitând WhatIsMyBrowser.com."; - out.policy_whatweknow_p2 = "Folosim Kibana, o platformă open source, pentru a afla mai multe despre utilizatorii noștri. Kibana ne spune despre cum ai găsit CryptPad, căutare directă, printr-un motor de căutare, sau prin recomandare de la un alt serviciu online ca Reddit sau Twitter."; - out.policy_howweuse = "Cum folosim ce aflăm"; - out.policy_howweuse_p1 = "Folosim aceste informații pentru a lua decizii mai bune în promovarea CryptPad, prin evaluarea eforturilor trecute care au fost de succes. Informațiile despre locația ta ne ajută să aflăm dacă ar trebui să oferim suport pentru alte limbi, pe lângă engleză."; - out.policy_howweuse_p2 = "Informațiile despre browser-ul tău (dacă este bazat pe un sistem de operare desktop sau mobil) ne ajută să luăm decizii când prioritizăm viitoarele îmbunătățiri. Echipa noastră de dezvoltare este mică, și încercăm să facem alegeri care să îmbunătățească experiența câtor mai mulți utilizatori."; - - out.policy_whatwetell = "Ce le spunem altora despre tine"; - out.policy_whatwetell_p1 = "Nu furnizăm informațiile obținute terților, decât dacă ne este cerut în mod legal."; - out.policy_links = "Link-uri către alte site-uri"; - out.policy_links_p1 = "Acest site conține link-uri către alte site-uri, incluzându-le pe cele produse de alte organizații. Nu suntem responsabili pentru practicile de intimitate sau pentru conținutul site-urilor externe. Ca regulă generală, link-urile către site-uri externe sunt deschise ntr-o fereastră noup, pentru a face clar faptul că părăsiți CryptPad.fr."; - out.policy_ads = "Reclame"; - out.policy_ads_p1 = "Nu afișăm nici o formă de publicitate online, dar s-ar putea să atașăm link-uri către instituțiile care ne finanțează cerecetarea."; - out.policy_choices = "Ce alegeri ai"; - out.policy_choices_open = "Codul nostru este open source, așa că tu ai mereu posibilitatea de a-ți găzdui propria instanță de CryptPad."; - out.policy_choices_vpn = "Dacă vrei să folosești instanța găzduită de noi, dar nu vrei să îți expui IP-ul, poți să îl protejezi folosind Tor browser bundle, sau VPN."; - out.policy_choices_ads = "Dacă vrei doar să blochezi platforma noastră de analiză, poți folosi soluții de adblocking ca Privacy Badger."; - out.tos_title = "CryptPad Termeni de Utilizare"; - out.tos_legal = "Te rugăm să nu fii rău intenționat, abuziv, sau să faci orice ilegal."; - out.tos_availability = "Sperăm că o să găsești acest serviciu util, dar disponibilitatea sau performanța nu poate fi garantată. Te rugăm să îți exporți datele n mod regulat."; - out.tos_e2ee = "Conținutul CryptPad poate fi citit sau modificat de oricine care poate ghici sau obține fragmentul identificator al pad-ului. Recomandăm să folosești soluții de comunicare criptate end-to-end-encrypted (e2ee) pentru a partaja link-uri, evitând orice risc în cazul unei scurgeri de informații."; - out.tos_logs = "Metadatele oferite de browser-ul tău serverului ar putea fi înscrise în scopul de a menține serviciul."; - out.tos_3rdparties = "Nu oferim date personale terților, decât dacă ne sunt solicitate prin lege."; - out.bottom_france = "Realizat cu \"love\" n \"Franța\""; - out.bottom_support = "Un proiect al \"XWiki Labs Project cu susținerea \"OpenPaaS-ng\""; - out.header_france = "With \"love\" from \"Franța\"/ by \"XWiki"; - out.header_support = " \"OpenPaaS-ng\""; - out.header_logoTitle = "Mergi la pagina principală"; - out.initialState = "

    Acesta este CryptPad, editorul colaborativ bazat pe tehnologia Zero Knowledge în timp real. Totul este salvat pe măsură ce scrii.
    Partajează link-ul către acest pad pentru a edita cu prieteni sau folosește butonul pentru a partaja read-only link permițând vizualizarea dar nu și editarea.

    "; - out.codeInitialState = "/*\n Acesta este editorul colaborativ de cod bazat pe tehnologia Zero Knowledge CryptPad.\n Ce scrii aici este criptat, așa că doar oamenii care au link-ul pot să-l acceseze.\n Poți să alegi ce limbaj de programare pus n evidență și schema de culori UI n dreapta sus.\n*/"; - out.slideInitialState = "# CryptSlide\n1. Scrie-ți conținutul slide-urilor folosind sintaxa markdown\n - Află mai multe despre sintaxa markdown [aici](http://www.markdowntutorial.com/)\n2. Separă-ți slide-urile cu ---\n3. Click pe butonul \"Play\" pentru a vedea rezultatele - Slide-urile tale sunt actualizate în timp real."; - out.driveReadmeTitle = "Ce este CryptPad?"; - out.readme_welcome = "Bine ai venit n CryptPad !"; - out.readme_p1 = "Bine ai venit în CryptPad, acesta este locul unde îți poți lua notițe, singur sau cu prietenii."; - out.readme_p2 = "Acest pad o să îți ofere un scurt ghid în cum poți să folosești CryptPad pentru a lua notițe, a le ține organizate și a colabora pe ele."; - out.readme_cat1 = "Descoperă-ți CryptDrive-ul"; - out.readme_cat1_l1 = "Crează un pad: În CryptDrive-ul tău, dă click {0} apoi {1} și poți să creezi un pad."; - out.readme_cat1_l2 = "Deschide pad-urile din CryptDrive-ul tău: doublu-click pe iconița unui pad pentru a-l deschide."; - out.readme_cat1_l3 = "Organizează-ți pad-urile: Când ești logat, orice pad accesezi va fi afișat ca în secțiunea {0} a drive-ului tău."; - out.readme_cat1_l3_l1 = "Poți să folosești funcția click and drag pentru a muta fișierele în folderele secțiunii {0} a drive-ului tău și pentru a crea noi foldere."; - out.readme_cat1_l3_l2 = "Ține minte să încerci click-dreapta pe iconițe pentru că există și meniuri adiționale."; - out.readme_cat1_l4 = "Pune pad-urile vechi în gunoi. Poți să folosești funcția click and drag pe pad-uri în categoria {0} la fel ca și în cazul folderelor."; - out.readme_cat2 = "Crează pad-uri ca un profesionist"; - out.edit = "editează"; - out.view = "vezi"; - out.readme_cat2_l1 = "Butonul {0} din pad-ul tău dă accesul colaboratorilor tăi să {1} sau să {2} pad-ul."; - out.readme_cat2_l2 = "Schimbă titlul pad-ului dând click pe creion"; - out.readme_cat3 = "Descoperă aplicațiile CryptPad"; - out.readme_cat3_l1 = "Cu editorul de cod CryptPad, poți colabora pe cod ca Javascript și markdown ca HTML și Markdown"; - out.readme_cat3_l2 = "Cu editorul de slide-uri CryptPad, poți să faci prezentări scurte folosind Markdown"; - out.readme_cat3_l3 = "Cu CryptPoll poți să organizezi votări rapide, mai ales pentru a programa ntâlniri care se potrivesc calendarelor tuturor"; - - out.tips = { }; - out.tips.lag = "Iconița verde din dreapta-sus arată calitatea conexiunii internetului tău la serverele CryptPad."; - out.tips.shortcuts = "`ctrl+b`, `ctrl+i` and `ctrl+u` sunt scurtături pentru bold, italic și underline."; - out.tips.indentare = "În listele cu bulină sau cele numerotate, poți folosi tab sau shift+tab pentru a mări sau micșora indentarea."; - out.tips.titlu = "Poți seta titlul pad-urilor tale prin click pe centru sus."; - out.tips.stocare = "De fiecare dată când vizitezi un pad, dacă ești logat va fi salvat pe CryptDrive-ul tău."; - out.tips.marker = "Poți sublinia text într-un pad folosind itemul \"marker\" n meniul de stiluri."; - - out.feedback_about = "Dacă citești asta, probabil că ești curios de ce CryptPad cere pagini web atunci când întreprinzi anumite acțiuni"; - out.feedback_privacy = "Ne pasă de intimitatea ta, si în același timp vrem să păstrăm CryptPad ușor de folosit. Folosim acest fișier pentru a ne da seama care beneficii UI contează cel mai mult pentru utilizatori, cerându-l alături de un parametru specific atunci când acțiunea se desfășoară"; - out.feedback_optout = "Dacă vrei să ieși, vizitează setările de pe pagina ta de user, unde vei găsi o căsuță pentru a activa sau dezactiva feedback-ul de la user"; - - return out; -}); diff --git a/www/common/translations/old/messages.zh.js b/www/common/translations/old/messages.zh.js deleted file mode 100644 index 6d69b35ca..000000000 --- a/www/common/translations/old/messages.zh.js +++ /dev/null @@ -1,535 +0,0 @@ -/* - * This is an internal language file. - * If you want to change some translations in your CryptPad instance, use the '/customize/translations/messages.{LANG}.js' - * file (make a copy from /customize.dist/translations/messages.{LANG}.js) - */ -define(function () { - var out = {}; - // translations must set this key for their language to be available in - // the language dropdowns that are shown throughout Cryptpad's interface - - out._languageName = 'Chinese'; - - out.main_title = "CryptPad: 零知識, 即時協作編寫"; - out.main_slogan = "團結就是力量 - 合作是關鍵"; // TODO remove? - - out.type = {}; - out.type.pad = '富文本'; - out.type.code = '編碼'; - out.type.poll = '投票'; - out.type.slide = '投影片簡報'; - out.type.drive = '磁碟'; - out.type.whiteboard = '白板'; - out.type.file = '檔案'; - out.type.media = '多媒體'; - - out.button_newpad = '富文件檔案'; - out.button_newcode = '新代碼檔案'; - out.button_newpoll = '新投票調查'; - out.button_newslide = '新簡報'; - out.button_newwhiteboard = '新白板'; - - // NOTE: We want to update the 'common_connectionLost' key. - // Please do not add a new 'updated_common_connectionLostAndInfo' but change directly the value of 'common_connectionLost' - out.updated_0_common_connectionLost = "伺服器連線中斷
    現在是唯讀狀態,直到連線恢復正常。"; - out.common_connectionLost = out.updated_0_common_connectionLost; - - out.websocketError = '無法連結上 websocket 伺服器...'; - out.typeError = "這個編輯檔與所選的應用程式並不相容"; - out.onLogout = '你已登出, {0}點擊這裏{1} 來登入
    或按Escape 來以唯讀模型使用你的編輯檔案'; - out.wrongApp = "無法在瀏覽器顯示即時期間的內容,請試著再重新載入本頁。"; - - out.loading = "載入中..."; - out.error = "錯誤"; - out.saved = "儲存"; - out.synced = "所有資料已儲存好了"; - out.deleted = "自 CryptDrive 刪除檔案"; - - out.disconnected = '已斷線'; - out.synchronizing = '同步中'; - out.reconnecting = '重新連結...'; - out.lag = 'Lag'; - out.readonly = '唯讀'; - out.anonymous = "匿名"; - out.yourself = "你自己"; - out.anonymousUsers = "匿名的編輯群"; - out.anonymousUser = "匿名的編輯群者"; - out.users = "用戶"; - out.and = "與"; - out.viewer = "檢視者"; - out.viewers = "檢視群"; - out.editor = "編輯者"; - out.editors = "編輯群"; - - out.language = "語言"; - - out.comingSoon = "即將上市..."; - - out.newVersion = 'CryptPad 已更新!
    ' + - '檢查最新版本有什麼新功能:
    '+ - 'CryptPad新發佈記事 {0}'; - - out.upgrade = "昇級"; - out.upgradeTitle = "昇級帳戶以取得更多的儲存空間"; - out.MB = "MB"; - out.GB = "GB"; - out.KB = "KB"; - - out.formattedMB = "{0} MB"; - out.formattedGB = "{0} GB"; - out.formattedKB = "{0} KB"; - - out.greenLight = "每件事都很順利"; - out.orangeLight = "連線速度慢可能會影響用戶體驗"; - out.redLight = "你這段期間的連線已中斷"; - - out.pinLimitReached = "你已達到儲存容量上限"; - out.updated_0_pinLimitReachedAlert = "你已達到儲存容量上限,新檔案不會儲存到你的 CryptDrive.
    " + - '要嘛你可以自 CryptDrive 移除原有文件或是 昇級到付費版增加你的儲存容量。'; - out.pinLimitReachedAlert = out.updated_0_pinLimitReachedAlert; - out.pinLimitNotPinned = "你已達到容量使用上限
    "+ - "這個檔案無法儲存到你的 CryptDrive."; - out.pinLimitDrive = "你已達到容量使用上限
    " + - "你不能建立新的編輯檔案"; - out.importButtonTitle = '從電腦上傳滙入檔案'; - - out.exportButtonTitle = '將這個檔案滙出到電腦'; - out.exportPrompt = '你希望怎麼命名你的檔案?'; - - out.changeNamePrompt = '更換你的名稱(若留空白則會成為無名氏): '; - out.user_rename = "改變顯示名稱"; - out.user_displayName = "顯示名稱"; - out.user_accountName = "帳號名稱"; - - out.clickToEdit = "點擊以編輯"; - - out.forgetButtonTitle = '將這個檔案移置垃圾筒'; - out.forgetPrompt = '點擊 OK 將把這個檔案移置垃圾筒,確定要這樣做嗎'; - out.movedToTrash = '這個檔案已被移置垃圾筒
    讀取我的雲端硬碟'; - - out.shareButton = '分享'; - out.shareSuccess = '複製連結到剪貼版'; - - out.newButton = '新'; - out.newButtonTitle = '建立新的工作檔案'; - - out.saveTemplateButton = "存成模版"; - out.saveTemplatePrompt = "為這個模版選一個標題"; - out.templateSaved = "模版已儲存!"; - out.selectTemplate = "選擇一個模版或是按 escape 跳出"; - - out.previewButtonTitle = "顯示或隱藏 Markdown 預覽模式"; - - out.presentButtonTitle = "輸入簡報模式"; - - out.backgroundButtonTitle = '改變簡報的顏色背景'; - out.colorButtonTitle = '在簡報模式下改變文字顏色'; - - out.printButton = "列印 (enter)"; - out.printButtonTitle = "列印投影片或滙出成 PDF 檔案"; - out.printOptions = "版型選項"; - out.printSlideNumber = "顯示投影片號碼"; - out.printDate = "顯示日期"; - out.printTitle = "顯示檔案標題"; - out.printCSS = "自定風格規則 (CSS):"; - out.printTransition = "啟用轉場動畫"; - - out.slideOptionsTitle = "自定你的投影片"; - out.slideOptionsButton = "儲存 (enter)"; - - out.editShare = "編輯連結"; - out.editShareTitle = "複製所編輯的連結到剪貼版"; - out.editOpen = "在新分頁開啟連結編輯"; - out.editOpenTitle = "在新分頁開啟這個檔案為編輯模式"; - out.viewShare = "唯讀連結"; - out.viewShareTitle = "複製唯讀的連結到剪貼版"; - out.viewOpen = "在新分頁開啟唯讀連結"; - out.viewOpenTitle = "在新分頁開啟這個檔案為唯讀模式"; - - out.notifyJoined = "{0} 已加入此協作期間"; - out.notifyRenamed = "{0} 現在改名為 {1}"; - out.notifyLeft = "{0} 已離開了這個協作期間"; - - out.okButton = 'OK (enter)'; - - out.cancel = "取消"; - out.cancelButton = '取消 (esc)'; - - out.historyButton = "顯示文件歷史"; - out.history_next = "到下一個版本"; - out.history_prev = "到之前的版本"; - out.history_goTo = "到所選擇的版本"; - out.history_close = "回到"; - out.history_closeTitle = "關閉歷史記錄"; - out.history_restore = "重建"; - out.history_restoreTitle = "將此文件重建到所挑選的版本"; - out.history_restorePrompt = "確定要將這個展現的版本來取代現有版本嗎?"; - out.history_restoreDone = "文件已重建"; - out.history_version = "版本:"; - - // Polls - - out.poll_title = "零知識日期挑選"; - out.poll_subtitle = "零知識, 即時 排程"; - - out.poll_p_save = "你的設定會立即更新, 因此從不需要按鍵儲存或擔心遺失。"; - out.poll_p_encryption = "你所有幹入的資料都會予以加密,只有取得連結者才可以讀取它。即便是伺服器也不能看到你作了什麼變動。"; - - out.wizardLog = "點擊左上方的按鍵以回到你的調查"; - out.wizardTitle = "使用精靈來建立調查投票"; - out.wizardConfirm = "你真的要新增這些問題到你的調查中嗎?"; - - out.poll_publish_button = "發佈"; - out.poll_admin_button = "管理者"; - out.poll_create_user = "新增使用者"; - out.poll_create_option = "新增選項"; - out.poll_commit = "投入"; - - out.poll_closeWizardButton = "關閉協助精靈"; - out.poll_closeWizardButtonTitle = "關閉協助精靈"; - out.poll_wizardComputeButton = "計算最適化"; - out.poll_wizardClearButton = "清除表格"; - out.poll_wizardDescription = "透過輸入任何日期或時間分段,可自動建立一些選項"; - out.poll_wizardAddDateButton = "+ 日期"; - out.poll_wizardAddTimeButton = "+ 時間"; - - out.poll_optionPlaceholder = "選項"; - out.poll_userPlaceholder = "你的名稱"; - out.poll_removeOption = "確定要移除這個選項嗎?"; - out.poll_removeUser = "確定要移除這位使用者嗎?"; - - out.poll_titleHint = "標題"; - out.poll_descriptionHint = "請簡述這個調查目的,完成時使用「發佈鍵」。任何知道此調查連結者可以更改這裏的描述內容,但我們不鼓勵這麼做。."; - - // Canvas - out.canvas_clear = "清除"; - out.canvas_delete = "刪除所選"; - out.canvas_disable = "取消繪圖"; - out.canvas_enable = "啟動繪圖"; - out.canvas_width = "寛度"; - out.canvas_opacity = "透明度"; - - // File manager - - out.fm_rootName = "根目錄"; - out.fm_trashName = "垃圾桶"; - out.fm_unsortedName = "未整理的檔案"; - out.fm_filesDataName = "所有檔案"; - out.fm_templateName = "模版"; - out.fm_searchName = "搜尋"; - out.fm_searchPlaceholder = "搜尋..."; - out.fm_newButton = "新的"; - out.fm_newButtonTitle = "建立新工作檔案或資料夾"; - out.fm_newFolder = "新資料夾"; - out.fm_newFile = "新工作檔案"; - out.fm_folder = "資料夾"; - out.fm_folderName = "資料夾名稱"; - out.fm_numberOfFolders = "# 個資料夾"; - out.fm_numberOfFiles = "# 檔案"; - out.fm_fileName = "檔案名"; - out.fm_title = "標題"; - out.fm_type = "類型"; - out.fm_lastAccess = "上回使用"; - out.fm_creation = "創建"; - out.fm_forbidden = "禁止的行為"; - out.fm_originalPath = "原始路徑"; - out.fm_openParent = "顯示在目錄夾中"; - out.fm_noname = "無標題文件"; - out.fm_emptyTrashDialog = "確定要清理垃圾筒嗎?"; - out.fm_removeSeveralPermanentlyDialog = "確定要將這些 {0} 東西永自垃圾筒移除嗎?"; - out.fm_removePermanentlyDialog = "你確定要永久地移除這些項目嗎?"; - out.fm_removeSeveralDialog = "確定要將這些 {0} 東西移至垃圾筒嗎?"; - out.fm_removeDialog = "確定要將移動 {0} 至垃圾筒嗎?"; - out.fm_restoreDialog = "確定要重置 {0} 到它之前的位置嗎?"; - out.fm_unknownFolderError = "所選或上回訪問的目錄不再存在了,正開啟上層目錄中..."; - out.fm_contextMenuError = "無法在此元件下打開文本選單。如果這個問題一直發生,請試著重新載入此頁。"; - out.fm_selectError = "無法選取目標的要素。如果這個問題一直發生,請試著重新載入此頁。"; - out.fm_categoryError = "無法打開所選的類別,正在顯示根目錄。"; - out.fm_info_root = "在此建立任何巢狀目錄夾以便於整理分類你的檔案。"; - out.fm_info_unsorted = '包含所有你曾訪問過的檔案,其尚未被整理在 "根目錄" 或移到到"垃圾筒".'; // "My Documents" should match with the "out.fm_rootName" key, and "Trash" with "out.fm_trashName" - out.fm_info_template = '包含所有工作檔案已存成模版,便於讓你在建立新工作檔案時套用。'; - out.updated_0_fm_info_trash = '清空垃圾筒好讓 CryptDrive 多出一些空間'; - out.fm_info_trash = out.updated_0_fm_info_trash; - out.fm_info_allFiles = '包含在 "根目錄", "未整理的" 和 "垃圾筒" 裏的所有檔案。這裏你無法移動或移除檔案。'; // Same here - out.fm_info_anonymous = '你尚未登入,因此這些工作檔案可能會被刪除。 (了解原因). ' + - '註冊登入以便保留它們。'; - out.fm_alert_backupUrl = "這個雲端硬碟的備份連結
    " + - "高度建議把自己的 IP 資訊保留成只有自己知道
    " + - "萬一瀏覽器記憶被消除,你可以用它來接收所有的檔案。
    " + - "任何知道此連結的人可以編輯或移除你檔案管理底下的所有檔案。
    "; - out.fm_alert_anonymous = "嗨你好, 你目前正以匿名方式在使用 CryptPad , 這也沒問題,不過你的東西過一段時間沒動靜後,就會自動被刪除。 " + - "匿名的用戶我們也取消其進階功能,因為我們要明確地讓用戶知道,這裏 " + - '不是一個安全存放東西的地方。你可以 進一步了解 關於 ' + - '為何我們這樣作,以及為何你最好能夠註冊 以及 登錄使用。'; - out.fm_backup_title = '備份連結'; - out.fm_nameFile = '你想要如何來命名這個檔案呢?'; - out.fm_error_cantPin = "內部伺服器出錯,請重新載入本頁並再試一次。"; - // File - Context menu - out.fc_newfolder = "新資料夾"; - out.fc_rename = "重新命名"; - out.fc_open = "打開"; - out.fc_open_ro = "打開 (唯讀)"; - out.fc_delete = "刪除"; - out.fc_restore = "重置"; - out.fc_remove = "永久刪除"; - out.fc_empty = "清理垃圾筒"; - out.fc_prop = "Properties"; - out.fc_sizeInKilobytes = "容量大小 (Kilobytes)"; - // fileObject.js (logs) - out.fo_moveUnsortedError = "你不能移動資料夾到未整理的工作檔案清單"; - out.fo_existingNameError = "名稱已被使用,請選擇其它名稱"; - out.fo_moveFolderToChildError = "你不能移動資料夾到它的子資料夾底下"; - out.fo_unableToRestore = "無法將這個檔案重置到原始的位置。你可以試著將它移動到其它新位置。"; - out.fo_unavailableName = "在新位置裏同名的檔案或資料夾名稱已存在,請重新命名後再試看看。"; - - // login - out.login_login = "登入"; - out.login_makeAPad = '匿名地建立一個工作檔案'; - out.login_nologin = "瀏覽本地的工作檔案"; - out.login_register = "註冊"; - out.logoutButton = "登出"; - out.settingsButton = "設定"; - - out.login_username = "用戶名"; - out.login_password = "密碼"; - out.login_confirm = "確認你的密碼"; - out.login_remember = "記住我"; - - out.login_hashing = "散列你的密碼中,這要花上一點時間"; - - out.login_hello = 'Hello {0},'; // {0} is the username - out.login_helloNoName = 'Hello,'; - out.login_accessDrive = '取用你的磁碟'; - out.login_orNoLogin = '或'; - - out.login_noSuchUser = '無效的用戶名或密碼,請再試一次或重新註冊'; - out.login_invalUser = '要求用戶名'; - out.login_invalPass = '要求密碼'; - out.login_unhandledError = '發生了未預期的錯誤 :('; - - out.register_importRecent = "滙入檔案記錄 (建議)"; - out.register_acceptTerms = "我同意 服務條款"; - out.register_passwordsDontMatch = "密碼不相符!"; - out.register_mustAcceptTerms = "你必須同意我們的服務條款。"; - out.register_mustRememberPass = "如果你忘了密碼,我們也無法為你重置。因此務必自行好好記住! 請在勾選處勾選確認。"; - - out.register_header = "歡迎來到 CryptPad"; - out.register_explanation = [ - "

    首先讓我們先了解幾件事

    ", - "
      ", - "
    • 你的密碼是你用來加密所有工作檔案的密鑰。一旦遺失它,我們也沒辦法幫你恢復你的資料。
    • ", - "
    • 你可以滙入近期在瀏覽器下檢視的工作檔案到你的雲端硬碟裏。
    • ", - "
    • 如果你使用的是公用分享電腦,你需要在完成工作後進行登出,只是關閉分頁是不夠的。
    • ", - "
    " - ].join(''); - - out.register_writtenPassword = "我已記下了我的用戶名和密碼,請繼續"; - out.register_cancel = "回去"; - - out.register_warning = "零知識表示如果你遺失了密碼,我們也無法還原你的資料"; - - out.register_alreadyRegistered = "這名用戶己存在了,你要登入嗎?"; - - // Settings - out.settings_title = "設定"; - out.settings_save = "儲存"; - out.settings_backupTitle = "備份或重建你所有的資料"; - out.settings_backup = "備份"; - out.settings_restore = "重建"; - out.settings_resetTitle = "清除你的雲端硬碟"; - out.settings_reset = "從你的 CryptDrive 移除所有的檔案和資料夾"; - out.settings_resetPrompt = "這個動作會自你的雲端硬碟中移除所有工作檔案
    "+ - "確定要繼續嗎?
    " + - "輸入 “I love CryptPad” 來確認。"; - out.settings_resetDone = "你的目錄現已清空!"; - out.settings_resetError = "不正確的認證文字,你的 CryptDrive 並未更改。"; - out.settings_resetTips = "使用 CryptDrive 的竅門"; - out.settings_resetTipsButton = "在 CryptDrive 下重置可用的訣竅"; - out.settings_resetTipsDone = "所有的訣竅現在都可再次看到了。"; - - out.settings_importTitle = "滙入這個瀏覽器近期的工作檔案到我的 CryptDrive"; - out.settings_import = "滙入"; - out.settings_importConfirm = "確定要從這個瀏覽器滙入近期的工作檔案到你的 CryptDrive ?"; - out.settings_importDone = "滙入完成"; - - out.settings_userFeedbackHint1 = "CryptPad 會提供一些基本的反饋到伺服器,以讓我們知道如何改善用戶體驗。"; - out.settings_userFeedbackHint2 = "你的工作檔案內容絕不會被分享到伺服器"; - out.settings_userFeedback = "啟用用戶反饋功能"; - - out.settings_anonymous = "你尚未登入,在此瀏覽器上進行特別設定。"; - out.settings_publicSigningKey = "公開金鑰簽署"; - - out.settings_usage = "用法"; - out.settings_usageTitle = "查看所有置頂的工作檔案所佔的容量"; - out.settings_pinningNotAvailable = "工作檔案置頂功能只開放給已註冊用戶"; - out.settings_pinningError = "有點不對勁"; - out.settings_usageAmount = "你置頂的工作檔案佔了 {0}MB"; - - out.settings_logoutEverywhereTitle = "自所有地點登出"; - out.settings_logoutEverywhere = "自所有其它的網頁期間登出"; - out.settings_logoutEverywhereConfirm = "你確定嗎?你將需要登入到所有用到設置。"; - - out.upload_serverError = "伺服器出錯:本次無法上傳你的檔案"; - out.upload_uploadPending = "你欲上傳檔案正在傳輸中,要取消並上傳新檔案嗎?"; - out.upload_success = "你的檔案 ({0}) 已成功地上傳並放入到你的網路磁碟中。"; - out.upload_notEnoughSpace = "你的 CryptDrive 無足夠空間來存放這個檔案。"; - out.upload_tooLarge = "此檔案超過了上傳單一檔案可允許的容量上限。"; - out.upload_choose = "選擇一個檔案"; - out.upload_pending = "待處理"; - out.upload_cancelled = "已取消的"; - out.upload_name = "檔案名"; - out.upload_size = "大小"; - out.upload_progress = "進度"; - out.download_button = "解密 & 下載"; - - // general warnings - out.warn_notPinned = "這個工作檔案並不在任何人的 CryptDrive 裏,它將在 3 個月到期後刪除。 進一步了解..."; - - // index.html - - - //about.html - out.main_p2 = '本專案使用 CKEditor 視覺編輯器, CodeMirror, 以及 ChainPad 即時引擊。'; - out.main_howitworks_p1 = 'CryptPad 應用一種變體的 操作型變換 Operational transformation 演算法,它利用Nakamoto Blockchain來找到分散的共識, Nakamoto Blockchain 是一種建構當前流行的比特幣。這套演算法可避免需要一個中央的伺服器來解析操作型變換編輯衝突,而無須處理解析衝突,伺服器並不知道哪一個檔案被編輯。'; - - // contact.html - out.main_about_p2 = '若有任何問題和建議, 可以在tweet us, github提出問題, 或是來到 irc (irc.freenode.net)打聲招呼, 再或者 寄封電郵給我們.'; - - out.main_info = "

    Collaborate in Confidence


    利用共同享文件發嚮點子,透過 零知識 科技確保隱私安全; 對任何網路服務商都要加以提防。"; - - out.main_howitworks = '它如何運作'; - out.main_zeroKnowledge = '零知識'; - out.main_zeroKnowledge_p = "你不必相信我們所說的並不會 察看你的檔案, CryptPad 革命性的零知識技術讓我們 真的不能看到。 進一步了解在這裏,我們如何保護用戶的 隱私和安全。"; - out.main_writeItDown = '寫下它'; - out.main_writeItDown_p = "偉大的專案來自不起眼的小點子。記下靈感與點子的瞬間,因為你從不會知道哪個會帶來重大突破。"; - out.main_share = '分享連結, 分享工作檔案'; - out.main_share_p = "一起來發響想法點子: 在任何設備上,與朋友一起執行有效率的會議, 協作待辦清單與快速製作簡報。"; - out.main_organize = 'Get organized'; - out.main_organize_p = "利用 CryptPad 空間, 你可以保留看管重要的東西。資料夾讓你可以追踪專案和全盤了解事情的走向狀況。"; - out.tryIt = 'Try it out!'; - out.main_richText = '富文字編輯器'; - out.main_richText_p = '利用我們的即時零知識技術,集體協作地編輯富文本檔案 CkEditor 應用程式application.'; - out.main_code = '代碼編輯器'; - out.main_code_p = '利用我們的即時零知識技術,集體協作地編輯程式代碼 CodeMirror 應用程式。'; - out.main_slide = '投影片編輯器'; - out.main_slide_p = '使用 Markdown 語法來建立投影片,並利用瀏覽器來展示投影片。'; - out.main_poll = '調查'; - out.main_poll_p = '規劃會議或活動,或是為問題舉行投最佳方案的投票。'; - out.main_drive = 'CryptDrive'; - - out.footer_applications = "應用程式"; - out.footer_contact = "聯繫"; - out.footer_aboutUs = "關於 Cryptpad"; - - out.about = "關於"; - out.privacy = "隱私"; - out.contact = "聯繫"; - out.terms = "服務條款"; - out.blog = "Blog"; - - // privacy.html - - out.policy_title = 'CryptPad 隱私政策'; - out.policy_whatweknow = '我們會知道哪些關於你的資料'; - out.policy_whatweknow_p1 = '作為一個網頁上的應用程式, CryptPad 可以接取 HTTP 協議所曝露的元數據。 這包括你的 IP 地址、各式其它的 HTTP 標頭,其用於識別你特定的瀏覽器。 你可以訪問 WhatIsMyBrowser.com這個網站,知道你的瀏覽器分享了哪些資訊。'; - out.policy_whatweknow_p2 = '我們使用 Kibana, 它是一個開源的流量數據分析平台, 以更了解用戶。Kibana 讓我們知道你是如何地發現 CryptPad, 是透過直接接入、攑搜尋引擊或是其它網站的介紹如 Reddit 和 Twitter。'; - out.policy_howweuse = '我們如何利用我們知道的東西'; - out.policy_howweuse_p1 = '我們利用這些資訊評估過去成功的效果,以更佳地決定如何推廣 CryptPad。有關你地理位置的資訊讓我們知道是否該提供英語之外的語言版本支援'; - out.policy_howweuse_p2 = "有關你的瀏覽器資訊 (是桌面還是手機操作系統) 有助於讓我們決定要優先哪些功能改善。我們開發團隊人很少,我們試著挑選盡可能地提昇更多用戶的使用體驗。"; - out.policy_whatwetell = '我們可以告訴別人關於你的哪些資料'; - out.policy_whatwetell_p1 = '我們不會給第三人我們所收集的資訊,除非被依法要求配合。'; - out.policy_links = '其它網站連結'; - out.policy_links_p1 = '本站含有其它網站的連結,包括其它組織的産品。我們無法對這些隱私實踐或任何本站以外的內容負責。一般而言,連到外站的連結會另啟新視窗,以明確讓你知道已離開了CryptPad.fr.'; - out.policy_ads = '廣告'; - out.policy_ads_p1 = '我們不會放置任何線上廣告,但會提供一些資助我們研究的機構與團體的網址連結'; - out.policy_choices = '你有的選擇'; - out.policy_choices_open = '我們的代碼是開放的,你可以選擇自行在自己的機器上來架設自己的 CryptPad.'; - out.policy_choices_vpn = '如果你要使用我們架設的服務, 但不希望曝露自己的 IP 地址, 你可以利用Tor 瀏覽器套件來保護隱藏 IP 地址, 或是使用 VPN。'; - out.policy_choices_ads = '如果你只是想要封鎖我們的數據分析器, 你可以使用廣告封鎖工具如 Privacy Badger.'; - - // terms.html - - out.tos_title = "CryptPad 服務條款"; - out.tos_legal = "請不要惡意、濫用或從事非法活動。"; - out.tos_availability = "希望你覺得我們的産品與服務對你有所幫助, 但我們並不能一直百分百保證它的表現穩定與可得性。請記得定期滙出你的資料。"; - out.tos_e2ee = "CryptPad 的內容可以被任何猜出或取得工作檔案分段識別碼的人讀取與修改。我們建議你使用端對端加密 (e2ee) 訊息技術來分享工作檔案連結 以及假設如果一旦連結外漏不會背上任何責任。"; - out.tos_logs = "你的瀏覽器提供給伺服器的元數據,可能會因為維護本服務之效能而被收集記錄。"; - out.tos_3rdparties = "除非法令要求,我們不會提供任何個人資料給第三方。"; - - // BottomBar.html - - out.bottom_france = 'Made with love in France'; - out.bottom_support = 'An XWiki SAS Labs Project with the support of OpenPaaS-ng'; - - // Header.html - - out.header_france = 'With love from France by XWiki SAS'; - - out.header_support = ' OpenPaaS-ng'; - out.header_logoTitle = '回到主頁'; - - // Initial states - - out.initialState = [ - '

    ', - '這是 CryptPad, 零知識即時協作編輯平台,當你輸入時一切已即存好。', - '
    ', - '分享這個工作檔案的網址連結給友人或是使用、 按鈕分享唯讀的連結 其只能看不能編寫。', - '

    ' - ].join(''); - - out.codeInitialState = [ - '# CryptPad 零知識即時協作代碼編輯平台\n', - '\n', - '* 你所輸入的東西會予以加密,僅有知道此網頁連結者可以接取這份文件。\n', - '* 你可以在右上角選擇欲編寫的程式語言以及樣版配色風格。' - ].join(''); - - out.slideInitialState = [ - '# CryptSlide\n', - '1. 使用 markdown 語法來寫下你的投影片內容\n', - ' - 進一步學習 markdown 語法 [here](http://www.markdowntutorial.com/)\n', - '2. 利用 --- 來區隔不同的投影片\n', - '3. 點擊下方 "Play" 鍵來查看成果', - ' - 你的投影片會即時更新' - ].join(''); - - // Readme - - out.driveReadmeTitle = "什麼是 CryptPad?"; - out.readme_welcome = "歡迎來到 CryptPad !"; - out.readme_p1 = "歡迎來到 CryptPad, 這裏你可以獨自作個人筆記或是和別人共享協作。"; - out.readme_p2 = "這個工作檔案可以讓你快速地了解如何使用 CryptPad 作筆記,有效地整理管理文件工作檔案。"; - out.readme_cat1 = "認識如何使用 CryptDrive"; - out.readme_cat1_l1 = "建立一個工作檔案: 在 CryptDrive 底下, 點擊 {0} 然後 {1} 這樣就可以建立一個新的工作檔案。"; // 0: New, 1: Rich Text - out.readme_cat1_l2 = "從 CryptDrive 開啟工作檔案: 雙擊工作檔案的圖示來開啟它。"; - out.readme_cat1_l3 = "分類你的工作檔案:登入之後,每一個你能接取使用的工作檔案會顯示在你雲端硬碟中的 {0} 部份。"; // 0: Unsorted files - out.readme_cat1_l3_l1 = "你可以點擊或是拉曳檔案到雲端硬碟 {0} 區,新增資料夾。"; // 0: Documents - out.readme_cat1_l3_l2 = "記得試著點擊圖示,以顯示更多的選項功能。"; - out.readme_cat1_l4 = "把舊的工作檔案放到垃圾筒:點擊或是拉曳檔案到 {0} 如同把它們拉到文件目錄夾一樣的方法。"; // 0: Trash - out.readme_cat2 = "像個專業人士來編寫你的工作檔案"; - out.edit = "編輯"; - out.view = "檢視"; - out.readme_cat2_l1 = "在工作檔案下的 {0} 按鍵可讓其它的協作者接取 {1} 或是 {2} 工作檔案"; // 0: Share, 1: edit, 2: view - out.readme_cat2_l2 = "若要更改工作檔案的名稱,只要點擊右上的鉛筆圖示即可"; - out.readme_cat3 = "發現其它的 CryptPad 應用"; - out.readme_cat3_l1 = "使用 CryptPad 代碼編輯器,你可以和其它人協作各種程式碼,如 Javascript、 markdown、 HTML 等等。"; - out.readme_cat3_l2 = "使用 CryptPad 投影片編輯功能,你可以使用 Markdown 快速製作簡報檔。"; - out.readme_cat3_l3 = "利用 CryptPoll 你可以快速作個線上調查,尤其是調查每個人有空的會議時間。"; - - // Tips - out.tips = {}; - out.tips.lag = "右上角的綠色圖標顯示你連線至 CryptPad 伺服器的連線品質。"; - out.tips.shortcuts = "`ctrl+b`, `ctrl+i` 和 `ctrl+u` 分別是粗體字、斜體、與加底線用法的快速鍵。"; - out.tips.indent = "要使用數字以及符號列表, 可使用 tab 或 shift+tab 快速地增加或滅少縮排指令。"; - out.tips.title = "點擊正上方來設定工作檔案的標題。"; - out.tips.store = "每一回你造訪一個工作檔案, 如果是登入狀態,則這些檔案會自動儲存到你的 CryptDrive."; - out.tips.marker = "在格式下拉選單中使用 \"marker\" 可以標注反亮文字."; - - out.feedback_about = "如果你讀了這裏,也許會好奇為何當你執行某些動作時 CryptPad 會請求網頁資訊。"; - out.feedback_privacy = "我們注重你的隱私,同時也要讓 CryptPad 容易使用。我們利用這個檔案來了解哪一種介面設計為用戶所重視,透過它來請求特別的功能參數。"; - out.feedback_optout = "如果欲退出客戶資料收集, 請到 用戶設定頁, 可以找到勾選項目來啟用或關閉用戶回饋功能。"; - - return out; -}); - diff --git a/www/kanban/inner.js b/www/kanban/inner.js index f5f7c4ac3..f04e78918 100644 --- a/www/kanban/inner.js +++ b/www/kanban/inner.js @@ -21,6 +21,12 @@ define([ '/kanban/jkanban_cp.js', 'cm/mode/gfm/gfm', + 'cm/addon/edit/closebrackets', + 'cm/addon/edit/matchbrackets', + 'cm/addon/edit/trailingspace', + 'cm/addon/selection/active-line', + 'cm/addon/search/search', + 'cm/addon/search/match-highlighter', 'css!/bower_components/codemirror/lib/codemirror.css', 'css!/bower_components/codemirror/addon/dialog/dialog.css', @@ -211,15 +217,11 @@ define([ }; // Body - var editor = CodeMirror.fromTextArea(text, { - allowDropFileTypes: [], - lineWrapping: true, - styleActiveLine: true, - autoCloseBrackets: true, - inputStyle: 'contenteditable', - extraKeys: {"Shift-Ctrl-R": undefined}, - mode: "gfm" - }); + var cm = SFCodeMirror.create("gfm", CodeMirror, text); + var editor = cm.editor; + editor.setOption('gutters', []); + editor.setOption('lineNumbers', false); + editor.setOption('readOnly', false); editor.on('keydown', function (editor, e) { if (e.which === 27) { // Focus the next form element but don't close the modal (stopPropagation) @@ -257,6 +259,25 @@ define([ commit(); }); + setTimeout(function () { + var privateData = framework._.cpNfInner.metadataMgr.getPrivateData(); + var fmConfig = { + dropArea: $('.CodeMirror'), + body: $('body'), + onUploaded: function (ev, data) { + var parsed = Hash.parsePadUrl(data.url); + var secret = Hash.getSecrets('file', parsed.hash, data.password); + var fileHost = privateData.fileHost || privateData.origin; + var src = fileHost + Hash.getBlobPathFromHex(secret.channel); + var key = Hash.encodeBase64(secret.keys.cryptKey); + var mt = ''; + editor.replaceSelection(mt); + } + }; + common.createFileManager(fmConfig); + }); + + // Tags var _field, initialTags; var tags = { @@ -281,6 +302,12 @@ define([ _field.setTokens(tags || []); $tags.find('.token-input').on('keydown', function (e) { + // if the tokenfield is blank and the user hits enter or escape + // then allow the event to propogate (closing the modal) + // this can leave behind the autocomplete menu, so forcefully hide it + if (!$(this).val() && [13, 27].indexOf(e.which) !== -1) { + return void $('.ui-autocomplete.ui-front').hide(); + } e.stopPropagation(); }); @@ -343,6 +370,7 @@ define([ var idx = list.indexOf(id); if (idx !== -1) { list.splice(idx, 1); } delete (boards.data || {})[id]; + kanban.removeBoard(id); return void commit(); } Object.keys(boards.data || {}).forEach(function (boardId) { @@ -775,8 +803,11 @@ define([ } }); }, + applyHtml: function (html, node) { + DiffMd.apply(html, $(node),framework._.sfCommon); + }, renderMd: function (md) { - return DiffMd.render(md, true, false); + return DiffMd.render(md); }, addItemButton: true, getTextColor: getTextColor, diff --git a/www/kanban/jkanban_cp.js b/www/kanban/jkanban_cp.js index d366a7fad..061b5f06b 100644 --- a/www/kanban/jkanban_cp.js +++ b/www/kanban/jkanban_cp.js @@ -50,6 +50,7 @@ define([ boardTitleclick: function (/*el, boardId*/) {}, addItemClick: function (/*el, boardId*/) {}, renderMd: function (/*md*/) {}, + applyHtml: function (/*html, node*/) {}, refresh: function () {}, onChange: function () {} }; @@ -522,7 +523,7 @@ define([ }; } var nodeBody = document.createElement('div'); - nodeBody.classList.add('kanban-item-body'); + nodeBody.setAttribute('id', 'kanban-body-' + element.id); $(nodeBody).on('click', 'a', function (e) { e.preventDefault(); var a = e.target; @@ -533,7 +534,9 @@ define([ nodeBody.onclick = function (e) { e.preventDefault(); }; - nodeBody.innerHTML = html; + //nodeBody.innerHTML = html; + self.applyHtml(html, nodeBody); + nodeBody.classList.add('kanban-item-body'); nodeItem.appendChild(nodeBody); } if (Array.isArray(element.tags)) { @@ -796,6 +799,9 @@ define([ return self; }; + this.applyHtml = function (html, node) { + return self.options.applyHtml(html, node); + }; this.renderMd = function (md) { return self.options.renderMd(md); }; diff --git a/www/pad/comments.js b/www/pad/comments.js index 128784671..da98ceeb2 100644 --- a/www/pad/comments.js +++ b/www/pad/comments.js @@ -42,30 +42,8 @@ define([ var canonicalize = function(t) { return t.replace(/\r\n/g, '\n'); }; - // XXX function duplicated from www/code/markers.js - var authorUid = function(existing) { - if (!Array.isArray(existing)) { existing = []; } - var n; - var i = 0; - while (!n || existing.indexOf(n) !== -1 && i++ < 1000) { - n = Math.floor(Math.random() * 1000000); - } - // If we can't find a valid number in 1000 iterations, use 0... - if (existing.indexOf(n) !== -1) { n = 0; } - return n; - }; var getAuthorId = function(Env, curve) { - var existing = Object.keys(Env.comments.authors || {}).map(Number); - if (!Env.common.isLoggedIn()) { return authorUid(existing); } - - var uid; - existing.some(function(id) { - var author = Env.comments.authors[id] || {}; - if (author.curvePublic !== curve) { return; } - uid = Number(id); - return true; - }); - return uid || authorUid(existing); + return Env.common.getAuthorId(Env.comments.authors, curve); }; // Return the author ID and add/update the data for registered users diff --git a/www/pad/export.js b/www/pad/export.js index d1deef146..f1e3497c9 100644 --- a/www/pad/export.js +++ b/www/pad/export.js @@ -5,15 +5,17 @@ define([ '/bower_components/nthen/index.js', ], function ($, Util, Hyperjson, nThen) { var module = { - ext: '.html' + ext: '.html', // default + exts: ['.html', '.doc'] }; var exportMediaTags = function (inner, cb) { var $clone = $(inner).clone(); nThen(function (waitFor) { $(inner).find('media-tag').each(function (i, el) { - if (!$(el).data('blob') || !el.blob) { return; } - Util.blobToImage(el.blob || $(el).data('blob'), waitFor(function (imgSrc) { + var blob = Util.find(el, ['_mediaObject','_blob', 'content']); + if (!blob) { return; } + Util.blobToImage(blob, waitFor(function (imgSrc) { $clone.find('media-tag[src="' + $(el).attr('src') + '"] img') .attr('src', imgSrc); $clone.find('media-tag').parent() @@ -25,18 +27,31 @@ define([ }); }; + var cleanHtml = function (inner) { + return inner.innerHTML.replace(/]*class="cke_anchor"[^>]*data-cke-realelement="([^"]*)"[^>]*>/g, + function(match,realElt){ + //console.log("returning realElt \"" + unescape(realElt)+ "\"."); + return decodeURIComponent(realElt); + }); + }; module.getHTML = function (inner) { return ('\n' + '\n' + ' \n ' + - inner.innerHTML.replace(/]*class="cke_anchor"[^>]*data-cke-realelement="([^"]*)"[^>]*>/g, - function(match,realElt){ - //console.log("returning realElt \"" + unescape(realElt)+ "\"."); - return decodeURIComponent(realElt); }) + + cleanHtml(inner) + ' \n' ); }; - module.main = function (userDoc, cb) { + var exportDoc = function (inner) { + var preHtml = "Export HTML To Doc"; + var postHtml = ""; + var _html = preHtml+cleanHtml(inner)+postHtml; + return _html; + }; + + module.main = function (userDoc, cb, ext) { + if (!ext || module.exts.indexOf(ext) === -1) { ext = module.ext; } + var inner; if (userDoc && userDoc.tagName) { inner = userDoc; @@ -56,7 +71,14 @@ define([ } } exportMediaTags(inner, function (toExport) { - cb(new Blob([ module.getHTML(toExport) ], { type: "text/html;charset=utf-8" })); + if (ext === ".doc") { + var blob = new Blob(['\ufeff', exportDoc(toExport)], { + type: 'application/msword' + }); + return void cb(blob); + } + var html = module.getHTML(toExport); + cb(new Blob([ html ], { type: "text/html;charset=utf-8" })); }); }; diff --git a/www/pad/inner.js b/www/pad/inner.js index b7f309c35..05cf2c788 100644 --- a/www/pad/inner.js +++ b/www/pad/inner.js @@ -793,8 +793,8 @@ define([ }); }, true); - framework.setFileExporter(Exporter.ext, function(cb) { - Exporter.main(inner, cb); + framework.setFileExporter(Exporter.exts, function(cb, ext) { + Exporter.main(inner, cb, ext); }, true); framework.setNormalizer(function(hjson) { diff --git a/www/support/ui.js b/www/support/ui.js index dda07c657..ac61bfe7f 100644 --- a/www/support/ui.js +++ b/www/support/ui.js @@ -173,7 +173,7 @@ define([ classes: 'btn-danger' }, function() { if (typeof(onHide) !== "function") { return; } - onHide(); + onHide(hide); // XXX }); $(answer).click(function () {