From 85d0c890de182cfa71ea45a688387de5cee64b1e Mon Sep 17 00:00:00 2001 From: Moli Date: Thu, 16 Jul 2026 20:50:09 +0800 Subject: [PATCH] Docs: Fix broken links and incorrect source file references (#49294) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Description Fixes #49285 This PR fixes three documentation files with broken links or incorrect source file references: ### 1. `doc/devdocs/modules/fileexploreraddons.md` — broken source code link The "Source code folder" link pointed to `src/modules/fileexplorerpreview`, which does not exist in the repository. Changed to `src/modules/previewpane` (the actual directory). ### 2. `doc/devdocs/modules/launcher/plugins/calculator.md` — broken unit test links (10 occurrences) All 10 links in the "Unit Tests" section pointed to `Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests` (plural), but the actual test project directory is `Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest` (singular). All link references have been corrected. ### 3. `doc/devdocs/core/runner.md` — incorrect file reference The "Centralized Keyboard Hook" section referenced `centralized_keyboard_hook.cpp`, but the actual file is `centralized_kb_hook.cpp` (at `src/runner/centralized_kb_hook.cpp`). ## Validation Each fix was verified against the actual repository structure: | Fix | Verified path exists | |-----|---------------------| | `fileexploreraddons.md` | `src/modules/previewpane/` (contains `powerpreview/` subproject) | | `calculator.md` | `src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/` (contains `BracketHelperTests.cs`, `ExtendedCalculatorParserTests.cs`, `NumberTranslatorTests.cs`, `QueryTests.cs`) | | `runner.md` | `src/runner/centralized_kb_hook.cpp` | ## PR Checklist - [x] Docs-only change — no code or tests affected - [x] Links verified against actual repository structure --- doc/devdocs/core/runner.md | 2 +- doc/devdocs/modules/fileexploreraddons.md | 2 +- .../modules/launcher/plugins/calculator.md | 20 +++++++++---------- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/doc/devdocs/core/runner.md b/doc/devdocs/core/runner.md index f337032d1d..f029cea6c7 100644 --- a/doc/devdocs/core/runner.md +++ b/doc/devdocs/core/runner.md @@ -119,7 +119,7 @@ The flyout window is then activated and brought to the foreground using native W ## Centralized Keyboard Hook -- Located in "centralized_keyboard_hook.cpp" +- Located in "centralized_kb_hook.cpp" - Handles hotkeys for multiple modules to prevent performance issues - Contains optimizations to exit early when possible: - Ignores keystrokes generated by PowerToys itself diff --git a/doc/devdocs/modules/fileexploreraddons.md b/doc/devdocs/modules/fileexploreraddons.md index 8d70af448d..0ca1abb3b9 100644 --- a/doc/devdocs/modules/fileexploreraddons.md +++ b/doc/devdocs/modules/fileexploreraddons.md @@ -14,7 +14,7 @@ File Explorer Add-ons are extensions that enhance Windows File Explorer function ## Links -- [Source code folder](https://github.com/microsoft/PowerToys/tree/main/src/modules/fileexplorerpreview) +- [Source code folder](https://github.com/microsoft/PowerToys/tree/main/src/modules/previewpane) - [Issue tracker](https://github.com/microsoft/PowerToys/issues?q=is%3Aissue+label%3A%22File+Explorer%22) ## Implementation Details diff --git a/doc/devdocs/modules/launcher/plugins/calculator.md b/doc/devdocs/modules/launcher/plugins/calculator.md index d9ac8e1e56..5624d11dd5 100644 --- a/doc/devdocs/modules/launcher/plugins/calculator.md +++ b/doc/devdocs/modules/launcher/plugins/calculator.md @@ -47,18 +47,18 @@ var result = CalculateEngine.Interpret(query.Search, CultureInfo.CurrentUICultur The score of each result from the calculator plugin is `300`. -## [Unit Tests](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests) -We have a [Unit Test project](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests) that executes various test to ensure that the plugin works as expected. +## [Unit Tests](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest) +We have a [Unit Test project](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest) that executes various test to ensure that the plugin works as expected. -### [`BracketHelperTests`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests/BracketHelperTests.cs) -- The [`BracketHelperTests.cs`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests/BracketHelperTests.cs) class contains tests to validate that brackets are handled correctly. +### [`BracketHelperTests`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/BracketHelperTests.cs) +- The [`BracketHelperTests.cs`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/BracketHelperTests.cs) class contains tests to validate that brackets are handled correctly. -### [`ExtendedCalculatorParserTests`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests/ExtendedCalculatorParserTests.cs) -- The [`ExtendedCalculatorParserTests.cs`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests/ExtendedCalculatorParserTests.cs) class contains tests to validate that the input is parsed correctly and the result is correct. +### [`ExtendedCalculatorParserTests`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/ExtendedCalculatorParserTests.cs) +- The [`ExtendedCalculatorParserTests.cs`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/ExtendedCalculatorParserTests.cs) class contains tests to validate that the input is parsed correctly and the result is correct. -### [`NumberTranslatorTests`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests/NumberTranslatorTests.cs) -- The [`NumberTranslatorTests.cs`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests/NumberTranslatorTests.cs) class contains tests to validate that each number is converted correctly based on the defined locals. +### [`NumberTranslatorTests`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/NumberTranslatorTests.cs) +- The [`NumberTranslatorTests.cs`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/NumberTranslatorTests.cs) class contains tests to validate that each number is converted correctly based on the defined locals. -### [`QueryTests`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests/QueryTests.cs) -- The [`QueryTests.cs`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests/QueryTests.cs) class contains tests to validate that the user gets the correct results when searching. +### [`QueryTests`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/QueryTests.cs) +- The [`QueryTests.cs`](/src/modules/launcher/Plugins/Microsoft.PowerToys.Run.Plugin.Calculator.UnitTest/QueryTests.cs) class contains tests to validate that the user gets the correct results when searching.