Skip to content

Commit e6477e8

Browse files
committed
Fix global query determination issue
1 parent 01f896a commit e6477e8

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

Flow.Launcher/ViewModel/MainViewModel.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1208,11 +1208,11 @@ private async Task QueryResultsAsync(bool searchDelay, bool isReQuery = false, b
12081208

12091209
_lastQuery = query;
12101210

1211-
if (query.ActionKeyword == Plugin.Query.GlobalPluginWildcardSign)
1211+
if (string.IsNullOrEmpty(query.ActionKeyword))
12121212
{
1213-
// Wait 45 millisecond for query change in global query
1213+
// Wait 15 millisecond for query change in global query
12141214
// if query changes, return so that it won't be calculated
1215-
await Task.Delay(45, _updateSource.Token);
1215+
await Task.Delay(15, _updateSource.Token);
12161216
if (_updateSource.Token.IsCancellationRequested)
12171217
return;
12181218
}

Flow.Launcher/ViewModel/ResultViewModel.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
using System;
2+
using System.Collections;
23
using System.Collections.Generic;
34
using System.Drawing.Text;
45
using System.IO;
@@ -137,7 +138,7 @@ public Visibility ShowBadge
137138
}
138139
}
139140

140-
public bool IsGlobalQuery => Result.OriginQuery.ActionKeyword == Query.GlobalPluginWildcardSign;
141+
public bool IsGlobalQuery => string.IsNullOrEmpty(Result.OriginQuery.ActionKeyword);
141142

142143
private bool GlyphAvailable => Glyph is not null;
143144

0 commit comments

Comments
 (0)