diff options
author | TheCharlatan <seb.kung@gmail.com> | 2024-03-21 16:09:02 +0100 |
---|---|---|
committer | TheCharlatan <seb.kung@gmail.com> | 2024-03-21 16:41:16 +0100 |
commit | 824f47294a309ba8e58ba8d1da0af15d8d828f43 (patch) | |
tree | cc818bc0c5d07182ef66c9e9b63627859c14ed3d /src/noui.cpp | |
parent | ddc7872c08b7ddf9b1e83abdb97c21303f4a9172 (diff) |
node: Use log levels in noui_ThreadSafeMessageBox
Diffstat (limited to 'src/noui.cpp')
-rw-r--r-- | src/noui.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/noui.cpp b/src/noui.cpp index af5a180ce3..23637dfa1f 100644 --- a/src/noui.cpp +++ b/src/noui.cpp @@ -28,20 +28,21 @@ bool noui_ThreadSafeMessageBox(const bilingual_str& message, const std::string& switch (style) { case CClientUIInterface::MSG_ERROR: strCaption = "Error: "; + if (!fSecure) LogError("%s\n", message.original); break; case CClientUIInterface::MSG_WARNING: strCaption = "Warning: "; + if (!fSecure) LogWarning("%s\n", message.original); break; case CClientUIInterface::MSG_INFORMATION: strCaption = "Information: "; + if (!fSecure) LogInfo("%s\n", message.original); break; default: strCaption = caption + ": "; // Use supplied caption (can be empty) + if (!fSecure) LogInfo("%s%s\n", strCaption, message.original); } - if (!fSecure) { - LogPrintf("%s%s\n", strCaption, message.original); - } tfm::format(std::cerr, "%s%s\n", strCaption, message.original); return false; } |