-
Notifications
You must be signed in to change notification settings - Fork 28.2k
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
Handle Alt+Click for terminal links. Fixes #30761 #31263
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Just a few minor comments 😃
|
||
this._xterm.setHypertextLinkHandler(this._wrapLinkHandler(uri => { | ||
this._handleHypertextLink(uri); | ||
return; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's remove this return
, plus the one in registerLocalLinkHandler
. Not sure why I put them there 😅
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
okay
anonymous function with void return, explicit return is redundant/unnecessary
@@ -164,6 +170,12 @@ export class TerminalLinkHandler { | |||
callback(true); | |||
} | |||
|
|||
private _handleHypertextLink(url: string) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add : void
return type
private _handleHypertextLink(url: string) { | ||
let uri = Uri.parse(url); | ||
this._openerService.open(uri); | ||
return; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove
@Tyriar |
@Tyriar
Fixes #30761