diff options
Diffstat (limited to 'core/fxge/win32')
-rw-r--r-- | core/fxge/win32/fx_win32_device.cpp | 5 | ||||
-rw-r--r-- | core/fxge/win32/win32_int.h | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/core/fxge/win32/fx_win32_device.cpp b/core/fxge/win32/fx_win32_device.cpp index b857dde91b..337f9643d1 100644 --- a/core/fxge/win32/fx_win32_device.cpp +++ b/core/fxge/win32/fx_win32_device.cpp @@ -1061,7 +1061,7 @@ bool CGdiDeviceDriver::DrawPath(const CFX_PathData* pPathData, return true; } -bool CGdiDeviceDriver::FillRectWithBlend(const FX_RECT* pRect, +bool CGdiDeviceDriver::FillRectWithBlend(const FX_RECT& rect, uint32_t fill_color, int blend_type) { if (blend_type != FXDIB_BLEND_NORMAL) @@ -1077,7 +1077,8 @@ bool CGdiDeviceDriver::FillRectWithBlend(const FX_RECT* pRect, return false; HBRUSH hBrush = CreateSolidBrush(colorref); - ::FillRect(m_hDC, (RECT*)pRect, hBrush); + const RECT* pRect = reinterpret_cast<const RECT*>(&rect); + ::FillRect(m_hDC, pRect, hBrush); DeleteObject(hBrush); return true; } diff --git a/core/fxge/win32/win32_int.h b/core/fxge/win32/win32_int.h index 34d307c2cd..b248522f0a 100644 --- a/core/fxge/win32/win32_int.h +++ b/core/fxge/win32/win32_int.h @@ -151,7 +151,7 @@ class CGdiDeviceDriver : public RenderDeviceDriverIface { uint32_t stroke_color, int fill_mode, int blend_type) override; - bool FillRectWithBlend(const FX_RECT* pRect, + bool FillRectWithBlend(const FX_RECT& rect, uint32_t fill_color, int blend_type) override; bool DrawCosmeticLine(const CFX_PointF& ptMoveTo, |