/*!--------------------------------------------------------
 * Copyright (C) Microsoft Corporation. All rights reserved.
 *--------------------------------------------------------*/
(function(){var e=["exports","require","vs/base/common/winjs.base","vs/base/common/event","vs/base/common/lifecycle","vs/base/common/functional","vs/base/common/errors","vs/base/common/linkedList","vs/base/common/uuid","vs/base/common/cancellation","vs/base/common/async","vs/base/parts/ipc/node/ipc","vs/base/parts/ipc/node/ipc.net","vs/platform/instantiation/common/instantiation","path","os","net","vs/platform/driver/node/driver"],t=function(t){for(var n=[],r=0,i=t.length;r<i;r++)n[r]=e[t[r]];return n};define(e[5],t([1,0]),function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.once=function(e){var t,n=this,r=!1;return function(){return r?t:(r=!0,t=e.apply(n,arguments))}}}),define(e[4],t([1,0,5]),function(e,t,n){"use strict";function r(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return Array.isArray(e)?(e.forEach(function(e){return e&&e.dispose()}),[]):0!==t.length?(r(e),r(t),[]):e?(e.dispose(),e):void 0}Object.defineProperty(t,"__esModule",{value:!0}),
t.isDisposable=function(e){return"function"==typeof e.dispose&&0===e.dispose.length},t.dispose=r,t.combinedDisposable=function(e){return{dispose:function(){return r(e)}}},t.toDisposable=function(e){return{dispose:function(){e()}}};var i=function(){function e(){this._toDispose=[]}return Object.defineProperty(e.prototype,"toDispose",{get:function(){return this._toDispose},enumerable:!0,configurable:!0}),e.prototype.dispose=function(){this._toDispose=r(this._toDispose)},e.prototype._register=function(e){return this._toDispose.push(e),e},e.None=Object.freeze({dispose:function(){}}),e}();t.Disposable=i;var o=function(){function e(){this.references=Object.create(null)}return e.prototype.acquire=function(e){var t=this,r=this.references[e];r||(r=this.references[e]={counter:0,object:this.createReferencedObject(e)});var i=r.object,o=n.once(function(){0==--r.counter&&(t.destroyReferencedObject(r.object),delete t.references[e])});return r.counter++,{object:i,dispose:o}},e}();t.ReferenceCollection=o;var s=function(){
function e(e){this.object=e}return e.prototype.dispose=function(){},e}();t.ImmortalReference=s}),define(e[7],t([1,0]),function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){return function(e){this.element=e}}(),r=function(){function e(){}return e.prototype.isEmpty=function(){return!this._first},e.prototype.clear=function(){this._first=void 0,this._last=void 0},e.prototype.unshift=function(e){return this.insert(e,!1)},e.prototype.push=function(e){return this.insert(e,!0)},e.prototype.insert=function(e,t){var r=this,i=new n(e);if(this._first)if(t){var o=this._last;this._last=i,i.prev=o,o.next=i}else{var s=this._first;this._first=i,i.next=s,s.prev=i}else this._first=i,this._last=i;return function(){for(var e=r._first;e instanceof n;e=e.next)if(e===i){if(e.prev&&e.next){var t=e.prev;t.next=e.next,e.next.prev=t}else e.prev||e.next?e.next?e.prev||(r._first=r._first.next,r._first.prev=void 0):(r._last=r._last.prev,r._last.next=void 0):(r._first=void 0,r._last=void 0);break}}},
e.prototype.iterator=function(){var e={done:void 0,value:void 0},t=this._first;return{next:function(){return t?(e.done=!1,e.value=t.element,t=t.next):(e.done=!0,e.value=void 0),e}}},e.prototype.toArray=function(){for(var e=[],t=this._first;t instanceof n;t=t.next)e.push(t.element);return e},e}();t.LinkedList=r});var n=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();define(e[8],t([1,0]),function(e,t){"use strict";function r(){return new s}function i(e){return u.test(e)}Object.defineProperty(t,"__esModule",{value:!0});var o=function(){function e(e){this._value=e}return e.prototype.asHex=function(){return this._value},e}(),s=function(e){function t(){
return e.call(this,[t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),"-",t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),"-","4",t._randomHex(),t._randomHex(),t._randomHex(),"-",t._oneOf(t._timeHighBits),t._randomHex(),t._randomHex(),t._randomHex(),"-",t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex(),t._randomHex()].join(""))||this}return n(t,e),t._oneOf=function(e){return e[Math.floor(e.length*Math.random())]},t._randomHex=function(){return t._oneOf(t._chars)},t._chars=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],t._timeHighBits=["8","9","a","b"],t}(o);t.v4=r;var u=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;t.isUUID=i,t.parse=function(e){if(!i(e))throw new Error("invalid uuid");return new o(e)},t.generateUuid=function(){return r().asHex()}});var r;!function(){
var e=Object.create(null);e["WinJS/Core/_WinJS"]={};var t=function(t,n,r){var i={},o=!1,s=n.map(function(t){return"exports"===t?(o=!0,i):e[t]}),u=r.apply({},s);e[t]=o?i:u};t("WinJS/Core/_Global",[],function(){"use strict";return"undefined"!=typeof window?window:"undefined"!=typeof self?self:"undefined"!=typeof global?global:{}}),t("WinJS/Core/_BaseCoreUtils",["WinJS/Core/_Global"],function(e){"use strict";var t=null;return{hasWinRT:!!e.Windows,markSupportedForProcessing:function(e){return e.supportedForProcessing=!0,e},_setImmediate:function(n){null===t&&(t=e.setImmediate?e.setImmediate.bind(e):"undefined"!=typeof process&&"function"==typeof process.nextTick?process.nextTick.bind(process):e.setTimeout.bind(e)),t(n)}}}),t("WinJS/Core/_WriteProfilerMark",["WinJS/Core/_Global"],function(e){"use strict";return e.msWriteProfilerMark||function(){}}),t("WinJS/Core/_Base",["WinJS/Core/_WinJS","WinJS/Core/_Global","WinJS/Core/_BaseCoreUtils","WinJS/Core/_WriteProfilerMark"],function(e,t,n,r){"use strict"
;function i(e,t,n){var r,i,o,s=Object.keys(t),u=Array.isArray(e);for(i=0,o=s.length;i<o;i++){var c=s[i],a=95!==c.charCodeAt(0),l=t[c];!l||"object"!=typeof l||void 0===l.value&&"function"!=typeof l.get&&"function"!=typeof l.set?a?u?e.forEach(function(e){e[c]=l}):e[c]=l:(r=r||{})[c]={value:l,enumerable:a,configurable:!0,writable:!0}:(void 0===l.enumerable&&(l.enumerable=a),n&&l.setName&&"function"==typeof l.setName&&l.setName(n+"."+c),(r=r||{})[c]=l)}r&&(u?e.forEach(function(e){Object.defineProperties(e,r)}):Object.defineProperties(e,r))}return function(){function n(n,r){var i=n||{};if(r){var o=r.split(".");i===t&&"WinJS"===o[0]&&(i=e,o.splice(0,1));for(var s=0,u=o.length;s<u;s++){var c=o[s];i[c]||Object.defineProperty(i,c,{value:{},writable:!1,enumerable:!0,configurable:!0}),i=i[c]}}return i}function o(e,t,r){var o=n(e,t);return r&&i(o,r,t||"<ANONYMOUS>"),o}var s=e;s.Namespace||(s.Namespace=Object.create(Object.prototype));var u={uninitialized:1,working:2,initialized:3};Object.defineProperties(s.Namespace,{
defineWithParent:{value:o,writable:!0,enumerable:!0,configurable:!0},define:{value:function(e,n){return o(t,e,n)},writable:!0,enumerable:!0,configurable:!0},_lazy:{value:function(e){var t,n,i=u.uninitialized;return{setName:function(e){t=e},get:function(){switch(i){case u.initialized:return n;case u.uninitialized:i=u.working;try{r("WinJS.Namespace._lazy:"+t+",StartTM"),n=e()}finally{r("WinJS.Namespace._lazy:"+t+",StopTM"),i=u.uninitialized}return e=null,i=u.initialized,n;case u.working:throw"Illegal: reentrancy on initialization";default:throw"Illegal"}},set:function(e){switch(i){case u.working:throw"Illegal: reentrancy on initialization";default:i=u.initialized,n=e}},enumerable:!0,configurable:!0}},writable:!0,enumerable:!0,configurable:!0},_moduleDefine:{value:function(e,r,o){var s=[e],u=null;return r&&(u=n(t,r),s.push(u)),i(s,o,r||"<ANONYMOUS>"),u},writable:!0,enumerable:!0,configurable:!0}})}(),function(){function t(e,t,r){return e=e||function(){},n.markSupportedForProcessing(e),t&&i(e.prototype,t),
r&&i(e,r),e}e.Namespace.define("WinJS.Class",{define:t,derive:function(e,r,o,s){if(e){r=r||function(){};var u=e.prototype;return r.prototype=Object.create(u),n.markSupportedForProcessing(r),Object.defineProperty(r.prototype,"constructor",{value:r,writable:!0,configurable:!0,enumerable:!0}),o&&i(r.prototype,o),s&&i(r,s),r}return t(r,o,s)},mix:function(e){e=e||function(){};var t,n;for(t=1,n=arguments.length;t<n;t++)i(e.prototype,arguments[t]);return e}})}(),{Namespace:e.Namespace,Class:e.Class}}),t("WinJS/Core/_ErrorFromName",["WinJS/Core/_Base"],function(e){"use strict";var t=e.Class.derive(Error,function(e,t){this.name=e,this.message=t||e},{},{supportedForProcessing:!1});return e.Namespace.define("WinJS",{ErrorFromName:t}),t}),t("WinJS/Core/_Events",["exports","WinJS/Core/_Base"],function(e,t){"use strict";function n(e){var t="_on"+e+"state";return{get:function(){var e=this[t];return e&&e.userHandler},set:function(n){var r=this[t];n?(r||(r={wrapper:function(e){return r.userHandler(e)},userHandler:n},
Object.defineProperty(this,t,{value:r,enumerable:!1,writable:!0,configurable:!0}),this.addEventListener(e,r.wrapper,!1)),r.userHandler=n):r&&(this.removeEventListener(e,r.wrapper,!1),this[t]=null)},enumerable:!0}}var r=t.Class.define(function(e,t,n){this.detail=t,this.target=n,this.timeStamp=Date.now(),this.type=e},{bubbles:{value:!1,writable:!1},cancelable:{value:!1,writable:!1},currentTarget:{get:function(){return this.target}},defaultPrevented:{get:function(){return this._preventDefaultCalled}},trusted:{value:!1,writable:!1},eventPhase:{value:0,writable:!1},target:null,timeStamp:null,type:null,preventDefault:function(){this._preventDefaultCalled=!0},stopImmediatePropagation:function(){this._stopImmediatePropagationCalled=!0},stopPropagation:function(){}},{supportedForProcessing:!1}),i={_listeners:null,addEventListener:function(e,t,n){n=n||!1,this._listeners=this._listeners||{};for(var r=this._listeners[e]=this._listeners[e]||[],i=0,o=r.length;i<o;i++){var s=r[i];if(s.useCapture===n&&s.listener===t)return}
r.push({listener:t,useCapture:n})},dispatchEvent:function(e,t){var n=this._listeners&&this._listeners[e];if(n){for(var i=new r(e,t,this),o=0,s=(n=n.slice(0,n.length)).length;o<s&&!i._stopImmediatePropagationCalled;o++)n[o].listener(i);return i.defaultPrevented||!1}return!1},removeEventListener:function(e,t,n){n=n||!1;var r=this._listeners&&this._listeners[e];if(r)for(var i=0,o=r.length;i<o;i++){var s=r[i];if(s.listener===t&&s.useCapture===n){r.splice(i,1),0===r.length&&delete this._listeners[e];break}}}};t.Namespace._moduleDefine(e,"WinJS.Utilities",{_createEventProperty:n,createEventProperties:function(){for(var e={},t=0,r=arguments.length;t<r;t++){var i=arguments[t];e["on"+i]=n(i)}return e},eventMixin:i})}),t("WinJS/Core/_Trace",["WinJS/Core/_Global"],function(e){"use strict";function t(e){return e}return{_traceAsyncOperationStarting:e.Debug&&e.Debug.msTraceAsyncOperationStarting&&e.Debug.msTraceAsyncOperationStarting.bind(e.Debug)||t,
_traceAsyncOperationCompleted:e.Debug&&e.Debug.msTraceAsyncOperationCompleted&&e.Debug.msTraceAsyncOperationCompleted.bind(e.Debug)||t,_traceAsyncCallbackStarting:e.Debug&&e.Debug.msTraceAsyncCallbackStarting&&e.Debug.msTraceAsyncCallbackStarting.bind(e.Debug)||t,_traceAsyncCallbackCompleted:e.Debug&&e.Debug.msTraceAsyncCallbackCompleted&&e.Debug.msTraceAsyncCallbackCompleted.bind(e.Debug)||t}}),t("WinJS/Promise/_StateMachine",["WinJS/Core/_Global","WinJS/Core/_BaseCoreUtils","WinJS/Core/_Base","WinJS/Core/_ErrorFromName","WinJS/Core/_Events","WinJS/Core/_Trace"],function(e,t,n,r,i,o){"use strict";function s(){}function u(e,t){var n;n=t&&"object"==typeof t&&"function"==typeof t.then?L:j,e._value=t,e._setState(n)}function c(e,t,n,r,i,o){return{exception:e,error:t,promise:n,handler:o,id:r,parent:i}}function a(e,t,n,r){var i=n._isException,o=n._errorId;return c(i?t:null,i?null:t,e,o,n,r)}function l(e,t,n){var r=n._isException,i=n._errorId;return b(e,i,r),c(r?t:null,r?null:t,e,i,n)}function f(e,t){var n=++H
;return b(e,n),c(null,t,e,n)}function h(e,t){var n=++H;return b(e,n,!0),c(t,null,e,n)}function p(e,t,n,r){g(e,{c:t,e:n,p:r,asyncOpID:o._traceAsyncOperationStarting("WinJS.Promise.done")})}function d(e,t,n,r){e._value=t,_(e,t,n,r),e._setState(W)}function v(t,n){var r=t._value,i=t._listeners;if(i){t._listeners=null;var s,u;for(s=0,u=Array.isArray(i)?i.length:1;s<u;s++){var c=1===u?i:i[s],a=c.c,l=c.promise;if(o._traceAsyncOperationCompleted(c.asyncOpID,e.Debug&&e.Debug.MS_ASYNC_OP_STATUS_SUCCESS),l){o._traceAsyncCallbackStarting(c.asyncOpID);try{l._setCompleteValue(a?a(r):r)}catch(e){l._setExceptionValue(e)}finally{o._traceAsyncCallbackCompleted()}l._state!==L&&l._listeners&&n.push(l)}else V.prototype.done.call(t,a)}}}function m(t,n){var r=t._value,i=t._listeners;if(i){t._listeners=null;var s,u;for(s=0,u=Array.isArray(i)?i.length:1;s<u;s++){var c=1===u?i:i[s],l=c.e,f=c.promise,h=e.Debug&&(r&&r.name===S?e.Debug.MS_ASYNC_OP_STATUS_CANCELED:e.Debug.MS_ASYNC_OP_STATUS_ERROR)
;if(o._traceAsyncOperationCompleted(c.asyncOpID,h),f){var p=!1;try{l?(o._traceAsyncCallbackStarting(c.asyncOpID),p=!0,l.handlesOnError||_(f,r,a,t,l),f._setCompleteValue(l(r))):f._setChainedErrorValue(r,t)}catch(e){f._setExceptionValue(e)}finally{p&&o._traceAsyncCallbackCompleted()}f._state!==L&&f._listeners&&n.push(f)}else F.prototype.done.call(t,null,l)}}}function _(e,t,n,r,i){if(C._listeners[k]){if(t instanceof Error&&t.message===S)return;C.dispatchEvent(k,n(e,t,r,i))}}function y(e,t){var n=e._listeners;if(n){var r,i;for(r=0,i=Array.isArray(n)?n.length:1;r<i;r++){var o=1===i?n:n[r],s=o.p;if(s)try{s(t)}catch(e){}o.c||o.e||!o.promise||o.promise._progress(t)}}}function g(e,t){var n=e._listeners;n?(n=Array.isArray(n)?n:[n]).push(t):n=t,e._listeners=n}function b(e,t,n){e._isException=n||!1,e._errorId=t}function E(e,t,n,r){e._value=t,_(e,t,n,r),e._setState(N)}function w(e,t){var n;n=t&&"object"==typeof t&&"function"==typeof t.then?L:q,e._value=t,e._setState(n)}function P(e,t,n,r){var i=new M(e);return g(e,{
promise:i,c:t,e:n,p:r,asyncOpID:o._traceAsyncOperationStarting("WinJS.Promise.then")}),i}e.Debug&&(e.Debug.setNonUserCodeExceptions=!0);var C=new(n.Class.mix(n.Class.define(null,{},{supportedForProcessing:!1}),i.eventMixin));C._listeners={};var k="error",S="Canceled",T=!1,D={promise:1,thenPromise:2,errorPromise:4,exceptionPromise:8,completePromise:16};D.all=D.promise|D.thenPromise|D.errorPromise|D.exceptionPromise|D.completePromise;var O,x,L,I,A,R,j,q,W,N,H=1;O={name:"created",enter:function(e){e._setState(x)},cancel:s,done:s,then:s,_completed:s,_error:s,_notify:s,_progress:s,_setCompleteValue:s,_setErrorValue:s},x={name:"working",enter:s,cancel:function(e){e._setState(A)},done:p,then:P,_completed:u,_error:d,_notify:s,_progress:y,_setCompleteValue:w,_setErrorValue:E},L={name:"waiting",enter:function(e){var t=e._value;if(t instanceof M&&t._state!==N&&t._state!==q)g(t,{promise:e});else{var n=function(r){t._errorId?e._chainedError(r,t):(_(e,r,a,t,n),e._error(r))};n.handlesOnError=!0,
t.then(e._completed.bind(e),n,e._progress.bind(e))}},cancel:function(e){e._setState(I)},done:p,then:P,_completed:u,_error:d,_notify:s,_progress:y,_setCompleteValue:w,_setErrorValue:E},I={name:"waiting_canceled",enter:function(e){e._setState(R);var t=e._value;t.cancel&&t.cancel()},cancel:s,done:p,then:P,_completed:u,_error:d,_notify:s,_progress:y,_setCompleteValue:w,_setErrorValue:E},A={name:"canceled",enter:function(e){e._setState(R),e._cancelAction()},cancel:s,done:p,then:P,_completed:u,_error:d,_notify:s,_progress:y,_setCompleteValue:w,_setErrorValue:E},R={name:"canceling",enter:function(e){var t=new Error(S);t.name=t.message,e._value=t,e._setState(W)},cancel:s,done:s,then:s,_completed:s,_error:s,_notify:s,_progress:s,_setCompleteValue:s,_setErrorValue:s},j={name:"complete_notify",enter:function(e){if(e.done=V.prototype.done,e.then=V.prototype.then,e._listeners)for(var t,n=[e];n.length;)(t=n.shift())._state._notify(t,n);e._setState(q)},cancel:s,done:null,then:null,_completed:s,_error:s,_notify:v,
_progress:s,_setCompleteValue:s,_setErrorValue:s},q={name:"success",enter:function(e){e.done=V.prototype.done,e.then=V.prototype.then,e._cleanupAction()},cancel:s,done:null,then:null,_completed:s,_error:s,_notify:v,_progress:s,_setCompleteValue:s,_setErrorValue:s},W={name:"error_notify",enter:function(e){if(e.done=F.prototype.done,e.then=F.prototype.then,e._listeners)for(var t,n=[e];n.length;)(t=n.shift())._state._notify(t,n);e._setState(N)},cancel:s,done:null,then:null,_completed:s,_error:s,_notify:m,_progress:s,_setCompleteValue:s,_setErrorValue:s},N={name:"error",enter:function(e){e.done=F.prototype.done,e.then=F.prototype.then,e._cleanupAction()},cancel:s,done:null,then:null,_completed:s,_error:s,_notify:m,_progress:s,_setCompleteValue:s,_setErrorValue:s};var B,J=n.Class.define(null,{_listeners:null,_nextState:null,_state:null,_value:null,cancel:function(){this._state.cancel(this),this._run()},done:function(e,t,n){this._state.done(this,e,t,n)},then:function e(t,n,r){
if(this.then===e)return this._state.then(this,t,n,r);this.then(t,n,r)},_chainedError:function(e,t){var n=this._state._error(this,e,l,t);return this._run(),n},_completed:function(e){var t=this._state._completed(this,e);return this._run(),t},_error:function(e){var t=this._state._error(this,e,f);return this._run(),t},_progress:function(e){this._state._progress(this,e)},_setState:function(e){this._nextState=e},_setCompleteValue:function(e){this._state._setCompleteValue(this,e),this._run()},_setChainedErrorValue:function(e,t){var n=this._state._setErrorValue(this,e,l,t);return this._run(),n},_setExceptionValue:function(e){var t=this._state._setErrorValue(this,e,h);return this._run(),t},_run:function(){for(;this._nextState;)this._state=this._nextState,this._nextState=null,this._state.enter(this)}},{supportedForProcessing:!1}),M=n.Class.derive(J,function(e){T&&(!0===T||T&D.thenPromise)&&(this._stack=z._getStack()),this._creator=e,this._setState(O),this._run()},{_creator:null,_cancelAction:function(){
this._creator&&this._creator.cancel()},_cleanupAction:function(){this._creator=null}},{supportedForProcessing:!1}),F=n.Class.define(function(e){T&&(!0===T||T&D.errorPromise)&&(this._stack=z._getStack()),this._value=e,_(this,e,f)},{cancel:function(){},done:function(e,t){var n=this._value;if(t)try{t.handlesOnError||_(null,n,a,this,t);var r=t(n);return void(r&&"object"==typeof r&&"function"==typeof r.done&&r.done())}catch(e){n=e}n instanceof Error&&n.message===S||z._doneHandler(n)},then:function(e,t){if(!t)return this;var n,r=this._value;try{t.handlesOnError||_(null,r,a,this,t),n=new V(t(r))}catch(e){n=e===r?this:new U(e)}return n}},{supportedForProcessing:!1}),U=n.Class.derive(F,function(e){T&&(!0===T||T&D.exceptionPromise)&&(this._stack=z._getStack()),this._value=e,_(this,e,h)},{},{supportedForProcessing:!1}),V=n.Class.define(function(e){if(T&&(!0===T||T&D.completePromise)&&(this._stack=z._getStack()),e&&"object"==typeof e&&"function"==typeof e.then){var t=new M(null);return t._setCompleteValue(e),t}
this._value=e},{cancel:function(){},done:function(e){if(e)try{var t=e(this._value);t&&"object"==typeof t&&"function"==typeof t.done&&t.done()}catch(e){z._doneHandler(e)}},then:function(e){try{var t=e?e(this._value):this._value;return t===this._value?this:new V(t)}catch(e){return new U(e)}}},{supportedForProcessing:!1}),z=n.Class.derive(J,function(e,t){T&&(!0===T||T&D.promise)&&(this._stack=z._getStack()),this._oncancel=t,this._setState(O),this._run();try{e(this._completed.bind(this),this._error.bind(this),this._progress.bind(this))}catch(e){this._setExceptionValue(e)}},{_oncancel:null,_cancelAction:function(){try{if(!this._oncancel)throw new Error("Promise did not implement oncancel");this._oncancel()}catch(e){e.message,e.stack;C.dispatchEvent("error",e)}},_cleanupAction:function(){this._oncancel=null}},{addEventListener:function(e,t,n){C.addEventListener(e,t,n)},any:function(e){return new z(function(t,n){var r=Object.keys(e);0===r.length&&t();var i=0;r.forEach(function(o){z.as(e[o]).then(function(){t({key:o,
value:e[o]})},function(s){s instanceof Error&&s.name===S?++i===r.length&&t(z.cancel):n({key:o,value:e[o]})})})},function(){Object.keys(e).forEach(function(t){var n=z.as(e[t]);"function"==typeof n.cancel&&n.cancel()})})},as:function(e){return e&&"object"==typeof e&&"function"==typeof e.then?e:new V(e)},cancel:{get:function(){return B=B||new F(new r(S))}},dispatchEvent:function(e,t){return C.dispatchEvent(e,t)},is:function(e){return e&&"object"==typeof e&&"function"==typeof e.then},join:function(e){return new z(function(t,n,r){var i=Object.keys(e),o=Array.isArray(e)?[]:{},s=Array.isArray(e)?[]:{},u=0,c=i.length,a=function(e){if(0==--c){var u=Object.keys(o).length;if(0===u)t(s);else{var a=0;i.forEach(function(e){var t=o[e];t instanceof Error&&t.name===S&&a++}),a===u?t(z.cancel):n(o)}}else r({Key:e,Done:!0})};i.forEach(function(t){var n=e[t];void 0===n?u++:z.then(n,function(e){s[t]=e,a(t)},function(e){o[t]=e,a(t)})}),0!==(c-=u)||t(s)},function(){Object.keys(e).forEach(function(t){var n=z.as(e[t])
;"function"==typeof n.cancel&&n.cancel()})})},removeEventListener:function(e,t,n){C.removeEventListener(e,t,n)},supportedForProcessing:!1,then:function(e,t,n,r){return z.as(e).then(t,n,r)},thenEach:function(e,t,n,r){var i=Array.isArray(e)?[]:{};return Object.keys(e).forEach(function(o){i[o]=z.as(e[o]).then(t,n,r)}),z.join(i)},timeout:function(n,r){var i=function(n){var r;return new z(function(i){n?r=e.setTimeout(i,n):t._setImmediate(i)},function(){r&&e.clearTimeout(r)})}(n);return r?function(e,t){var n=function(){e.cancel()};return e.then(function(){t.cancel()}),t.then(n,n),t}(i,r):i},wrap:function(e){return new V(e)},wrapError:function(e){return new F(e)},_veryExpensiveTagWithStack:{get:function(){return T},set:function(e){T=e}},_veryExpensiveTagWithStack_tag:D,_getStack:function(){if(e.Debug&&e.Debug.debuggerEnabled)try{throw new Error}catch(e){return e.stack}},_cancelBlocker:function(e,t){if(!z.is(e))return z.wrap(e);var n,r,i=new z(function(e,t){n=e,r=t},function(){n=null,r=null,t&&t()})
;return e.then(function(e){n&&n(e)},function(e){r&&r(e)}),i}});return Object.defineProperties(z,i.createEventProperties(k)),z._doneHandler=function(e){t._setImmediate(function(){throw e})},{PromiseStateMachine:J,Promise:z,state_created:O}}),t("WinJS/Promise",["WinJS/Core/_Base","WinJS/Promise/_StateMachine"],function(e,t){"use strict";return e.Namespace.define("WinJS",{Promise:t.Promise}),t.Promise}),(r=e["WinJS/Core/_WinJS"]).TPromise=r.Promise,r.PPromise=r.Promise,"undefined"==typeof exports&&"function"==typeof define&&define.amd?define("vs/base/common/winjs.base",[],r):module.exports=r}(),define(e[6],t([1,0,2]),function(e,t,n){"use strict";function r(e){i(e)||t.errorHandler.onUnexpectedError(e)}function i(e){return e instanceof Error&&e.name===u&&e.message===u}Object.defineProperty(t,"__esModule",{value:!0});var o={};n.TPromise.addEventListener("error",function(e){var t=e.detail,n=t.id;t.parent?t.handler&&o&&delete o[n]:(o[n]=t,1===Object.keys(o).length&&setTimeout(function(){var e=o;o={},
Object.keys(e).forEach(function(t){var n=e[t];n.exception?r(n.exception):n.error&&r(n.error),console.log("WARNING: Promise with no error callback:"+n.id),console.log(n),n.exception&&console.log(n.exception.stack)})},0))});var s=function(){function e(){this.listeners=[],this.unexpectedErrorHandler=function(e){setTimeout(function(){if(e.stack)throw new Error(e.message+"\n\n"+e.stack);throw e},0)}}return e.prototype.addListener=function(e){var t=this;return this.listeners.push(e),function(){t._removeListener(e)}},e.prototype.emit=function(e){this.listeners.forEach(function(t){t(e)})},e.prototype._removeListener=function(e){this.listeners.splice(this.listeners.indexOf(e),1)},e.prototype.setUnexpectedErrorHandler=function(e){this.unexpectedErrorHandler=e},e.prototype.getUnexpectedErrorHandler=function(){return this.unexpectedErrorHandler},e.prototype.onUnexpectedError=function(e){this.unexpectedErrorHandler(e),this.emit(e)},e.prototype.onUnexpectedExternalError=function(e){this.unexpectedErrorHandler(e)},e}()
;t.ErrorHandler=s,t.errorHandler=new s,t.setUnexpectedErrorHandler=function(e){t.errorHandler.setUnexpectedErrorHandler(e)},t.onUnexpectedError=r,t.onUnexpectedExternalError=function(e){i(e)||t.errorHandler.onUnexpectedExternalError(e)},t.transformErrorForSerialization=function(e){if(e instanceof Error)return{$isError:!0,name:e.name,message:e.message,stack:e.stacktrace||e.stack};return e};var u="Canceled";t.isPromiseCanceledError=i,t.canceled=function(){var e=new Error(u);return e.name=e.message,e},t.illegalArgument=function(e){return e?new Error("Illegal argument: "+e):new Error("Illegal argument")},t.illegalState=function(e){return e?new Error("Illegal state: "+e):new Error("Illegal state")},t.readonly=function(e){return e?new Error("readonly property '"+e+" cannot be changed'"):new Error("readonly property cannot be changed")},t.disposed=function(e){var t=new Error(e+" has been disposed");return t.name="DISPOSED",t},t.isErrorWithActions=function(e){return e instanceof Error&&Array.isArray(e.actions)},
t.create=function(e,t){void 0===t&&(t=Object.create(null));var n=new Error(e);return t.actions&&(n.actions=t.actions),n},t.getErrorMessage=function(e){return e?e.message?e.message:e.stack?e.stack.split("\n")[0]:String(e):"Error"}});var i=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))(function(i,o){function s(e){try{c(r.next(e))}catch(e){o(e)}}function u(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){e.done?i(e.value):new n(function(t){t(e.value)}).then(s,u)}c((r=r.apply(e,t||[])).next())})},o=this&&this.__generator||function(e,t){function n(n){return function(s){return function(n){if(r)throw new TypeError("Generator is already executing.");for(;u;)try{if(r=1,i&&(o=2&n[0]?i.return:n[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,n[1])).done)return o;switch(i=0,o&&(n=[2&n[0],o.value]),n[0]){case 0:case 1:o=n;break;case 4:return u.label++,{value:n[1],done:!1};case 5:u.label++,i=n[1],n=[0];continue;case 7:n=u.ops.pop(),u.trys.pop();continue;default:if(o=u.trys,
!(o=o.length>0&&o[o.length-1])&&(6===n[0]||2===n[0])){u=0;continue}if(3===n[0]&&(!o||n[1]>o[0]&&n[1]<o[3])){u.label=n[1];break}if(6===n[0]&&u.label<o[1]){u.label=o[1],o=n;break}if(o&&u.label<o[2]){u.label=o[2],u.ops.push(n);break}o[2]&&u.ops.pop(),u.trys.pop();continue}n=t.call(e,u)}catch(e){n=[6,e],i=0}finally{r=o=0}if(5&n[0])throw n[1];return{value:n[0]?n[1]:void 0,done:!0}}([n,s])}}var r,i,o,s,u={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return s={next:n(0),throw:n(1),return:n(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s};define(e[3],t([1,0,6,5,4,7,2]),function(e,t,r,s,u,c,a){"use strict";function l(e){return function(t,n,r){void 0===n&&(n=null);var i=e(function(e){return i.dispose(),t.call(n,e)},null,r);return i}}function f(e,t){return function(n,r,i){return void 0===r&&(r=null),e(function(e){return n.call(r,t(e))},null,i)}}function h(e,t){return function(n,r,i){return void 0===r&&(r=null),e(function(e){t(e),n.call(r,e)},null,i)}}
function p(e,t){return function(n,r,i){return void 0===r&&(r=null),e(function(e){return t(e)&&n.call(r,e)},null,i)}}function d(e){var t,n=!0;return p(e,function(e){var r=n||e!==t;return n=!1,t=e,r})}Object.defineProperty(t,"__esModule",{value:!0});!function(e){var t={dispose:function(){}};e.None=function(){return t}}(t.Event||(t.Event={}));var v=function(){function e(e){this._options=e}return Object.defineProperty(e.prototype,"event",{get:function(){var t=this;return this._event||(this._event=function(n,r,i){t._listeners||(t._listeners=new c.LinkedList);var o=t._listeners.isEmpty();o&&t._options&&t._options.onFirstListenerAdd&&t._options.onFirstListenerAdd(t);var s=t._listeners.push(r?[n,r]:n);o&&t._options&&t._options.onFirstListenerDidAdd&&t._options.onFirstListenerDidAdd(t),t._options&&t._options.onListenerDidAdd&&t._options.onListenerDidAdd(t,n,r);var u;return u={dispose:function(){u.dispose=e._noop,t._disposed||(s(),
t._options&&t._options.onLastListenerRemove&&t._listeners.isEmpty()&&t._options.onLastListenerRemove(t))}},Array.isArray(i)&&i.push(u),u}),this._event},enumerable:!0,configurable:!0}),e.prototype.fire=function(e){if(this._listeners){this._deliveryQueue||(this._deliveryQueue=[]);for(var t=this._listeners.iterator(),n=t.next();!n.done;n=t.next())this._deliveryQueue.push([n.value,e]);for(;this._deliveryQueue.length>0;){var i=this._deliveryQueue.shift(),o=i[0],s=i[1];try{"function"==typeof o?o.call(void 0,s):o[0].call(o[1],s)}catch(n){r.onUnexpectedError(n)}}}},e.prototype.dispose=function(){this._listeners&&(this._listeners=void 0),this._deliveryQueue&&(this._deliveryQueue.length=0),this._disposed=!0},e._noop=function(){},e}();t.Emitter=v;var m=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n(t,e),t.prototype.fireAsync=function(e){return i(this,void 0,void 0,function(){var t,n,i,s,u,c;return o(this,function(o){switch(o.label){case 0:if(!this._listeners)return[2]
;for(this._asyncDeliveryQueue||(this._asyncDeliveryQueue=[]),t=this._listeners.iterator(),n=t.next();!n.done;n=t.next())c=[],this._asyncDeliveryQueue.push([n.value,e(c,"function"==typeof n.value?n.value:n.value[0]),c]);o.label=1;case 1:if(!(this._asyncDeliveryQueue.length>0))return[3,3];i=this._asyncDeliveryQueue.shift(),s=i[0],u=i[1],c=i[2];try{"function"==typeof s?s.call(void 0,u):s[0].call(s[1],u)}catch(e){return r.onUnexpectedError(e),[3,1]}return Object.freeze(c),[4,Promise.all(c)];case 2:return o.sent(),[3,1];case 3:return[2]}})})},t}(v);t.AsyncEmitter=m;var _=function(){function e(){var e=this;this.hasListeners=!1,this.events=[],this.emitter=new v({onFirstListenerAdd:function(){return e.onFirstListenerAdd()},onLastListenerRemove:function(){return e.onLastListenerRemove()}})}return Object.defineProperty(e.prototype,"event",{get:function(){return this.emitter.event},enumerable:!0,configurable:!0}),e.prototype.add=function(e){var t=this,n={event:e,listener:null};this.events.push(n),
this.hasListeners&&this.hook(n);return u.toDisposable(s.once(function(){t.hasListeners&&t.unhook(n);var e=t.events.indexOf(n);t.events.splice(e,1)}))},e.prototype.onFirstListenerAdd=function(){var e=this;this.hasListeners=!0,this.events.forEach(function(t){return e.hook(t)})},e.prototype.onLastListenerRemove=function(){var e=this;this.hasListeners=!1,this.events.forEach(function(t){return e.unhook(t)})},e.prototype.hook=function(e){var t=this;e.listener=e.event(function(e){return t.emitter.fire(e)})},e.prototype.unhook=function(e){e.listener.dispose(),e.listener=null},e.prototype.dispose=function(){this.emitter.dispose()},e}();t.EventMultiplexer=_,t.fromCallback=function(e){var t,n=new v({onFirstListenerAdd:function(){return t=e(function(e){return n.fire(e)})},onLastListenerRemove:function(){return t.dispose()}});return n.event},t.fromPromise=function(e){var t=new v,n=!1;return e.then(null,function(){return null}).then(function(){n?t.fire():setTimeout(function(){return t.fire()},0)}),n=!0,t.event},
t.toPromise=function(e){return new a.TPromise(function(t){var n=e(function(e){n.dispose(),t(e)})})},t.once=l,t.anyEvent=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t,n,r){return void 0===n&&(n=null),u.combinedDisposable(e.map(function(e){return e(function(e){return t.call(n,e)},null,r)}))}},t.debounceEvent=function(e,t,n,r){void 0===n&&(n=100),void 0===r&&(r=!1);var i,o=void 0,s=void 0,u=0,c=new v({onFirstListenerAdd:function(){i=e(function(e){u++,o=t(o,e),r&&!s&&c.fire(o),clearTimeout(s),s=setTimeout(function(){var e=o;o=void 0,s=void 0,(!r||u>1)&&c.fire(e),u=0},n)})},onLastListenerRemove:function(){i.dispose()}});return c.event};var y=function(){function e(){this.buffers=[]}return e.prototype.wrapEvent=function(e){var t=this;return function(n,r,i){return e(function(e){var i=t.buffers[t.buffers.length-1];i?i.push(function(){return n.call(r,e)}):n.call(r,e)},void 0,i)}},e.prototype.bufferEvents=function(e){var t=[];this.buffers.push(t),e(),this.buffers.pop(),
t.forEach(function(e){return e()})},e}();t.EventBufferer=y,t.mapEvent=f,t.forEach=h,t.filterEvent=p;var g=function(){function e(e){this._event=e}return Object.defineProperty(e.prototype,"event",{get:function(){return this._event},enumerable:!0,configurable:!0}),e.prototype.map=function(t){return new e(f(this._event,t))},e.prototype.forEach=function(t){return new e(h(this._event,t))},e.prototype.filter=function(t){return new e(p(this._event,t))},e.prototype.latch=function(){return new e(d(this._event))},e.prototype.on=function(e,t,n){return this._event(e,t,n)},e.prototype.once=function(e,t,n){return l(this._event)(e,t,n)},e}();t.chain=function(e){return new g(e)},t.stopwatch=function(e){var t=(new Date).getTime();return f(l(e),function(e){return(new Date).getTime()-t})},t.buffer=function(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=[]),n=n.slice();var r=e(function(e){n?n.push(e):o.fire(e)}),i=function(){n.forEach(function(e){return o.fire(e)}),n=null},o=new v({onFirstListenerAdd:function(){r||(r=e(function(e){
return o.fire(e)}))},onFirstListenerDidAdd:function(){n&&(t?setTimeout(i):i())},onLastListenerRemove:function(){r.dispose(),r=null}});return o.event},t.echo=function(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=[]),n=n.slice(),e(function(e){n.push(e),i.fire(e)});var r=function(e,t){return n.forEach(function(n){return e.call(t,n)})},i=new v({onListenerDidAdd:function(e,n,i){t?setTimeout(function(){return r(n,i)}):r(n,i)}});return i.event};var b=function(){function e(){this.emitter=new v,this.event=this.emitter.event,this.disposable=u.Disposable.None}return Object.defineProperty(e.prototype,"input",{set:function(e){this.disposable.dispose(),this.disposable=e(this.emitter.fire,this.emitter)},enumerable:!0,configurable:!0}),e.prototype.dispose=function(){this.disposable.dispose(),this.emitter.dispose()},e}();t.Relay=b,t.fromNodeEventEmitter=function(e,t,n){void 0===n&&(n=function(e){return e});var r=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return i.fire(n.apply(void 0,e))},i=new v({
onFirstListenerAdd:function(){return e.on(t,r)},onLastListenerRemove:function(){return e.removeListener(t,r)}});return i.event},t.latch=d}),define(e[9],t([1,0,3]),function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=Object.freeze(function(e,t){var n=setTimeout(e.bind(t),0);return{dispose:function(){clearTimeout(n)}}});!function(e){e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:n.Event.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:i})}(r=t.CancellationToken||(t.CancellationToken={}));var o=function(){function e(){this._isCancelled=!1}return e.prototype.cancel=function(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))},Object.defineProperty(e.prototype,"isCancellationRequested",{get:function(){return this._isCancelled},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"onCancellationRequested",{get:function(){
return this._isCancelled?i:(this._emitter||(this._emitter=new n.Emitter),this._emitter.event)},enumerable:!0,configurable:!0}),e.prototype.dispose=function(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)},e}(),s=function(){function e(){}return Object.defineProperty(e.prototype,"token",{get:function(){return this._token||(this._token=new o),this._token},enumerable:!0,configurable:!0}),e.prototype.cancel=function(){this._token?this._token instanceof o&&this._token.cancel():this._token=r.Cancelled},e.prototype.dispose=function(){this._token?this._token instanceof o&&this._token.dispose():this._token=r.None},e}();t.CancellationTokenSource=s}),define(e[10],t([1,0,6,2,9,4,3]),function(e,t,r,i,o,s,u){"use strict";function c(e){return e&&"function"==typeof e.then}function a(e){var t=new o.CancellationTokenSource,n=e(t.token),i=new Promise(function(e,i){t.token.onCancellationRequested(function(){i(r.canceled())}),Promise.resolve(n).then(function(n){t.dispose(),e(n)},function(e){t.dispose(),i(e)})})
;return new(function(){function e(){}return e.prototype.cancel=function(){t.cancel()},e.prototype.then=function(e,t){return i.then(e,t)},e.prototype.catch=function(e){return this.then(void 0,e)},e}())}function l(e){return c(e)&&"function"==typeof e.done}function f(e,t){return l(e)?new i.TPromise(function(n,i){e.done(function(e){try{t(e)}catch(e){r.onUnexpectedError(e)}n(e)},function(e){try{t(e)}catch(e){r.onUnexpectedError(e)}i(e)})},function(){e.cancel()}):(e.then(function(e){return t()},function(e){return t()}),e)}function h(e){function t(s){void 0!==s&&null!==s&&n.push(s);var u=r<o?e[r++]():null;return u?u.then(t):i.TPromise.as(n)}var n=[],r=0,o=e.length;return i.TPromise.as(null).then(t)}Object.defineProperty(t,"__esModule",{value:!0}),t.isThenable=c,t.toThenable=function(e){return c(e)?e:i.TPromise.as(e)},t.toWinJsPromise=function(e){return e instanceof i.TPromise?e:new i.TPromise(function(t,n){return e.then(t,n)})},t.createCancelablePromise=a,t.asWinJsPromise=function(e){
var t=new o.CancellationTokenSource;return new i.TPromise(function(n,r){var o=e(t.token);o instanceof i.TPromise?o.then(function(e){t.dispose(),n(e)},function(e){t.dispose(),r(e)}):c(o)?o.then(function(e){t.dispose(),n(e)},function(e){t.dispose(),r(e)}):(t.dispose(),n(o))},function(){t.cancel()})},t.wireCancellationToken=function(e,t,n){var o=e.onCancellationRequested(function(){return t.cancel()});return n&&(t=t.then(void 0,function(e){if(!r.isPromiseCanceledError(e))return i.TPromise.wrapError(e)})),f(t,function(){return o.dispose()})},t.asDisposablePromise=function(e,t,n){var o,s={promise:new i.TPromise(function(n,i){o=function(){n(t),l(e)&&e.cancel()},e.then(n,function(e){r.isPromiseCanceledError(e)?n(t):i(e)})}),dispose:o};return Array.isArray(n)&&n.push(s),s};var p=function(){function e(){this.activePromise=null,this.queuedPromise=null,this.queuedPromiseFactory=null}return e.prototype.queue=function(e){var t=this;if(this.activePromise){if(this.queuedPromiseFactory=e,!this.queuedPromise){
var n=function(){t.queuedPromise=null;var e=t.queue(t.queuedPromiseFactory);return t.queuedPromiseFactory=null,e};this.queuedPromise=new i.TPromise(function(e){t.activePromise.then(n,n).done(e)},function(){t.activePromise.cancel()})}return new i.TPromise(function(e,n){t.queuedPromise.then(e,n)},function(){})}return this.activePromise=e(),new i.TPromise(function(e,n){t.activePromise.done(function(n){t.activePromise=null,e(n)},function(e){t.activePromise=null,n(e)})},function(){t.activePromise.cancel()})},e}();t.Throttler=p;var d=function(){function e(){this.current=i.TPromise.wrap(null)}return e.prototype.queue=function(e){return this.current=this.current.then(function(){return e()})},e}();t.SimpleThrottler=d;var v=function(){function e(e){this.defaultDelay=e,this.timeout=null,this.completionPromise=null,this.onSuccess=null,this.task=null}return e.prototype.trigger=function(e,t){var n=this;return void 0===t&&(t=this.defaultDelay),this.task=e,this.cancelTimeout(),
this.completionPromise||(this.completionPromise=new i.TPromise(function(e){n.onSuccess=e},function(){}).then(function(){n.completionPromise=null,n.onSuccess=null;var e=n.task;return n.task=null,e()})),this.timeout=setTimeout(function(){n.timeout=null,n.onSuccess(null)},t),this.completionPromise},e.prototype.isTriggered=function(){return null!==this.timeout},e.prototype.cancel=function(){this.cancelTimeout(),this.completionPromise&&(this.completionPromise.cancel(),this.completionPromise=null)},e.prototype.cancelTimeout=function(){null!==this.timeout&&(clearTimeout(this.timeout),this.timeout=null)},e}();t.Delayer=v;var m=function(e){function t(t){var n=e.call(this,t)||this;return n.throttler=new p,n}return n(t,e),t.prototype.trigger=function(t,n){var r=this;return e.prototype.trigger.call(this,function(){return r.throttler.queue(t)},n)},t}(v);t.ThrottledDelayer=m;var _=function(){function e(){var e=this;this._isOpen=!1,this._promise=new i.TPromise(function(t,n){e._completePromise=t},function(){
console.warn("You should really not try to cancel this ready promise!")})}return e.prototype.isOpen=function(){return this._isOpen},e.prototype.open=function(){this._isOpen=!0,this._completePromise(!0)},e.prototype.wait=function(){return this._promise},e}();t.Barrier=_;var y=function(e){function t(t){var n,i,o=this;return o=e.call(this,function(e,t){n=e,i=t},function(){i(r.canceled())})||this,t.then(n,i),o}return n(t,e),t}(i.TPromise);t.ShallowCancelThenPromise=y,t.timeout=function(e){return a(function(t){return new Promise(function(n,i){var o=setTimeout(n,e);t.onCancellationRequested(function(e){clearTimeout(o),i(r.canceled())})})})},t.isWinJSPromise=l,t.always=f,t.sequence=h,t.first2=function(e,t,n){void 0===t&&(t=function(e){return!!e}),void 0===n&&(n=null);var r=0,i=e.length,o=function(){return r>=i?Promise.resolve(n):(0,e[r++])().then(function(e){return t(e)?Promise.resolve(e):o()})};return o()},t.first=function(e,t,n){void 0===t&&(t=function(e){return!!e}),void 0===n&&(n=null)
;var r=0,o=e.length,s=function(){return r>=o?i.TPromise.as(n):(0,e[r++])().then(function(e){return t(e)?i.TPromise.as(e):s()})};return s()};var g=function(){function e(e){this.maxDegreeOfParalellism=e,this.outstandingPromises=[],this.runningPromises=0,this._onFinished=new u.Emitter}return Object.defineProperty(e.prototype,"onFinished",{get:function(){return this._onFinished.event},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"size",{get:function(){return this.runningPromises+this.outstandingPromises.length},enumerable:!0,configurable:!0}),e.prototype.queue=function(e){var t=this;return new i.TPromise(function(n,r){t.outstandingPromises.push({factory:e,c:n,e:r}),t.consume()})},e.prototype.consume=function(){for(var e=this;this.outstandingPromises.length&&this.runningPromises<this.maxDegreeOfParalellism;){var t=this.outstandingPromises.shift();this.runningPromises++;var n=t.factory();n.done(t.c,t.e),n.done(function(){return e.consumed()},function(){return e.consumed()})}},
e.prototype.consumed=function(){this.runningPromises--,this.outstandingPromises.length>0?this.consume():this._onFinished.fire()},e.prototype.dispose=function(){this._onFinished.dispose()},e}();t.Limiter=g;var b=function(e){function t(){return e.call(this,1)||this}return n(t,e),t}(g);t.Queue=b;var E=function(){function e(){this.queues=Object.create(null)}return e.prototype.queueFor=function(e){var t=this,n=e.toString();if(!this.queues[n]){var r=new b;r.onFinished(function(){r.dispose(),delete t.queues[n]}),this.queues[n]=r}return this.queues[n]},e}();t.ResourceQueue=E,t.setDisposableTimeout=function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i=setTimeout.apply(void 0,[e,t].concat(n));return{dispose:function(){clearTimeout(i)}}};var w=function(e){function t(){var t=e.call(this)||this;return t._token=-1,t}return n(t,e),t.prototype.dispose=function(){this.cancel(),e.prototype.dispose.call(this)},t.prototype.cancel=function(){-1!==this._token&&(clearTimeout(this._token),this._token=-1)},
t.prototype.cancelAndSet=function(e,t){var n=this;this.cancel(),this._token=setTimeout(function(){n._token=-1,e()},t)},t.prototype.setIfNotSet=function(e,t){var n=this;-1===this._token&&(this._token=setTimeout(function(){n._token=-1,e()},t))},t}(s.Disposable);t.TimeoutTimer=w;var P=function(e){function t(){var t=e.call(this)||this;return t._token=-1,t}return n(t,e),t.prototype.dispose=function(){this.cancel(),e.prototype.dispose.call(this)},t.prototype.cancel=function(){-1!==this._token&&(clearInterval(this._token),this._token=-1)},t.prototype.cancelAndSet=function(e,t){this.cancel(),this._token=setInterval(function(){e()},t)},t}(s.Disposable);t.IntervalTimer=P;var C=function(){function e(e,t){this.timeoutToken=-1,this.runner=e,this.timeout=t,this.timeoutHandler=this.onTimeout.bind(this)}return e.prototype.dispose=function(){this.cancel(),this.runner=null},e.prototype.cancel=function(){this.isScheduled()&&(clearTimeout(this.timeoutToken),this.timeoutToken=-1)},e.prototype.schedule=function(e){
void 0===e&&(e=this.timeout),this.cancel(),this.timeoutToken=setTimeout(this.timeoutHandler,e)},e.prototype.isScheduled=function(){return-1!==this.timeoutToken},e.prototype.onTimeout=function(){this.timeoutToken=-1,this.runner&&this.doRun()},e.prototype.doRun=function(){this.runner()},e}();t.RunOnceScheduler=C;var k=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.units=[],r}return n(t,e),t.prototype.work=function(e){this.units.push(e),this.isScheduled()||this.schedule()},t.prototype.doRun=function(){var e=this.units;this.units=[],this.runner(e)},t.prototype.dispose=function(){this.units=[],e.prototype.dispose.call(this)},t}(C);t.RunOnceWorker=k,t.nfcall=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return new i.TPromise(function(n,r){return e.apply(void 0,t.concat([function(e,t){return e?r(e):n(t)}]))},function(){return null})},t.ninvoke=function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return new i.TPromise(function(r,i){
return t.call.apply(t,[e].concat(n,[function(e,t){return e?i(e):r(t)}]))},function(){return null})}}),define(e[11],t([1,0,2,4,3]),function(e,t,n,r,i){"use strict";function o(e,t){void 0===t&&(t=void 0);var n=Buffer.allocUnsafe(4),r=function(e){return void 0===e?{buffer:h,type:f.Undefined}:"string"==typeof e?{buffer:Buffer.from(e),type:f.String}:Buffer.isBuffer(e)?{buffer:e,type:f.Buffer}:{buffer:Buffer.from(JSON.stringify(e)),type:f.Object}}(t),i=r.buffer,o=r.type,s=Buffer.from(JSON.stringify([e,o]));return n.writeUInt32BE(s.byteLength,0),Buffer.concat([n,s,i])}function s(e){var t=e.readUInt32BE(0),n=e.slice(4,4+t),r=e.slice(4+t),i=JSON.parse(n.toString());return{header:i[0],body:function(e,t){switch(t){case f.Undefined:return;case f.String:return e.toString();case f.Buffer:return e;case f.Object:return JSON.parse(e.toString())}}(r,i[1])}}function u(e){return{call:function(t,n){return e.then(function(e){return e.call(t,n)})},listen:function(t,n){var r=new i.Relay;return e.then(function(e){
return r.input=e.listen(t,n)}),r.event}}}Object.defineProperty(t,"__esModule",{value:!0});var c;!function(e){e[e.Promise=100]="Promise",e[e.PromiseCancel=101]="PromiseCancel",e[e.EventListen=102]="EventListen",e[e.EventDispose=103]="EventDispose"}(c=t.RequestType||(t.RequestType={}));var a;!function(e){e[e.Initialize=200]="Initialize",e[e.PromiseSuccess=201]="PromiseSuccess",e[e.PromiseError=202]="PromiseError",e[e.PromiseErrorObj=203]="PromiseErrorObj",e[e.EventFire=204]="EventFire"}(a=t.ResponseType||(t.ResponseType={}));var l;!function(e){e[e.Uninitialized=0]="Uninitialized",e[e.Idle=1]="Idle"}(l||(l={}));var f;!function(e){e[e.Undefined=0]="Undefined",e[e.String=1]="String",e[e.Buffer=2]="Buffer",e[e.Object=3]="Object"}(f||(f={}));var h=Buffer.allocUnsafe(0),p=function(){function e(e){var t=this;this.protocol=e,this.channels=Object.create(null),this.activeRequests=Object.create(null),this.protocolListener=this.protocol.onMessage(function(e){return t.onRawMessage(e)}),this.sendResponse({type:a.Initialize})
}return e.prototype.registerChannel=function(e,t){this.channels[e]=t},e.prototype.onPromise=function(e){var t,i=this,o=this.channels[e.channelName];try{t=o.call(e.name,e.arg)}catch(e){t=n.TPromise.wrapError(e)}var s=e.id,u=t.then(function(t){i.sendResponse({id:s,data:t,type:a.PromiseSuccess}),delete i.activeRequests[e.id]},function(t){t instanceof Error?i.sendResponse({id:s,data:{message:t.message,name:t.name,stack:t.stack?t.stack.split?t.stack.split("\n"):t.stack:void 0},type:a.PromiseError}):i.sendResponse({id:s,data:t,type:a.PromiseErrorObj}),delete i.activeRequests[e.id]});this.activeRequests[e.id]=r.toDisposable(function(){return u.cancel()})},e.prototype.onEventListen=function(e){var t=this,n=this.channels[e.channelName],r=e.id,i=n.listen(e.name,e.arg)(function(e){return t.sendResponse({id:r,data:e,type:a.EventFire})});this.activeRequests[e.id]=i},e.prototype.disposeActiveRequest=function(e){var t=this.activeRequests[e.id];t&&(t.dispose(),delete this.activeRequests[e.id])},
e.prototype.onRawMessage=function(e){var t,n=s(e),r=n.header,i=n.body;switch(r[0]){case c.Promise:case c.EventListen:t={type:r[0],id:r[1],channelName:r[2],name:r[3],arg:i};break;case c.PromiseCancel:case c.EventDispose:t={type:r[0],id:r[1]};break;default:return}this.onRequest(t)},e.prototype.onRequest=function(e){switch(e.type){case c.Promise:this.onPromise(e);break;case c.EventListen:this.onEventListen(e);break;case c.PromiseCancel:case c.EventDispose:this.disposeActiveRequest(e)}},e.prototype.sendResponse=function(e){var t;switch(e.type){case a.Initialize:t=o([e.type]);break;case a.PromiseSuccess:case a.PromiseError:case a.EventFire:case a.PromiseErrorObj:t=o([e.type,e.id],e.data)}this.sendRawMessage(t)},e.prototype.sendRawMessage=function(e){try{this.protocol.send(e)}catch(e){}},e.prototype.dispose=function(){var e=this;this.protocolListener.dispose(),this.protocolListener=null,Object.keys(this.activeRequests).forEach(function(t){e.activeRequests[t].dispose()}),this.activeRequests=null},e}()
;t.ChannelServer=p;var d=function(){function e(e){var t=this;this.protocol=e,this.state=l.Uninitialized,this.activeRequests=[],this.bufferedRequests=[],this.handlers=Object.create(null),this.lastRequestId=0,this._onDidInitialize=new i.Emitter,this.onDidInitialize=this._onDidInitialize.event,this.protocolListener=this.protocol.onMessage(function(e){return t.onRawMessage(e)})}return e.prototype.getChannel=function(e){var t=this;return{call:function(n,r){return t.requestPromise(e,n,r)},listen:function(n,r){return t.requestEvent(e,n,r)}}},e.prototype.requestPromise=function(e,t,n){var i=this,o={raw:{id:this.lastRequestId++,type:c.Promise,channelName:e,name:t,arg:n}},s=this.state===l.Uninitialized?this.bufferRequest(o):this.doRequest(o),u=r.toDisposable(function(){return s.cancel()});return this.activeRequests.push(u),s.then(null,function(e){return null}).done(function(){return i.activeRequests=i.activeRequests.filter(function(e){return e!==u})}),s},e.prototype.requestEvent=function(e,t,n){
var r=this,o=this.lastRequestId++,s={raw:{id:o,type:c.EventListen,channelName:e,name:t,arg:n}},u=null,a=new i.Emitter({onFirstListenerAdd:function(){(u=r.whenInitialized()).then(function(){u=null,r.sendRequest(s.raw)})},onLastListenerRemove:function(){u?(u.cancel(),u=null):r.sendRequest({id:o,type:c.EventDispose})}});return this.handlers[o]=function(e){return a.fire(e.data)},a.event},e.prototype.doRequest=function(e){var t=this,r=e.raw.id;return new n.TPromise(function(n,i){t.handlers[r]=function(e){switch(e.type){case a.PromiseSuccess:delete t.handlers[r],n(e.data);break;case a.PromiseError:delete t.handlers[r];var o=new Error(e.data.message);o.stack=e.data.stack,o.name=e.data.name,i(o);break;case a.PromiseErrorObj:delete t.handlers[r],i(e.data)}},t.sendRequest(e.raw)},function(){return t.sendRequest({id:r,type:c.PromiseCancel})})},e.prototype.bufferRequest=function(e){var t=this,r=null;return new n.TPromise(function(n,i){t.bufferedRequests.push(e),e.flush=function(){e.flush=null,r=t.doRequest(e).then(n,i)}
},function(){if(e.flush=null,t.state===l.Uninitialized){var n=t.bufferedRequests.indexOf(e);-1!==n&&t.bufferedRequests.splice(n,1)}else r&&(r.cancel(),r=null)})},e.prototype.onRawMessage=function(e){var t,n=s(e),r=n.header,i=n.body;switch(r[0]){case a.Initialize:t={type:r[0]};break;case a.PromiseSuccess:case a.PromiseError:case a.EventFire:case a.PromiseErrorObj:t={type:r[0],id:r[1],data:i};break;default:return}this.onResponse(t)},e.prototype.onResponse=function(e){if(e.type===a.Initialize)return this.state=l.Idle,this._onDidInitialize.fire(),this.bufferedRequests.forEach(function(e){return e.flush&&e.flush()}),void(this.bufferedRequests=null);var t=this.handlers[e.id];t&&t(e)},e.prototype.sendRequest=function(e){var t;switch(e.type){case c.Promise:case c.EventListen:t=o([e.type,e.id,e.channelName,e.name],e.arg);break;case c.PromiseCancel:case c.EventDispose:t=o([e.type,e.id])}this.sendRawMessage(t)},e.prototype.sendRawMessage=function(e){try{this.protocol.send(e)}catch(e){}},
e.prototype.whenInitialized=function(){return this.state===l.Idle?n.TPromise.as(null):n.TPromise.wrap(i.toPromise(this.onDidInitialize))},e.prototype.dispose=function(){this.protocolListener.dispose(),this.protocolListener=null,this.activeRequests=r.dispose(this.activeRequests)},e}();t.ChannelClient=d;var v=function(){function e(e){var t=this;this.channels=Object.create(null),this.channelClients=Object.create(null),this.onClientAdded=new i.Emitter,e(function(e){var n=e.protocol,r=e.onDidClientDisconnect;i.once(n.onMessage)(function(e){var i=new p(n),o=new d(n);Object.keys(t.channels).forEach(function(e){return i.registerChannel(e,t.channels[e])});var s=e.toString();t.channelClients[s]=o,t.onClientAdded.fire(s),r(function(){i.dispose(),o.dispose(),delete t.channelClients[s]})})})}return e.prototype.getChannel=function(e,t){var n=this;return{call:function(r,i){return u(t.routeCall(r,i).then(function(e){return n.getClient(e)}).then(function(t){return t.getChannel(e)})).call(r,i)},listen:function(r,i){
return u(t.routeEvent(r,i).then(function(e){return n.getClient(e)}).then(function(t){return t.getChannel(e)})).listen(r,i)}}},e.prototype.registerChannel=function(e,t){this.channels[e]=t},e.prototype.getClient=function(e){var t=this;if(!e)return n.TPromise.wrapError(new Error("Client id should be provided"));var r=this.channelClients[e];return r?n.TPromise.as(r):new n.TPromise(function(n){i.once(i.filterEvent(t.onClientAdded.event,function(t){return t===e}))(function(){return n(t.channelClients[e])})})},e.prototype.dispose=function(){this.channels=Object.create(null),this.channelClients=Object.create(null),this.onClientAdded.dispose()},e}();t.IPCServer=v;var m=function(){function e(e,t){e.send(Buffer.from(t)),this.channelClient=new d(e),this.channelServer=new p(e)}return e.prototype.getChannel=function(e){return this.channelClient.getChannel(e)},e.prototype.registerChannel=function(e,t){this.channelServer.registerChannel(e,t)},e.prototype.dispose=function(){this.channelClient.dispose(),
this.channelClient=null,this.channelServer.dispose(),this.channelServer=null},e}();t.IPCClient=m,t.getDelayedChannel=u,t.getNextTickChannel=function(e){var t=!1;return{call:function(r,i){return t?e.call(r,i):n.TPromise.timeout(0).then(function(){return t=!0}).then(function(){return e.call(r,i)})},listen:function(r,o){if(t)return e.listen(r,o);var s=new i.Relay;return n.TPromise.timeout(0).then(function(){return t=!0}).then(function(){return s.input=e.listen(r,o)}),s.event}}}}),define(e[12],t([1,0,16,2,3,11,14,15,8,10]),function(e,t,r,i,o,s,u,c,a,l){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.generateRandomPipeName=function(){var e=a.generateUuid();return"win32"===process.platform?"\\\\.\\pipe\\vscode-ipc-"+e+"-sock":u.join(c.tmpdir(),"vscode-ipc-"+e+".sock")};var f=function(){function e(t,n){var r=this;this._socket=t,this._onMessage=new o.Emitter,this.onMessage=this._onMessage.event,this._onClose=new o.Emitter,this.onClose=this._onClose.event,this._writeBuffer=new(function(){function e(){
this._data=[],this._totalLength=0}return e.prototype.add=function(e,t){var n=0===this._totalLength;return this._data.push(e,t),this._totalLength+=e.length+t.length,n},e.prototype.take=function(){var e=Buffer.concat(this._data,this._totalLength);return this._data.length=0,this._totalLength=0,e},e}()),this._isDisposed=!1,this._chunks=[];var i=0,s={readHead:!0,bodyLen:-1},u=function(t){for(r._chunks.push(t),i+=t.length;i>0;){if(s.readHead){if(!(i>=e._headerLen))break;n=Buffer.concat(r._chunks);s.bodyLen=n.readUInt32BE(0),s.readHead=!1;u=n.slice(e._headerLen);i=u.length,r._chunks=[u]}if(!s.readHead){if(!(i>=s.bodyLen))break;var n,o=(n=Buffer.concat(r._chunks)).slice(0,s.bodyLen),u=n.slice(s.bodyLen);if(i=u.length,r._chunks=[u],s.bodyLen=-1,s.readHead=!0,r._onMessage.fire(o),r._isDisposed)break}}},c=function(){if(n&&n.length>0){var e=n;n=null,u(e)}};this._firstChunkTimer=new l.TimeoutTimer,this._firstChunkTimer.setIfNotSet(function(){c()},0),this._socketDataListener=function(e){c(),u(e)},
t.on("data",this._socketDataListener),this._socketEndListener=function(){c()},t.on("end",this._socketEndListener),this._socketCloseListener=function(){r._onClose.fire()},t.once("close",this._socketCloseListener)}return e.prototype.dispose=function(){this._isDisposed=!0,this._firstChunkTimer.dispose(),this._socket.removeListener("data",this._socketDataListener),this._socket.removeListener("end",this._socketEndListener),this._socket.removeListener("close",this._socketCloseListener)},e.prototype.end=function(){this._socket.end()},e.prototype.getBuffer=function(){return Buffer.concat(this._chunks)},e.prototype.send=function(t){var n=Buffer.allocUnsafe(e._headerLen);n.writeUInt32BE(t.length,0,!0),this._writeSoon(n,t)},e.prototype._writeSoon=function(e,t){var n=this;this._writeBuffer.add(e,t)&&setImmediate(function(){n._socket.destroyed||n._socket.write(n._writeBuffer.take())})},e._headerLen=4,e}();t.Protocol=f;var h=function(e){function t(n){var r=e.call(this,t.toClientConnectionEvent(n))||this;return r.server=n,r
}return n(t,e),t.toClientConnectionEvent=function(e){var t=o.fromNodeEventEmitter(e,"connection");return o.mapEvent(t,function(e){return{protocol:new f(e),onDidClientDisconnect:o.once(o.fromNodeEventEmitter(e,"close"))}})},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.server.close(),this.server=null},t}(s.IPCServer);t.Server=h;var p=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.protocol=t,r}return n(t,e),t.fromSocket=function(e,n){return new t(new f(e),n)},Object.defineProperty(t.prototype,"onClose",{get:function(){return this.protocol.onClose},enumerable:!0,configurable:!0}),t.prototype.dispose=function(){e.prototype.dispose.call(this),this.protocol.end()},t}(s.IPCClient);t.Client=p,t.serve=function(e){return new i.TPromise(function(t,n){var i=r.createServer();i.on("error",n),i.listen(e,function(){i.removeListener("error",n),t(new h(i))})})},t.connect=function(e,t){return new i.TPromise(function(n,i){var o=r.createConnection(e,function(){o.removeListener("error",i),
n(p.fromSocket(o,t))});o.once("error",i)})}}),define(e[13],t([1,0]),function(e,t){"use strict";function n(e,t,n,r){t[i.DI_TARGET]===t?t[i.DI_DEPENDENCIES].push({id:e,index:n,optional:r}):(t[i.DI_DEPENDENCIES]=[{id:e,index:n,optional:r}],t[i.DI_TARGET]=t)}function r(e){if(i.serviceIds.has(e))return i.serviceIds.get(e);var t=function(e,r,i){if(3!==arguments.length)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");n(t,e,i,!1)};return t.toString=function(){return e},i.serviceIds.set(e,t),t}Object.defineProperty(t,"__esModule",{value:!0});var i;!function(e){e.serviceIds=new Map,e.DI_TARGET="$di$target",e.DI_DEPENDENCIES="$di$dependencies",e.getServiceDependencies=function(t){return t[e.DI_DEPENDENCIES]||[]}}(i=t._util||(t._util={})),t.IInstantiationService=r("instantiationService"),t.createDecorator=r,t.optional=function(e){return function(t,r,i){if(3!==arguments.length)throw new Error("@optional-decorator can only be used to decorate a parameter");n(e,t,i,!0)}}}),
define(e[17],t([1,0,12,13]),function(e,t,n,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ID="driverService",t.IDriver=r.createDecorator(t.ID);var s=function(){function e(e){this.driver=e}return e.prototype.listen=function(e){throw new Error("No event found")},e.prototype.call=function(e,t){switch(e){case"getWindowIds":return this.driver.getWindowIds();case"capturePage":return this.driver.capturePage(t);case"reloadWindow":return this.driver.reloadWindow(t);case"dispatchKeybinding":return this.driver.dispatchKeybinding(t[0],t[1]);case"click":return this.driver.click(t[0],t[1],t[2],t[3]);case"doubleClick":return this.driver.doubleClick(t[0],t[1]);case"setValue":return this.driver.setValue(t[0],t[1],t[2]);case"getTitle":return this.driver.getTitle(t[0]);case"isActiveElement":return this.driver.isActiveElement(t[0],t[1]);case"getElements":return this.driver.getElements(t[0],t[1],t[2]);case"typeInEditor":return this.driver.typeInEditor(t[0],t[1],t[2]);case"getTerminalBuffer":
return this.driver.getTerminalBuffer(t[0],t[1]);case"writeInTerminal":return this.driver.writeInTerminal(t[0],t[1],t[2])}},e}();t.DriverChannel=s;var u=function(){function e(e){this.channel=e}return e.prototype.getWindowIds=function(){return this.channel.call("getWindowIds")},e.prototype.capturePage=function(e){return this.channel.call("capturePage",e)},e.prototype.reloadWindow=function(e){return this.channel.call("reloadWindow",e)},e.prototype.dispatchKeybinding=function(e,t){return this.channel.call("dispatchKeybinding",[e,t])},e.prototype.click=function(e,t,n,r){return this.channel.call("click",[e,t,n,r])},e.prototype.doubleClick=function(e,t){return this.channel.call("doubleClick",[e,t])},e.prototype.setValue=function(e,t,n){return this.channel.call("setValue",[e,t,n])},e.prototype.getTitle=function(e){return this.channel.call("getTitle",[e])},e.prototype.isActiveElement=function(e,t){return this.channel.call("isActiveElement",[e,t])},e.prototype.getElements=function(e,t,n){
return this.channel.call("getElements",[e,t,n])},e.prototype.typeInEditor=function(e,t,n){return this.channel.call("typeInEditor",[e,t,n])},e.prototype.getTerminalBuffer=function(e,t){return this.channel.call("getTerminalBuffer",[e,t])},e.prototype.writeInTerminal=function(e,t,n){return this.channel.call("writeInTerminal",[e,t,n])},e}();t.DriverChannelClient=u;var c=function(){function e(e){this.registry=e}return e.prototype.listen=function(e){throw new Error("No event found")},e.prototype.call=function(e,t){switch(e){case"registerWindowDriver":return this.registry.registerWindowDriver(t);case"reloadWindowDriver":return this.registry.reloadWindowDriver(t)}},e}();t.WindowDriverRegistryChannel=c;var a=function(){function e(e){this.channel=e}return e.prototype.registerWindowDriver=function(e){return this.channel.call("registerWindowDriver",e)},e.prototype.reloadWindowDriver=function(e){return this.channel.call("reloadWindowDriver",e)},e}();t.WindowDriverRegistryChannelClient=a;var l=function(){function e(e){
this.driver=e}return e.prototype.listen=function(e){throw new Error("No event found")},e.prototype.call=function(e,t){switch(e){case"click":return this.driver.click(t[0],t[1],t[2]);case"doubleClick":return this.driver.doubleClick(t);case"setValue":return this.driver.setValue(t[0],t[1]);case"getTitle":return this.driver.getTitle();case"isActiveElement":return this.driver.isActiveElement(t);case"getElements":return this.driver.getElements(t[0],t[1]);case"typeInEditor":return this.driver.typeInEditor(t[0],t[1]);case"getTerminalBuffer":return this.driver.getTerminalBuffer(t);case"writeInTerminal":return this.driver.writeInTerminal(t[0],t[1])}},e}();t.WindowDriverChannel=l;var f=function(){function e(e){this.channel=e}return e.prototype.click=function(e,t,n){return this.channel.call("click",[e,t,n])},e.prototype.doubleClick=function(e){return this.channel.call("doubleClick",e)},e.prototype.setValue=function(e,t){return this.channel.call("setValue",[e,t])},e.prototype.getTitle=function(){
return this.channel.call("getTitle")},e.prototype.isActiveElement=function(e){return this.channel.call("isActiveElement",e)},e.prototype.getElements=function(e,t){return this.channel.call("getElements",[e,t])},e.prototype.typeInEditor=function(e,t){return this.channel.call("typeInEditor",[e,t])},e.prototype.getTerminalBuffer=function(e){return this.channel.call("getTerminalBuffer",e)},e.prototype.writeInTerminal=function(e,t){return this.channel.call("writeInTerminal",[e,t])},e}();t.WindowDriverChannelClient=f,t.connect=function(e){return i(this,void 0,void 0,function(){var t,r,i;return o(this,function(o){switch(o.label){case 0:return[4,n.connect(e,"driverClient")];case 1:return t=o.sent(),r=t.getChannel("driver"),i=new u(r),[2,{client:t,driver:i}]}})})}})}).call(this);
//# sourceMappingURL=https://ticino.blob.core.windows.net/sourcemaps/5944e81f3c46a3938a82c701f96d7a59b074cfdc/core/vs/platform/driver/node/driver.js.map
