@dimensional-innovations/electron-background 2.3.0 → 2.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AutoUpdater.js +2 -2
- package/dist/BrowserWindow.js +19 -9
- package/dist/DevTools.js +2 -2
- package/dist/StaticFileDir.js +2 -2
- package/dist/init.js +4 -4
- package/package.json +1 -1
package/dist/AutoUpdater.js
CHANGED
|
@@ -32,8 +32,8 @@ class AutoUpdater {
|
|
|
32
32
|
this.enabled = enabled;
|
|
33
33
|
this.options = options;
|
|
34
34
|
}
|
|
35
|
-
afterLoad(
|
|
36
|
-
return __awaiter(this,
|
|
35
|
+
afterLoad(_a) {
|
|
36
|
+
return __awaiter(this, arguments, void 0, function* ({ log }) {
|
|
37
37
|
const { channel } = this.options;
|
|
38
38
|
if (this.enabled && channel) {
|
|
39
39
|
this.startAutoUpdater(channel);
|
package/dist/BrowserWindow.js
CHANGED
|
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
|
|
|
15
15
|
}) : function(o, v) {
|
|
16
16
|
o["default"] = v;
|
|
17
17
|
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
};
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
25
35
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
26
36
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
27
37
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -104,8 +114,8 @@ class FullScreenBrowserWindow extends DefaultBrowserWindow {
|
|
|
104
114
|
super(options);
|
|
105
115
|
this.enabled = enabled;
|
|
106
116
|
}
|
|
107
|
-
beforeLoad(
|
|
108
|
-
return __awaiter(this,
|
|
117
|
+
beforeLoad(_a) {
|
|
118
|
+
return __awaiter(this, arguments, void 0, function* ({ browserWindow }) {
|
|
109
119
|
if (!this.enabled) {
|
|
110
120
|
return;
|
|
111
121
|
}
|
package/dist/DevTools.js
CHANGED
|
@@ -35,8 +35,8 @@ class DevTools {
|
|
|
35
35
|
this.devTools = devTools;
|
|
36
36
|
this.enabled = enabled;
|
|
37
37
|
}
|
|
38
|
-
beforeLoad(
|
|
39
|
-
return __awaiter(this,
|
|
38
|
+
beforeLoad(_a) {
|
|
39
|
+
return __awaiter(this, arguments, void 0, function* ({ browserWindow }) {
|
|
40
40
|
if (!this.enabled) {
|
|
41
41
|
return;
|
|
42
42
|
}
|
package/dist/StaticFileDir.js
CHANGED
|
@@ -9,7 +9,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.StaticFileDir = void 0;
|
|
13
|
+
exports.createFileProtocol = createFileProtocol;
|
|
13
14
|
const electron_1 = require("electron");
|
|
14
15
|
const path_1 = require("path");
|
|
15
16
|
/**
|
|
@@ -51,4 +52,3 @@ function createFileProtocol(scheme, sourceDirectory) {
|
|
|
51
52
|
respond({ path });
|
|
52
53
|
});
|
|
53
54
|
}
|
|
54
|
-
exports.createFileProtocol = createFileProtocol;
|
package/dist/init.js
CHANGED
|
@@ -12,7 +12,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
12
12
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.
|
|
15
|
+
exports.InitContext = void 0;
|
|
16
|
+
exports.init = init;
|
|
16
17
|
const electron_1 = require("electron");
|
|
17
18
|
const electron_log_1 = __importDefault(require("electron-log"));
|
|
18
19
|
/**
|
|
@@ -64,8 +65,8 @@ function runPluginPhase(plugins, phase, context, logger) {
|
|
|
64
65
|
* @param options - Options used to define how the application is initialized.
|
|
65
66
|
* @returns - The final state of the init context, including the created browser window for additional setup.
|
|
66
67
|
*/
|
|
67
|
-
function init(
|
|
68
|
-
return __awaiter(this,
|
|
68
|
+
function init(_a) {
|
|
69
|
+
return __awaiter(this, arguments, void 0, function* ({ appUrl, browserWindowOptions = { height: 1920, width: 1080, backgroundColor: '#000' }, plugins = [], }) {
|
|
69
70
|
process.env.ELECTRON_DISABLE_SECURITY_WARNINGS = 'true';
|
|
70
71
|
electron_1.app.on('window-all-closed', electron_1.app.quit);
|
|
71
72
|
process.on('message', (data) => {
|
|
@@ -93,4 +94,3 @@ function init({ appUrl, browserWindowOptions = { height: 1920, width: 1080, back
|
|
|
93
94
|
return context;
|
|
94
95
|
});
|
|
95
96
|
}
|
|
96
|
-
exports.init = init;
|