Fix: Remove the option to Pin to Sidebar for the Libraries root - #18928
Open
JorgChrist wants to merge 1 commit into
Open
Fix: Remove the option to Pin to Sidebar for the Libraries root#18928JorgChrist wants to merge 1 commit into
JorgChrist wants to merge 1 commit into
Conversation
yair100
force-pushed
the
main
branch
5 times, most recently
from
September 7, 2026 22:51
0b848cc to
3a7c7ed
Compare
JorgChrist
force-pushed
the
fix/16857-pin-libraries-root
branch
from
September 8, 2026 08:36
3b3a36c to
b28b5a5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolved / Related Issues
Steps used to test these changes
%APPDATA%\Microsoft\Windows\Libraries. "Pin to Sidebar" is no longer an option.%APPDATA%\Microsoft\Windows, selected theLibrariesfolder and opened the context menu. Also no longer an option.Context
Full investigation is in the comment of issue #16857. Windows silently refuses the
pintohomeverb for the Libraries root when it's invoked programmatically:IContextMenu::InvokeCommandreturns S_OK and nothing is written to Quick Access. It's not specific to Files, invoking the same verb throughShell.Applicationfrom PowerShell behaves identically. File Explorer can create the pin but once it exists it can't be removed again from Files, Explorer orShell.Application, so a user who tries this ends up with a sidebar entry they can only get rid of by deleting the Quick Access store.Since the pin can never succeed, hiding the option seemed better than letting it silently do nothing. This matches how
ContentPageTypes.RecycleBinis already handled at the top ofGetIsExecutable.One thing I'd like input on
This covers the case where the folder is addressed by its file system path. When it's reached through the shell namespace (
shell:Libraries),ItemPathis the\\SHELL\<base64 PIDL>form instead and isn't caught, so the option still shows there.I left it out because catching it means decoding the PIDL inside a synchronous predicate and I didn't want to add that without asking. I can fix that as well if you are okay with it.