|
9 | 9 | using Microsoft.UI.Xaml.Controls; |
10 | 10 | using Microsoft.UI.Xaml.Controls.Primitives; |
11 | 11 | using Microsoft.UI.Xaml.Input; |
| 12 | +using Microsoft.UI.Xaml.Media.Imaging; |
12 | 13 | using System.IO; |
13 | 14 | using System.Windows.Input; |
14 | 15 | using Windows.AI.Actions; |
15 | | -using Windows.AI.Actions.Hosting; |
16 | 16 | using Windows.ApplicationModel.DataTransfer; |
17 | | -using Microsoft.Windows.ApplicationModel.Resources; |
18 | 17 | using Windows.UI.Text; |
19 | | -using Microsoft.UI.Xaml.Media.Imaging; |
20 | 18 |
|
21 | 19 | namespace Files.App.ViewModels.UserControls |
22 | 20 | { |
@@ -254,7 +252,7 @@ public bool IsOmnibarFocused |
254 | 252 | _ = PopulateOmnibarSuggestionsForPathMode(); |
255 | 253 | break; |
256 | 254 | case OmnibarPaletteModeName: |
257 | | - PopulateOmnibarSuggestionsForCommandPaletteMode(); |
| 255 | + PopulateOmnibarSuggestionsForCommandPaletteMode(); |
258 | 256 | break; |
259 | 257 | case OmnibarSearchModeName: |
260 | 258 | break; |
@@ -816,6 +814,10 @@ public void SwitchToSearchMode() |
816 | 814 | public void SwitchToPathMode() |
817 | 815 | { |
818 | 816 | OmnibarCurrentSelectedModeName = OmnibarPathModeName; |
| 817 | + |
| 818 | + var omnibar = AddressToolbar?.FindDescendant("Omnibar") as Omnibar; |
| 819 | + omnibar?.Focus(FocusState.Programmatic); |
| 820 | + omnibar.IsFocused = true; |
819 | 821 | } |
820 | 822 |
|
821 | 823 | public void UpdateAdditionalActions() |
|
0 commit comments