Modifying points works
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using Avalonia.Controls;
|
||||
using CommunityToolkit.Mvvm.Messaging;
|
||||
using GazpromApp.Messages;
|
||||
using GazpromApp.ViewModels;
|
||||
|
||||
namespace GazpromApp.Views;
|
||||
|
||||
@@ -10,6 +11,18 @@ public partial class EditPointDialog : Window
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
if (Design.IsDesignMode)
|
||||
return;
|
||||
|
||||
WeakReferenceMessenger.Default.Register<EditPointDialog, ViewImageMessage>(this, static (w, m) =>
|
||||
{
|
||||
ImageView dialog = new ImageView()
|
||||
{
|
||||
DataContext = m.Image
|
||||
};
|
||||
m.Reply(dialog.ShowDialog<ImageViewModel?>(w));
|
||||
});
|
||||
|
||||
WeakReferenceMessenger.Default.Register<EditPointDialog, EditPointDone>(this, static (w, m) =>
|
||||
{
|
||||
w.Close(m.Point);
|
||||
|
||||
Reference in New Issue
Block a user