aboutsummaryrefslogtreecommitdiff
path: root/src/libs
diff options
context:
space:
mode:
authorSean Hall <r.sean.hall@gmail.com>2021-10-27 15:30:02 -0500
committerSean Hall <r.sean.hall@gmail.com>2021-11-01 16:34:09 -0500
commitc092722a147940532b08f62403e182ef279f2c74 (patch)
tree2f4d85e26c3e13566ec7f1bf7b18a2de4430d628 /src/libs
parent3d73efba15565f5995a492e660dff72286e0b672 (diff)
downloadwix-c092722a147940532b08f62403e182ef279f2c74.tar.gz
wix-c092722a147940532b08f62403e182ef279f2c74.tar.bz2
wix-c092722a147940532b08f62403e182ef279f2c74.zip
Add CS_HREDRAW and CS_VREDRAW to fix painting issues when resizing.
Diffstat (limited to 'src/libs')
-rw-r--r--src/libs/dutil/WixToolset.DUtil/inc/thmutil.h13
-rw-r--r--src/libs/dutil/WixToolset.DUtil/thmutil.cpp20
2 files changed, 33 insertions, 0 deletions
diff --git a/src/libs/dutil/WixToolset.DUtil/inc/thmutil.h b/src/libs/dutil/WixToolset.DUtil/inc/thmutil.h
index eda81485..cd286854 100644
--- a/src/libs/dutil/WixToolset.DUtil/inc/thmutil.h
+++ b/src/libs/dutil/WixToolset.DUtil/inc/thmutil.h
@@ -530,6 +530,19 @@ HRESULT DAPI ThemeRegisterVariableCallbacks(
530 ); 530 );
531 531
532/******************************************************************** 532/********************************************************************
533 ThemeInitializeWindowClass - sets defaults for the window class
534 from the given theme.
535
536*******************************************************************/
537void DAPI ThemeInitializeWindowClass(
538 __in THEME* pTheme,
539 __in WNDCLASSW* pWndClass,
540 __in WNDPROC pfnWndProc,
541 __in HINSTANCE hInstance,
542 __in LPCWSTR wzClassName
543 );
544
545/********************************************************************
533 ThemeCreateParentWindow - creates a parent window for the theme. 546 ThemeCreateParentWindow - creates a parent window for the theme.
534 547
535*******************************************************************/ 548*******************************************************************/
diff --git a/src/libs/dutil/WixToolset.DUtil/thmutil.cpp b/src/libs/dutil/WixToolset.DUtil/thmutil.cpp
index 068638f6..e8c23b6c 100644
--- a/src/libs/dutil/WixToolset.DUtil/thmutil.cpp
+++ b/src/libs/dutil/WixToolset.DUtil/thmutil.cpp
@@ -824,6 +824,26 @@ LExit:
824} 824}
825 825
826 826
827DAPI_(void) ThemeInitializeWindowClass(
828 __in THEME* pTheme,
829 __in WNDCLASSW* pWndClass,
830 __in WNDPROC pfnWndProc,
831 __in HINSTANCE hInstance,
832 __in LPCWSTR wzClassName
833 )
834{
835 pWndClass->style = CS_HREDRAW | CS_VREDRAW;
836 pWndClass->hCursor = ::LoadCursorW(NULL, (LPCWSTR)IDC_ARROW);
837
838 pWndClass->lpfnWndProc = pfnWndProc;
839 pWndClass->hInstance = hInstance;
840 pWndClass->lpszClassName = wzClassName;
841
842 pWndClass->hIcon = reinterpret_cast<HICON>(pTheme->hIcon);
843 pWndClass->hbrBackground = pTheme->rgFonts[pTheme->dwFontId].hBackground;
844}
845
846
827DAPI_(HRESULT) ThemeCreateParentWindow( 847DAPI_(HRESULT) ThemeCreateParentWindow(
828 __in THEME* pTheme, 848 __in THEME* pTheme,
829 __in DWORD dwExStyle, 849 __in DWORD dwExStyle,