Bladeren bron

Removes collapse all from file/line history view

main
Eric Amodio 4 jaren geleden
bovenliggende
commit
808456f2bf
3 gewijzigde bestanden met toevoegingen van 12 en 3 verwijderingen
  1. +4
    -1
      src/views/fileHistoryView.ts
  2. +4
    -1
      src/views/lineHistoryView.ts
  3. +4
    -1
      src/views/viewBase.ts

+ 4
- 1
src/views/fileHistoryView.ts Bestand weergeven

@ -11,12 +11,15 @@ const pinnedSuffix = ' (pinned)';
export class FileHistoryView extends ViewBase<FileHistoryTrackerNode | LineHistoryTrackerNode, FileHistoryViewConfig> {
protected readonly configKey = 'fileHistory';
protected readonly showCollapseAll = false;
constructor() {
super('gitlens.views.fileHistory', 'File History');
}
protected get showCollapseAll(): boolean {
return false;
}
getRoot(): LineHistoryTrackerNode | FileHistoryTrackerNode {
return this._followCursor ? new LineHistoryTrackerNode(this) : new FileHistoryTrackerNode(this);
}

+ 4
- 1
src/views/lineHistoryView.ts Bestand weergeven

@ -10,12 +10,15 @@ const pinnedSuffix = ' (pinned)';
export class LineHistoryView extends ViewBase<LineHistoryTrackerNode, LineHistoryViewConfig> {
protected readonly configKey = 'lineHistory';
protected readonly showCollapseAll = false;
constructor() {
super('gitlens.views.lineHistory', 'Line History');
}
protected get showCollapseAll(): boolean {
return false;
}
getRoot() {
return new LineHistoryTrackerNode(this);
}

+ 4
- 1
src/views/viewBase.ts Bestand weergeven

@ -105,7 +105,6 @@ export abstract class ViewBase<
protected disposable: Disposable | undefined;
protected root: RootNode | undefined;
protected tree: TreeView<ViewNode> | undefined;
protected readonly showCollapseAll: boolean = true;
private readonly _lastKnownLimits = new Map<string, number | undefined>();
@ -145,6 +144,10 @@ export abstract class ViewBase<
setImmediate(() => this.onConfigurationChanged(configuration.initializingChangeEvent));
}
protected get showCollapseAll(): boolean {
return true;
}
protected filterConfigurationChanged(e: ConfigurationChangeEvent) {
if (!configuration.changed(e, 'views')) return false;

Laden…
Annuleren
Opslaan