From 5e59b396b0b9e0245e0f47b9878dfe547e34fb26 Mon Sep 17 00:00:00 2001 From: Gabi Melman Date: Sun, 24 Sep 2023 21:40:19 +0300 Subject: [PATCH] Update wincolor_sink.cpp --- src/sinks/wincolor_sink.cpp | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) diff --git a/src/sinks/wincolor_sink.cpp b/src/sinks/wincolor_sink.cpp index f4574bcf..7601ebef 100644 --- a/src/sinks/wincolor_sink.cpp +++ b/src/sinks/wincolor_sink.cpp @@ -2,15 +2,12 @@ // Distributed under the MIT License (http://opensource.org/licenses/MIT) #ifdef _WIN32 -# pragma once +#include +#include +#include +#include -# include - -# include -# include - -# include -# include +#include namespace spdlog { namespace sinks { @@ -20,7 +17,6 @@ wincolor_sink::wincolor_sink(void *out_handle, color_mode mode) , mutex_(ConsoleMutex::mutex()) , formatter_(std::make_unique()) { - set_color_mode_impl(mode); // set level colors colors_.at(level_to_number(level::trace)) = FOREGROUND_RED | FOREGROUND_GREEN | FOREGROUND_BLUE; // white @@ -174,10 +170,11 @@ wincolor_stderr_sink::wincolor_stderr_sink(color_mode mode) } // namespace spdlog // template instantiations -template SPDLOG_API class spdlog::sinks::wincolor_stdout_sink; -template SPDLOG_API class spdlog::sinks::wincolor_stdout_sink; +template class SPDLOG_API spdlog::sinks::wincolor_sink; +template class SPDLOG_API spdlog::sinks::wincolor_sink; +template class SPDLOG_API spdlog::sinks::wincolor_stdout_sink; +template class SPDLOG_API spdlog::sinks::wincolor_stdout_sink; +template class SPDLOG_API spdlog::sinks::wincolor_stderr_sink; +template class SPDLOG_API spdlog::sinks::wincolor_stderr_sink; -template SPDLOG_API class spdlog::sinks::wincolor_stderr_sink; -template SPDLOG_API class spdlog::sinks::wincolor_stderr_sink; - -#endif // _WIN32 \ No newline at end of file +#endif // _WIN32