mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-27 21:42:53 +00:00
LibWeb/CSS: Extract border width values directly
Some checks are pending
CI / Lagom (arm64, Sanitizer_CI, false, macos-15, macOS, Clang) (push) Waiting to run
CI / Lagom (x86_64, Fuzzers_CI, false, ubuntu-24.04, Linux, Clang) (push) Waiting to run
CI / Lagom (x86_64, Sanitizer_CI, false, ubuntu-24.04, Linux, GNU) (push) Waiting to run
CI / Lagom (x86_64, Sanitizer_CI, true, ubuntu-24.04, Linux, Clang) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (arm64, macos-15, macOS, macOS-universal2) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (x86_64, ubuntu-24.04, Linux, Linux-x86_64) (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Label PRs with merge conflicts / auto-labeler (push) Waiting to run
Push notes / build (push) Waiting to run
Some checks are pending
CI / Lagom (arm64, Sanitizer_CI, false, macos-15, macOS, Clang) (push) Waiting to run
CI / Lagom (x86_64, Fuzzers_CI, false, ubuntu-24.04, Linux, Clang) (push) Waiting to run
CI / Lagom (x86_64, Sanitizer_CI, false, ubuntu-24.04, Linux, GNU) (push) Waiting to run
CI / Lagom (x86_64, Sanitizer_CI, true, ubuntu-24.04, Linux, Clang) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (arm64, macos-15, macOS, macOS-universal2) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (x86_64, ubuntu-24.04, Linux, Linux-x86_64) (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Label PRs with merge conflicts / auto-labeler (push) Waiting to run
Push notes / build (push) Waiting to run
There's no need to keep a copy of a `BorderData` object in this case. This makes the variable names used a bit less confusing.
This commit is contained in:
parent
32812f5db0
commit
026bc91d6c
Notes:
github-actions[bot]
2025-04-05 10:55:21 +00:00
Author: https://github.com/tcl3
Commit: 026bc91d6c
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4233
1 changed files with 8 additions and 8 deletions
|
@ -945,20 +945,20 @@ RefPtr<CSSStyleValue const> CSSStyleProperties::style_value_for_computed_propert
|
|||
// The resolved value is the computed value.
|
||||
// NOTE: This is handled inside the `default` case.
|
||||
case PropertyID::BorderBottomWidth: {
|
||||
auto border_bottom_width = layout_node.computed_values().border_bottom();
|
||||
return LengthStyleValue::create(Length::make_px(border_bottom_width.width));
|
||||
auto border_bottom_width = layout_node.computed_values().border_bottom().width;
|
||||
return LengthStyleValue::create(Length::make_px(border_bottom_width));
|
||||
}
|
||||
case PropertyID::BorderLeftWidth: {
|
||||
auto border_left_width = layout_node.computed_values().border_left();
|
||||
return LengthStyleValue::create(Length::make_px(border_left_width.width));
|
||||
auto border_left_width = layout_node.computed_values().border_left().width;
|
||||
return LengthStyleValue::create(Length::make_px(border_left_width));
|
||||
}
|
||||
case PropertyID::BorderRightWidth: {
|
||||
auto border_right_width = layout_node.computed_values().border_right();
|
||||
return LengthStyleValue::create(Length::make_px(border_right_width.width));
|
||||
auto border_right_width = layout_node.computed_values().border_right().width;
|
||||
return LengthStyleValue::create(Length::make_px(border_right_width));
|
||||
}
|
||||
case PropertyID::BorderTopWidth: {
|
||||
auto border_top_width = layout_node.computed_values().border_top();
|
||||
return LengthStyleValue::create(Length::make_px(border_top_width.width));
|
||||
auto border_top_width = layout_node.computed_values().border_top().width;
|
||||
return LengthStyleValue::create(Length::make_px(border_top_width));
|
||||
}
|
||||
case PropertyID::OutlineWidth: {
|
||||
auto outline_width = layout_node.computed_values().outline_width();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue