DevTools: Move Source related code to dedicated source.rs file (#36667)

Currently Source related code exists in watcher.rs and thread.rs. This
change moves source-related code to a dedicated source.rs file. This is
in preparation for adding support for showing source code in the
Debugger > Source panel.

- [x] Testing: These changes should not affect current functionality as
it only moves the existing code
- [x] Fixes: part of https://github.com/servo/servo/issues/36027

---------

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
This commit is contained in:
atbrakhi 2025-04-24 09:50:56 +02:00 committed by GitHub
parent d661d4a620
commit c16d86f7a4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 62 additions and 38 deletions

View file

@ -265,7 +265,7 @@ impl Actor for WatcherActor {
},
"source" => {
let thread_actor = registry.find::<ThreadActor>(&target.thread);
let sources = thread_actor.sources();
let sources = thread_actor.source_manager.sources();
target.resources_available(sources.iter().collect(), "source".into());
},
"console-message" | "error-message" => {},