File tree Expand file tree Collapse file tree
editor/contrib/wordHighlighter/common Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -221,13 +221,13 @@ export class SimpleWorkerClient<T> extends Disposable {
221221
222222 // Gather loader configuration
223223 let loaderConfiguration : any = null ;
224- let globalRequire = ( < any > window ) . require ;
224+ let globalRequire = ( < any > self ) . require ;
225225 if ( typeof globalRequire . getConfig === 'function' ) {
226226 // Get the configuration from the Monaco AMD Loader
227227 loaderConfiguration = globalRequire . getConfig ( ) ;
228- } else if ( typeof ( < any > window ) . requirejs !== 'undefined' ) {
228+ } else if ( typeof ( < any > self ) . requirejs !== 'undefined' ) {
229229 // Get the configuration from requirejs
230- loaderConfiguration = ( < any > window ) . requirejs . s . contexts . _ . config ;
230+ loaderConfiguration = ( < any > self ) . requirejs . s . contexts . _ . config ;
231231 }
232232
233233 this . _lazyProxy = new TPromise ( ( c , e , p ) => {
Original file line number Diff line number Diff line change @@ -100,7 +100,7 @@ class WordHighlighter {
100100
101101 // Cancel any renderDecorationsTimer
102102 if ( this . renderDecorationsTimer !== - 1 ) {
103- window . clearTimeout ( this . renderDecorationsTimer ) ;
103+ clearTimeout ( this . renderDecorationsTimer ) ;
104104 this . renderDecorationsTimer = - 1 ;
105105 }
106106
@@ -190,7 +190,7 @@ class WordHighlighter {
190190 if ( this . workerRequestCompleted && this . renderDecorationsTimer !== - 1 ) {
191191 // case b)
192192 // Delay the firing of renderDecorationsTimer by an extra 250 ms
193- window . clearTimeout ( this . renderDecorationsTimer ) ;
193+ clearTimeout ( this . renderDecorationsTimer ) ;
194194 this . renderDecorationsTimer = - 1 ;
195195 this . _beginRenderDecorations ( ) ;
196196 }
@@ -226,7 +226,7 @@ class WordHighlighter {
226226 this . renderDecorations ( ) ;
227227 } else {
228228 // Asyncrhonous
229- this . renderDecorationsTimer = window . setTimeout ( ( ) => {
229+ this . renderDecorationsTimer = setTimeout ( ( ) => {
230230 this . renderDecorations ( ) ;
231231 } , ( minimumRenderTime - currentTime ) ) ;
232232 }
You can’t perform that action at this time.
0 commit comments