|
13 | 13 | using Flow.Launcher.Plugin.SharedCommands;
|
14 | 14 | using Flow.Launcher.ViewModel;
|
15 | 15 | using Flow.Launcher.Helper;
|
| 16 | +using System.Windows.Controls; |
16 | 17 |
|
17 | 18 | namespace Flow.Launcher
|
18 | 19 | {
|
@@ -186,20 +187,18 @@ private void OnPluginToggled(object sender, RoutedEventArgs e)
|
186 | 187 |
|
187 | 188 | private void OnPluginPriorityClick(object sender, RoutedEventArgs e)
|
188 | 189 | {
|
189 |
| - |
190 |
| - |
191 |
| - PriorityChangeWindow priorityChangeWindow = new PriorityChangeWindow(viewModel.SelectedPlugin.PluginPair.Metadata.ID, settings, viewModel.SelectedPlugin); |
| 190 | + if (sender is Control { DataContext: PluginViewModel pluginViewModel }) |
| 191 | + { |
| 192 | + PriorityChangeWindow priorityChangeWindow = new PriorityChangeWindow(pluginViewModel.PluginPair.Metadata.ID, settings, pluginViewModel); |
192 | 193 | priorityChangeWindow.ShowDialog();
|
193 |
| - |
| 194 | + } |
194 | 195 | }
|
195 | 196 |
|
196 | 197 | private void OnPluginActionKeywordsClick(object sender, RoutedEventArgs e)
|
197 | 198 | {
|
198 |
| - |
199 |
| - var id = viewModel.SelectedPlugin.PluginPair.Metadata.ID; |
200 |
| - ActionKeywords changeKeywordsWindow = new ActionKeywords(id, settings, viewModel.SelectedPlugin); |
201 |
| - changeKeywordsWindow.ShowDialog(); |
202 |
| - |
| 199 | + var id = viewModel.SelectedPlugin.PluginPair.Metadata.ID; |
| 200 | + ActionKeywords changeKeywordsWindow = new ActionKeywords(id, settings, viewModel.SelectedPlugin); |
| 201 | + changeKeywordsWindow.ShowDialog(); |
203 | 202 | }
|
204 | 203 |
|
205 | 204 | private void OnPluginNameClick(object sender, MouseButtonEventArgs e)
|
|
0 commit comments