mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
19 lines
319 B
C++
19 lines
319 B
C++
|
#pragma once
|
||
|
|
||
|
#include <QCoreApplication>
|
||
|
#include <QThread>
|
||
|
#include <cassert>
|
||
|
|
||
|
namespace chatterino {
|
||
|
namespace util {
|
||
|
|
||
|
void assertInGuiThread()
|
||
|
{
|
||
|
#ifdef _DEBUG
|
||
|
assert(QCoreApplication::instance()->thread() == QThread::currentThread());
|
||
|
#endif
|
||
|
}
|
||
|
|
||
|
} // namespace util
|
||
|
} // namespace chatterino
|