Skip to content

Commit ec03715

Browse files
author
Christopher Liu
committed
add patches
1 parent 1f6e69b commit ec03715

File tree

2 files changed

+49
-0
lines changed

2 files changed

+49
-0
lines changed

patches/musicblocks-app.patch

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
diff --git a/main.js b/main.js
2+
index 3d791c3f39c6f001b8ae92881bfefc181731c8ee..755c31a8166fa37ac1de7f7345d2e35dc1482f52 100644
3+
--- a/main.js
4+
+++ b/main.js
5+
@@ -20,6 +20,8 @@ function createWindow () {
6+
mainWindow.isElectron = true;
7+
// and load the index.html of the app.
8+
mainWindow.loadFile('musicblocks/index.html');
9+
+ mainWindow.removeMenu();
10+
+ /*
11+
mainWindow.on('close', function(e){
12+
var choice = require('electron').dialog.showMessageBoxSync(this,
13+
{
14+
@@ -32,6 +34,7 @@ function createWindow () {
15+
e.preventDefault();
16+
}
17+
});
18+
+ */
19+
20+
// Open the DevTools.
21+
// mainWindow.webContents.openDevTools()

patches/musicblocks.patch

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
diff --git a/js/SaveInterface.js b/js/SaveInterface.js
2+
index 2b8f36e47c54beef53ccfdc43a8626b44187874b..9521b864465c3e666591e5f38d4d5864d8bf7758 100644
3+
--- a/js/SaveInterface.js
4+
+++ b/js/SaveInterface.js
5+
@@ -84,7 +84,7 @@ function SaveInterface(PlanetInterface) {
6+
if (window.isElectron == true) {
7+
filename = defaultfilename;
8+
} else {
9+
- filename = prompt("Filename:", defaultfilename);
10+
+ filename = defaultfilename;
11+
}
12+
} else {
13+
if (fileExt(defaultfilename) != extension) {
14+
@@ -484,6 +484,7 @@ function SaveInterface(PlanetInterface) {
15+
16+
this.init = function() {
17+
this.timeLastSaved = -100;
18+
+ /*
19+
window.onbeforeunload = function(e) {
20+
if (
21+
this.PlanetInterface !== undefined &&
22+
@@ -516,5 +517,6 @@ function SaveInterface(PlanetInterface) {
23+
e.returnValue = "";
24+
}
25+
}.bind(this);
26+
+ */
27+
};
28+
}

0 commit comments

Comments
 (0)