mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 14:27:35 +00:00
LibWeb: Make resolution calculable
No tests unfortunately, because no CSS property we currently support accepts `<resolution>`.
This commit is contained in:
parent
e907ad44c3
commit
30dcbc306c
7 changed files with 67 additions and 2 deletions
|
@ -12,6 +12,7 @@
|
|||
#include <LibWeb/CSS/Frequency.h>
|
||||
#include <LibWeb/CSS/Length.h>
|
||||
#include <LibWeb/CSS/Percentage.h>
|
||||
#include <LibWeb/CSS/Resolution.h>
|
||||
#include <LibWeb/CSS/StyleValues/CalculatedStyleValue.h>
|
||||
#include <LibWeb/CSS/Time.h>
|
||||
|
||||
|
@ -128,6 +129,13 @@ public:
|
|||
Percentage resolve_calculated(NonnullRefPtr<CalculatedStyleValue> const&, Layout::Node const&) const override;
|
||||
};
|
||||
|
||||
class ResolutionOrCalculated : public CalculatedOr<Resolution> {
|
||||
public:
|
||||
using CalculatedOr<Resolution>::CalculatedOr;
|
||||
|
||||
Resolution resolve_calculated(NonnullRefPtr<CalculatedStyleValue> const&, Layout::Node const&) const override;
|
||||
};
|
||||
|
||||
class TimeOrCalculated : public CalculatedOr<Time> {
|
||||
public:
|
||||
using CalculatedOr<Time>::CalculatedOr;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue