Skip to content

fix: avoid clearing active filter text in delayed desktop.ini task - #18819

Closed
marko1olo wants to merge 4 commits into
files-community:mainfrom
marko1olo:fix-filter-textbox-cleared
Closed

fix: avoid clearing active filter text in delayed desktop.ini task#18819
marko1olo wants to merge 4 commits into
files-community:mainfrom
marko1olo:fix-filter-textbox-cleared

Conversation

@marko1olo

Copy link
Copy Markdown
Contributor

Problem

Fixes #18807.

When opening a folder with the filter bar enabled, typing into the filter textbox shortly after navigation starts gets wiped out 1–2 seconds later when the directory load finishes.

Cause

NavigateToPath in ModernShellPage.xaml.cs already resets ShellViewModel.FilesAndFoldersFilter = null; when navigation begins. However, desktopIniUpdateTask was scheduled on DispatcherQueuePriority.Low and also set FilesAndFoldersFilter = null; upon completion, clearing whatever filter query the user had already entered while the folder was loading.

Solution

Remove the redundant and delayed FilesAndFoldersFilter = null; from desktopIniUpdateTask.

@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@Josh65-2201

Copy link
Copy Markdown
Member

Duplicate of #18809 also has many unnecessary changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: Filter textbox is cleared when typing right after opening a folder

3 participants