尝试整合分类代码文件

This commit is contained in:
fengjiayi
2024-08-06 15:41:14 +08:00
parent 276e3b65e9
commit f15baf0d9b
45 changed files with 886 additions and 484 deletions

View File

@@ -1,5 +1,5 @@
using Serein;
using Serein.DynamicFlow.SerinExpression;
using Serein.Flow.SerinExpression;
using Serein.WorkBench.Themes;
using Newtonsoft.Json;
using SqlSugar;

View File

@@ -5,9 +5,9 @@ using Serein.WorkBench.tool;
using Microsoft.Win32;
using Newtonsoft.Json.Linq;
using Serein;
using Serein.DynamicFlow;
using Serein.DynamicFlow.NodeModel;
using Serein.DynamicFlow.Tool;
using Serein.Flow;
using Serein.Flow.NodeModel;
using Serein.Flow.Tool;
using System.Collections.Concurrent;
using System.Diagnostics;
using System.IO;
@@ -22,6 +22,7 @@ using static Serein.WorkBench.Connection;
using DynamicDemo.Node;
using Npgsql.Logging;
using System.Threading.Tasks.Dataflow;
using Serein.Library.IOC;
namespace Serein.WorkBench
{
@@ -120,7 +121,7 @@ namespace Serein.WorkBench
/// <summary>
/// 节点的命名空间
/// </summary>
public const string NodeSpaceName = $"{nameof(Serein)}.{nameof(Serein.DynamicFlow)}.{nameof(Serein.DynamicFlow.NodeModel)}";
public const string NodeSpaceName = $"{nameof(Serein)}.{nameof(Serein.Flow)}.{nameof(Serein.Flow.NodeModel)}";
/// <summary>
/// 一种轻量的IOC容器
/// </summary>
@@ -1328,7 +1329,6 @@ namespace Serein.WorkBench
}
}
/// <summary>
/// 控件的鼠标左键松开事件,结束拖动操作,创建连线
/// </summary>
@@ -1380,24 +1380,6 @@ namespace Serein.WorkBench
return;
}
if (startConnectBlock != null && isRegion && startConnectBlock.Node.MethodDetails != null && startConnectBlock.Node.MethodDetails.MethodDynamicType == DynamicNodeType.Action)
{
if (!targetBlock.Node.MethodDetails.IsCanConnect(startConnectBlock.Node.MethodDetails.ReturnType))
{
string mboxStr = "类型不匹配。" +
"\r\n" +
$"起始节点:{startConnectBlock.Node.MethodDetails.MethodName}" + "\r\n" +
$"返回类型:{startConnectBlock.Node.MethodDetails.ReturnType.Name}" + "\r\n" +
"\r\n" +
$"起始节点:{targetBlock.Node.MethodDetails.MethodName}" + "\r\n" +
$"接收类型:{string.Join("\r\n", targetBlock.Node.MethodDetails.ExplicitDatas.Select(it => it.ToString()))}" + "\r\n";
MessageBox.Show(mboxStr);
return;
}
}
if (startConnectBlock != null && targetBlock != null && startConnectBlock != targetBlock)
{
@@ -1523,6 +1505,8 @@ namespace Serein.WorkBench
FlowChartCanvas.Height = scrollViewerViewportHeight;
}
}
/// <summary>
/// 删除该控件,以及与该控件相关的所有连线
/// </summary>
@@ -1717,6 +1701,10 @@ namespace Serein.WorkBench
}*/
}
/// <summary>
/// 树形结构展开类型的成员
/// </summary>
/// <param name="type"></param>
private void DisplayReturnTypeTreeViewer(Type type)
{
try

View File

@@ -1,4 +1,4 @@
using Serein.DynamicFlow.NodeModel;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Node.ViewModel;
namespace Serein.WorkBench.Node.View

View File

@@ -1,4 +1,4 @@
using Serein.DynamicFlow.NodeModel;
using Serein.Flow.NodeModel;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;

View File

@@ -1,5 +1,5 @@
using Serein.DynamicFlow;
using Serein.DynamicFlow.NodeModel;
using Serein.Flow;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Node.ViewModel;
using static Serein.WorkBench.MainWindow;
using System.Windows.Controls;

View File

@@ -1,5 +1,5 @@
using Serein.DynamicFlow;
using Serein.DynamicFlow.NodeModel;
using Serein.Flow;
using Serein.Flow.NodeModel;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Controls.Primitives;

View File

@@ -1,4 +1,4 @@
using Serein.DynamicFlow;
using Serein.Flow;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;

View File

@@ -1,4 +1,4 @@
using Serein.DynamicFlow.NodeModel;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Node.ViewModel;
using System;
using System.Collections.Generic;

View File

@@ -1,5 +1,5 @@
using Serein.DynamicFlow;
using Serein.DynamicFlow.NodeModel;
using Serein.Flow;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Node.ViewModel;
using System.Windows;
using System.Windows.Controls;

View File

@@ -1,5 +1,5 @@
using Serein.DynamicFlow;
using Serein.DynamicFlow.NodeModel;
using Serein.Flow;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Themes;
using System.Collections.ObjectModel;
using System.Collections.Specialized;

View File

@@ -1,5 +1,5 @@
using Serein.DynamicFlow;
using Serein.DynamicFlow.NodeModel;
using Serein.Flow;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Node.View;
using System.ComponentModel;
using System.Runtime.CompilerServices;

View File

@@ -1,5 +1,5 @@
using Serein.DynamicFlow;
using Serein.DynamicFlow.NodeModel;
using Serein.Flow;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Node.View;
using System.ComponentModel;
using System.Runtime.CompilerServices;

View File

@@ -1,4 +1,4 @@
using Serein.DynamicFlow.NodeModel;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Node.View;
using System;
using System.Collections.Generic;

View File

@@ -1,4 +1,4 @@
using Serein.DynamicFlow.NodeModel;
using Serein.Flow.NodeModel;
using Serein.WorkBench.Node.View;
namespace Serein.WorkBench.Node.ViewModel

View File

@@ -1,4 +1,4 @@
using Serein.DynamicFlow;
using Serein.Flow;
using System;
using System.Collections;
using System.Collections.Generic;