Skip to content

Commit 07c5fa4

Browse files
committed
Improve code quality
1 parent 7c23aeb commit 07c5fa4

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

Flow.Launcher/MainWindow.xaml.cs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -187,10 +187,8 @@ private void OnInitialized(object sender, EventArgs e)
187187

188188
private void OnLoaded(object sender, RoutedEventArgs _)
189189
{
190-
Dispatcher.BeginInvoke((Action)(() =>
191-
{
192-
ThemeManager.Instance.RefreshFrame();
193-
}), DispatcherPriority.Background);
190+
// Refresh frame
191+
ThemeManager.Instance.RefreshFrame();
194192

195193
// MouseEventHandler
196194
PreviewMouseMove += MainPreviewMouseMove;

Flow.Launcher/ViewModel/MainViewModel.cs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,6 @@ public MainViewModel()
143143
_userSelectedRecord = _userSelectedRecordStorage.Load();
144144
_topMostRecord = _topMostRecordStorage.Load();
145145

146-
147146
ContextMenu = new ResultsViewModel(Settings)
148147
{
149148
LeftClickResultCommand = OpenResultCommand,
@@ -791,7 +790,6 @@ public string VerifyOrSetDefaultHotkey(string hotkey, string defaultHotkey)
791790
public string CycleHistoryUpHotkey => VerifyOrSetDefaultHotkey(Settings.CycleHistoryUpHotkey, "Alt+Up");
792791
public string CycleHistoryDownHotkey => VerifyOrSetDefaultHotkey(Settings.CycleHistoryDownHotkey, "Alt+Down");
793792

794-
795793
public string Image => Constant.QueryTextBoxIconImagePath;
796794

797795
public bool StartWithEnglishMode => Settings.AlwaysStartEn;
@@ -1407,7 +1405,6 @@ public void Show()
14071405
});
14081406
}
14091407

1410-
14111408
public async void Hide()
14121409
{
14131410
lastHistoryIndex = 1;
@@ -1483,8 +1480,6 @@ public async void Hide()
14831480
VisibilityChanged?.Invoke(this, new VisibilityChangedEventArgs { IsVisible = false });
14841481
}
14851482

1486-
1487-
14881483
/// <summary>
14891484
/// Checks if Flow Launcher should ignore any hotkeys
14901485
/// </summary>

0 commit comments

Comments
 (0)