Commit graph

409 commits

Author SHA1 Message Date
Jack Ye
984b3dabdc
Fix Explorer plugin Quick Access items missing from general search results (#4294)
Some checks failed
Build / build (push) Has been cancelled
2026-03-04 21:25:25 +11:00
Diego Henrique
9066913710
[FEATURE] Folder and File Action Keywords (#4093) 2025-12-14 12:18:21 +02:00
Jack Ye
48f67b1886
Improve and fix query result update logic issue & provide access to exact query typed by user (#3502) 2025-11-26 21:15:12 +11:00
Jack251970
2adbc334a2 Improve semaphore lock handling and code robustness
Added `lockAcquired` flags in `PluginsManifest.cs` and `Main.cs`
to ensure semaphore locks are only released if successfully
acquired, preventing potential runtime errors. Updated `finally`
blocks to conditionally release locks based on these flags.

Removed redundant cancellation check in `EverythingAPI.cs` to
simplify code, assuming cancellation is handled elsewhere. These
changes enhance reliability and maintainability of the codebase.
2025-11-07 15:30:07 +08:00
Jack251970
88fd1e56d0 Handle OperationCanceledException gracefully
Added a `catch` block for `OperationCanceledException` in
`PluginsManifest.cs` to ignore canceled operations. Updated
`EverythingAPI.cs` to use cancellation tokens with `_semaphore.WaitAsync`
and handle cancellations by exiting the method cleanly with `yield break`.
2025-11-06 20:47:54 +08:00
Jack251970
49f89e33b5 Make locking operations cancelable with tokens
Updated `_semaphore.WaitAsync` in `EverythingAPI.cs` to accept a `CancellationToken` and handle `OperationCanceledException` gracefully, returning `false` instead of propagating the exception.

Refactored locking mechanisms in `Main.cs` to use `CancellationToken` for `_win32sLock` and `_uwpsLock`. Added `try-catch` blocks to handle `OperationCanceledException` and ensure proper lock release. Methods now return `emptyResults` when operations are canceled.
2025-11-06 20:46:29 +08:00
Jack251970
d0a47c84b9 Clarify CancellationToken handling in comments
Updated comments to explain the rationale for not directly passing
CancellationToken to methods and instead checking
IsCancellationRequested within locks. This prevents unexpected
OperationCanceledException. Changes made in EverythingAPI.cs
(IsEverythingRunningAsync) and Main.cs (Win32 and UWP program
preparation). No functional changes to the code.
2025-11-06 15:39:19 +08:00
Jack251970
bfaff5cca5 Improve semaphore usage and logging clarity
Added comments in `EverythingAPI.cs` and `Main.cs` to explain
why `CancellationToken` is not directly passed to semaphore
locks, preventing unexpected `OperationCanceledException`.

Updated debug log messages in `Main.cs` for better clarity,
including changing "Start handling programs" to "Start querying
programs". Removed redundant log messages to improve logging
consistency.
2025-11-06 15:32:08 +08:00
Jack251970
30d7f67d42 Refactor token cancellation check for readability
Simplified the `if` statement that checks for token cancellation
by condensing it into a single line. This improves code readability
and eliminates unnecessary line breaks.
2025-11-06 15:30:32 +08:00
Jack251970
3d8fd1d352 Improve cancellation, locking, and logging mechanisms
Enhanced cancellation handling by adding `token.IsCancellationRequested` checks to improve responsiveness. Refactored locking mechanisms for `_win32sLock` and `_uwpsLock` using `try-finally` blocks to ensure proper acquisition and release, improving thread safety and preventing deadlocks.

Reorganized Win32 and UWP program querying logic for better modularity and readability. Replaced shared collection access with local variables to improve clarity and maintain thread safety. Simplified empty result handling by directly returning `emptyResults` when canceled.

Removed redundant debug log statements to reduce verbosity and updated remaining logs for clarity. Suppressed unused result warnings by replacing direct calls to `EverythingApiDllImport.Everything_GetMajorVersion()` with null-coalescing assignments.
2025-11-06 15:28:13 +08:00
Jack251970
db0c86d50c Remove CancellationToken from semaphore WaitAsync calls
Removed the `CancellationToken` parameter from `WaitAsync` calls
on semaphores in `EverythingAPI.cs` and `Main.cs`. This change
eliminates cancellation support for semaphore waits, likely due
to a design decision prioritizing simplicity or avoiding issues
with cancellation handling.

In `EverythingAPI.cs`, `WaitAsync(token)` was replaced with
`WaitAsync()` in two methods. Similarly, in `Main.cs`, the
`WaitAsync` calls for `_win32sLock` and `_uwpsLock` were updated
to remove the `token` parameter.

Note: This change may impact the ability to gracefully handle
cancellation during semaphore waits.
2025-11-04 14:25:55 +08:00
Diego Henrique
1bfd147421
BUG: Explorer plugin navigate path should only show results in current path (#4053) 2025-10-21 12:12:45 +11:00
Jack251970
78e5bf2a60 Use Flow.Launcher.Localization to improve code quality 2025-09-21 11:50:51 +08:00
Jeremy Wu
e1cc50c579 Merge remote-tracking branch 'origin/master' into resolve_conflicts 2025-08-31 17:53:21 +10:00
Jack Ye
54a2817962
Merge branch 'dev' into code_quality 2025-07-24 11:55:46 +01:00
Jack251970
3cfe122c7b Use new MonitorInfo class class 2025-07-23 13:51:35 +08:00
Jack Ye
ed0524d207
Merge branch 'dev' into code_quality 2025-07-20 20:02:51 +08:00
Kevin Zhang
4f269d3fa9
Dialog Jump - Quickly navigate the Open/Save As dialog window (#1018) 2025-07-20 21:11:09 +10:00
VictoriousRaptor
30f7ae0d67 Use Localization for Explorer plugin 2025-07-16 21:28:17 +08:00
VictoriousRaptor
e116668ef9 Rename file 2025-07-15 23:57:21 +08:00
Jack251970
d6310bc4f0 Add quick access result score for folder results 2025-06-28 11:02:44 +08:00
Jack251970
03c1e58922 Support volume type for quick access link 2025-06-28 11:00:56 +08:00
Jeremy Wu
7ae91b1af3
Release 1.20.1 | Plugin 4.6.0 (#3706) 2025-06-14 13:45:30 +03:00
Jack251970
b166b18ab7 Add preview information back for external preview 2025-06-12 14:25:10 +08:00
Jack Ye
a3f98a69b7
Merge branch 'dev' into PreviewMedia 2025-06-09 15:54:52 +08:00
Jack Ye
d04f493e57
Merge pull request #3631 from Flow-Launcher/file_tooltip
Support More Information for Files, Folders and Volumes Tooltips & Add Custom Preview Panel Support for Folder Results
2025-06-09 13:00:16 +08:00
DB P
8f10f4a9ee Add additional media file extensions to ResultManager 2025-06-09 11:06:40 +09:00
Jack251970
bdbd1e77e8 Remove blank lines 2025-06-07 14:12:06 +08:00
Jack Ye
37cab1b30c
Merge branch 'dev' into rename-quick-access-links 2025-06-07 13:39:00 +08:00
Jack Ye
d0c240f50f
Merge branch 'dev' into file_tooltip 2025-06-06 20:09:02 +08:00
Jack251970
7d5001de18 Catch exception when installing Everything 2025-06-05 18:16:13 +08:00
Jack251970
4c7a4fec1f Add more info tooltip support for volumes 2025-06-05 11:56:21 +08:00
Jack251970
ce0729923c Add try-catch for tooltip getter 2025-06-04 17:26:33 +08:00
Jack251970
85c038719e Support custom preview panel for folder results 2025-06-04 17:12:53 +08:00
Jack251970
f069ee9094 Show more info in file & folder tooltip 2025-06-04 17:01:46 +08:00
01Dri
3b425413a2 Edit access link 2025-05-25 04:31:08 -03:00
01Dri
59d5cd62bc AccessLink Refactor 2025-05-25 02:34:48 -03:00
Jack251970
222ef41c8f Fix nullabl warnings 2025-04-15 13:29:26 +08:00
Jack251970
50130e4b00 Use class name instead 2025-04-13 17:59:39 +08:00
Jack251970
a9748acd22 Code quality 2025-04-12 21:11:22 +08:00
Jack251970
022b345a4d Add readonly 2025-04-12 21:10:39 +08:00
Jack251970
625ddbc0e1 Code quality 2025-04-12 21:10:26 +08:00
Jack251970
dd9dc82ecf Fix Logical error in query constraint using System.Search.Rank 2025-04-12 21:06:52 +08:00
Jack251970
136a4aa1dd Code quality 2025-04-12 20:47:43 +08:00
Jack Ye
cd916b391f
Merge branch 'dev' into SearchOrderByRank 2025-04-12 20:40:22 +08:00
Jack251970
da8a69038a Improve code quality 2025-04-09 13:05:43 +08:00
Jack251970
9c07989edf Improve code quality 2025-04-09 12:14:07 +08:00
Jack251970
5ee110b3b7 Fix unix directory seperator issue 2025-02-07 16:42:01 +08:00
Jack251970
3ee3528e54 Revert "Fix unix directory seperator issue"
This reverts commit a3cc5e25f9.
2025-02-07 16:40:45 +08:00
Jack251970
a3cc5e25f9 Fix unix directory seperator issue 2025-02-07 16:05:35 +08:00