We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 18e0479 commit c7332afCopy full SHA for c7332af
src/Views/ContextMenuExtension.cs
@@ -1,5 +1,4 @@
1
using System.ComponentModel;
2
-
3
using Avalonia.Controls;
4
5
namespace SourceGit.Views
@@ -15,7 +14,7 @@ public static void OpenContextMenu(this Control control, ContextMenu menu)
15
14
menu.Closing += OnContextMenuClosing; // Clear context menu because it is dynamic.
16
17
control.ContextMenu = menu;
18
- control.ContextMenu.Open();
+ control.ContextMenu?.Open();
19
}
20
21
private static void OnContextMenuClosing(object sender, CancelEventArgs e)
0 commit comments