From 296ce5ce62bcde6888df291f97105fa912ed7d35 Mon Sep 17 00:00:00 2001 From: Vijay Raghavan Aravamudhan Date: Wed, 26 May 2021 21:05:50 +0530 Subject: Replace 'remote' with 'electron/remote' (#1448) * Locked new version of 'recipes' submodule with corresponding changes. --- src/stores/AppStore.js | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) (limited to 'src/stores/AppStore.js') diff --git a/src/stores/AppStore.js b/src/stores/AppStore.js index c409b6ac7..4af802460 100644 --- a/src/stores/AppStore.js +++ b/src/stores/AppStore.js @@ -1,7 +1,8 @@ -import { remote, ipcRenderer, shell } from 'electron'; +import { ipcRenderer, shell } from 'electron'; import { - action, computed, observable, -} from 'mobx'; + app, screen, powerMonitor, nativeTheme, getCurrentWindow, process as remoteProcess, +} from '@electron/remote'; +import { action, computed, observable } from 'mobx'; import moment from 'moment'; import AutoLaunch from 'auto-launch'; import ms from 'ms'; @@ -24,18 +25,11 @@ import { sleep } from '../helpers/async-helpers'; const debug = require('debug')('Ferdi:AppStore'); -const { - app, - screen, - powerMonitor, - nativeTheme, -} = remote; - -const mainWindow = remote.getCurrentWindow(); +const mainWindow = getCurrentWindow(); const defaultLocale = DEFAULT_APP_SETTINGS.locale; -const executablePath = isMac ? remote.process.execPath : process.execPath; +const executablePath = isMac ? remoteProcess.execPath : process.execPath; const autoLauncher = new AutoLaunch({ name: 'Ferdi', path: executablePath, -- cgit v1.2.3-70-g09d2