summaryrefslogtreecommitdiff
path: root/src/common/logging/backend.h
diff options
context:
space:
mode:
authorGravatar Carl Kenner2018-10-05 12:52:49 +0930
committerGravatar Carl Kenner2018-10-07 13:24:04 +1030
commitf5f6292810dab70bc9be0fa4d9f37fe2b5544d86 (patch)
tree1ec449a6d6e33a36a3133de2196954a6967af9ad /src/common/logging/backend.h
parentMerge pull request #1450 from FearlessTobi/port-4312 (diff)
downloadyuzu-f5f6292810dab70bc9be0fa4d9f37fe2b5544d86.tar.gz
yuzu-f5f6292810dab70bc9be0fa4d9f37fe2b5544d86.tar.xz
yuzu-f5f6292810dab70bc9be0fa4d9f37fe2b5544d86.zip
logging: Add DebuggerBackend for logging to Visual Studio
Diffstat (limited to 'src/common/logging/backend.h')
-rw-r--r--src/common/logging/backend.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/common/logging/backend.h b/src/common/logging/backend.h
index 11edbf1b6..91bb0c309 100644
--- a/src/common/logging/backend.h
+++ b/src/common/logging/backend.h
@@ -103,6 +103,20 @@ private:
103 std::size_t bytes_written; 103 std::size_t bytes_written;
104}; 104};
105 105
106/**
107 * Backend that writes to Visual Studio's output window
108 */
109class DebuggerBackend : public Backend {
110public:
111 static const char* Name() {
112 return "debugger";
113 }
114 const char* GetName() const override {
115 return Name();
116 }
117 void Write(const Entry& entry) override;
118};
119
106void AddBackend(std::unique_ptr<Backend> backend); 120void AddBackend(std::unique_ptr<Backend> backend);
107 121
108void RemoveBackend(std::string_view backend_name); 122void RemoveBackend(std::string_view backend_name);