@@ -98,7 +98,6 @@ export class DataPreview {
9898 private _fileName : string ;
9999 private _fileExtension : string ;
100100 private _fileSize : number ;
101- private _title : string ;
102101 private _html : string ;
103102 private _panel : WebviewPanel ;
104103 private _status : StatusBarItem ;
@@ -152,7 +151,6 @@ export class DataPreview {
152151 this . _fileName = path . basename ( uri . fsPath ) ;
153152 this . _fileExtension = this . _fileName . substr ( this . _fileName . lastIndexOf ( '.' ) ) ;
154153 this . _previewUri = this . _uri . with ( { scheme : 'data' } ) ;
155- this . _title = `${ this . _fileName } ` ;
156154
157155 // parse view config
158156 viewConfig = this . parseConfig ( viewConfig ) ;
@@ -222,7 +220,7 @@ export class DataPreview {
222220 private initWebview ( viewType : string , viewColumn : ViewColumn ) : void {
223221 if ( ! this . _panel ) {
224222 // create new webview panel
225- this . _panel = window . createWebviewPanel ( viewType , this . _title , viewColumn , this . getWebviewOptions ( ) ) ;
223+ this . _panel = window . createWebviewPanel ( viewType , this . _fileName , viewColumn , this . getWebviewOptions ( ) ) ;
226224 this . _panel . iconPath = Uri . file ( path . join ( this . _extensionPath , './images/data-preview.svg' ) ) ;
227225 }
228226 this . _logger . debug ( 'initWebview(): data.view created!' ) ;
0 commit comments