diff --git a/patches/shell32-SHGetStockIconInfo/0001-shell32-Improve-semi-stub-SHGetStockIconInfo-try-fin.patch b/patches/shell32-SHGetStockIconInfo/0001-shell32-Improve-semi-stub-SHGetStockIconInfo-try-fin.patch index 3256f915..e0077f8f 100644 --- a/patches/shell32-SHGetStockIconInfo/0001-shell32-Improve-semi-stub-SHGetStockIconInfo-try-fin.patch +++ b/patches/shell32-SHGetStockIconInfo/0001-shell32-Improve-semi-stub-SHGetStockIconInfo-try-fin.patch @@ -1,4 +1,4 @@ -From 68d7bcf933fabf684262f42a152ddf4fa5c38577 Mon Sep 17 00:00:00 2001 +From 0d5690ffe44182224aef5488508a8eeb2750e757 Mon Sep 17 00:00:00 2001 From: Louis Lenders Date: Fri, 12 Oct 2018 11:57:18 +0200 Subject: [PATCH] shell32: Improve semi-stub SHGetStockIconInfo, try find @@ -18,10 +18,10 @@ Signed-off-by: Louis Lenders 2 files changed, 164 insertions(+), 7 deletions(-) diff --git a/dlls/shell32/iconcache.c b/dlls/shell32/iconcache.c -index 1851d0d0fc6..705b818083c 100644 +index 03eea049d0c..4a84b2055fe 100644 --- a/dlls/shell32/iconcache.c +++ b/dlls/shell32/iconcache.c -@@ -1019,6 +1019,119 @@ INT WINAPI SHGetIconOverlayIndexW(LPCWSTR pszIconPath, INT iIconIndex) +@@ -1021,6 +1021,119 @@ INT WINAPI SHGetIconOverlayIndexW(LPCWSTR pszIconPath, INT iIconIndex) return -1; } @@ -141,7 +141,7 @@ index 1851d0d0fc6..705b818083c 100644 /**************************************************************************** * SHGetStockIconInfo [SHELL32.@] * -@@ -1036,23 +1149,52 @@ INT WINAPI SHGetIconOverlayIndexW(LPCWSTR pszIconPath, INT iIconIndex) +@@ -1038,25 +1151,54 @@ INT WINAPI SHGetIconOverlayIndexW(LPCWSTR pszIconPath, INT iIconIndex) */ HRESULT WINAPI SHGetStockIconInfo(SHSTOCKICONID id, UINT flags, SHSTOCKICONINFO *sii) { @@ -164,6 +164,8 @@ index 1851d0d0fc6..705b818083c 100644 - FIXME("flags 0x%x not implemented\n", flags); - sii->hIcon = NULL; + if (flags & SHGSI_ICON) + sii->hIcon = LoadIconW(GetModuleHandleW(sii->szPath), MAKEINTRESOURCEW(sii->iIcon)); sii->iSysImageIndex = -1; + /* this is not how windows does it, on windows picked mostly from imageres.dll !*/ @@ -202,10 +204,10 @@ index 1851d0d0fc6..705b818083c 100644 return S_OK; diff --git a/dlls/shell32/tests/shelllink.c b/dlls/shell32/tests/shelllink.c -index e4e1e664038..b2e95e5301a 100644 +index f13155ade2f..c70bc9d5946 100644 --- a/dlls/shell32/tests/shelllink.c +++ b/dlls/shell32/tests/shelllink.c -@@ -1073,6 +1073,21 @@ static void test_SHGetStockIconInfo(void) +@@ -1119,6 +1119,21 @@ static void test_SHGetStockIconInfo(void) /* there is a NULL check for the struct */ hr = pSHGetStockIconInfo(SIID_FOLDER, SHGSI_ICONLOCATION, NULL); ok(hr == E_INVALIDARG, "NULL: got 0x%lx\n", hr); @@ -228,5 +230,5 @@ index e4e1e664038..b2e95e5301a 100644 static void test_SHExtractIcons(void) -- -2.35.1 +2.43.0 diff --git a/staging/upstream-commit b/staging/upstream-commit index 850da950..2c50e776 100644 --- a/staging/upstream-commit +++ b/staging/upstream-commit @@ -1 +1 @@ -1dfac2a252d0036c3bae08bf47f00582343a80fb +a891fcf66751921cf81db294b09a696c6b6999b8