mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 20:29:18 +00:00
LibWeb: Rename is_scrollable()
to could_be_scrolled_by_wheel_event()
Previous name for misleading because it checks if box could be scrolled by user input event which is diffent from checking if box is scrollable. For example box with `overflow: hidden` is scrollable but it can't be scrolled by user input event.
This commit is contained in:
parent
dd37d1c536
commit
74dde4dc0f
Notes:
github-actions[bot]
2025-01-30 23:39:27 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: 74dde4dc0f
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3410
Reviewed-by: https://github.com/gmta ✅
4 changed files with 10 additions and 10 deletions
|
@ -1651,7 +1651,7 @@ void Node::serialize_tree_as_json(JsonObjectSerializer<StringBuilder>& object) c
|
|||
}
|
||||
|
||||
if (paintable_box()) {
|
||||
if (paintable_box()->is_scrollable()) {
|
||||
if (paintable_box()->could_be_scrolled_by_wheel_event()) {
|
||||
MUST(object.add("scrollable"sv, true));
|
||||
}
|
||||
if (!paintable_box()->is_visible()) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue