mirror of
https://github.com/smartfrigde/armcord.git
synced 2024-08-14 23:56:58 +00:00
Move the getLang handler to main ipc module instead of storing it in settings
This commit is contained in:
parent
bdb09bb912
commit
ef73af66c4
2 changed files with 3 additions and 3 deletions
|
@ -14,6 +14,9 @@ export function registerIpc() {
|
|||
ipcMain.on("setLang", (event, lang: string) => {
|
||||
setLang(lang);
|
||||
});
|
||||
ipcMain.handle("getLang", (event, toGet: string) => {
|
||||
return getLang(toGet);
|
||||
});
|
||||
ipcMain.on("open-external-link", (event, href: string) => {
|
||||
shell.openExternal(href);
|
||||
});
|
||||
|
|
|
@ -31,9 +31,6 @@ export function createSettingsWindow() {
|
|||
ipcMain.handle("getSetting", (event, toGet: string) => {
|
||||
return getConfig(toGet);
|
||||
});
|
||||
ipcMain.handle("getLang", (event, toGet: string) => {
|
||||
return getLang(toGet);
|
||||
});
|
||||
settingsWindow.webContents.setWindowOpenHandler(({url}) => {
|
||||
shell.openExternal(url);
|
||||
return {action: "deny"};
|
||||
|
|
Loading…
Reference in a new issue