mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
Additional change for r940.
This commit is contained in:
parent
8b605c8fc5
commit
2e9f063cef
@ -95,7 +95,15 @@ void CDialogAbout::Open(int tab)
|
||||
|
||||
void CDialogAbout::AddLogItem(int level, LPCWSTR time, LPCWSTR message)
|
||||
{
|
||||
if (c_Dialog && c_Dialog->m_TabLog && c_Dialog->m_TabLog->IsInitialized())
|
||||
if (!c_Dialog)
|
||||
{
|
||||
if (level == LOG_ERROR)
|
||||
{
|
||||
// Open About Log window for errors
|
||||
CDialogAbout::Open();
|
||||
}
|
||||
}
|
||||
else if (c_Dialog->m_TabLog && c_Dialog->m_TabLog->IsInitialized())
|
||||
{
|
||||
c_Dialog->m_TabLog->AddItem(level, time, message);
|
||||
}
|
||||
|
@ -3079,8 +3079,8 @@ BOOL CRainmeter::ExecuteBang(const std::wstring& bang, const std::wstring& arg,
|
||||
}
|
||||
else
|
||||
{
|
||||
std::wstring error = L"Unknown !bang: " + bang;
|
||||
MessageBox(NULL, error.c_str(), APPNAME, MB_OK | MB_TOPMOST | MB_ICONEXCLAMATION);
|
||||
std::wstring error = L"Unknown bang: " + bang;
|
||||
Log(LOG_ERROR, error.c_str());
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
@ -4350,12 +4350,6 @@ void CRainmeter::DeleteLogFile()
|
||||
|
||||
void CRainmeter::AddAboutLogInfo(int level, LPCWSTR time, LPCWSTR message)
|
||||
{
|
||||
if (level == LOG_ERROR)
|
||||
{
|
||||
// Open About Log window for errors
|
||||
CDialogAbout::Open();
|
||||
}
|
||||
|
||||
// Store 20 last items
|
||||
LOG_INFO logInfo = {level, time, message};
|
||||
m_LogData.push_back(logInfo);
|
||||
|
Loading…
Reference in New Issue
Block a user