Add about page & setting to open links with electron
This commit is contained in:
18
src/main/about.ts
Normal file
18
src/main/about.ts
Normal file
@@ -0,0 +1,18 @@
|
||||
import { BrowserWindow } from "electron";
|
||||
import { join } from "path";
|
||||
import { ICON_PATH, STATIC_DIR } from "shared/paths";
|
||||
import { makeLinksOpenExternally } from "./utils/makeLinksOpenExternally";
|
||||
|
||||
export function createAboutWindow() {
|
||||
const about = new BrowserWindow({
|
||||
center: true,
|
||||
autoHideMenuBar: true,
|
||||
icon: ICON_PATH
|
||||
});
|
||||
|
||||
makeLinksOpenExternally(about);
|
||||
|
||||
about.loadFile(join(STATIC_DIR, "about.html"));
|
||||
|
||||
return about;
|
||||
}
|
||||
Reference in New Issue
Block a user