rpcs3/rpcs3/Emu/SysCalls/LogBase.cpp

22 lines
615 B
C++
Raw Normal View History

2014-08-22 16:58:50 +02:00
#include "stdafx.h"
2014-08-22 23:15:02 +02:00
#include "Emu/System.h"
#include "Emu/state.h"
2014-08-22 16:58:50 +02:00
#include "LogBase.h"
2014-08-22 23:15:02 +02:00
bool LogBase::CheckLogging() const
{
return rpcs3::config.misc.log.hle_logging.value() || m_logging;
2014-08-22 23:15:02 +02:00
}
void LogBase::LogOutput(LogType type, std::string text) const
2014-08-22 16:58:50 +02:00
{
2014-08-23 16:51:51 +02:00
switch (type)
{
case LogNotice: LOG_NOTICE(HLE, GetName() + ": " + text); break;
case LogSuccess: LOG_SUCCESS(HLE, GetName() + ": " + text); break;
case LogWarning: LOG_WARNING(HLE, GetName() + ": " + text); break;
case LogError: LOG_ERROR(HLE, GetName() + ": " + text); break;
case LogTodo: LOG_ERROR(HLE, GetName() + " TODO: " + text); break;
2014-09-08 16:56:47 +02:00
}
}