فهرست منبع

LibWeb: Make DOMRectReadOnly use double instead of float

Bastiaan van der Plaat 1 سال پیش
والد
کامیت
e4270bc01d
2فایلهای تغییر یافته به همراه2 افزوده شده و 1 حذف شده
  1. 1 0
      Userland/Libraries/LibGfx/Rect.h
  2. 1 1
      Userland/Libraries/LibWeb/Geometry/DOMRectReadOnly.h

+ 1 - 0
Userland/Libraries/LibGfx/Rect.h

@@ -1038,6 +1038,7 @@ private:
 
 using IntRect = Rect<int>;
 using FloatRect = Rect<float>;
+using DoubleRect = Rect<double>;
 
 [[nodiscard]] ALWAYS_INLINE IntRect enclosing_int_rect(FloatRect const& float_rect)
 {

+ 1 - 1
Userland/Libraries/LibWeb/Geometry/DOMRectReadOnly.h

@@ -45,6 +45,6 @@ protected:
 
     virtual void initialize(JS::Realm&) override;
 
-    Gfx::FloatRect m_rect;
+    Gfx::DoubleRect m_rect;
 };
 }