Commit 9fcdb9e5 by 王永辉

清空位置按钮点击后开始位置、结束位置、无效位置三个按钮设置为可用

parent 65ad393a
......@@ -10,11 +10,11 @@ none
false
DEBUG;TRACE
18560433975
1470602451
11-350624472
241319896476
181380438361
1-1441241311
11-1602666439
23304678694
Style\Button\Button_NdiView.xaml;Style\Button\Button_Setting.xaml;Style\Button\Button_WindowTop.xaml;Style\CheckBox\CheckBox_NdiView.xaml;Style\CheckBox\CheckBox_Setting.xaml;Style\CheckBox\CheckBox_WindowTop.xaml;Style\ComboBox\ComboBox_Setting.xaml;Style\HotkeyBox\HotkeyBox_Setting.xaml;Style\MessageBox\MessageBoxEx.xaml;Style\RadioButton\RadioButton_FootballSide.xaml;Style\RadioButton\RadioButton_NdiView.xaml;Style\RadioButton\RadioButton_Setting.xaml;Style\Slider\Slider_Setting.xaml;Style\TextBlock\TextBlock_Setting.xaml;Style\TextBox\TextBox_Setting.xaml;Style\ToogleButton\ToogleButton_Setting.xaml;Themes\Generic.xaml;Toolkit\NumericUpDown\NumericUpDown.xaml;
False
True
using System;
using Gma.System.MouseKeyHook;
using log4net;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Input;
using VIZ.Framework.Common;
using VIZ.Framework.Core;
using VIZ.Framework.Domain;
using System.Diagnostics;
using Gma.System.MouseKeyHook;
using System.Windows.Interop;
using log4net;
using System.Threading;
using VIZ.FGOUT.Storage;
using VIZ.FGOUT.Domain;
using System.Windows.Controls;
using VIZ.Framework.Connection;
using VIZ.FGOUT.Connection;
using VIZ.FGOUT.Domain;
using VIZ.FGOUT.Domain.Message.Setting;
using VIZ.FGOUT.Storage;
using VIZ.Framework.Common;
using VIZ.Framework.Connection;
using VIZ.Framework.Core;
using VIZ.Framework.Domain;
namespace VIZ.FGOUT.Module
{
......@@ -616,7 +611,6 @@ namespace VIZ.FGOUT.Module
private void EndRegion()
{
endPlaceModel.EndPlace = true;
invalidPlaceModel.IsInvalid = false;
ApplicationDomainEx.MessageManager.Send(endPlaceModel);
......@@ -646,10 +640,12 @@ namespace VIZ.FGOUT.Module
private void CleanRect()
{
cleanPlaceModel.CleanPlace = true;
ApplicationDomainEx.MessageManager.Send(cleanPlaceModel);
//三个按钮恢复可用
StartEnable = true;
EndEnable = true;
InvalidEnable = true;
}
......@@ -700,9 +696,6 @@ namespace VIZ.FGOUT.Module
set { startEnable = value;this.RaisePropertyChanged(nameof(StartEnable)); }
}
/// <summary>
/// 结束位置按钮可用性
/// </summary>
......@@ -714,8 +707,6 @@ namespace VIZ.FGOUT.Module
set { endEnable = value; this.RaisePropertyChanged(nameof(EndEnable)); }
}
/// <summary>
/// 无效位置按钮可用性
/// </summary>
......@@ -727,8 +718,6 @@ namespace VIZ.FGOUT.Module
set { invalidEnable = value; this.RaisePropertyChanged(nameof(InvalidEnable)); }
}
/// <summary>
/// 清空位置按钮可用性
/// </summary>
......@@ -740,9 +729,6 @@ namespace VIZ.FGOUT.Module
set { cleanEnable = value; this.RaisePropertyChanged(nameof(CleanEnable)); }
}
#endregion
#region CloseCommand -- 关闭命令
......
using System;
using System.Collections.Generic;
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;
using VIZ.Framework.Core;
using VIZ.Framework.Storage;
using VIZ.FGOUT.Domain;
using VIZ.FGOUT.Storage;
using VIZ.Framework.Core;
namespace VIZ.FGOUT.Module
{
......@@ -24,28 +16,20 @@ namespace VIZ.FGOUT.Module
/// </summary>
public partial class NDIView : UserControl
{
NDIViewModel vm = new NDIViewModel();
//Rectangle rectStart = new Rectangle();
// Rectangle rectEnd = new Rectangle();
public PathGeometry aa = new PathGeometry();
//PathGeometry bb = new PathGeometry();
public Rect rectStart;
public Rect rectEnd;
public Rect rectInvalid;
public Path myPath = new Path();
//public Path myPath1 = new Path();
......@@ -54,7 +38,6 @@ namespace VIZ.FGOUT.Module
{
InitializeComponent();
//if (WPFHelper.IsInDesignMode(this))
// return;
......@@ -66,7 +49,6 @@ namespace VIZ.FGOUT.Module
//rectStart.StrokeThickness = 0;
//rectStart.Name = "rectStart1";
//this.canvas1.Children.Add(rectStart);
//rectEnd.Stroke = Brushes.Green;
......@@ -74,7 +56,6 @@ namespace VIZ.FGOUT.Module
//rectEnd.Name = "rectEnd1";
//this.canvas1.Children.Add(rectEnd);
myPath.Fill = Brushes.Transparent;
myPath.Stroke = Brushes.Blue;
myPath.StrokeThickness = 1;
......@@ -86,16 +67,11 @@ namespace VIZ.FGOUT.Module
//myPath1.StrokeThickness = 1;
//this.canvas1.Children.Add(myPath1);
}
bool isMouseDown = false;
public Point startPoint;
#region NDIKey -- NDI
/// <summary>
......@@ -121,7 +97,6 @@ namespace VIZ.FGOUT.Module
private void Border_MouseLeftButtonUp(object sender, MouseButtonEventArgs e)
{
this.manualConfig = ApplicationDomainEx.LiteDbContext.SetManualConfig.FindAll().FirstOrDefault();
if (!this.manualConfig.IsManual) return;
......@@ -151,7 +126,6 @@ namespace VIZ.FGOUT.Module
// // this.canvas1.Children.Add(rectEnd);
// //}
//}
double width= this.video.ActualWidth;
double height = this.video.ActualHeight;
......@@ -160,9 +134,6 @@ namespace VIZ.FGOUT.Module
double cans1height = this.canvas1.ActualHeight;
if (vm.IsDrawStartPlace)
{
///aa = new PathGeometry();
......@@ -174,15 +145,17 @@ namespace VIZ.FGOUT.Module
//RectangleGeometry temp1 = new RectangleGeometry(rectStart);
// temp1.StrokeContains
//foreach (var rectStart in rectStarts)
//{
// aa.AddGeometry(new RectangleGeometry(rectStart));
//}
aa.AddGeometry(new RectangleGeometry(rectStart));
aa.AddGeometry(new RectangleGeometry(rectEnd));
aa.AddGeometry(new RectangleGeometry(rectInvalid));
// }
}
else if(vm.IsDrawEndPlace)
{
//if (aa == null)
//{
......@@ -191,35 +164,33 @@ namespace VIZ.FGOUT.Module
// }
aa = new PathGeometry();
//foreach (var rectStart in rectStarts)
//{
// aa.AddGeometry(new RectangleGeometry(rectStart));
//}
aa.AddGeometry(new RectangleGeometry(rectStart));
aa.AddGeometry(new RectangleGeometry(rectEnd));
aa.AddGeometry(new RectangleGeometry(rectInvalid));
}
else if(vm.IsDrawInvalidPlace)
{
aa = new PathGeometry();
//foreach (var rectStart in rectStarts)
//{
// aa.AddGeometry(new RectangleGeometry(rectStart));
//}
aa.AddGeometry(new RectangleGeometry(rectStart));
aa.AddGeometry(new RectangleGeometry(rectEnd));
aa.AddGeometry(new RectangleGeometry(rectInvalid));
}
myPath.Data = aa;
}
private void Border_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
{
startPoint = e.GetPosition(this.canvas1);
isMouseDown = true;
//if (vm.IsDrawStartPlace)
//{
// myPath.Stroke = Brushes.Red;
......@@ -229,29 +200,25 @@ namespace VIZ.FGOUT.Module
//{
// myPath.Stroke = Brushes.Green;
//}
}
List<Rect> rectStarts = new List<Rect>();
private void Border_MouseMove(object sender, MouseEventArgs e)
{
if (isMouseDown)
{
if (vm.IsDrawStartPlace)
{
rectStart = new Rect(startPoint, e.GetPosition(this.canvas1));
//rectStarts.Add(new Rect(startPoint, e.GetPosition(this.canvas1)));
//rectStart.Margin = new Thickness(rect.Left, rect.Top, 0, 0);
//rectStart.Width = rect.Width;
//rectStart.Height = rect.Height;
}
else if(vm.IsDrawEndPlace)
{
rectEnd = new Rect(startPoint, e.GetPosition(this.canvas1));
//rectEnd.Margin = new Thickness(rect.Left, rect.Top, 0, 0);
//rectEnd.Width = rect.Width;
//rectEnd.Height = rect.Height;
......
using System;
using log4net;
using SharpDX.Mathematics.Interop;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Web.UI;
using System.Windows;
using System.Windows.Media;
using log4net;
using SharpDX.Mathematics.Interop;
using VIZ.Framework.Common;
using VIZ.Framework.Core;
using VIZ.FGOUT.Connection;
using VIZ.FGOUT.Domain;
using VIZ.FGOUT.Domain.Message.Setting;
using VIZ.FGOUT.Module.SystemSetting.View;
using VIZ.FGOUT.Storage;
using Xceed.Wpf.Toolkit.Primitives;
using VIZ.Framework.Common;
using VIZ.Framework.Connection;
using System.Windows;
using VIZ.Framework.Core;
using VIZ.Framework.Storage;
using VIZ.FGOUT.Connection;
using VIZ.FGOUT.Domain.Message.Setting;
using VIZ.FGOUT.Module.SystemSetting.View;
namespace VIZ.FGOUT.Module
{
......@@ -76,9 +72,6 @@ namespace VIZ.FGOUT.Module
}
/// <summary>
/// 初始化命令
/// </summary>
......@@ -113,10 +106,6 @@ namespace VIZ.FGOUT.Module
//this.AlgorithmControllerDic.Add(AlgorithmStrategyType.Cableway, new AlgorithmController_Cableway(this));
this.ManualController = new ManualController(this);
}
/// <summary>
......@@ -204,7 +193,6 @@ namespace VIZ.FGOUT.Module
private void StartPlace(StartPlaceModel startPlaceModel)
{
if (this.ViewKey != "CAM_1")
{
IsDrawStartPlace = false;
......@@ -214,7 +202,6 @@ namespace VIZ.FGOUT.Module
IsDrawEndPlace = false;
IsDrawInvalidPlace = false;
IsCleanPlace = false;
}
......@@ -350,9 +337,6 @@ namespace VIZ.FGOUT.Module
}
/// <summary>
/// 保存配置命令
/// </summary>
......@@ -369,7 +353,6 @@ namespace VIZ.FGOUT.Module
return;
}
this.setPlaceConfig = ApplicationDomainEx.LiteDbContext.SetPlaceConfig.FindAll().FirstOrDefault();
NDIView nDIView = this.GetView<NDIView>();
......
......@@ -43,7 +43,7 @@ namespace VIZ.FGOUT.Module
//ConnectionManager.UdpConnection.AddEndpointManager(new UdpEndpointManager(_endpointKey, "127.0.0.1", 8888));
string clientIP = ApplicationDomainEx.IniStorage.GetValue<UdpConfig, string>(p => p.UDP_BINDING_IP);
ConnectionManager.UdpConnection.AddEndpointManager(new UdpEndpointManager(_endpointKey, clientIP, 8888));
//ConnectionManager.UdpConnection.AddEndpointManager(new UdpEndpointManager(_endpointKey, "192.168.31.70", 8888));
javelinThrowConfig = ApplicationDomainEx.LiteDbContext.JavelinThrowConfig.FindAll().FirstOrDefault();
if (javelinThrowConfig == null) return;
......
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "0347975785EB8D0B2CAB944BBEB7B3F6D1C8069AB7CA02C4A73B61DBC4120CF3"
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "F17D6BBFCB868C891664C3375D890DAF01CAC7C6DE76035A166ABE8DF84CF8DA"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -58,7 +58,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 299 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 305 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam1;
......@@ -66,7 +66,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 317 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 323 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam2;
......
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "0347975785EB8D0B2CAB944BBEB7B3F6D1C8069AB7CA02C4A73B61DBC4120CF3"
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "F17D6BBFCB868C891664C3375D890DAF01CAC7C6DE76035A166ABE8DF84CF8DA"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -58,7 +58,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 299 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 305 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam1;
......@@ -66,7 +66,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 317 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 323 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam2;
......
#pragma checksum "..\..\..\..\..\NDIView\View\NDIView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "2AB93701F1A14F4DA814782884ECEB4B29DBE75E9E6969987DDF5393C34689A0"
#pragma checksum "..\..\..\..\..\NDIView\View\NDIView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "1B8D7DB41D18FB6AD221B9112F3D2D3E77F56EB7B3EA18B2A2F39D16FDE28C85"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -60,7 +60,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 244 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 306 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Border Border;
......@@ -68,7 +68,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 249 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 311 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Canvas canvas1;
......@@ -76,7 +76,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 251 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 314 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.Framework.Common.VideoControl video;
......@@ -119,19 +119,19 @@ namespace VIZ.FGOUT.Module {
case 2:
this.Border = ((System.Windows.Controls.Border)(target));
#line 245 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseLeftButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.Border_MouseLeftButtonUp);
#line 308 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseLeftButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.Border_MouseLeftButtonDown);
#line default
#line hidden
#line 246 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseLeftButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.Border_MouseLeftButtonDown);
#line 309 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseLeftButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.Border_MouseLeftButtonUp);
#line default
#line hidden
#line 247 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 310 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseMove += new System.Windows.Input.MouseEventHandler(this.Border_MouseMove);
#line default
......
#pragma checksum "..\..\..\..\..\NDIView\View\NDIView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "2AB93701F1A14F4DA814782884ECEB4B29DBE75E9E6969987DDF5393C34689A0"
#pragma checksum "..\..\..\..\..\NDIView\View\NDIView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "1B8D7DB41D18FB6AD221B9112F3D2D3E77F56EB7B3EA18B2A2F39D16FDE28C85"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -60,7 +60,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 244 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 306 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Border Border;
......@@ -68,7 +68,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 249 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 311 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Canvas canvas1;
......@@ -76,7 +76,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 251 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 314 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.Framework.Common.VideoControl video;
......@@ -119,19 +119,19 @@ namespace VIZ.FGOUT.Module {
case 2:
this.Border = ((System.Windows.Controls.Border)(target));
#line 245 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseLeftButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.Border_MouseLeftButtonUp);
#line 308 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseLeftButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.Border_MouseLeftButtonDown);
#line default
#line hidden
#line 246 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseLeftButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.Border_MouseLeftButtonDown);
#line 309 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseLeftButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.Border_MouseLeftButtonUp);
#line default
#line hidden
#line 247 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 310 "..\..\..\..\..\NDIView\View\NDIView.xaml"
this.Border.PreviewMouseMove += new System.Windows.Input.MouseEventHandler(this.Border_MouseMove);
#line default
......
D:\wyh\FGOUT\FGOUT\VIZ.FGOUT\VIZ.FGOUT.Module\obj\x64\Debug\GeneratedInternalTypeHelper.g.cs

FD:\wyh\FGOUT\FGOUT\VIZ.FGOUT\VIZ.FGOUT.Module\NDIMainView\View\NDIMainView.xaml;;
FD:\wyh\FGOUT\FGOUT\VIZ.FGOUT\VIZ.FGOUT.Module\NDIPreviewView\View\NDIPreviewView.xaml;;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -10,10 +10,10 @@ none
false
DEBUG;TRACE
91711917753
9-721875057
3-1719726047
19-915820474
3-630027162
192063791830
Path\ArrowPathResource.xaml;Style\Button\Button_MessageBox.xaml;Style\Button\Button_Normal.xaml;Style\Button\Button_WindowTop.xaml;Style\GridSplitter\GridSplitter_None.xaml;Style\ListBox\ListBox_None.xaml;Style\ScrollView\ScrollView_Default.xaml;Style\TextBox\TextBox_None.xaml;Themes\Generic.xaml;
False
......
D:\wyh\FGOUT\FGOUT\VIZ.Framework\VIZ.Framework.Common\obj\x64\Debug\GeneratedInternalTypeHelper.g.cs

FD:\wyh\FGOUT\FGOUT\VIZ.Framework\VIZ.Framework.Common\MessageBox\MessageBoxEx.xaml;;
FD:\wyh\FGOUT\FGOUT\VIZ.Framework\VIZ.Framework.Common\MessageBox\MessageBoxExWindow.xaml;;
......
......@@ -10,11 +10,11 @@ none
false
DEBUG;TRACE
11882902973
1-731644535
212023628146
25-2140555781
212002329545
25-1459698188
Themes\Generic.xaml;
False
True
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment