summaryrefslogtreecommitdiff
path: root/Source/Core/Common/Logging/LogManager.h
diff options
context:
space:
mode:
authorJordan Woyak <jordan.woyak@gmail.com>2026-11-04 18:58:44 -0600
committerJordan Woyak <jordan.woyak@gmail.com>2026-11-08 13:08:09 -0600
commitd02fc5f4bb1733a0cfd45ee00b4a8e3ff2a53ca3 (patch)
treeac573056dc0f8e5e992d7d41e2014be511c2da52 /Source/Core/Common/Logging/LogManager.h
parent5c3b7f75e1a5e40a8e9761863d7022b3003c252f (diff)
Common/Logging/LogManager: Add IsListenerEnabled function to avoid string formatting when log types are enabled but all listeners are disabled.
Also eliminate redundant IsEnabled(type, level) check.
Diffstat (limited to 'Source/Core/Common/Logging/LogManager.h')
-rw-r--r--Source/Core/Common/Logging/LogManager.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/Source/Core/Common/Logging/LogManager.h b/Source/Core/Common/Logging/LogManager.h
index 624cd1e697..7e145b0da1 100644
--- a/Source/Core/Common/Logging/LogManager.h
+++ b/Source/Core/Common/Logging/LogManager.h
@@ -75,6 +75,7 @@ public:
void RegisterListener(LogListener::LISTENER id, std::unique_ptr<LogListener> listener);
void EnableListener(LogListener::LISTENER id, bool enable);
bool IsListenerEnabled(LogListener::LISTENER id) const;
+ bool IsAnyListenerEnabled() const { return static_cast<bool>(m_listener_ids); }
void SaveSettings();