Replace NetworkEventUpdateMsg with ResourcesUpdatedArray (#37384)

*Replaces NetworkEventUpdateMsg with ResourcesUpdatedArray in
HttpResponse case of handle_network_event *
- Adds ResourcesUpdatedArray and UpdateEntry structs in
`devtools/network_handler.rs` to hold an array of updates
(requestHeaders, responseCookies). Updates handle_network_event to use
BrowsingContextActor::resource_available for sending
"resources-updated-array").
- Adds browsing_context_actor_name parameter to handle_network_event to
resolve borrow checker issues and enable BrowsingContextActor lookup.
- Ensures borrow safety by scoping mutable actor access.

Testing: *Does not require test*
Fixes: part of https://github.com/servo/servo/issues/33556

---------

Signed-off-by: Uthman Yahaya Baba <uthmanyahayababa@gmail.com>
This commit is contained in:
Usman Yahaya Baba 2025-06-11 23:07:57 +01:00 committed by GitHub
parent ea5a20ab8d
commit 8e1cf31db3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 64 additions and 95 deletions

View file

@ -30,6 +30,8 @@ pub struct Method {
pub trait JsonPacketStream {
fn write_json_packet<T: Serialize>(&mut self, obj: &T) -> Result<(), Box<dyn Error>>;
#[allow(dead_code)]
fn write_merged_json_packet<T: Serialize, U: Serialize>(
&mut self,
base: &T,