Skip to content

Commit bbb7bf3

Browse files
committed
Merge branch 'main' into alexr00/stiff-amphibian
2 parents 11e04a6 + ae33756 commit bbb7bf3

3 files changed

Lines changed: 23 additions & 3 deletions

File tree

src/commands.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1524,7 +1524,11 @@ ${contents}
15241524
ReviewManager.getReviewManagerForFolderManager(reviewsManager.reviewManagers, folderManager)?.updateComments();
15251525
}
15261526

1527-
PullRequestOverviewPanel.refresh();
1527+
PullRequestOverviewPanel.refresh(
1528+
prNode.pullRequestModel.remote.owner,
1529+
prNode.pullRequestModel.remote.repositoryName,
1530+
prNode.pullRequestModel.number,
1531+
);
15281532
}),
15291533
);
15301534

src/github/issueOverview.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,9 @@ export class IssueOverviewPanel<TItem extends IssueModel = IssueModel> extends W
8181
await panel.updateWithIdentity(folderRepositoryManager, identity, issue);
8282
}
8383

84-
public static refresh(): void {
85-
for (const panel of this._panels.values()) {
84+
public static refresh(owner: string, repo: string, number: number): void {
85+
const panel = this.findPanel(owner, repo, number);
86+
if (panel) {
8687
panel.refreshPanel();
8788
}
8889
}

src/github/pullRequestOverview.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,13 +113,28 @@ export class PullRequestOverviewPanel extends IssueOverviewPanel<PullRequestMode
113113
}
114114
}
115115

116+
public static refreshActive(): void {
117+
const panel = this.getActivePanel();
118+
if (panel) {
119+
panel.refreshPanel();
120+
}
121+
}
122+
123+
public static override refresh(owner: string, repo: string, number: number): void {
124+
const panel = this.findPanel(owner, repo, number);
125+
if (panel) {
126+
panel.refreshPanel();
127+
}
128+
}
129+
116130
/**
117131
* Scroll the webview to the pending review section.
118132
*/
119133
public scrollToPendingReview(): void {
120134
this._postMessage({ command: 'pr.scrollToPendingReview' });
121135
}
122136

137+
123138
/**
124139
* Get the currently active pull request from the active panel
125140
*/

0 commit comments

Comments
 (0)