mirror of
https://gitee.com/akwkevin/aistudio.-wpf.-diagram
synced 2026-03-06 09:40:50 +08:00
xx
This commit is contained in:
@@ -27,14 +27,14 @@ namespace AIStudio.Wpf.DiagramDesigner
|
||||
{
|
||||
PathMode = drawMode.ToString();
|
||||
RouterMode = routerMode.ToString();
|
||||
Init(sourceConnectorInfo, sinkConnectorInfo);
|
||||
Init(root, sourceConnectorInfo, sinkConnectorInfo);
|
||||
}
|
||||
|
||||
public ConnectionViewModel(IDiagramViewModel root, FullyCreatedConnectorInfo sourceConnectorInfo, FullyCreatedConnectorInfo sinkConnectorInfo, ConnectionItem designer) : base(root, designer)
|
||||
{
|
||||
PathMode = designer.PathMode;
|
||||
RouterMode = designer.RouterMode;
|
||||
Init(sourceConnectorInfo, sinkConnectorInfo);
|
||||
Init(root, sourceConnectorInfo, sinkConnectorInfo);
|
||||
}
|
||||
|
||||
public override SelectableItemBase GetSerializableObject()
|
||||
@@ -51,9 +51,9 @@ namespace AIStudio.Wpf.DiagramDesigner
|
||||
}
|
||||
}
|
||||
|
||||
protected virtual void Init(FullyCreatedConnectorInfo sourceConnectorInfo, ConnectorInfoBase sinkConnectorInfo)
|
||||
protected virtual void Init(IDiagramViewModel root, FullyCreatedConnectorInfo sourceConnectorInfo, ConnectorInfoBase sinkConnectorInfo)
|
||||
{
|
||||
this.Root = sourceConnectorInfo.DataItem.Root;
|
||||
this.Root = root?? sourceConnectorInfo.Root;
|
||||
|
||||
if (sinkConnectorInfo is FullyCreatedConnectorInfo sink && sink.DataItem.ShowArrow == false)
|
||||
{
|
||||
@@ -427,17 +427,17 @@ namespace AIStudio.Wpf.DiagramDesigner
|
||||
#endregion
|
||||
|
||||
#region 方法
|
||||
public SimpleCommand DeleteConnectionCommand
|
||||
public ICommand DeleteConnectionCommand
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
|
||||
public SimpleCommand AddVertexCommand
|
||||
public ICommand AddVertexCommand
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
|
||||
public SimpleCommand AddLabelCommand
|
||||
public ICommand AddLabelCommand
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Windows.Input;
|
||||
using AIStudio.Wpf.DiagramDesigner.Geometrys;
|
||||
using AIStudio.Wpf.DiagramDesigner.Models;
|
||||
using SvgPathProperties;
|
||||
@@ -82,12 +83,12 @@ namespace AIStudio.Wpf.DiagramDesigner
|
||||
get; set;
|
||||
}
|
||||
|
||||
public SimpleCommand DeleteLabelCommand
|
||||
public ICommand DeleteLabelCommand
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
|
||||
public SimpleCommand EditCommand
|
||||
public ICommand EditCommand
|
||||
{
|
||||
get; private set;
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using System.Windows.Input;
|
||||
using AIStudio.Wpf.DiagramDesigner.Geometrys;
|
||||
using AIStudio.Wpf.DiagramDesigner.Models;
|
||||
|
||||
@@ -68,7 +69,7 @@ namespace AIStudio.Wpf.DiagramDesigner
|
||||
|
||||
public override PointBase MiddlePosition => new PointBase(Connector.Area.Left + Left + ConnectorWidth / 2, Connector.Area.Top + Top + ConnectorHeight / 2);
|
||||
|
||||
public SimpleCommand DeleteVertexCommand
|
||||
public ICommand DeleteVertexCommand
|
||||
{
|
||||
get; set;
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Windows;
|
||||
using System.Windows.Input;
|
||||
using AIStudio.Wpf.DiagramDesigner.Geometrys;
|
||||
using AIStudio.Wpf.DiagramDesigner.Models;
|
||||
|
||||
@@ -185,11 +186,11 @@ namespace AIStudio.Wpf.DiagramDesigner
|
||||
#endregion
|
||||
|
||||
#region 方法
|
||||
public SimpleCommand DeleteCommand
|
||||
public ICommand DeleteCommand
|
||||
{
|
||||
get; private set;
|
||||
}
|
||||
public SimpleCommand MenuItemCommand
|
||||
public ICommand MenuItemCommand
|
||||
{
|
||||
get; private set;
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -13,7 +13,7 @@ namespace AIStudio.Wpf.DiagramDesigner
|
||||
|
||||
public interface ISelectItems
|
||||
{
|
||||
SimpleCommand SelectItemCommand
|
||||
ICommand SelectItemCommand
|
||||
{
|
||||
get;
|
||||
}
|
||||
@@ -64,7 +64,7 @@ namespace AIStudio.Wpf.DiagramDesigner
|
||||
return true;
|
||||
}
|
||||
|
||||
public SimpleCommand SelectItemCommand
|
||||
public ICommand SelectItemCommand
|
||||
{
|
||||
get; private set;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user