Files
serein-flow/Workbench/Node/View/UINodeControl.xaml.cs

68 lines
2.0 KiB
C#
Raw Normal View History

2025-03-14 16:04:06 +08:00
using Serein.Workbench.Node.ViewModel;
using Serein.Workbench.Tool;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace Serein.Workbench.Node.View
{
/// <summary>
/// UINodeControl.xaml 的交互逻辑
/// </summary>
public partial class UINodeControl : NodeControlBase, INodeJunction
{
private new UINodeControlViewModel ViewModel { get; }
2025-03-14 16:04:06 +08:00
public UINodeControl()
{
base.ViewModel.IsEnabledOnView = true;
2025-05-30 23:31:31 +08:00
base.ViewModel.NodeModel.DisplayName = "[流程UI]";
2025-03-14 16:04:06 +08:00
InitializeComponent();
}
internal UINodeControl(UINodeControlViewModel viewModel) : base(viewModel)
2025-03-14 16:04:06 +08:00
{
ViewModel = viewModel;
2025-03-14 16:04:06 +08:00
DataContext = viewModel;
2025-05-30 23:31:31 +08:00
ViewModel.NodeModel.DisplayName = "[流程UI]";
2025-03-14 16:04:06 +08:00
InitializeComponent();
}
JunctionControlBase INodeJunction.ExecuteJunction => this.ExecuteJunctionControl;
2025-03-14 16:04:06 +08:00
JunctionControlBase INodeJunction.NextStepJunction => throw new NotImplementedException();
2025-03-14 16:04:06 +08:00
JunctionControlBase[] INodeJunction.ArgDataJunction => throw new NotImplementedException();
2025-03-14 16:04:06 +08:00
JunctionControlBase INodeJunction.ReturnDataJunction => throw new NotImplementedException();
2025-03-14 16:04:06 +08:00
private void NodeControlBase_Loaded(object sender, RoutedEventArgs e)
{
//ViewModel.InitAdapter();
ViewModel.InitAdapter(userControl => {
2025-03-14 16:04:06 +08:00
EmbedContainer.Child = userControl;
});
}
private void NodeControlBase_Initialized(object sender, EventArgs e)
{
UINodeControlViewModel vm = (UINodeControlViewModel)DataContext;
}
}
}