Fix build on Qt 5.15 Beta 2

Reverts most of 10dae7482c
This commit is contained in:
Cameron Gutman 2020-03-23 18:30:56 -07:00
commit 6c980eba68
6 changed files with 17 additions and 22 deletions

View file

@ -1,18 +1,8 @@
#pragma once
#include <QtGlobal>
#define THROW_BAD_ALLOC_IF_NULL(x) \
if ((x) == nullptr) throw std::bad_alloc()
#if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0)
#define QNETREPLY_GET_ERROR(r) ((r)->networkError())
#define QSOCK_GET_ERROR(s) ((s)->socketError())
#else
#define QNETREPLY_GET_ERROR(r) ((r)->error())
#define QSOCK_GET_ERROR(s) ((s)->error())
#endif
namespace WMUtils {
bool isRunningX11();
bool isRunningWayland();