Added message log to history items; new field <Log> is returned by RPC-command <history> for each item

This commit is contained in:
Andrey Prygunkov
2009-09-19 15:49:08 +00:00
parent c37b8f37e2
commit dc9e938510
6 changed files with 155 additions and 10 deletions

View File

@@ -746,6 +746,15 @@ void PostScriptController::Run()
void PostScriptController::AddMessage(Message::EKind eKind, bool bDefaultKind, Options::EMessageTarget eMessageTarget, const char* szText)
{
if (!strncmp(szText, "[HISTORY] ", 10))
{
if (eMessageTarget == Options::mtScreen || eMessageTarget == Options::mtBoth)
{
m_pPostInfo->GetNZBInfo()->AppendMessage(eKind, 0, szText + 10);
}
return;
}
ScriptController::AddMessage(eKind, bDefaultKind, eMessageTarget, szText);
if (eMessageTarget == Options::mtScreen || eMessageTarget == Options::mtBoth)