31 lines
844 B
C#
31 lines
844 B
C#
|
|
using CommunityToolkit.Mvvm.ComponentModel;
|
|
|
|
namespace Szmedi.RevitToolkit.Approval.Controls.ProgressWrapper
|
|
{
|
|
public partial class ProgressMonitorViewModel : ObservableObject
|
|
{
|
|
[ObservableProperty]
|
|
public int maxValue = 100;
|
|
|
|
[ObservableProperty]
|
|
private int currentValue = 0;
|
|
|
|
[ObservableProperty]
|
|
private string currentContext = string.Empty;
|
|
[ObservableProperty]
|
|
private string title = "处理任务";
|
|
|
|
public void NotifyUI()
|
|
{
|
|
var classType = this.GetType();
|
|
if (classType != null)
|
|
{
|
|
var currentProperties = classType.GetProperties();
|
|
foreach (var currentProperty in currentProperties)
|
|
OnPropertyChanged(currentProperty.Name);
|
|
}
|
|
}
|
|
}
|
|
}
|