mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-26 19:44:25 +01:00
ipc events should not use TPromise
This commit is contained in:
@@ -66,7 +66,7 @@ function main(server: Server, initData: ISharedProcessInitData, configuration: I
|
||||
process.once('exit', () => dispose(disposables));
|
||||
|
||||
const environmentService = new EnvironmentService(initData.args, process.execPath);
|
||||
const logLevelClient = new LogLevelSetterChannelClient(server.getChannel('loglevel', { route: () => 'main' }));
|
||||
const logLevelClient = new LogLevelSetterChannelClient(server.getChannel('loglevel', { routeCall: () => 'main', routeEvent: () => 'main' }));
|
||||
const logService = new FollowerLogService(logLevelClient, createSpdLogService('sharedprocess', initData.logLevel, environmentService.logsPath));
|
||||
disposables.push(logService);
|
||||
|
||||
@@ -77,14 +77,18 @@ function main(server: Server, initData: ISharedProcessInitData, configuration: I
|
||||
services.set(IConfigurationService, new SyncDescriptor(ConfigurationService));
|
||||
services.set(IRequestService, new SyncDescriptor(RequestService));
|
||||
|
||||
const windowsChannel = server.getChannel('windows', { route: () => 'main' });
|
||||
const windowsChannel = server.getChannel('windows', { routeCall: () => 'main', routeEvent: () => 'main' });
|
||||
const windowsService = new WindowsChannelClient(windowsChannel);
|
||||
services.set(IWindowsService, windowsService);
|
||||
|
||||
const activeWindowManager = new ActiveWindowManager(windowsService);
|
||||
const dialogChannel = server.getChannel('dialog', {
|
||||
route: () => {
|
||||
logService.info('Routing dialog request to the client', activeWindowManager.activeClientId);
|
||||
routeCall: () => {
|
||||
logService.info('Routing dialog call request to the client', activeWindowManager.activeClientId);
|
||||
return activeWindowManager.activeClientId;
|
||||
},
|
||||
routeEvent: () => {
|
||||
logService.info('Routing dialog listen request to the client', activeWindowManager.activeClientId);
|
||||
return activeWindowManager.activeClientId;
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user