diff options
author | Andreas Kling <kling@serenityos.org> | 2022-10-06 14:39:11 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2022-10-06 15:29:38 +0200 |
commit | 5989a3ee77463aa0ed029019364faf64e54ebb62 (patch) | |
tree | fcb4ff77536655c245827475d78e5177494211f0 /Ports/openttd-opensfx | |
parent | fe03149a470840defa8783cb633b3f46bdff703c (diff) | |
download | serenity-5989a3ee77463aa0ed029019364faf64e54ebb62.zip |
LibWeb: Honor CSS display value in is_inline() and is_inline_block()
These were totally ad-hoc before, is_inline() was based on a boolean
flag on Layout::Node that we set in various situations.
Meanwhile, is_inline_block() was a combination on is_inline() plus a
type check to see if the layout node inherited from BlockContainer.
This patch replaces the above mess with simple lookups of the CSS
display value. Note that layout nodes without their own style (i.e text
nodes) are automatically assumed to be inline and non-blocks. This has
to be special-cased since layout nodes without style will consult the
style of their parent, so without short-circuiting this would break.
Diffstat (limited to 'Ports/openttd-opensfx')
0 files changed, 0 insertions, 0 deletions