DotNet 4.8.1 build of DotNetBar

This commit is contained in:
2025-02-07 10:35:23 -05:00
parent 33439b63a0
commit 6b0a5d60f4
2609 changed files with 989814 additions and 7 deletions

View File

@@ -0,0 +1,65 @@
#if FRAMEWORK20
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;
namespace DevComponents.DotNetBar.Validator
{
internal class ErrorProviderWrapper : IErrorProvider
{
#region Constructors
private ErrorProvider _ErrorProvider = null;
/// <summary>
/// Initializes a new instance of the ErrorProviderWrapper class.
/// </summary>
/// <param name="errorProvider"></param>
public ErrorProviderWrapper(ErrorProvider errorProvider)
{
_ErrorProvider = errorProvider;
}
/// <summary>
/// Initializes a new instance of the ErrorProviderWrapper class.
/// </summary>
/// <param name="errorProvider"></param>
/// <param name="iconPadding"></param>
public ErrorProviderWrapper(ErrorProvider errorProvider, int iconPadding)
{
_ErrorProvider = errorProvider;
_IconPadding = iconPadding;
}
private int _IconPadding = 0;
public int IconPadding
{
get { return _IconPadding; }
set
{
_IconPadding = value;
}
}
#endregion
#region IErrorProvider Members
public void SetError(Control control, string value)
{
_ErrorProvider.SetError(control, value);
if (_IconPadding != 0)
_ErrorProvider.SetIconPadding(control, _IconPadding);
}
public void ClearError(Control control)
{
_ErrorProvider.SetError(control, null);
if (_IconPadding != 0)
_ErrorProvider.SetIconPadding(control, 0);
}
#endregion
}
}
#endif