ladybird/Userland/Libraries/LibWeb/Painting/ScrollFrame.h
Aliaksandr Kalenik ab76b99f1e LibWeb: Update scroll thumb position by mutating display list
A new display list item type named PaintScrollBar is introduced. Having
a dedicated type for scroll bars allows the thumb position to be updated
without rebuilding a display list. This was not possible with
FillRectWithRoundedCorners that does not allow to tell whether it
belongs to scroll thumb.
2024-08-19 18:57:20 +02:00

19 lines
344 B
C++

/*
* Copyright (c) 2024, Aliaksandr Kalenik <kalenik.aliaksandr@gmail.com>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <LibWeb/PixelUnits.h>
namespace Web::Painting {
struct ScrollFrame : public RefCounted<ScrollFrame> {
i32 id { -1 };
CSSPixelPoint cumulative_offset;
CSSPixelPoint own_offset;
};
}