37 lines
850 B
C#
37 lines
850 B
C#
using System.Collections.Generic;
|
|
|
|
namespace DTS.Common.Enums
|
|
{
|
|
public enum UIItemStatus
|
|
{
|
|
None,
|
|
Success,
|
|
Failed,
|
|
Error,
|
|
Warning
|
|
}
|
|
|
|
public abstract class SelectedItemsStatus
|
|
{
|
|
private static Dictionary<object, bool> _ListStatus = new Dictionary<object, bool>();
|
|
private static readonly object MyLock = new object();
|
|
|
|
public static void SetUpdating(object o, bool updating)
|
|
{
|
|
lock (MyLock)
|
|
{
|
|
_ListStatus[o] = updating;
|
|
}
|
|
}
|
|
|
|
public static bool GetUpdating(object o)
|
|
{
|
|
lock (MyLock)
|
|
{
|
|
if( _ListStatus.ContainsKey(o) ){ return _ListStatus[o]; }
|
|
return false;
|
|
}
|
|
}
|
|
}
|
|
}
|