8246 Commits

Author SHA1 Message Date
Leilei Zhang
add49a59ad fix cmdpal uitest 2025-08-21 17:25:35 +08:00
Shawn Yuan
44d34e45c0
Add telemetry for shortcut conflict detection feature. (#41271)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
Add telemetry for shortcut conflict detection.

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

---------

Signed-off-by: Shawn Yuan <shuaiyuan@microsoft.com>
Signed-off-by: Shuai Yuan <shuai.yuan.zju@gmail.com>
2025-08-21 09:27:01 +08:00
Jiří Polášek
3c0af323bf
CmdPal: Add Acrylic backdrop to the context menu and tweak its style (#41136)
## Summary of the Pull Request

- Adds acrylic backdrop to the context menu
- Tweaks border of the context menu to match CmdPal aesthetics
- Acrylic backdrop requires ShouldConstrainToRootBounds="False",
otherwise the backdrop is not rendered

After:

Video:



https://github.com/user-attachments/assets/e32741a3-6bbb-4064-9e7f-84d7551b5164


Still:

<img width="1007" height="1313" alt="image"
src="https://github.com/user-attachments/assets/d6a7bd6a-d5d8-4674-9062-91f496f49f0c"
/>


<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #41134
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-20 18:32:03 -05:00
Michael Jolley
e0097c94c6
Adding app icon to run context menu item in all apps ext (#40991)
Closes #40978

All apps extension's "Run" command now has the apps icon if available.

<img width="1197" height="741" alt="image"
src="https://github.com/user-attachments/assets/96ce75cb-cc6e-4176-bf4f-c92c2842b258"
/>
2025-08-20 17:54:01 -05:00
Pedro Lamas
e1086726ec
Fixes bgcode handlers registration (#40985)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [X] Closes: #30352
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

This is a follow up on #38667 and specifically addresses some of the
comments that GitHub Copilot review pointed out.

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

(Manual validation only)
2025-08-20 17:20:14 +08:00
leileizhang
759f5c02cb
[Cmdpal] Use DynamicDependency to preserve trimmed Adaptive Card action types (#41027)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
1. Preserve Adaptive Card action types during trimming using
DynamicDependency
2. Revert PR https://github.com/microsoft/PowerToys/pull/41010

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #40979
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-20 16:47:38 +08:00
Yu Leng
e0428eef1d
[CmdPal] Add WinAppSDK dependency in SamplePageExtension And ProcessMonitorExtension (#41274)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
To be honest, I don't know why we need it. But without this dependency,
I can not deploy in my local env.

How to repro:
1. Pull main branch.
2. Git clean -xfd (clean up the output path)
3. Click deploy in the VS

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

Co-authored-by: Yu Leng <yuleng@microsoft.com>
2025-08-20 16:26:14 +08:00
Yu Leng
3bc746d0ff
[CmdPal][UnitTests] Add/Migrate unit test for Apps and Bookmarks extension (#41238)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
1. Create Apps and Bookmarks ut project.
2. Refactor Apps and Bookmarks. And some interface in these extensions
to add a abstraction layer for testing purpose.
New interface list:
* ISettingsInterface
* IUWPApplication
* IAppCache
* IBookmarkDataSource
3. Add/Migrate some test case for Apps and Bookmarks extension

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #41239 #41240
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [x] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

---------

Co-authored-by: Yu Leng <yuleng@microsoft.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-08-20 16:25:46 +08:00
Shawn Yuan
75526b9580
[Feature] PowerToys hotkey conflict detection (#41029)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
Implements comprehensive hotkey conflict detection and resolution system
for PowerToys, providing real-time conflict checking and centralized
management interface.

## PR Checklist

- [ ] **Closes:** #xxx
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [x] **Localization:** All end-user-facing strings can be localized
- [x] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [x] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: [Shortcut conflict detction dev
spec](https://github.com/MicrosoftDocs/windows-dev-docs/pull/5519)

## TODO Lists
- [x] Add real-time hotkey validation functionality to the hotkey dialog
- [x] Immediately detect conflicts and update shortcut conflict status
after applying new shortcuts
- [x] Return conflict list from runner hotkey conflict detector for
conflict checking.
- [x] Implement the Tooltip for every shortcut control 
- [x] Add dialog UI for showing all the shortcut conflicts
- [x] Support changing shortcut directly inside the shortcut conflict
window/dialog, no need to nav to the settings page.
- [x] Redesign the `ShortcutConflictDialogContentControl` to align with
the spec
- [x] Add navigating and changing hotkey auctionability to the
`ShortcutConflictDialogContentControl`
- [x] Add telemetry. Impemented in [another
PR](https://github.com/shuaiyuanxx/PowerToys/pull/47)

## Shortcut Conflict Support Modules

![image](https://github.com/user-attachments/assets/3915174e-d1e7-4f86-8835-2a1bafcc85c9)

<details>
<summary>Demo videos</summary>


https://github.com/user-attachments/assets/476d992c-c6ca-4bcd-a3f2-b26cc612d1b9


https://github.com/user-attachments/assets/1c1a2537-de54-4db2-bdbf-6f1908ff1ce7


https://github.com/user-attachments/assets/9c992254-fc2b-402c-beec-20fceef25e6b


https://github.com/user-attachments/assets/d66abc1c-b8bf-45f8-a552-ec989dab310f
</details>

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
Manually validation performed.

---------

Signed-off-by: Shawn Yuan <shuaiyuan@microsoft.com>
Signed-off-by: Shuai Yuan <shuai.yuan.zju@gmail.com>
Co-authored-by: Niels Laute <niels.laute@live.nl>
2025-08-20 09:31:52 +08:00
Mike Griese
ce4d8dc11e
CmdPal: Clean up ListItemViewModels when we no longer need them (#41169)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
_We already fixed one leak, yes, but what about second leak?_

We already clean up `ListItemViewModel`s for a page when the page is
navigated away from. However, if the page updates it's items, we would
never actually `Cleanup` the old items. We'd just lose them, and never
unregister their event handlers. The objects would just leak forever.

This builds on the work in #41166, to do two things:
* Cleanup items that were removed from our list, when we actually update
`Items`. This involved a change to `Toolkit.ListHelpers`, to let us know
which items were removed from the list during `InPlaceUpdateList`
* Cleanup items that are thrown out when we cancel a FetchItems. Those
items were constructed, and might have registered event handlers, even
if we never actually put them into `Items`.

_Targets #41166_

Closes #39837

Tested with the evil sample from #41158, and loading thousands and
thousands of items no longer causes us to leak memory like we're
Deepwater Horizon.
2025-08-19 16:02:38 -05:00
rluengen
917da2e07e
Remove all explicit dependencies from the toolkit and extensions api on WinAppSDK (#41261)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
This pull request removes the dependencies from the toolkit and the SDK
on WinAppSDK and WebView2. This allows clients of these APIs to have
their own version dependencies.

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ X] Closes: #41235 
- [ X] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ X] **Tests:** Added/updated and all pass
- [ X] **Localization:** All end-user-facing strings can be localized
- [ X] **Dev docs:** Added/updated
- [ X] **New binaries:** Added on the required places
- [ X] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ X] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ X] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ X] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ X] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

Co-authored-by: Ross Luengen <rossl@microsoft.com>
2025-08-19 15:53:41 -05:00
Niels Laute
ea6115f892
Remove debug dialog (#41250)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
Quality of life improvement for the dev loop: removing the dialog in
Settings, since we have a DEBUG header in the titlebar anyways.
2025-08-19 15:51:33 +02:00
Mike Griese
8dbff245d6
CmdPal: cancel fetching new items when we get another one (#41166)
This just adds a simple `CancellationToken` around
`ListViewModel.FetchItems()`. Now, when we start a second `FetchItems`
(in responce to a `RaiseItemsChanged`), we'll cancel the old one first.
That'll prevent a particularly long first `GetItems` call from returning
after a second one has already set the list.

Closes #41149

No longer repros the evil sample from #41158
2025-08-19 06:20:06 -05:00
Jiří Polášek
fa741470bc
CmdPal: Add local keyboard listener and use it to handle GoBack key (#41122)
## Summary of the Pull Request

Listener registers a hook on WH_KEYBOARD and raises an event when a key
is pressed down. Main window then uses it to handle the GoBack key that
we can't reach any other way.


<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Related to: #41011
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-19 05:54:27 -05:00
Deniz
446d8087a3
Update readme.md (#41150)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
The link to styling in developer documentation was not working. The path
was wrong.
<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [x] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-19 05:17:01 -05:00
Niels Laute
a0a8ce9f69
Adding Office / Copilot templates to KeyVisual (#41167)
Small change for #41161. For shortcuts in Settings, I guess we need to
figure out later how the Copilot/Office keys are mapped in our
shortcuts, but at least we have the right visual templates available.
2025-08-19 11:32:28 +02:00
Jiří Polášek
7b06fb3bdb
CmdPal: Remove constrain that keeps the context menu flyout in the bounds of the window (#41133)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
## Summary of the Pull Request

Added `ShouldConstrainToRootBounds="False"` to the Flyout element,
allowing it to extend beyond the bounds of its parent container. This
allows the menu to always open with top-left corner at the cursor
position as is common for the context menus.

This affects the menu only when opened as a context menu on the list
item (e.g. mouse right-click), not when opened from the Command Bar
(that opens same as before).

After screenshot:

<img width="834" height="589" alt="image"
src="https://github.com/user-attachments/assets/acb40e08-074e-4bae-afe7-87c6a73a6581"
/>


<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #41131 
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-19 14:32:16 +08:00
Mohammed Saalim K
6130d2ad39
Hosts: add “No leading spaces” option and honor it when saving (#41206)
## Summary of the Pull Request

Adds a new Hosts File Editor setting “No leading spaces” that prevents
prepending spaces to active lines when saving the hosts file (when any
entry is disabled). Default is Off to preserve current behavior.



## PR Checklist

- [x] Closes: #36386  

- [ ] Communication: N/A (small, scoped option)

- [x] Tests: Added/updated and all pass

- [x] Localization: New en-US strings added; other locales handled by
loc pipeline

- [ ] Dev docs: N/A

- [x] New binaries: None

- [x] Documentation updated: N/A



## Detailed Description of the Pull Request / Additional comments

- Settings surface:

  - `src/settings-ui/Settings.UI.Library/HostsProperties.cs`: add
`NoLeadingSpaces`

  - `src/modules/Hosts/HostsUILib/Settings/IUserSettings.cs`: add
`NoLeadingSpaces`

  - `src/modules/Hosts/Hosts/Settings/UserSettings.cs`: load/save value
from settings.json

  - `src/settings-ui/Settings.UI/ViewModels/HostsViewModel.cs`: expose
`NoLeadingSpaces`

  - `src/settings-ui/Settings.UI/SettingsXAML/Views/HostsPage.xaml`: new
SettingsCard toggle

  - `src/settings-ui/Settings.UI/Strings/en-us/Resources.resw`: add
`Hosts_NoLeadingSpaces.Header/Description`

- Writer change:

  - `src/modules/Hosts/HostsUILib/Helpers/HostsService.cs`: gate indent
with `anyDisabled && !_userSettings.NoLeadingSpaces`

- Tests:

  - `src/modules/Hosts/Hosts.Tests/HostsServiceTest.cs`:
`NoLeadingSpaces_Disabled_RemovesIndent`



Backward compatibility: default Off, current formatting unchanged unless
the user enables the option.



## Validation Steps Performed

- Automated: `HostsEditor.UnitTests` including
`NoLeadingSpaces_Disabled_RemovesIndent` passing.

- Manual:

  1. Run PowerToys (runner) as Admin.

  2. Settings → Hosts File Editor → enable “No leading spaces”.

  3. In editor, add active `127.0.0.10 example1` and disabled
`127.0.0.11 example2`; Save.

  4. Open `C:\Windows\System32\drivers\etc\hosts` in Notepad.

     - ON: active line starts at column 0; disabled is `# 127...`.

     - OFF: active line begins with two spaces when a disabled entry
exists.
2025-08-19 13:58:10 +08:00
Mike Griese
8737de29af
CmdPal: mark CommandProvider.Dispose as virtual (#41184)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
If your provider wants to implement this, they should be able to
2025-08-18 16:52:49 -05:00
Mike Griese
2f6876b85f
CmdPal: Add a couple evil samples for testing (#41158)
This doesn't fix any bugs, it just makes them easier to repro

RE: #38190
RE: #41149
also accidentally a great example for RE: #39837
2025-08-18 16:46:36 -05:00
Jiří Polášek
8f93d0269f
CmdPal: Honor "Single-click activation" only for pointer clicks and not for keyboard (#41119)
## Summary of the Pull Request

Changes the behavior of keyboard item activation when the item list view
has focus.
Previously, the list view handled item activation according to the
"Single-click activation" setting regardless of the input source (mouse,
pen, touch, or keyboard).

Now, when handling a ListView item click, the input source is detected,
and the "Single-click activation" setting is applied only for
pointer-raised clicks. For keyboard-triggered clicks, items are always
activated immediately.

Since the event `ListView.ItemClick` doesn't provide information about
what caused the item activation, this PR work around that by observing
last user input on the list immediately before `ItemClick` event is
invoked.

## PR Checklist

- [x] Closes: #41101
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-18 16:46:08 -05:00
Jiří Polášek
d2a4c96e12
CmdPal: Prevent disposed ContentPage from handling messages (#41083)
## Summary of the Pull Request

Changes the timing of when `ContentPage` registers to messages from the
Toolkit Messenger so it happens only when navigated to, mirroring the
unregister on navigation from. Also unregisters from all messages when
unloaded.

Proactively unregisters the Settings window from all messages on close
instead of relying on the GC’s nondeterministic cleanup. Since the
Settings window is newly created each time, old instances can still
react to messages even after their time is over, merely waiting for GC
to collect them.

Co-authored-by: zadjii-msft <migrie@microsoft.com>


## PR Checklist

- [x] Closes: #40846 
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-18 11:45:25 -05:00
Jiří Polášek
409ae3d73a
CmdPal: Improve page exception details for users (#41035)
## Summary of the Pull Request

Show timestamp, HRESULT (hex/decimal), and full Exception.ToString() in
the error message. Centralize message generation in a helper class for
consistency.

Example:

```
============================================================
😢 An unexpected error occurred in the 'Open' extension.

Summary:
  Message:    Operation is not valid due to the current state of the object. (inferred from HRESULT 0x80131509)
  Type:       System.Runtime.InteropServices.COMException
  Source:     WinRT.Runtime
  Time:       2025-08-07 15:54:20.4189499
  HRESULT:    0x80131509 (-2146233079)

Stack Trace:
   at WinRT.ExceptionHelpers.<ThrowExceptionForHR>g__Throw|38_0(Int32 hr)
   at ABI.Microsoft.CommandPalette.Extensions.IListPageMethods.GetItems(IObjectReference _obj)
   at Microsoft.CmdPal.Core.ViewModels.ListViewModel.FetchItems()
   at Microsoft.CmdPal.Core.ViewModels.ListViewModel.InitializeProperties()
   at Microsoft.CmdPal.Core.ViewModels.PageViewModel.InitializeAsync()

------------------ Full Exception Details ------------------
System.Runtime.InteropServices.COMException (0x80131509)
   at WinRT.ExceptionHelpers.<ThrowExceptionForHR>g__Throw|38_0(Int32 hr)
   at ABI.Microsoft.CommandPalette.Extensions.IListPageMethods.GetItems(IObjectReference _obj)
   at Microsoft.CmdPal.Core.ViewModels.ListViewModel.FetchItems()
   at Microsoft.CmdPal.Core.ViewModels.ListViewModel.InitializeProperties()
   at Microsoft.CmdPal.Core.ViewModels.PageViewModel.InitializeAsync()

ℹ️ If you need further assistance, please include this information in your support request.
ℹ️ Before sending, take a quick look to make sure it doesn't contain any personal or sensitive information.
============================================================

```

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #41034
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

## Validation Steps Performed

I crashed an extension on purpose and read the message.
2025-08-18 11:31:41 -05:00
Heiko
65b752b3ff
[CmdPal > Ext] Use empty content for WindowWalker, Windows Settings and Windows Search (#40722)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request

This PR improves the behavior of CmdPal on empty or wrong search query
for the following exts:
- Window Walker
- Windows Settings
- Windows Search (indexer)

### Window Walker
<img width="795" height="482" alt="image"
src="https://github.com/user-attachments/assets/352a122d-2b8f-45be-bf49-6a56f6ca0848"
/>

### Windows Settings - Empty query
<img width="796" height="485" alt="image"
src="https://github.com/user-attachments/assets/12f193b3-22c5-45d8-89c0-bba5740da62b"
/>

### Windows Settings - No search match
<img width="855" height="483" alt="image"
src="https://github.com/user-attachments/assets/e521f63d-65ae-4b93-992d-2bb0a11edaa7"
/>

### Windows search (indexer)
<img width="796" height="483" alt="image"
src="https://github.com/user-attachments/assets/c2e6a218-de2b-4657-a9e7-9def26c9258e"
/>



<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] **Closes:** #40614 , #38293 , #40565
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [x] **Tests:** Added/updated and all pass
- [x] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

---------

Co-authored-by: Niels Laute <niels.laute@live.nl>
Co-authored-by: Mike Griese <migrie@microsoft.com>
2025-08-18 11:22:26 -05:00
Michael Jolley
6acb793184
CmdPal: Null pattern matching based on is expression rather than overridable operators (#40972)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
What the title says. 😄 

Rather than relying on the potentially overloaded `!=` or `==` operators
when checking for null, now we'll use the `is` expression (possibly
combined with the `not` operator) to ensure correct checking. Probably
overkill for many of these classes, but decided to err on the side of
consistency. Would matter more on classes that may be inherited or
extended.

Using `is` and `is not` will provide us a guarantee that no
user-overloaded equality operators (`==`/`!=`) is invoked when a
`expression is null` is evaluated.

In code form, changed all instances of:

```c#
something != null

something == null
```

to:

```c#
something is not null

something is null
```

The one exception was checking null on a `KeyChord`. `KeyChord` is a
struct which is never null so VS will raise an error when trying this
versus just providing a warning when using `keyChord != null`. In
reality, we shouldn't do this check because it can't ever be null. In
the case of a `KeyChord` it **would** be a `KeyChord` equivalent to:

```c#
KeyChord keyChord = new ()
{
    Modifiers = 0,
    Vkey = 0,
    ScanCode = 0
};
```
2025-08-18 06:07:28 -05:00
Dustin L. Howett
efb48aa163
build: remove *tests* and all coverage/DIA DLLs from binskim (#41108)
This thing files about 900 bugs a month on us.

Before:

```
Done. 11,036 files scanned.
```

After:

```
Done. 4,753 files scanned.
```
2025-08-18 06:00:13 -05:00
leileizhang
e8754e4cd6
Fix: Move ImageResizer satellite resource dlls under WinUI3Apps<culture> (#41152)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
### Root cause:
Problem Previously the installer installed ImageResizer satellite
assemblies into [INSTALLFOLDER]<culture>*.dll. The runtime probes
WinUI3Apps<culture>\ for WinUI3 app resource assemblies, so localization
failed.

### Fix:
Updated Resources.wxs: ImageResizer_$(var.IdSafeLanguage)_Component now
targets
Directory="Resource$(var.IdSafeLanguage)WinUI3AppsInstallFolder".

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #41142
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

## AI Summary
This pull request updates the installer configuration in `Resources.wxs`
to support resource management for WinUI 3 apps. The main changes ensure
that resource directories and uninstall logic properly handle the new
`WinUI3AppsInstallFolder`, and update the component registration for
localized resources.

**Installer resource management updates:**

* Added `WinUI3AppsInstallFolder` to the list of parent directories for
resource file generation, ensuring resources for WinUI 3 apps are
included during installer builds.

**Component and uninstall logic updates:**

* Updated the `ImageResizer` component to register its resources under
`Resource$(var.IdSafeLanguage)WinUI3AppsInstallFolder` instead of the
default install folder, aligning with the new directory structure for
WinUI 3 apps.
* Added uninstall logic to remove the localized resource folder for
`WinUI3AppsInstallFolder`, ensuring cleanup of WinUI 3 app resources
during uninstall.
2025-08-18 10:18:47 +08:00
Jiří Polášek
c4c9277f3f
CmdPal: Fix regression when updating a command provider without commands (#40984)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Improves item insertion logic in TopLevelCommandManager.

Updated the insertion logic to handle invalid startIndex values. If
startIndex is -1, new items will be appended to the end of the
collection, enhancing robustness.

Fixes regression introduced in #40752

<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-15 09:17:57 -05:00
Jiří Polášek
67cd0f055c
CmdPal: Check icon parent before adding in ContentIcon (Closes: #40928) (#40931)
## Summary of the Pull Request

This pull request introduces a minor but important update to the
`ContentIcon` control in the `Microsoft.CmdPal.UI` module. The changes
improve robustness by adding checks to prevent duplicate parenting of
the `Content` element and include a debug assertion for better
diagnostics during development.

## PR Checklist

- [x] Closes: #40928 
- [ ] **Communication:** not yet
- [ ] **Tests:** nope
- [ ] **Localization:** none
- [ ] **Dev docs:** nay
- [ ] **New binaries:** no nothing
- [ ] **Documentation updated:** too lazy for that

## Detailed Description of the Pull Request / Additional comments

### Key changes:

#### Diagnostics and robustness improvements:
* Added a `Debug.Assert` statement to verify that the `Content` element
is not already parented to another element, helping to catch potential
issues during development.
(`[src/modules/cmdpal/Microsoft.CmdPal.UI/Controls/ContentIcon.csR39-R49](diffhunk://#diff-330aad69f925cf7a9e07bb7147af8e6cd09776a4c745455ac8a91a24b482d076R39-R49)`)
* Introduced checks to ensure the `Content` element is not added to the
`Grid`'s `Children` collection if it already exists there, preventing
redundant operations.
(`[src/modules/cmdpal/Microsoft.CmdPal.UI/Controls/ContentIcon.csR39-R49](diffhunk://#diff-330aad69f925cf7a9e07bb7147af8e6cd09776a4c745455ac8a91a24b482d076R39-R49)`)

#### Code maintenance:
* Added a `using System.Diagnostics` directive to enable the use of the
`Debug` class for assertions.
(`[src/modules/cmdpal/Microsoft.CmdPal.UI/Controls/ContentIcon.csR5](diffhunk://#diff-330aad69f925cf7a9e07bb7147af8e6cd09776a4c745455ac8a91a24b482d076R5)`)

## Validation Steps Performed

Turned extensions off and on and off and on and off and on and off and
on and off and on and off and on and off and on and off and on and off
and on and off and on and off and on and off and on and off and on and
off and on and off and on.
And then off and on again, just to be sure.

---------

Co-authored-by: Mike Griese <migrie@microsoft.com>
2025-08-15 06:48:54 -05:00
Jiří Polášek
051c07885e
CmdPal: Replace the brush used for the menu item separator (#41130)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
## Summary of the Pull Request

Replace the brush used for the menu item separator in
SeparatorContextMenuViewModelTemplate with the brush used by WinUI 3 for
flyout menus.

The brush previously used is a legacy brush and a WinUI trap.

After screenshot:

<img width="830" height="513" alt="image"
src="https://github.com/user-attachments/assets/32620050-29a3-40a5-aa6a-fe83afb55090"
/>


## PR Checklist

- [x] Closes: #41128
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-14 10:52:37 -05:00
Jiří Polášek
a5b9a38517
CmdPal: Bring existing Settings window to the foreground when opened (#41087)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
## Summary of the Pull Request

Adds extra BringToFront after Activate. Don't ask.

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #41086
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-13 13:48:07 -05:00
Jiří Polášek
7a3616e996
CmdPal: Replace Clipboard History extension outline icon with colorful icon (#41012)
## Summary of the Pull Request

Replace Clipboard History extension icon with an icon derived from
Fluent UI System Color set
(https://github.com/microsoft/fluentui-system-icons/). Icon is under MIT
license.

<img width="786" height="473" alt="image"
src="https://github.com/user-attachments/assets/6b9471d8-c98f-45c7-85e3-9521ce2a9717"
/>

## PR Checklist

- [x] Closes: #41018
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx


## Detailed Description of the Pull Request / Additional comments


## Validation Steps Performed

I looked at the icon in the top-level list. Looks nice.
I looked at the icon in the settings page. Also looks nice.
2025-08-13 13:45:47 -05:00
Jiří Polášek
b36530bf87
CmdPal: Fix race condition in SupersedingAsyncGate cancellation handling [MSH] (#40983)
## Summary of the Pull Request

Change SetCanceled to TrySetCanceled in OperationCanceledException
handler to prevent InvalidOperationException when external and internal
cancellation tokens complete the TaskCompletionSource simultaneously.


<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #40982
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** none
- [ ] **Localization:** nope
- [ ] **Dev docs:** none
- [ ] **New binaries:** none
- [ ] **Documentation updated:** none

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-13 13:44:31 -05:00
Jessica Dene Earley-Cha
e260c01553
CmdPal: Setting Activation Shortcut now auto focuses on window & delivers dialog (#40968)
## Summary of the Pull Request
Screen readers now will focus on the activation shortcut windows and
read out the text

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #40967
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments


<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed


https://github.com/user-attachments/assets/d72a9aea-28b8-49d1-b51f-7a7d2a8ff42f
2025-08-13 13:43:54 -05:00
Mike Griese
7f4a97cac5
CmdPal: extension nuget should target a lower windows SDK version (#40902)
related to some #40113 work

The extension SDK shouldn't rely on a preview version of the Windows
SDK. It should use the stable one.

Also moves some messages around that we didn't need
2025-08-13 13:42:52 -05:00
Davide Giacometti
ab76dd1255
[CmdPal] Search PATH starting with ~ / \ (#40887)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request

Love that we have now environment variables expanding! 🚀 
Porting also few small features I implemented in Run Folder plugin a
long time ago and I love:
- https://github.com/microsoft/PowerToys/pull/7711
- https://github.com/microsoft/PowerToys/pull/9579

Threat `/` and `\` as root of system drive (typically `C:\`)
Threat `~` as user home directory `%USERPROFILE%`

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<img width="591" height="356" alt="image"
src="https://github.com/user-attachments/assets/9c1f196a-bd4d-428c-a4e6-af9f269acd1f"
/>

<img width="591" height="356" alt="image"
src="https://github.com/user-attachments/assets/4295ebca-f12b-43b0-b3d0-c130b6faf419"
/>


<img width="591" height="356" alt="image"
src="https://github.com/user-attachments/assets/87748864-e250-4141-b366-29b45d58edcf"
/>

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

- Tested search starting with `~` `/` `\`
- Tested UNC network path starting with `\\...` and `//...`
2025-08-13 13:42:40 -05:00
Dustin L. Howett
911989bac1
store: update package catalog before running install (#41121)
It's actually failing because we're bad at... Linux?
2025-08-13 11:01:25 -05:00
Gordon Lam
c690cb1bb8
Initial draft for 0.93 release note (#41036)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request

## AI Summary
This pull request updates the `README.md` to document the 0.93 (August
2025) release of Microsoft PowerToys. It introduces a new, modern
settings dashboard, details major improvements and new features across
multiple modules, and updates installation links and documentation. The
release focuses on enhanced user experience, accessibility, performance,
stability, and test coverage.

Most important changes:

**Release and Installation Updates**
- Updated all installer links and release references from version 0.92.1
to 0.93.0, and milestone tracking for the next release to 0.94.
- Updated the release highlights and version number to reflect the 0.93
(August 2025) release, with a summary of new features and improvements.

**Settings and User Experience**
- Introduced a completely redesigned, card-based settings dashboard with
clearer descriptions, faster navigation, and improved release notes
formatting for a better user experience.
- Rewrote setting descriptions for clarity and consistency, added deep
link support to specific settings pages, and fixed various UI/UX issues
in the settings module.

**Command Palette and Extensions**
- Resolved over 99 issues in Command Palette, including accessibility
improvements, context menu enhancements, new navigation shortcuts, AOT
compilation mode (reducing install size and memory usage), and
re-enabled Clipboard History.
- Added new settings and features to Command Palette extensions, such as
command history in Run, improved Apps extension handling, and new
context menu options.

**Module Improvements and New Features**
- Mouse Utilities: Added a new spotlight highlighting mode for
presentations.
- Peek: Added instant previews and embedded thumbnail support for Binary
G-code (.bgcode) 3D printing files.
- Quick Accent: Added Vietnamese language support.

**Development, Testing, and Documentation**
- Upgraded .NET libraries and spell check system, improved CI pipelines,
reduced test timeouts, and added over 600 new unit tests (mainly for
Command Palette), doubling UI automation coverage.
- Added detailed developer documentation, fixed broken SDK links, and
documented new community plugins.

Other minor changes:
- Standardized naming, improved spelling, and cleaned up configuration
files for smoother development.
- Minor capitalization fix for "Mouse Utilities" in the utilities table.
2025-08-13 17:19:06 +02:00
Yu Leng
c23dcb0c5a
[CmdPal][UT] Refactor some cmdpal ext's ut and improve the test case (#40896)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
1. Remove some AI generated nonsense case
2. Add ISettingsInterface for those ext for testing purpose.
3. Add query test.

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #40897
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [x] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

---------

Co-authored-by: Yu Leng <yuleng@microsoft.com>
2025-08-12 18:27:10 +08:00
Kai Tao
3682f186e3
Mouse highlighter spotlight mode, fix the gpu perf issue (#41079)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
The big border solution for implementing the spotlight mode is gpu
consuming, switch to a resource friendly implementation.

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

| Before | After | 
|----------|----------|
| <img width="739" height="263" alt="image"
src="https://github.com/user-attachments/assets/b369801a-4cda-44e8-968b-d76586931c8c"
/>| <img width="1031" height="319" alt="image"
src="https://github.com/user-attachments/assets/9b21c96d-f5ce-4ff7-8662-0c4e6e075976"
/>|
v0.93.0
2025-08-12 10:55:24 +08:00
Yu Leng
1eae1d9a12
[AOT] Remove rd.xml from CmdPal (#41031)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
Actually, we don't need to use rd.xml to preserve type. We can add
attribute to do the same things.

Tested in this build:
https://microsoft.visualstudio.com/Dart/_build/results?buildId=127875892&view=artifacts&pathAsName=false&type=publishedArtifacts

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #40633
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [x] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

---------

Co-authored-by: Yu Leng (from Dev Box) <yuleng@microsoft.com>
2025-08-12 07:44:23 +08:00
Mike Griese
bc134b344b
CmdPal: Make sure to include apps in the ctor (#41081)
A regression from #40132 

We need to set the value of `_includeApps` in the `MainListPage` ctor.
Without it, if the user doesn't have any extensions installed, the value
is never updated.
2025-08-12 07:43:08 +08:00
Jiří Polášek
04b8234192
CmdPal: Fix styles applied to MoreCommandsButton (#41059)
## Summary of the Pull Request

- Apply the same padding to the button as used for primary and secondary
command buttons.
- Use consistent spacing between keycap blocks.
- Match keycap border style and inner text brush with other command
buttons.
- Add min width constraint to shortcut keycap element to make it at
least square.

<img width="961" height="355" alt="image"
src="https://github.com/user-attachments/assets/cff5ef7e-fe67-41ac-9796-063c0e69768a"
/>


<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #41052
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

## Detailed Description of the Pull Request / Additional comments

## Validation Steps Performed
👀
2025-08-11 18:12:05 -05:00
Shawn Yuan
d72e0ab20d
Fixed toggle switch not working issue. (#41049)
Some checks failed
Spell checking / Check Spelling (push) Has been cancelled
Spell checking / Report (Push) (push) Has been cancelled
Spell checking / Report (PR) (push) Has been cancelled
Spell checking / Update PR (push) Has been cancelled
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
Fixed toggle switch not working issue.

## AI Summary
This pull request refactors how `DashboardListItem` objects are created
and added to collections in the `DashboardViewModel`. The main
improvement is to separate the instantiation of each `DashboardListItem`
from the assignment of its `EnabledChangedCallback` property, which is
now set after the object is added to the relevant collection. This
change improves clarity and may help prevent issues related to object
initialization order.

Refactoring of `DashboardListItem` creation and initialization:

* In the `AddDashboardListItem` method, the `DashboardListItem` object
is now created and added to `AllModules` before its
`EnabledChangedCallback` property is set, instead of setting this
property during object initialization.
* In the `GetShortcutModules` method, both `ShortcutModules` and
`ActionModules` collections now receive `DashboardListItem` objects that
are instantiated first, added to the collection, and then have their
`EnabledChangedCallback` property set. This replaces the previous
pattern of setting the callback during object creation.
[[1]](diffhunk://#diff-aea3404667e7a3de2750bf9ab7ee8ff5e717892caa68ee1de86713cf8e21b44cL123-R136)
[[2]](diffhunk://#diff-aea3404667e7a3de2750bf9ab7ee8ff5e717892caa68ee1de86713cf8e21b44cL144-R159)
* 
<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [x] Closes: #41046
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments
It is an regression from
https://github.com/microsoft/PowerToys/pull/40214

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

---------

Signed-off-by: Shuai Yuan <shuai.yuan.zju@gmail.com>
2025-08-08 22:55:00 +08:00
Kai Tao
062234c295
Settings: Mouse utils setting crash (#41050)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
Fix a crash in settings page due to not found converter
<!-- Please review the items on the PR checklist before submitting-->

## AI Summary
This pull request makes a small update to the `MouseUtilsPage.xaml` file
to use the correct resource for converting boolean values to visibility
states in the UI.

- Updated the `Visibility` binding on an `InfoBar` to use the
`ReverseBoolToVisibilityConverter` instead of the incorrect
`BoolToReverseVisibilityConverter` resource.

## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments
Regression caused by https://github.com/microsoft/PowerToys/pull/40214

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
<img width="1983" height="1072" alt="image"
src="https://github.com/user-attachments/assets/13c806c3-e7af-4615-a649-6d58d8fe877b"
/>
2025-08-08 16:38:46 +08:00
Jeremy Sinclair
0d4f3d851e
[Deps] Update .NET packages from 9.0.7 to 9.0.8 (#41039)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
Updates .NET 9 Runtime / Library packages to the latest 9.0.8 servicing
release.

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-08 08:28:01 +08:00
Mike Griese
e93b044f39
CmdPal: Once again, I am asking you to fix form submits (#41010)
Closes #40979

Usually, you're supposed to try to cast the action to a specific
type, and use those objects to get the data you need.
However, there's something weird with AdaptiveCards and the way it
works when we consume it when built in Release, with AOT (and
trimming) enabled. Any sort of `action.As<IAdaptiveSubmitAction>()`
or similar will throw a System.InvalidCastException.

Instead we have this horror show.

The `action.ToJson()` blob ACTUALLY CONTAINS THE `type` field, which
we can use to determine what kind of action it is. Then we can parse
the JSON manually based on the type.
2025-08-06 19:41:02 -05:00
leileizhang
fed6e523b6
Fix: used wrong preview resize event from another handler (#40995)
<!-- Enter a brief description/summary of your PR here. What does it
fix/what does it change/how was it tested (even manually, if necessary)?
-->
## Summary of the Pull Request
Bug: Was using GcodePreviewResizeEvent, which will never work — switched
to use Bgcode's own event

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed

## AI Summary
This pull request makes a minor update to the event handling in the
preview pane module. The change updates the event constant used for
resizing the preview from `GcodePreviewResizeEvent` to
`BgcodePreviewResizeEvent`, likely to improve naming consistency or to
support a new event type.
2025-08-06 14:12:37 +08:00
Jiří Polášek
0997c1a013
CmdPal: Coalesce top-level commands list changes into a single task (#40943)
## Summary of the Pull Request

Self-refresh of `MainListPage` introduced in #40132 causes unnecessary
spawning of tasks by `ReapplySearchInBackground` and pushing the code
down the scenic route instead of taking shortcut.

This drop-in fix introduces a single-worker coalescing refresh loop to
eliminate thread-pool churn and syncs state in early-return paths.

## PR Checklist

- [x] Closes: #40916
- [x] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** no change
- [ ] **Localization:** nothing
- [ ] **Dev docs:** nothing
- [ ] **New binaries:** none
- [ ] **Documentation updated:** nothing

<!-- Provide a more detailed description of the PR, other things fixed,
or any additional comments/features here -->
## Detailed Description of the Pull Request / Additional comments

<!-- Describe how you validated the behavior. Add automated tests
wherever possible, but list manual validation steps taken as well -->
## Validation Steps Performed
2025-08-05 16:26:50 -05:00
Jiří Polášek
fa55cdb67f
CmdPal: properly dispose of the old backdrop controller (#40986)
## Summary of the Pull Request

Properly disposes the old DesktopAcrylicController when replacing it
with a new instance.

## PR Checklist

- [ ] Closes: #xxx
- [ ] **Communication:** I've discussed this with core contributors
already. If the work hasn't been agreed, this work might be rejected
- [ ] **Tests:** Added/updated and all pass
- [ ] **Localization:** All end-user-facing strings can be localized
- [ ] **Dev docs:** Added/updated
- [ ] **New binaries:** Added on the required places
- [ ] [JSON for
signing](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ESRPSigning_core.json)
for new binaries
- [ ] [WXS for
installer](https://github.com/microsoft/PowerToys/blob/main/installer/PowerToysSetup/Product.wxs)
for new binaries and localization folder
- [ ] [YML for CI
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/ci/templates/build-powertoys-steps.yml)
for new test projects
- [ ] [YML for signed
pipeline](https://github.com/microsoft/PowerToys/blob/main/.pipelines/release.yml)
- [ ] **Documentation updated:** If checked, please file a pull request
on [our docs
repo](https://github.com/MicrosoftDocs/windows-uwp/tree/docs/hub/powertoys)
and link it here: #xxx

## Detailed Description of the Pull Request / Additional comments


## Validation Steps Performed
2025-08-05 16:26:22 -05:00