Skip to content

Commit 6fab27b

Browse files
committed
Refactors view registration & access
1 parent 216d220 commit 6fab27b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+592
-569
lines changed

src/commands/compareWith.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,9 @@ export class CompareWithCommand extends ActiveEditorCommand {
7272
if (!repoPath) return;
7373

7474
if (args.ref1 != null && args.ref2 != null) {
75-
await this.container.searchAndCompareView.compare(repoPath, args.ref1, args.ref2);
75+
await this.container.views.searchAndCompare.compare(repoPath, args.ref1, args.ref2);
7676
} else {
77-
this.container.searchAndCompareView.selectForCompare(repoPath, args.ref1, { prompt: true });
77+
this.container.views.searchAndCompare.selectForCompare(repoPath, args.ref1, { prompt: true });
7878
}
7979
} catch (ex) {
8080
Logger.error(ex, 'CompareWithCommmand');

src/commands/git/branch.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ export class BranchGitCommand extends QuickCommand {
223223

224224
protected async *steps(state: PartialStepState<State>): StepGenerator {
225225
const context: Context = {
226-
associatedView: this.container.branchesView,
226+
associatedView: this.container.views.branches,
227227
repos: this.container.git.openRepositories,
228228
showTags: false,
229229
title: this.title,

src/commands/git/cherry-pick.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ export class CherryPickGitCommand extends QuickCommand<State> {
9191
protected async *steps(state: PartialStepState<State>): StepGenerator {
9292
const context: Context = {
9393
repos: this.container.git.openRepositories,
94-
associatedView: this.container.commitsView,
94+
associatedView: this.container.views.commits,
9595
cache: new Map<string, Promise<GitLog | undefined>>(),
9696
destination: undefined!,
9797
selectedBranchOrTag: undefined,

src/commands/git/coauthors.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ export class CoAuthorsGitCommand extends QuickCommand<State> {
9292
const context: Context = {
9393
repos: this.container.git.openRepositories,
9494
activeRepo: undefined,
95-
associatedView: this.container.contributorsView,
95+
associatedView: this.container.views.contributors,
9696
title: this.title,
9797
};
9898

src/commands/git/fetch.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export class FetchGitCommand extends QuickCommand<State> {
7272
protected async *steps(state: PartialStepState<State>): StepGenerator {
7373
const context: Context = {
7474
repos: this.container.git.openRepositories,
75-
associatedView: this.container.commitsView,
75+
associatedView: this.container.views.commits,
7676
title: this.title,
7777
};
7878

src/commands/git/log.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ export class LogGitCommand extends QuickCommand<State> {
8686
protected async *steps(state: PartialStepState<State>): StepGenerator {
8787
const context: Context = {
8888
repos: this.container.git.openRepositories,
89-
associatedView: this.container.commitsView,
89+
associatedView: this.container.views.commits,
9090
cache: new Map<string, Promise<GitLog | undefined>>(),
9191
selectedBranchOrTag: undefined,
9292
title: this.title,

src/commands/git/merge.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ export class MergeGitCommand extends QuickCommand<State> {
8383
protected async *steps(state: PartialStepState<State>): StepGenerator {
8484
const context: Context = {
8585
repos: this.container.git.openRepositories,
86-
associatedView: this.container.commitsView,
86+
associatedView: this.container.views.commits,
8787
cache: new Map<string, Promise<GitLog | undefined>>(),
8888
destination: undefined!,
8989
pickCommit: false,

src/commands/git/pull.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ export class PullGitCommand extends QuickCommand<State> {
8080
protected async *steps(state: PartialStepState<State>): StepGenerator {
8181
const context: Context = {
8282
repos: this.container.git.openRepositories,
83-
associatedView: this.container.commitsView,
83+
associatedView: this.container.views.commits,
8484
title: this.title,
8585
};
8686

src/commands/git/push.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ export class PushGitCommand extends QuickCommand<State> {
8484
protected async *steps(state: PartialStepState<State>): StepGenerator {
8585
const context: Context = {
8686
repos: this.container.git.openRepositories,
87-
associatedView: this.container.commitsView,
87+
associatedView: this.container.views.commits,
8888
title: this.title,
8989
};
9090

src/commands/git/rebase.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ export class RebaseGitCommand extends QuickCommand<State> {
9393
protected async *steps(state: PartialStepState<State>): StepGenerator {
9494
const context: Context = {
9595
repos: this.container.git.openRepositories,
96-
associatedView: this.container.commitsView,
96+
associatedView: this.container.views.commits,
9797
cache: new Map<string, Promise<GitLog | undefined>>(),
9898
destination: undefined!,
9999
pickCommit: false,

0 commit comments

Comments
 (0)