diff options
author | Petr Mrázek <peterix@gmail.com> | 2016-11-03 01:10:16 +0100 |
---|---|---|
committer | Petr Mrázek <peterix@gmail.com> | 2016-11-03 01:11:57 +0100 |
commit | f0b71f989ea798495ad80d1f059ae0a28514f9a2 (patch) | |
tree | 8551131b5ce3ccaa3c422f6635aefdbf6ca149ff /api/logic/launch/MessageLevel.cpp | |
parent | ac66af6c13604a4eb2d36cc82417aa6753b84afe (diff) | |
download | PrismLauncher-f0b71f989ea798495ad80d1f059ae0a28514f9a2.tar.gz PrismLauncher-f0b71f989ea798495ad80d1f059ae0a28514f9a2.tar.bz2 PrismLauncher-f0b71f989ea798495ad80d1f059ae0a28514f9a2.zip |
NOISSUE use LoggedProcess to work around issues with QProcess on macOS
Diffstat (limited to 'api/logic/launch/MessageLevel.cpp')
-rw-r--r-- | api/logic/launch/MessageLevel.cpp | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/api/logic/launch/MessageLevel.cpp b/api/logic/launch/MessageLevel.cpp deleted file mode 100644 index a5191290..00000000 --- a/api/logic/launch/MessageLevel.cpp +++ /dev/null @@ -1,36 +0,0 @@ -#include "MessageLevel.h" - -MessageLevel::Enum MessageLevel::getLevel(const QString& levelName) -{ - if (levelName == "MultiMC") - return MessageLevel::MultiMC; - else if (levelName == "Debug") - return MessageLevel::Debug; - else if (levelName == "Info") - return MessageLevel::Info; - else if (levelName == "Message") - return MessageLevel::Message; - else if (levelName == "Warning") - return MessageLevel::Warning; - else if (levelName == "Error") - return MessageLevel::Error; - else if (levelName == "Fatal") - return MessageLevel::Fatal; - // Skip PrePost, it's not exposed to !![]! - // Also skip StdErr and StdOut - else - return MessageLevel::Unknown; -} - -MessageLevel::Enum MessageLevel::fromLine(QString &line) -{ - // Level prefix - int endmark = line.indexOf("]!"); - if (line.startsWith("!![") && endmark != -1) - { - auto level = MessageLevel::getLevel(line.left(endmark).mid(3)); - line = line.mid(endmark + 2); - return level; - } - return MessageLevel::Unknown; -} |