https://git.reactos.org/?p=reactos.git;a=commitdiff;h=71e66c69c1fe53c9cec35…
commit 71e66c69c1fe53c9cec35e5fbf62b64a67f73f3a
Author: Giannis Adamopoulos <gadamopoulos(a)reactos.org>
AuthorDate: Tue Jan 16 11:43:28 2018 +0200
Commit: Giannis Adamopoulos <gadamopoulos(a)reactos.org>
CommitDate: Tue Jan 16 11:50:52 2018 +0200
[EXPLORER] CTrayBandSite: Call DBID_SETWINDOWTHEME on new bands to make them use the
theme of the taskbar. CORE-14176
---
base/shell/explorer/tbsite.cpp | 18 +++++++++++++++++-
1 file changed, 17 insertions(+), 1 deletion(-)
diff --git a/base/shell/explorer/tbsite.cpp b/base/shell/explorer/tbsite.cpp
index 1cb3ab5a66..aa2f4e6985 100644
--- a/base/shell/explorer/tbsite.cpp
+++ b/base/shell/explorer/tbsite.cpp
@@ -355,7 +355,23 @@ public:
/* FIXME: Should be delayed */
IUnknown_Exec(punk, IID_IDeskBand, DBID_DELAYINIT, 0, NULL, NULL);
- return m_BandSite->AddBand(punk);
+ HRESULT hr = m_BandSite->AddBand(punk);
+ if (FAILED_UNEXPECTEDLY(hr))
+ return hr;
+
+ VARIANT vThemeName;
+ V_VT(&vThemeName) = VT_BSTR;
+ V_BSTR(&vThemeName) = SysAllocString(L"TaskBar");
+ IUnknown_Exec(punk,
+ IID_IDeskBand,
+ DBID_SETWINDOWTHEME,
+ 0,
+ &vThemeName,
+ NULL);
+
+ SysFreeString(V_BSTR(&vThemeName));
+
+ return S_OK;
}
virtual HRESULT STDMETHODCALLTYPE EnumBands(