diff --git a/Plugins/Flow.Launcher.Plugin.Explorer/Search/ResultManager.cs b/Plugins/Flow.Launcher.Plugin.Explorer/Search/ResultManager.cs index ec35c2db5..0f6a5503a 100644 --- a/Plugins/Flow.Launcher.Plugin.Explorer/Search/ResultManager.cs +++ b/Plugins/Flow.Launcher.Plugin.Explorer/Search/ResultManager.cs @@ -54,7 +54,7 @@ namespace Flow.Launcher.Plugin.Explorer.Search { Title = title, IcoPath = path, - SubTitle = subtitle, + SubTitle = Path.GetDirectoryName(path), AutoCompleteText = GetPathWithActionKeyword(path, ResultType.Folder), TitleHighlightData = StringMatcher.FuzzySearch(query.Search, title).MatchData, Action = c => @@ -218,7 +218,7 @@ namespace Flow.Launcher.Plugin.Explorer.Search var result = new Result { Title = Path.GetFileName(filePath), - SubTitle = filePath, + SubTitle = Path.GetDirectoryName(filePath), IcoPath = filePath, AutoCompleteText = GetPathWithActionKeyword(filePath, ResultType.File), TitleHighlightData = StringMatcher.FuzzySearch(query.Search, Path.GetFileName(filePath)).MatchData, @@ -229,7 +229,7 @@ namespace Flow.Launcher.Plugin.Explorer.Search { if (File.Exists(filePath) && c.SpecialKeyState.CtrlPressed && c.SpecialKeyState.ShiftPressed) { - Task.Run(() => + _ = Task.Run(() => { try { diff --git a/Plugins/Flow.Launcher.Plugin.Explorer/Search/SearchManager.cs b/Plugins/Flow.Launcher.Plugin.Explorer/Search/SearchManager.cs index f0d6e6295..1d5c7a73e 100644 --- a/Plugins/Flow.Launcher.Plugin.Explorer/Search/SearchManager.cs +++ b/Plugins/Flow.Launcher.Plugin.Explorer/Search/SearchManager.cs @@ -47,7 +47,8 @@ namespace Flow.Launcher.Plugin.Explorer.Search // This allows the user to type the below action keywords and see/search the list of quick folder links if (ActionKeywordMatch(query, Settings.ActionKeyword.SearchActionKeyword) || ActionKeywordMatch(query, Settings.ActionKeyword.QuickAccessActionKeyword) - || ActionKeywordMatch(query, Settings.ActionKeyword.PathSearchActionKeyword)) + || ActionKeywordMatch(query, Settings.ActionKeyword.PathSearchActionKeyword) + || ActionKeywordMatch(query, Settings.ActionKeyword.IndexSearchActionKeyword)) { if (string.IsNullOrEmpty(query.Search)) return QuickAccess.AccessLinkListAll(query, Settings.QuickAccessLinks); @@ -166,14 +167,16 @@ namespace Flow.Launcher.Plugin.Explorer.Search var useIndexSearch = Settings.IndexSearchEngine is Settings.IndexSearchEngineOption.WindowsIndex && UseWindowsIndexForDirectorySearch(locationPath); + + var retrievedDirectoryPath = FilesFolders.ReturnPreviousDirectoryIfIncompleteString(locationPath); - if (locationPath.EndsWith(":\\")) + if (retrievedDirectoryPath.EndsWith(":\\")) { - results.Add(ResultManager.CreateDriveSpaceDisplayResult(locationPath, useIndexSearch)); + results.Add(ResultManager.CreateDriveSpaceDisplayResult(retrievedDirectoryPath, useIndexSearch)); } else { - results.Add(ResultManager.CreateOpenCurrentFolderResult(locationPath, useIndexSearch)); + results.Add(ResultManager.CreateOpenCurrentFolderResult(retrievedDirectoryPath, useIndexSearch)); } if (token.IsCancellationRequested)