Skip to content

Commit

Permalink
apply code review suggestions
Browse files Browse the repository at this point in the history
- move scope switching to java status.
- move the setting to code navigation category.

Signed-off-by: Gayan Perera <[email protected]>
  • Loading branch information
gayanper committed Sep 17, 2024
1 parent 31de294 commit 0c8d064
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 45 deletions.
6 changes: 2 additions & 4 deletions src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ import { loadSupportedJreNames } from './jdkUtils';
import { BuildFileSelector, PICKED_BUILD_FILES, cleanupWorkspaceState } from './buildFilesSelector';
import { pasteFile } from './pasteAction';
import { ServerStatusKind } from './serverStatus';
import { searchScopeBarProvider } from './searchScopeStatusBarProvider';

const syntaxClient: SyntaxLanguageClient = new SyntaxLanguageClient();
const standardClient: StandardLanguageClient = new StandardLanguageClient();
Expand Down Expand Up @@ -549,13 +548,12 @@ export async function activate(context: ExtensionContext): Promise<ExtensionAPI>
context.subscriptions.push(commands.registerCommand(Commands.CHANGE_JAVA_SEARCH_SCOPE, async () => {
const selection = await window.showQuickPick(["all", "main"], {
canPickMany: false,
placeHolder: "Choose a Java Search Scope",
placeHolder: `Current: ${workspace.getConfiguration().get("java.search.scope")}`,
});
if(selection) {
workspace.getConfiguration().update("java.search.scope", selection, false).then(() => searchScopeBarProvider.update());
workspace.getConfiguration().update("java.search.scope", selection, false);
}
}));
context.subscriptions.push(searchScopeBarProvider);

context.subscriptions.push(snippetCompletionProvider.initialize());
context.subscriptions.push(serverStatusBarProvider);
Expand Down
41 changes: 0 additions & 41 deletions src/searchScopeStatusBarProvider.ts

This file was deleted.

0 comments on commit 0c8d064

Please sign in to comment.