mirror of
https://github.com/rubickCenter/rubick
synced 2025-06-19 18:42:43 +08:00
feat: electron12
This commit is contained in:
parent
3588c929bf
commit
bf6e95e370
@ -89,6 +89,7 @@
|
||||
"vuex-electron": "^1.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"babel-runtime": "^6.26.0",
|
||||
"ajv": "^6.5.0",
|
||||
"babel-core": "^6.26.3",
|
||||
"babel-loader": "^7.1.4",
|
||||
@ -104,7 +105,7 @@
|
||||
"css-loader": "^0.28.11",
|
||||
"del": "^3.0.0",
|
||||
"devtron": "^1.4.0",
|
||||
"electron": "^11.0.2",
|
||||
"electron": "^12.0.15",
|
||||
"electron-builder": "22.10.5",
|
||||
"electron-debug": "^1.5.0",
|
||||
"electron-devtools-installer": "^2.2.4",
|
||||
@ -135,7 +136,7 @@
|
||||
"iohook": {
|
||||
"targets": [
|
||||
"node-83",
|
||||
"electron-85"
|
||||
"electron-87"
|
||||
],
|
||||
"platforms": [
|
||||
"darwin"
|
||||
|
11567
pnpm-lock.yaml
generated
Normal file
11567
pnpm-lock.yaml
generated
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,9 +1,9 @@
|
||||
import { app } from 'electron'
|
||||
import '../renderer/store'
|
||||
import init from './common/common';
|
||||
import {autoUpdate} from './common/autoUpdate';
|
||||
import createTray from './tray';
|
||||
const {main} = require("./browsers")();
|
||||
import init from './common/common'
|
||||
import { autoUpdate } from './common/autoUpdate'
|
||||
import createTray from './tray'
|
||||
const { main } = require("./browsers")()
|
||||
/**
|
||||
* Set `__static` path to static files in production
|
||||
* https://simulatedgreg.gitbooks.io/electron-vue/content/en/using-static-assets.html
|
||||
@ -11,19 +11,16 @@ const {main} = require("./browsers")();
|
||||
if (process.env.NODE_ENV !== 'development') {
|
||||
global.__static = require('path').join(__dirname, '/static').replace(/\\/g, '\\\\')
|
||||
}
|
||||
// to fix https://github.com/electron/electron/issues/18397
|
||||
app.allowRendererProcessReuse = false;
|
||||
app.dock.hide();
|
||||
|
||||
function createWindow() {
|
||||
main.init();
|
||||
init(main.getWindow());
|
||||
main.init()
|
||||
init(main.getWindow())
|
||||
}
|
||||
|
||||
app.on('ready', () => {
|
||||
createWindow()
|
||||
createTray(main.getWindow());
|
||||
autoUpdate();
|
||||
createTray(main.getWindow())
|
||||
autoUpdate()
|
||||
})
|
||||
|
||||
app.on('window-all-closed', () => {
|
||||
@ -34,5 +31,5 @@ app.on('window-all-closed', () => {
|
||||
|
||||
app.on('activate', () => {
|
||||
createWindow()
|
||||
});
|
||||
})
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user