Skip to content

Truly independent web browser

1.6 KB
Raw Blame
#include <LibWebCommon/Page/AsyncScrollNodeStableID.h>
#include <LibWebCommon/Page/CompositorContextId.h>
#include <LibWebCommon/PixelUnits.h>

endpoint RenderClockClient
{
    // With where the compositor has scrolled the context's scroll nodes to at the tick.
    [RustReceiver, RustSender] clock_tick(Web::CompositorContextId context_id, i64 frame_time_nanoseconds, double frame_interval_milliseconds, Vector<Web::CompositorScrollOffset> scroll_offsets) =|

    // The pointer moved to `position`, in the context's device pixels, beside the mouse event the main thread takes,
    // whose input event id `input_event_id` is. `buttons` are the buttons held, and `scrolled_since_frame` says whether
    // the compositor scrolled the context since the last frame WebContent presented, whose scroll offsets a hit test
    // there would not know.
    [RustReceiver, RustSender] pointer_moved(Web::CompositorContextId context_id, Web::DevicePixelPoint position, u32 buttons, bool scrolled_since_frame, u64 input_event_id) =|
    // The pointer left the context, beside the mouse event with the input event id `input_event_id`.
    [RustReceiver, RustSender] pointer_left(Web::CompositorContextId context_id, u64 input_event_id) =|
    [RustReceiver, RustSender] pointer_rests_on_moving_content(Web::CompositorContextId context_id) =|

    // The compositor scrolled the context's scroll nodes to `scroll_offsets`, past what the display list it shows holds.
    [RustReceiver, RustSender] display_list_coverage_runs_out(Web::CompositorContextId context_id, Vector<Web::CompositorScrollOffset> scroll_offsets) =|
}