-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpreload.js
27 lines (23 loc) · 895 Bytes
/
preload.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
const path = require('path')
const url = require('url')
const customTitlebar = require('custom-electron-titlebar')
// var appVersion = require('electron').remote.app.getVersion()
window.addEventListener('DOMContentLoaded', () => {
var tb = new customTitlebar.Titlebar({
backgroundColor: customTitlebar.Color.fromHex('#242a32'),
icon: url.format(path.join(__dirname, '/icons', '/biplogo.png')),
// shadow: true,
minimizable: true,
maximizable: false,
titleHorizontalAlignment: 'left',
menu: null,
// enableMnemonics: false,
});
// document.title = 'KnightLauncher (' + appVersion + ')'
document.title = 'BiP Desktop'
tb.updateTitle()
// const replaceText = (selector, text) => {
// const element = document.getElementById(selector)
// if (element) element.innerText = text
// }
})