mirror of
https://github.com/yuruotong1/autoMate.git
synced 2026-03-22 13:07:17 +08:00
✨ ui(autoMate): import路径修复(window.ts)🐛, 创建窗口函数调用修复(index.ts)
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
import { BrowserWindow, shell } from 'electron'
|
||||
import { is } from '@electron-toolkit/utils'
|
||||
import icon from '../../../resources/icon.png?asset'
|
||||
import * as ipc from './ipc'
|
||||
import * as ipc from '../ipc'
|
||||
import { join } from 'path'
|
||||
|
||||
export function createWindow(): void { // Create the browser window.
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { app, BrowserWindow, ipcMain } from 'electron'
|
||||
import { electronApp, optimizer } from '@electron-toolkit/utils'
|
||||
import { createWindow } from './code/window'
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
@@ -21,7 +22,7 @@ app.whenReady().then(() => {
|
||||
app.on('activate', function () {
|
||||
// On macOS it's common to re-create a window in the app when the
|
||||
// dock icon is clicked and there are no other windows open.
|
||||
if (BrowserWindow.getAllWindows().length === 0) code.createWindow()
|
||||
if (BrowserWindow.getAllWindows().length === 0) createWindow()
|
||||
})
|
||||
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user