68 lines
1.5 KiB
C#
68 lines
1.5 KiB
C#
namespace MP.MONO.UI.Data
|
|
{
|
|
public class MessageService
|
|
{
|
|
#region Public Events
|
|
|
|
public event Action EA_PageUpdated = null!;
|
|
|
|
#endregion Public Events
|
|
|
|
#region Public Properties
|
|
|
|
public int currPage
|
|
{
|
|
get => _currPage;
|
|
set
|
|
{
|
|
if (_currPage != value)
|
|
{
|
|
_currPage = value;
|
|
if (EA_PageUpdated != null)
|
|
{
|
|
EA_PageUpdated?.Invoke();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
public int numRecord
|
|
{
|
|
get => _numRecord;
|
|
set
|
|
{
|
|
if (_numRecord != value)
|
|
{
|
|
_numRecord = value;
|
|
if (EA_PageUpdated != null)
|
|
{
|
|
EA_PageUpdated?.Invoke();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
#endregion Public Properties
|
|
|
|
#region Protected Methods
|
|
|
|
protected void reportPaging()
|
|
{
|
|
if (EA_PageUpdated != null)
|
|
{
|
|
EA_PageUpdated?.Invoke();
|
|
}
|
|
}
|
|
|
|
#endregion Protected Methods
|
|
|
|
#region Private Properties
|
|
|
|
private int _currPage { get; set; } = 1;
|
|
|
|
private int _numRecord { get; set; } = 10;
|
|
private int _totalVar { get; set; } = 0;
|
|
|
|
#endregion Private Properties
|
|
}
|
|
} |