Skip to content

Commit ec9b5fe

Browse files
committed
Replace local database icon
1 parent 3c56c54 commit ec9b5fe

File tree

3 files changed

+3
-25
lines changed

3 files changed

+3
-25
lines changed

extensions/ql-vscode/media/drive.svg

Lines changed: 0 additions & 7 deletions
This file was deleted.

extensions/ql-vscode/src/query-history/query-history.ts

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -101,11 +101,6 @@ const SHOW_QUERY_TEXT_QUICK_EVAL_MSG = `\
101101
102102
`;
103103

104-
/**
105-
* Path to icon to display next to a successful local run.
106-
*/
107-
const LOCAL_SUCCESS_QUERY_HISTORY_ITEM_ICON = "media/drive.svg";
108-
109104
/**
110105
* Path to icon to display next to a successful remote run.
111106
*/
@@ -153,8 +148,6 @@ export class HistoryTreeDataProvider
153148

154149
private history: QueryHistoryInfo[] = [];
155150

156-
private localSuccessIconPath: string;
157-
158151
private remoteSuccessIconPath: string;
159152

160153
private current: QueryHistoryInfo | undefined;
@@ -164,10 +157,6 @@ export class HistoryTreeDataProvider
164157
private readonly labelProvider: HistoryItemLabelProvider,
165158
) {
166159
super();
167-
this.localSuccessIconPath = join(
168-
extensionPath,
169-
LOCAL_SUCCESS_QUERY_HISTORY_ITEM_ICON,
170-
);
171160
this.remoteSuccessIconPath = join(
172161
extensionPath,
173162
REMOTE_SUCCESS_QUERY_HISTORY_ITEM_ICON,
@@ -198,7 +187,7 @@ export class HistoryTreeDataProvider
198187
return new ThemeIcon("sync~spin");
199188
case QueryStatus.Completed:
200189
if (element.t === "local") {
201-
return this.localSuccessIconPath;
190+
return new ThemeIcon("database");
202191
} else {
203192
return this.remoteSuccessIconPath;
204193
}

extensions/ql-vscode/test/vscode-tests/no-workspace/query-history/query-history.test.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1683,9 +1683,7 @@ describe("query-history", () => {
16831683
});
16841684
expect(treeItem.label).toContain("query-file.ql");
16851685
expect(treeItem.contextValue).toBe("rawResultsItem");
1686-
expect(treeItem.iconPath).toEqual(
1687-
vscode.Uri.file(`${mockExtensionLocation}/media/drive.svg`).fsPath,
1688-
);
1686+
expect(treeItem.iconPath).toEqual(new vscode.ThemeIcon("database"));
16891687
});
16901688

16911689
it("should get a tree item with interpreted results", async () => {
@@ -1701,9 +1699,7 @@ describe("query-history", () => {
17011699
mockQueryWithInterpretedResults,
17021700
);
17031701
expect(treeItem.contextValue).toBe("interpretedResultsItem");
1704-
expect(treeItem.iconPath).toEqual(
1705-
vscode.Uri.file(`${mockExtensionLocation}/media/drive.svg`).fsPath,
1706-
);
1702+
expect(treeItem.iconPath).toEqual(new vscode.ThemeIcon("database"));
17071703
});
17081704

17091705
it("should get a tree item that did not complete successfully", async () => {

0 commit comments

Comments
 (0)