Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ctrl+click Definition breaks editor.action.goToLocations #212089

Open
RedCMD opened this issue May 6, 2024 · 0 comments
Open

ctrl+click Definition breaks editor.action.goToLocations #212089

RedCMD opened this issue May 6, 2024 · 0 comments
Assignees

Comments

@RedCMD
Copy link
Contributor

RedCMD commented May 6, 2024

run editor.action.goToLocations command

const document = vscode.window.activeTextEditor.document;
vscode.commands.executeCommand(
	'editor.action.goToLocations',
	document.uri,
	new vscode.Position(0, 0),
	[
		new vscode.Location(
			document.uri,
			new vscode.Range(0, 0, document.lineCount, 0),
		)
	],
	"goto",
	"fail_message",
	false,
);

notice that the cursor jumps and the selected Location briefly flashes ✅

ctrl+click on an item with a valid definition

rerun the editor.action.goToLocations command
notice how the selected Location no longer flashes 🐛
(the cursor should still jump)

defintion_breaks_goto_locations.mp4

(I've bound goToLocations to a keybind`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants