mirror of
https://github.com/sourcegit-scm/sourcegit.git
synced 2024-11-01 13:13:21 -07:00
22 lines
585 B
C#
22 lines
585 B
C#
using Avalonia.Controls;
|
|
|
|
namespace SourceGit.Views
|
|
{
|
|
public partial class StashesPage : UserControl
|
|
{
|
|
public StashesPage()
|
|
{
|
|
InitializeComponent();
|
|
}
|
|
|
|
private void OnStashContextRequested(object sender, ContextRequestedEventArgs e)
|
|
{
|
|
if (DataContext is ViewModels.StashesPage vm && sender is Border border)
|
|
{
|
|
var menu = vm.MakeContextMenu(border.DataContext as Models.Stash);
|
|
border.OpenContextMenu(menu);
|
|
}
|
|
e.Handled = true;
|
|
}
|
|
}
|
|
}
|