import * as vscode from 'vscode' ; import { AppPackageDocument } from './appPackageDocument' ; import { ALSymbolsBrowser } from '../alsymbolsbrowser/alSymbolsBrowser' ; import { DevToolsExtensionContext } from '../devToolsExtensionContext' ; import { ALAppSymbolsLibrary } from '../symbollibraries/alAppSymbolsLibrary' ; export class AppPackageEditorProvider implements vscode . CustomReadonlyEditorProvider { protected _devToolsContext : DevToolsExtensionContext ; constructor ( devToolsContext ) { this . _devToolsContext = devToolsContext ; } openCustomDocument ( uri , openContext , token ) { return new AppPackageDocument ( uri ) ; } resolveCustomEditor ( document , webviewPanel , token ) { let library = new ALAppSymbolsLibrary ( this . _devToolsContext , document . uri . fsPath ) ; let symbolsBrowser = new ALSymbolsBrowser ( this . _devToolsContext , library ) ; symbolsBrowser . attachToWebView ( webviewPanel ) ; } }