Removed a few dependencies, refactored pixel-editor.js

This commit is contained in:
unsettledgames
2021-12-07 12:11:40 +01:00
parent 21dd47c2b0
commit 05beab6929
15 changed files with 94 additions and 121 deletions

View File

@ -58,7 +58,7 @@ const FileManager = (() => {
}
function exportProject() {
if (Startup.documentCreated()) {
if (EditorState.documentCreated()) {
//create name
let fileName = Util.getValue("export-file-name");
//set download link
@ -107,7 +107,7 @@ const FileManager = (() => {
function open() {
//if a document exists
if (Startup.documentCreated()) {
if (EditorState.documentCreated()) {
//check if the user wants to overwrite
if (confirm('Opening a pixel will discard your current one. Are you sure you want to do that?'))
//open file selection dialog