Remove FMT dependency (#1472)

All occurrences of log() have been replaced with qDebug()

bonus meme: remove a bunch of std::string usages in the pubsub client

Fixes #1467
This commit is contained in:
pajlada
2020-01-03 20:51:37 +01:00
committed by GitHub
parent f02988b657
commit 3c8992cac1
57 changed files with 230 additions and 4920 deletions
+2 -1
View File
@@ -10,7 +10,8 @@ BenchmarkGuard::BenchmarkGuard(const QString &_name)
BenchmarkGuard::~BenchmarkGuard()
{
log("{} {} ms", this->name_, float(timer_.nsecsElapsed()) / 1000000.0f);
qDebug() << this->name_ << float(timer_.nsecsElapsed()) / 1000000.0f
<< "ms";
}
qreal BenchmarkGuard::getElapsedMs()
+1 -2
View File
@@ -1,7 +1,6 @@
#pragma once
#include "debug/Log.hpp"
#include <QDebug>
#include <QElapsedTimer>
#include <boost/noncopyable.hpp>
-29
View File
@@ -1,29 +0,0 @@
#pragma once
#include "util/Helpers.hpp"
#include <QDebug>
#include <QTime>
namespace chatterino {
template <typename... Args>
inline void log(const std::string &formatString, Args &&... args)
{
qDebug().noquote() << QTime::currentTime().toString("hh:mm:ss.zzz")
<< fS(formatString, std::forward<Args>(args)...).c_str();
}
template <typename... Args>
inline void log(const char *formatString, Args &&... args)
{
log(std::string(formatString), std::forward<Args>(args)...);
}
template <typename... Args>
inline void log(const QString &formatString, Args &&... args)
{
log(formatString.toStdString(), std::forward<Args>(args)...);
}
} // namespace chatterino