Clean the renderer.js and the search bar now match the theme

This commit is contained in:
2026-02-13 15:29:27 +01:00
parent acfc97a078
commit a7df0b0897
7 changed files with 216 additions and 232 deletions

14
main.js
View File

@@ -29,6 +29,7 @@ let bepinexVersion
let bepinexBackupVersion
let mainWindow
let htmlFile
async function createWindow() {
mainWindow = new BrowserWindow({
@@ -40,13 +41,13 @@ async function createWindow() {
})
if(await fileExists(dataPath)) {
htmlFile = "renderer/index.html"
htmlFile = "index.html"
}
else {
htmlFile = "renderer/welcome.html"
htmlFile = "welcome.html"
}
mainWindow.loadFile(htmlFile)
mainWindow.loadFile(`renderer/${htmlFile}`)
}
app.whenReady().then(() => {
@@ -386,7 +387,12 @@ ipcMain.handle('auto-detect-game-path', async () => {
})
ipcMain.handle('load-main-page', () => {
mainWindow.loadFile("renderer/index.html")
htmlFile = "index.html"
mainWindow.loadFile(`renderer/${htmlFile}`)
})
ipcMain.handle('get-page', () => {
return htmlFile
})
ipcMain.handle('open-link', async (event, link) => {