/* * Copyright (c) 2024, Aliaksandr Kalenik * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include namespace Web::Painting { struct ScrollFrame : public RefCounted { i32 id { -1 }; CSSPixelPoint own_offset; RefPtr parent; CSSPixelPoint cumulative_offset() const { if (parent) return parent->cumulative_offset() + own_offset; return own_offset; } }; }