From 5649a83739f7d2455fdc7a1a7fe8ffdf85a4a060 Mon Sep 17 00:00:00 2001 From: Valentin Radu Date: Mon, 20 Mar 2023 20:48:34 +0200 Subject: [PATCH 1/4] Start11: Fixed a bug that prevented the menu from working when the setting "Disable Recommended section" is used and the display scaling is 125% Related issue: https://github.com/valinet/ExplorerPatcher/issues/1118 --- ExplorerPatcher/lvt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ExplorerPatcher/lvt.c b/ExplorerPatcher/lvt.c index 4b4aae522..254d4c9c4 100644 --- a/ExplorerPatcher/lvt.c +++ b/ExplorerPatcher/lvt.c @@ -573,9 +573,9 @@ void LVT_StartDocked_120DPIHack(int maxHeight) pStartSizingFrame->lpVtbl->QueryInterface(pStartSizingFrame, &IID_Windows_UI_Xaml_IFrameworkElement, &pFrameworkElement); if (pFrameworkElement) { - pIUIElement->lpVtbl->put_Visibility(pIUIElement, Windows_UI_Xaml_Visibility_Collapsed); + if (!IsWindows11Version22H2Build1413OrHigher()) pIUIElement->lpVtbl->put_Visibility(pIUIElement, Windows_UI_Xaml_Visibility_Collapsed); pFrameworkElement->lpVtbl->put_MaxHeight(pFrameworkElement, maxHeight); - pIUIElement->lpVtbl->put_Visibility(pIUIElement, Windows_UI_Xaml_Visibility_Visible); + if (!IsWindows11Version22H2Build1413OrHigher()) pIUIElement->lpVtbl->put_Visibility(pIUIElement, Windows_UI_Xaml_Visibility_Visible); pFrameworkElement->lpVtbl->Release(pFrameworkElement); } pIUIElement->lpVtbl->Release(pIUIElement); From 8e9403cfb53fa10954d1d8e13c9d8988e180f704 Mon Sep 17 00:00:00 2001 From: Valentin Radu Date: Mon, 20 Mar 2023 20:49:44 +0200 Subject: [PATCH 2/4] Version: 22621.1413.54.4 --- CHANGELOG.md | 4 ++++ version.h | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 51e4eb20d..86b0ce56e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -25,6 +25,10 @@ Please make sure you are connected to the Internet while installing, the applica * Windows 11 Start menu: Better enforcement for disabling the "Recommended" section. (27a8fd9) +##### 4 + +* Windows 11 Start menu: Fixed a bug that prevented the menu from working when the setting "Disable Recommended section" is used and the display scaling is 125%. (5649a83) + ## 22621.1344.53 Tested on OS builds 22621.1344, 22000.1574, and 19044.1466. diff --git a/version.h b/version.h index ade730815..4e4f95147 100644 --- a/version.h +++ b/version.h @@ -1,7 +1,7 @@ #define VER_MAJOR 22621 #define VER_MINOR 1413 #define VER_BUILD_HI 54 -#define VER_BUILD_LO 3 +#define VER_BUILD_LO 4 #define VER_FLAGS VS_FF_PRERELEASE @@ -12,5 +12,5 @@ #define VER_STR(arg) #arg // The String form of the version numbers -#define VER_FILE_STRING VALUE "FileVersion", "22621.1413.54.3" -#define VER_PRODUCT_STRING VALUE "ProductVersion", "22621.1413.54.3" +#define VER_FILE_STRING VALUE "FileVersion", "22621.1413.54.4" +#define VER_PRODUCT_STRING VALUE "ProductVersion", "22621.1413.54.4" From 6bc2ea5d2b0b6fbfe2ba62cdb425d6dc0992b10f Mon Sep 17 00:00:00 2001 From: Valentin Radu Date: Mon, 20 Mar 2023 23:58:32 +0200 Subject: [PATCH 3/4] All: Fix crash when attempting to hook function on older OS builds `RtlQueryFeatureConfiguration` is not available on old Windows 10 builds, like 17763 (LTSC 2019). Related issue: https://github.com/valinet/ExplorerPatcher/discussions/1142 --- ExplorerPatcher/dllmain.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/ExplorerPatcher/dllmain.c b/ExplorerPatcher/dllmain.c index 5b85cd6c0..eff4795cf 100644 --- a/ExplorerPatcher/dllmain.c +++ b/ExplorerPatcher/dllmain.c @@ -10161,15 +10161,17 @@ DWORD Inject(BOOL bIsExplorer) } RtlQueryFeatureConfigurationFunc = GetProcAddress(GetModuleHandleW(L"ntdll.dll"), "RtlQueryFeatureConfiguration"); - rv = funchook_prepare( - funchook, - (void**)&RtlQueryFeatureConfigurationFunc, - RtlQueryFeatureConfigurationHook - ); - if (rv != 0) - { - FreeLibraryAndExitThread(hModule, rv); - return FALSE; + if (RtlQueryFeatureConfigurationFunc) { + rv = funchook_prepare( + funchook, + (void**)&RtlQueryFeatureConfigurationFunc, + RtlQueryFeatureConfigurationHook + ); + if (rv != 0) + { + FreeLibraryAndExitThread(hModule, rv); + return FALSE; + } } printf("Setup ntdll functions done\n"); From 0344a5e156b5c6cae016141b5f6222d52ed00890 Mon Sep 17 00:00:00 2001 From: Valentin Radu Date: Tue, 21 Mar 2023 00:00:56 +0200 Subject: [PATCH 4/4] Version: 22621.1413.54.5 --- CHANGELOG.md | 4 ++++ version.h | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 86b0ce56e..c7730d4ca 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,6 +29,10 @@ Please make sure you are connected to the Internet while installing, the applica * Windows 11 Start menu: Fixed a bug that prevented the menu from working when the setting "Disable Recommended section" is used and the display scaling is 125%. (5649a83) +##### 5 + +* Fixed a bug that could crash File Explorer on older OS builds, like 17763 (LTSC 2019). (6bc2ea5) + ## 22621.1344.53 Tested on OS builds 22621.1344, 22000.1574, and 19044.1466. diff --git a/version.h b/version.h index 4e4f95147..c12c166ee 100644 --- a/version.h +++ b/version.h @@ -1,7 +1,7 @@ #define VER_MAJOR 22621 #define VER_MINOR 1413 #define VER_BUILD_HI 54 -#define VER_BUILD_LO 4 +#define VER_BUILD_LO 5 #define VER_FLAGS VS_FF_PRERELEASE @@ -12,5 +12,5 @@ #define VER_STR(arg) #arg // The String form of the version numbers -#define VER_FILE_STRING VALUE "FileVersion", "22621.1413.54.4" -#define VER_PRODUCT_STRING VALUE "ProductVersion", "22621.1413.54.4" +#define VER_FILE_STRING VALUE "FileVersion", "22621.1413.54.5" +#define VER_PRODUCT_STRING VALUE "ProductVersion", "22621.1413.54.5"