fix(lib/vscode): register LogLevelChannel
This commit is contained in:
@@ -5,8 +5,8 @@
|
||||
|
||||
import { ProxyChannel } from 'vs/base/parts/ipc/common/ipc';
|
||||
import { ILocalizationsService } from 'vs/platform/localizations/common/localizations';
|
||||
import { ISharedProcessService } from 'vs/platform/ipc/electron-sandbox/services';
|
||||
import { registerSingleton } from 'vs/platform/instantiation/common/extensions';
|
||||
import { IRemoteAgentService } from '../../remote/common/remoteAgentService';
|
||||
|
||||
// @ts-ignore: interface is implemented via proxy
|
||||
export class LocalizationsService implements ILocalizationsService {
|
||||
@@ -14,9 +14,17 @@ export class LocalizationsService implements ILocalizationsService {
|
||||
declare readonly _serviceBrand: undefined;
|
||||
|
||||
constructor(
|
||||
@ISharedProcessService sharedProcessService: ISharedProcessService,
|
||||
@IRemoteAgentService remoteAgentService: IRemoteAgentService,
|
||||
) {
|
||||
return ProxyChannel.toService<ILocalizationsService>(sharedProcessService.getChannel('localizations'));
|
||||
/*
|
||||
NOTE@coder:
|
||||
Upstream, they use the ISharedProcessService.
|
||||
|
||||
We run this on the browser where there is no shared process so it needs to connect
|
||||
to the localization channel through the remote agent.
|
||||
3/16/21 jsjoeio code-asher
|
||||
*/
|
||||
return ProxyChannel.toService<ILocalizationsService>(remoteAgentService.getConnection()!.getChannel('localizations'));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user