on(file){
			dragIn.push(file.filepath); 
		});
	}

	console.log("Loaded: ", inFiles);

	loadStorage("sessionFiles", function(sessionFiles){
		console.log(sessionFiles);
		if (sessionFiles == ""){
			//No previous opened files
			if (dragIn != ""){
				//If there is a file dragin, open it as well.
				dragIn.forEach(function(openingFile){
					newEditor(openingFile);
				})
			}else{
				newTab();
			}
		}else{
			//There are perviously opened files
			try{
				var pages = JSON.parse(sessionFiles);
				for 