mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-12 02:59:45 +00:00
HackStudio: Make TODO entries clickable
Now you can click a TODO entry to set focus on that position of that file.
This commit is contained in:
parent
935c7b2f4b
commit
e0f1c237d2
Notes:
sideshowbarker
2024-07-18 11:36:52 +09:00
Author: https://github.com/guerinoni
Commit: e0f1c237d2
Pull-request: https://github.com/SerenityOS/serenity/pull/6614
Reviewed-by: https://github.com/alimpfard
Reviewed-by: https://github.com/itamar8910 ✅
Reviewed-by: https://github.com/linusg
15 changed files with 83 additions and 39 deletions
|
@ -961,13 +961,13 @@ void Parser::print_tokens() const
|
|||
}
|
||||
}
|
||||
|
||||
Vector<String> Parser::get_todo_entries() const
|
||||
Vector<Parser::TodoEntry> Parser::get_todo_entries() const
|
||||
{
|
||||
Vector<String> ret;
|
||||
Vector<TodoEntry> ret;
|
||||
for (auto& token : m_tokens) {
|
||||
if (token.type() == Token::Type::Comment) {
|
||||
if (token.text().contains("TODO")) {
|
||||
ret.append(token.text());
|
||||
ret.append({ token.text(), m_filename, token.start().line, token.start().column });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue