start working on 0.7.x branch
- added FileLog which stores content to the file log - now Log is only a wrapper - it puts messages to the local buffer and when logsave is used then the buffer is put to FileLog - new base classes: WinixBase (Log, Config*, Synchro*) WinixModel : public WinixBase (morm::ModelConnector*, Plugin*) WinixSystem : public WinixModel (System*) WinixRequest : public WinixSystem (SLog, Cur*) - singletons: log, slog, plugin are depracated - now references to them are in base classses (WinixBase, WinixModel) - DbBase, DbConn and Db are depracated - now we are using Morm project (in WinixModel there is a model_connector pointer) each thread will have its own ModelConnector git-svn-id: svn://ttmath.org/publicrep/winix/branches/0.7.x@1146 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
*/
|
||||
|
||||
/*
|
||||
* Copyright (c) 2008-2014, Tomasz Sowa
|
||||
* Copyright (c) 2008-2018, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -55,10 +55,10 @@ void Notify::SetCur(Cur * pcur)
|
||||
}
|
||||
|
||||
|
||||
void Notify::SetConfig(Config * pconfig)
|
||||
{
|
||||
config = pconfig;
|
||||
}
|
||||
//void Notify::SetConfig(Config * pconfig)
|
||||
//{
|
||||
// config = pconfig;
|
||||
//}
|
||||
|
||||
|
||||
void Notify::SetUsers(Users * pusers)
|
||||
@@ -77,12 +77,21 @@ void Notify::SetThreadManager(ThreadManager * pmanager)
|
||||
}
|
||||
|
||||
|
||||
|
||||
//void Notify::SetFileLog(FileLog * file_log)
|
||||
//{
|
||||
// this->file_log = file_log;
|
||||
//}
|
||||
|
||||
|
||||
|
||||
void Notify::Init()
|
||||
{
|
||||
notify_thread.SetConfig(config);
|
||||
//notify_thread.SetConfig(config);
|
||||
notify_thread.SetUsers(users);
|
||||
notify_thread.SetNotifyPool(¬ify_pool);
|
||||
notify_thread.SetPatterns(&patterns);
|
||||
//notify_thread.SetFileLog(file_log);
|
||||
thread_manager->Add(¬ify_thread, L"notifications");
|
||||
|
||||
patterns.SetDirectories(config->txt_templates_dir, config->txt_templates_dir_default);
|
||||
@@ -93,7 +102,7 @@ void Notify::Init()
|
||||
notify_template_activate_account = AddTemplate(L"notify_confirm_account.txt");
|
||||
notify_template_reset_password = AddTemplate(L"notify_reset_password.txt");
|
||||
|
||||
plugin.Call((Session*)0, WINIX_NOTIFY_ADD_TEMPLATE);
|
||||
plugin->Call((Session*)0, WINIX_NOTIFY_ADD_TEMPLATE);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user