From b3045c6feb7ac13cb2a80e2bcf96482debc2233f Mon Sep 17 00:00:00 2001 From: Jonas Kümmerlin Date: Wed, 10 Jun 2020 17:51:49 +0200 Subject: notebook: uxtheme drawing and more fixes still missing mouseover effect and some fine tuning --- alf/alfcompat.cpp | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) (limited to 'alf/alfcompat.cpp') diff --git a/alf/alfcompat.cpp b/alf/alfcompat.cpp index b986ee8..6321a44 100644 --- a/alf/alfcompat.cpp +++ b/alf/alfcompat.cpp @@ -358,6 +358,21 @@ ALF_Compat_fallbackGetThemeColor(HTHEME hTheme, return E_NOTIMPL; } +static HRESULT WINAPI +ALF_Compat_fallbackGetThemeMargins(HTHEME hTheme, + HDC hdc, + int iPartId, + int iStateId, + int iPropId, + LPCRECT prc, + MARGINS *pMargins) +{ + (void)hTheme; (void)hdc; (void)iPartId; (void)iStateId; (void)iPropId; (void)prc; (void)pMargins; + + return E_NOTIMPL; +} + + static BOOL CALLBACK ALF_Compat_DrawDisabledText_DrawStateProc(HDC hdc, LPARAM lData, @@ -489,6 +504,7 @@ void ALF_LoadCompatFunctions(void) LOAD_FUNC(uxtheme, GetThemeTransitionDuration); LOAD_FUNC(uxtheme, GetThemePartSize); LOAD_FUNC(uxtheme, GetThemeColor); + LOAD_FUNC(uxtheme, GetThemeMargins); // initialize helper function for disabled text if (ALF_Compat_Is40()) { @@ -526,6 +542,7 @@ void ALF_UnloadCompatFunctions(void) UNLOAD_FUNC(GetThemeTransitionDuration); UNLOAD_FUNC(GetThemePartSize); UNLOAD_FUNC(GetThemeColor); + UNLOAD_FUNC(GetThemeMargins); FreeLibrary(_alf_dll_uxtheme); FreeLibrary(_alf_dll_user32); @@ -559,4 +576,5 @@ ALF_Compat_HANIMATIONBUFFER (WINAPI *ALF_Compat_BeginBufferedAnimation)(HWND,HDC HRESULT (WINAPI *ALF_Compat_EndBufferedAnimation)(ALF_Compat_HANIMATIONBUFFER,BOOL) = NULL; BOOL (WINAPI *ALF_Compat_BufferedPaintRenderAnimation)(HWND,HDC) = NULL; HRESULT (WINAPI *ALF_Compat_GetThemeTransitionDuration)(HTHEME,int,int,int,int,DWORD*) = NULL; -HRESULT (WINAPI *ALF_Compat_GetThemeColor)(HTHEME,int,int,int,COLORREF*); +HRESULT (WINAPI *ALF_Compat_GetThemeColor)(HTHEME,int,int,int,COLORREF*) = NULL; +HRESULT (WINAPI *ALF_Compat_GetThemeMargins)(HTHEME,HDC,int,int,int,const RECT *,MARGINS *) = NULL; -- cgit v1.2.3