'use strict' ; import * as vscode from 'vscode' ; import { window } from 'vscode' ; import ToDoDecorator from './decorators/ToDoDecorator' ; export default class ToDoController { private _disposable : vscode . Disposable ; private _toDoDecorator : ToDoDecorator ; constructor ( toDoDecorator ) { let subscriptions = [ ] ; vscode . window . onDidChangeTextEditorSelection ( this . _onEvent , this , subscriptions ) ; vscode . window . onDidChangeActiveTextEditor ( this . _onEvent , this , subscriptions ) ; this . _toDoDecorator = toDoDecorator ; } dispose ( ) { this . _disposable . dispose ( ) ; } private _onEvent ( ) { this . _toDoDecorator . decorateDocument ( ) ; } }