From af2f8a5ab8ebecd097dcf8f21d773183ffc044a3 Mon Sep 17 00:00:00 2001 From: Simon Hausmann Date: Fri, 7 Feb 2025 18:19:58 +0100 Subject: [PATCH] stm32: Fix compilation with newer STM BSPs Neither the BSP_LCD_Relaod typo nor the legacy #define is present in newer BSPs anymore. --- api/cpp/include/slint-stm32.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/api/cpp/include/slint-stm32.h b/api/cpp/include/slint-stm32.h index 35e5e09f5a8..8d2dc06ee18 100644 --- a/api/cpp/include/slint-stm32.h +++ b/api/cpp/include/slint-stm32.h @@ -162,10 +162,18 @@ struct StmSlintPlatform : public slint::platform::Platform SCB_CleanDCache_by_Addr((uint32_t *)buffer1.data(), buffer1.size()); +#if defined(BSP_LCD_Relaod) BSP_LCD_Relaod(0, BSP_LCD_RELOAD_NONE); +#else + BSP_LCD_Reload(0, BSP_LCD_RELOAD_NONE); +#endif BSP_LCD_SetLayerAddress(0, 0, uintptr_t(buffer1.data())); screen_ready = false; +#if defined(BSP_LCD_Relaod) BSP_LCD_Relaod(0, BSP_LCD_RELOAD_VERTICAL_BLANKING); +#else + BSP_LCD_Reload(0, BSP_LCD_RELOAD_VERTICAL_BLANKING); +#endif std::swap(buffer1, buffer2); }