Commit for development environment setup

This commit is contained in:
2023-06-19 16:12:33 -04:00
parent be72063a3c
commit bbce2ad0a6
2209 changed files with 1171775 additions and 625 deletions

View File

@@ -0,0 +1,81 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
namespace PTWin
{
public partial class WinPart : UserControl
{
public WinPart()
{
InitializeComponent();
}
protected internal virtual object GetIdValue()
{
return null;
}
public override bool Equals(object obj)
{
if (this.DesignMode)
return base.Equals(obj);
else
{
object id = GetIdValue();
if (this.GetType().Equals(obj.GetType()) && id != null)
return ((WinPart)obj).GetIdValue().Equals(id);
else
return false;
}
}
public override int GetHashCode()
{
object id = GetIdValue();
if (id != null)
return GetIdValue().GetHashCode();
else
return base.GetHashCode();
}
public override string ToString()
{
object id = GetIdValue();
if (id != null)
return id.ToString();
else
return base.ToString();
}
#region CloseWinPart
public event EventHandler CloseWinPart;
protected void Close()
{
if (CloseWinPart != null)
CloseWinPart(this, EventArgs.Empty);
}
#endregion
#region CurrentPrincipalChanged
public event EventHandler CurrentPrincipalChanged;
protected internal virtual void OnCurrentPrincipalChanged(
object sender, EventArgs e)
{
if (CurrentPrincipalChanged != null)
CurrentPrincipalChanged(sender, e);
}
#endregion
}
}