Skip to content

Commit

Permalink
Merge pull request #62796 from Microsoft/isidorn/explorerMemento
Browse files Browse the repository at this point in the history
explorer: fix memento state regression
  • Loading branch information
isidorn authored Nov 9, 2018
2 parents fc8935f + 8b6c095 commit 5e48194
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ export class ExplorerViewlet extends ViewContainerViewlet implements IExplorerVi
});

const explorerInstantiator = this.instantiationService.createChild(new ServiceCollection([IEditorService, delegatingEditorService]));
return explorerInstantiator.createInstance(ExplorerView, <IExplorerViewOptions>{ ...options, viewletState: this.fileViewletState });
return explorerInstantiator.createInstance(ExplorerView, <IExplorerViewOptions>{ ...options, fileViewletState: this.fileViewletState });
}
return super.createView(viewDescriptor, options);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import { IViewletPanelOptions } from 'vs/workbench/browser/parts/views/panelView
import { ILabelService } from 'vs/platform/label/common/label';

export interface IExplorerViewOptions extends IViewletViewOptions {
viewletState: FileViewletState;
fileViewletState: FileViewletState;
}

export class ExplorerView extends TreeViewsViewletPanel implements IExplorerView {
Expand All @@ -61,7 +61,7 @@ export class ExplorerView extends TreeViewsViewletPanel implements IExplorerView

private explorerViewer: WorkbenchTree;
private filter: FileFilter;
private viewletState: FileViewletState;
private fileViewletState: FileViewletState;

private explorerRefreshDelayer: ThrottledDelayer<void>;

Expand Down Expand Up @@ -100,7 +100,7 @@ export class ExplorerView extends TreeViewsViewletPanel implements IExplorerView
super({ ...(options as IViewletPanelOptions), ariaHeaderLabel: nls.localize('explorerSection', "Files Explorer Section") }, keybindingService, contextMenuService, configurationService);

this.viewState = options.viewletState;
this.viewletState = options.viewletState;
this.fileViewletState = options.fileViewletState;
this.autoReveal = true;

this.explorerRefreshDelayer = new ThrottledDelayer<void>(ExplorerView.EXPLORER_FILE_CHANGES_REFRESH_DELAY);
Expand Down Expand Up @@ -406,7 +406,7 @@ export class ExplorerView extends TreeViewsViewletPanel implements IExplorerView

private createViewer(container: HTMLElement): WorkbenchTree {
const dataSource = this.instantiationService.createInstance(FileDataSource);
const renderer = this.instantiationService.createInstance(FileRenderer, this.viewletState);
const renderer = this.instantiationService.createInstance(FileRenderer, this.fileViewletState);
const controller = this.instantiationService.createInstance(FileController);
this.disposables.push(controller);
const sorter = this.instantiationService.createInstance(FileSorter);
Expand Down

0 comments on commit 5e48194

Please sign in to comment.