[win-linux] update manager: add FUNCTION_INFO definition

This commit is contained in:
SimplestStudio
2023-08-31 20:48:42 +03:00
parent 4f38e4207b
commit 99d072c381
3 changed files with 6 additions and 4 deletions

View File

@ -40,8 +40,8 @@ using std::string;
using std::to_string;
using std::list;
#define DEFAULT_ERROR_MESSAGE "An error occurred: " + \
string(__FUNCTION__) + " Line: " + to_string(__LINE__)
#define FUNCTION_INFO string(__FUNCTION__) + " Line: " + to_string(__LINE__)
#define DEFAULT_ERROR_MESSAGE "An error occurred: " + FUNCTION_INFO
#define ADVANCED_ERROR_MESSAGE DEFAULT_ERROR_MESSAGE + \
" " + NS_Utils::GetLastErrorAsString()

View File

@ -41,8 +41,8 @@ using std::wstring;
using std::to_wstring;
using std::list;
#define DEFAULT_ERROR_MESSAGE L"An error occurred: " + \
wstring(TEXT(__FUNCTION__)) + L" Line: " + to_wstring(__LINE__)
#define FUNCTION_INFO wstring(TEXT(__FUNCTION__)) + L" Line: " + to_wstring(__LINE__)
#define DEFAULT_ERROR_MESSAGE L"An error occurred: " + FUNCTION_INFO
#define ADVANCED_ERROR_MESSAGE DEFAULT_ERROR_MESSAGE + \
L" " + NS_Utils::GetLastErrorAsString()

View File

@ -6,6 +6,8 @@
#include <QTextStream>
#include <QDateTime>
#define FUNCTION_INFO QString("%1 Line: %2").arg(QString(__FUNCTION__), QString::number(__LINE__))
class CLogger : public QObject
{
Q_OBJECT