event namespace consolidation & docs

This commit is contained in:
Joao Moreno
2018-12-11 10:14:26 +01:00
parent 392ccd9378
commit 408e03220c
109 changed files with 724 additions and 674 deletions

View File

@@ -6,7 +6,7 @@
import { localize } from 'vs/nls';
import { IDisposable, dispose } from 'vs/base/common/lifecycle';
import { IWindowsMainService } from 'vs/platform/windows/electron-main/windows';
import { fromNodeEventEmitter } from 'vs/base/common/event';
import { Event } from 'vs/base/common/event';
import { BrowserWindow, app } from 'electron';
type LoginEvent = {
@@ -32,7 +32,7 @@ export class ProxyAuthHandler {
constructor(
@IWindowsMainService private windowsMainService: IWindowsMainService
) {
const onLogin = fromNodeEventEmitter<LoginEvent>(app, 'login', (event, webContents, req, authInfo, cb) => ({ event, webContents, req, authInfo, cb }));
const onLogin = Event.fromNodeEventEmitter<LoginEvent>(app, 'login', (event, webContents, req, authInfo, cb) => ({ event, webContents, req, authInfo, cb }));
onLogin(this.onLogin, this, this.disposables);
}