1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-24 23:07:34 +00:00

Ladybird+WebContent: Update IPC calls to handle multiple traversables

The IPC layer between chromes and LibWeb now understands that multiple
top level traversables can live in each WebContent process.

This largely mechanical change adds a billion page_id/page_index
arguments to make sure that pages that end up opening new WebViews
through mechanisms like window.open() still work properly with those
extra windows.
This commit is contained in:
Andrew Kaster 2024-02-02 18:00:48 -07:00 committed by Tim Flynn
parent adb5c27331
commit 36cd2fb7c5
20 changed files with 1542 additions and 969 deletions

View file

@ -8,10 +8,12 @@
#pragma once
#include "ConnectionFromClient.h"
#include <AK/Vector.h>
#include <AK/Weakable.h>
#include <LibJS/Console.h>
#include <LibJS/Forward.h>
#include <LibWeb/Forward.h>
#include <WebContent/ConsoleGlobalEnvironmentExtensions.h>
#include <WebContent/Forward.h>
namespace WebContent {
@ -19,7 +21,7 @@ namespace WebContent {
class WebContentConsoleClient final : public JS::ConsoleClient
, public Weakable<WebContentConsoleClient> {
public:
WebContentConsoleClient(JS::Console&, JS::Realm&, ConnectionFromClient&);
WebContentConsoleClient(JS::Console&, JS::Realm&, PageClient&);
void handle_input(ByteString const& js_source);
void send_messages(i32 start_index);
@ -35,7 +37,7 @@ private:
m_current_message_style.append(';');
}
ConnectionFromClient& m_client;
PageClient& m_client;
JS::Handle<ConsoleGlobalEnvironmentExtensions> m_console_global_environment_extensions;
void clear_output();