summaryrefslogtreecommitdiff
path: root/kartik/crash/wrapper.js
diff options
context:
space:
mode:
Diffstat (limited to 'kartik/crash/wrapper.js')
-rwxr-xr-xkartik/crash/wrapper.js39
1 files changed, 39 insertions, 0 deletions
diff --git a/kartik/crash/wrapper.js b/kartik/crash/wrapper.js
new file mode 100755
index 0000000..16ecfd9
--- /dev/null
+++ b/kartik/crash/wrapper.js
@@ -0,0 +1,39 @@
+const { app, BrowserWindow } = require('electron')
+
+lp = "en";
+
+function createWindow () {
+ const win = new BrowserWindow({
+ width: 800,
+ height: 375,
+ resizeable: false,
+ resizable: false,
+ maximizable: false,
+ bgColor: "#ffffff",
+ title: "Kartik",
+ webPreferences: {
+ nodeIntegration: true,
+ contextIsolation: false,
+ enableRemoteModule: true,
+ webviewTag: true
+ }
+ })
+
+ win.lp = lp;
+ win.loadFile('crash.html')
+ win.setMenu(null);
+}
+
+app.whenReady().then(createWindow)
+
+app.on('window-all-closed', () => {
+ if (process.platform !== 'darwin') {
+ app.quit()
+ }
+})
+
+app.on('activate', () => {
+ if (BrowserWindow.getAllWindows().length === 0) {
+ createWindow()
+ }
+}) \ No newline at end of file