mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 21:59:07 +00:00
LibWeb: Change calc node representation from float to double
This commit is contained in:
parent
f5da6d61b4
commit
421559d725
Notes:
sideshowbarker
2024-07-17 02:21:14 +09:00
Author: https://github.com/stelar7
Commit: 421559d725
Pull-request: https://github.com/SerenityOS/serenity/pull/19162
22 changed files with 75 additions and 75 deletions
|
@ -15,13 +15,13 @@ Frequency::Frequency(int value, Type type)
|
|||
{
|
||||
}
|
||||
|
||||
Frequency::Frequency(float value, Type type)
|
||||
Frequency::Frequency(double value, Type type)
|
||||
: m_type(type)
|
||||
, m_value(value)
|
||||
{
|
||||
}
|
||||
|
||||
Frequency Frequency::make_hertz(float value)
|
||||
Frequency Frequency::make_hertz(double value)
|
||||
{
|
||||
return { value, Type::Hz };
|
||||
}
|
||||
|
@ -36,7 +36,7 @@ ErrorOr<String> Frequency::to_string() const
|
|||
return String::formatted("{}hz", to_hertz());
|
||||
}
|
||||
|
||||
float Frequency::to_hertz() const
|
||||
double Frequency::to_hertz() const
|
||||
{
|
||||
switch (m_type) {
|
||||
case Type::Hz:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue