mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-26 18:27:38 +01:00
shared process - 💄
This commit is contained in:
@@ -188,12 +188,12 @@ class SharedProcessMain extends Disposable {
|
||||
services.set(IDownloadService, new SyncDescriptor(DownloadService));
|
||||
|
||||
// Extension recommendations
|
||||
const activeWindowManager = new ActiveWindowManager(nativeHostService);
|
||||
const activeWindowManager = this._register(new ActiveWindowManager(nativeHostService));
|
||||
const activeWindowRouter = new StaticRouter(ctx => activeWindowManager.getActiveClientId().then(id => ctx === id));
|
||||
services.set(IExtensionRecommendationNotificationService, new ExtensionRecommendationNotificationServiceChannelClient(this.server.getChannel('extensionRecommendationNotification', activeWindowRouter)));
|
||||
|
||||
// Logger
|
||||
const loggerService = new LoggerService(logService, fileService);
|
||||
const loggerService = this._register(new LoggerService(logService, fileService));
|
||||
services.set(ILoggerService, loggerService);
|
||||
|
||||
// Telemetry
|
||||
|
||||
@@ -44,6 +44,8 @@ export class SharedProcess extends Disposable implements ISharedProcess {
|
||||
|
||||
// Shared process connections
|
||||
ipcMain.on('vscode:createSharedProcessMessageChannel', async (e, nonce: string) => {
|
||||
this.logService.trace('SharedProcess: on vscode:createSharedProcessMessageChannel');
|
||||
|
||||
const port = await this.connect();
|
||||
|
||||
e.sender.postMessage('vscode:createSharedProcessMessageChannelResult', nonce, [port]);
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
'vs/nls!vs/workbench/workbench.desktop.main',
|
||||
'vs/css!vs/workbench/workbench.desktop.main'
|
||||
],
|
||||
function (workbench, configuration) {
|
||||
function (_, configuration) {
|
||||
|
||||
// Mark start of workbench
|
||||
performance.mark('code/didLoadWorkbenchMain');
|
||||
|
||||
@@ -7,7 +7,7 @@ import { IChannel, IServerChannel, StaticRouter } from 'vs/base/parts/ipc/common
|
||||
import { Client as IPCElectronClient } from 'vs/base/parts/ipc/electron-sandbox/ipc.electron';
|
||||
import { Disposable } from 'vs/base/common/lifecycle';
|
||||
import { createDecorator } from 'vs/platform/instantiation/common/instantiation';
|
||||
import { Server } from 'vs/base/parts/ipc/electron-sandbox/ipc.mp';
|
||||
import { Server as MessagePortServer } from 'vs/base/parts/ipc/electron-sandbox/ipc.mp';
|
||||
|
||||
export const IMainProcessService = createDecorator<IMainProcessService>('mainProcessService');
|
||||
|
||||
@@ -54,7 +54,7 @@ export class MessagePortMainProcessService implements IMainProcessService {
|
||||
declare readonly _serviceBrand: undefined;
|
||||
|
||||
constructor(
|
||||
private server: Server,
|
||||
private server: MessagePortServer,
|
||||
private router: StaticRouter
|
||||
) { }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user