Remove rest of build messages
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
using System;
|
||||
#pragma warning disable IDE1006
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace VAR.Toolbox.Code.DirectShow
|
||||
|
||||
@@ -1,8 +1,10 @@
|
||||
#pragma warning disable IDE1006
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace VAR.Toolbox.Code.DirectShow
|
||||
{
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
/// <summary>
|
||||
/// The interface provides methods for controlling the flow of data through the filter graph.
|
||||
/// It includes methods for running, pausing, and stopping the graph.
|
||||
|
||||
@@ -1,13 +1,15 @@
|
||||
#pragma warning disable IDE1006
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace VAR.Toolbox.Code.DirectShow
|
||||
{
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
/// <summary>
|
||||
/// The interface sets properties on the video window.
|
||||
/// </summary>
|
||||
///
|
||||
[ComImport,
|
||||
[ComImport,
|
||||
Guid("56A868B4-0AD4-11CE-B03A-0020AF0BA770"),
|
||||
InterfaceType(ComInterfaceType.InterfaceIsDual)]
|
||||
internal interface IVideoWindow
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
#pragma warning disable IDE0018
|
||||
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace VAR.Toolbox.Code.DirectShow
|
||||
{
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
/// <summary>
|
||||
/// Some miscellaneous functions.
|
||||
/// </summary>
|
||||
|
||||
@@ -8,8 +8,10 @@ namespace VAR.Toolbox.Code
|
||||
{
|
||||
public static void Move(int dx, int dy)
|
||||
{
|
||||
User32.INPUT input = new User32.INPUT();
|
||||
input.Type = User32.INPUT_MOUSE;
|
||||
User32.INPUT input = new User32.INPUT
|
||||
{
|
||||
Type = User32.INPUT_MOUSE
|
||||
};
|
||||
input.Data.Mouse.X = dx;
|
||||
input.Data.Mouse.Y = dy;
|
||||
input.Data.Mouse.Flags = User32.MOUSEEVENTF_MOVE;
|
||||
@@ -27,8 +29,10 @@ namespace VAR.Toolbox.Code
|
||||
|
||||
public static void SetButton(MouseButtons button, bool down)
|
||||
{
|
||||
User32.INPUT input = new User32.INPUT();
|
||||
input.Type = User32.INPUT_MOUSE;
|
||||
User32.INPUT input = new User32.INPUT
|
||||
{
|
||||
Type = User32.INPUT_MOUSE
|
||||
};
|
||||
input.Data.Mouse.X = 0;
|
||||
input.Data.Mouse.Y = 0;
|
||||
if (button == MouseButtons.Left)
|
||||
@@ -57,8 +61,7 @@ namespace VAR.Toolbox.Code
|
||||
|
||||
public static void GetPosition(out UInt32 x, out UInt32 y)
|
||||
{
|
||||
User32.POINT lpPoint;
|
||||
User32.GetCursorPos(out lpPoint);
|
||||
User32.GetCursorPos(out User32.POINT lpPoint);
|
||||
x = lpPoint.X;
|
||||
y = lpPoint.Y;
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ namespace VAR.Toolbox.Code
|
||||
{
|
||||
public class ProxyCmdExecutorThroughSQLServer : IProxyCmdExecutor
|
||||
{
|
||||
private string _connectionString = null;
|
||||
private readonly string _connectionString = null;
|
||||
|
||||
public ProxyCmdExecutorThroughSQLServer(string connectionString)
|
||||
{
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
using System;
|
||||
#pragma warning disable IDE0018
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Drawing;
|
||||
using System.Drawing.Imaging;
|
||||
@@ -20,11 +22,11 @@ namespace VAR.Toolbox.Code
|
||||
private IBaseFilter samplegrabberfilter;
|
||||
private IBaseFilter nullrenderer;
|
||||
|
||||
private Grabber grabber;
|
||||
private readonly Grabber grabber;
|
||||
|
||||
private int width = 0;
|
||||
private int height = 0;
|
||||
private int bpp = 0;
|
||||
private readonly int bpp = 0;
|
||||
|
||||
private bool active = false;
|
||||
|
||||
@@ -75,9 +77,11 @@ namespace VAR.Toolbox.Code
|
||||
ISampleGrabber sampleGrabber = (ISampleGrabber)samplegrabberfilter;
|
||||
|
||||
// Set media type
|
||||
AMMediaType mediaType = new AMMediaType();
|
||||
mediaType.MajorType = MediaType.Video;
|
||||
mediaType.SubType = MediaSubType.RGB24;
|
||||
AMMediaType mediaType = new AMMediaType
|
||||
{
|
||||
MajorType = MediaType.Video,
|
||||
SubType = MediaSubType.RGB24
|
||||
};
|
||||
sampleGrabber.SetMediaType(mediaType);
|
||||
|
||||
grabber = new Grabber(this);
|
||||
@@ -262,8 +266,8 @@ namespace VAR.Toolbox.Code
|
||||
{
|
||||
private Webcam _parent;
|
||||
|
||||
private Bitmap[] _frames = null;
|
||||
private int _numFrames = 10;
|
||||
private readonly Bitmap[] _frames = null;
|
||||
private readonly int _numFrames = 10;
|
||||
private int _currentFrameIndex = -1;
|
||||
|
||||
public Grabber(Webcam parent)
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
using System;
|
||||
#pragma warning disable IDE1006
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
|
||||
|
||||
@@ -13,8 +13,8 @@ namespace VAR.Toolbox.UI
|
||||
private Random rnd = new Random();
|
||||
private Timer _timer = new Timer();
|
||||
|
||||
private uint _mouseX = 0;
|
||||
private uint _mouseY = 0;
|
||||
private readonly uint _mouseX = 0;
|
||||
private readonly uint _mouseY = 0;
|
||||
|
||||
#endregion Declarations
|
||||
|
||||
@@ -36,7 +36,7 @@ namespace VAR.Toolbox.UI
|
||||
|
||||
_timer.Interval = 1000;
|
||||
_timer.Enabled = true;
|
||||
_timer.Tick += timer_Tick;
|
||||
_timer.Tick += Timer_Tick;
|
||||
}
|
||||
|
||||
private void FrmCover_Load(object sender, EventArgs e)
|
||||
@@ -79,7 +79,7 @@ namespace VAR.Toolbox.UI
|
||||
Close();
|
||||
}
|
||||
|
||||
private void timer_Tick(object sender, EventArgs e)
|
||||
private void Timer_Tick(object sender, EventArgs e)
|
||||
{
|
||||
User32.SetForegroundWindow(Handle);
|
||||
try
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
this.lsvCmdProxyConfigs.Name = "lsvCmdProxyConfigs";
|
||||
this.lsvCmdProxyConfigs.Size = new System.Drawing.Size(149, 355);
|
||||
this.lsvCmdProxyConfigs.TabIndex = 0;
|
||||
this.lsvCmdProxyConfigs.SelectedIndexChanged += new System.EventHandler(this.lsvCmdProxyConfigs_SelectedIndexChanged);
|
||||
this.lsvCmdProxyConfigs.SelectedIndexChanged += new System.EventHandler(this.LsvCmdProxyConfigs_SelectedIndexChanged);
|
||||
//
|
||||
// txtCmdProxyConfigName
|
||||
//
|
||||
@@ -65,7 +65,7 @@
|
||||
this.btnSave.TabIndex = 3;
|
||||
this.btnSave.Text = "Save";
|
||||
this.btnSave.UseVisualStyleBackColor = true;
|
||||
this.btnSave.Click += new System.EventHandler(this.btnSave_Click);
|
||||
this.btnSave.Click += new System.EventHandler(this.BtnSave_Click);
|
||||
//
|
||||
// btnDelete
|
||||
//
|
||||
@@ -76,7 +76,7 @@
|
||||
this.btnDelete.TabIndex = 4;
|
||||
this.btnDelete.Text = "Delete";
|
||||
this.btnDelete.UseVisualStyleBackColor = true;
|
||||
this.btnDelete.Click += new System.EventHandler(this.btnDelete_Click);
|
||||
this.btnDelete.Click += new System.EventHandler(this.BtnDelete_Click);
|
||||
//
|
||||
// btnNew
|
||||
//
|
||||
@@ -87,7 +87,7 @@
|
||||
this.btnNew.TabIndex = 5;
|
||||
this.btnNew.Text = "New";
|
||||
this.btnNew.UseVisualStyleBackColor = true;
|
||||
this.btnNew.Click += new System.EventHandler(this.btnNew_Click);
|
||||
this.btnNew.Click += new System.EventHandler(this.BtnNew_Click);
|
||||
//
|
||||
// txtCmdProxyConfigContent
|
||||
//
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
using System;
|
||||
#pragma warning disable IDE0019
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Text;
|
||||
@@ -16,24 +18,24 @@ namespace VAR.Toolbox.UI
|
||||
}
|
||||
|
||||
|
||||
private void lsvCmdProxyConfigs_SelectedIndexChanged(object sender, EventArgs e)
|
||||
private void LsvCmdProxyConfigs_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
ProxyCmdConfigItem selectedConfig = lsvCmdProxyConfigs.SelectedItem as ProxyCmdConfigItem;
|
||||
if (selectedConfig == null) { CleanConfig(); return; }
|
||||
ShowConfig(selectedConfig);
|
||||
}
|
||||
|
||||
private void btnSave_Click(object sender, EventArgs e)
|
||||
private void BtnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
SaveConfig();
|
||||
}
|
||||
|
||||
private void btnDelete_Click(object sender, EventArgs e)
|
||||
private void BtnDelete_Click(object sender, EventArgs e)
|
||||
{
|
||||
DeleteSelected();
|
||||
}
|
||||
|
||||
private void btnNew_Click(object sender, EventArgs e)
|
||||
private void BtnNew_Click(object sender, EventArgs e)
|
||||
{
|
||||
CreateNew();
|
||||
}
|
||||
@@ -81,9 +83,11 @@ namespace VAR.Toolbox.UI
|
||||
ProxyCmdConfigItem selectedConfig = lsvCmdProxyConfigs.SelectedItem as ProxyCmdConfigItem;
|
||||
if (selectedConfig == null)
|
||||
{
|
||||
selectedConfig = new ProxyCmdConfigItem();
|
||||
selectedConfig.Name = txtCmdProxyConfigName.Text;
|
||||
selectedConfig.Config = txtCmdProxyConfigContent.Text;
|
||||
selectedConfig = new ProxyCmdConfigItem
|
||||
{
|
||||
Name = txtCmdProxyConfigName.Text,
|
||||
Config = txtCmdProxyConfigContent.Text
|
||||
};
|
||||
lsvCmdProxyConfigs.Items.Add(selectedConfig);
|
||||
}
|
||||
else
|
||||
|
||||
@@ -100,7 +100,7 @@
|
||||
this.btnTestSoap.TabIndex = 21;
|
||||
this.btnTestSoap.Text = "Test";
|
||||
this.btnTestSoap.UseVisualStyleBackColor = true;
|
||||
this.btnTestSoap.Click += new System.EventHandler(this.btnTestSoap_Click);
|
||||
this.btnTestSoap.Click += new System.EventHandler(this.BtnTestSoap_Click);
|
||||
//
|
||||
// label5
|
||||
//
|
||||
@@ -248,7 +248,7 @@
|
||||
this.btnTestRest.TabIndex = 19;
|
||||
this.btnTestRest.Text = "Test";
|
||||
this.btnTestRest.UseVisualStyleBackColor = true;
|
||||
this.btnTestRest.Click += new System.EventHandler(this.btnTestRest_Click);
|
||||
this.btnTestRest.Click += new System.EventHandler(this.BtnTestRest_Click);
|
||||
//
|
||||
// label7
|
||||
//
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace VAR.Toolbox.UI
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private void btnTestSoap_Click(object sender, EventArgs e)
|
||||
private void BtnTestSoap_Click(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
@@ -45,7 +45,7 @@ namespace VAR.Toolbox.UI
|
||||
}
|
||||
}
|
||||
|
||||
private void btnTestRest_Click(object sender, EventArgs e)
|
||||
private void BtnTestRest_Click(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
|
||||
@@ -54,12 +54,11 @@ namespace VAR.Toolbox.UI
|
||||
_frmCover.FormClosing += (sender, e) => { _frmCover = null; };
|
||||
_frmCover.Show();
|
||||
|
||||
Form frmParent = Parent as Form;
|
||||
if (frmParent != null)
|
||||
if (Parent is Form frmParent)
|
||||
{
|
||||
frmParent.WindowState = FormWindowState.Minimized;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user