시스템메세지, 정보메세지개념 추가
This commit is contained in:
@@ -138,47 +138,22 @@ namespace AGVNavigationCore.Controls
|
||||
private float _syncProgress = 0.0f;
|
||||
private string _syncDetail = "";
|
||||
|
||||
string _alertmesage = "";
|
||||
bool showalert = false;
|
||||
string _systemmesage = "";
|
||||
string _infomessage = "";
|
||||
bool showalertsystem = false;
|
||||
bool showinfo = false;
|
||||
|
||||
// 깜박임 효과를 위한 타이머 및 상태
|
||||
private Timer _alertBlinkTimer;
|
||||
private bool _isAlertBlinkOn = true;
|
||||
|
||||
public void SetAlertMessage(string m)
|
||||
public void SetInfoMessage(string m)
|
||||
{
|
||||
_alertmesage = m;
|
||||
showalert = !string.IsNullOrEmpty(m);
|
||||
|
||||
//if (showalert)
|
||||
//{
|
||||
// if (_alertBlinkTimer == null)
|
||||
// {
|
||||
// _alertBlinkTimer = new Timer();
|
||||
// _alertBlinkTimer.Interval = 500; // 0.5초 간격
|
||||
// _alertBlinkTimer.Tick += _alertBlinkTimer_Tick;
|
||||
// }
|
||||
// _alertBlinkTimer.Start();
|
||||
// _isAlertBlinkOn = true;
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// if (_alertBlinkTimer != null)
|
||||
// {
|
||||
// _alertBlinkTimer.Stop();
|
||||
// }
|
||||
// _isAlertBlinkOn = false;
|
||||
//}
|
||||
//Invalidate(); // 즉시 갱신
|
||||
_infomessage = m;
|
||||
showinfo = !string.IsNullOrEmpty(m);
|
||||
}
|
||||
|
||||
private void _alertBlinkTimer_Tick(object sender, EventArgs e)
|
||||
public void SetSystemMessage(string m)
|
||||
{
|
||||
//_isAlertBlinkOn = !_isAlertBlinkOn;
|
||||
//Invalidate();
|
||||
_systemmesage = m;
|
||||
showalertsystem = !string.IsNullOrEmpty(m);
|
||||
}
|
||||
|
||||
|
||||
// 브러쉬 및 펜
|
||||
private Brush _normalNodeBrush;
|
||||
private Brush _rotationNodeBrush;
|
||||
@@ -963,13 +938,6 @@ namespace AGVNavigationCore.Controls
|
||||
// 이미지 정리
|
||||
_companyLogo?.Dispose();
|
||||
|
||||
// 타이머 정리
|
||||
if (_alertBlinkTimer != null)
|
||||
{
|
||||
_alertBlinkTimer.Stop();
|
||||
_alertBlinkTimer.Dispose();
|
||||
_alertBlinkTimer = null;
|
||||
}
|
||||
}
|
||||
|
||||
base.Dispose(disposing);
|
||||
|
||||
Reference in New Issue
Block a user