Get rid of some #ifdef qt6
None of this code is even compiled in qt6. Change-Id: I5891cc9459320083ad3908fcbf646f3ba75b8a4d Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
47ae99a07a
commit
cc692bb58c
@ -218,7 +218,7 @@ inline void swap(TYPE &value1, TYPE &value2) \
|
||||
{ value1.swap(value2); }
|
||||
#define Q_DECLARE_SHARED(TYPE) Q_DECLARE_SHARED_IMPL(TYPE, Q_MOVABLE_TYPE)
|
||||
#define Q_DECLARE_SHARED_NOT_MOVABLE_UNTIL_QT6(TYPE) \
|
||||
Q_DECLARE_SHARED_IMPL(TYPE, QT_VERSION >= QT_VERSION_CHECK(6,0,0) ? Q_MOVABLE_TYPE : Q_RELOCATABLE_TYPE)
|
||||
Q_DECLARE_SHARED_IMPL(TYPE, Q_MOVABLE_TYPE)
|
||||
|
||||
namespace QTypeTraits
|
||||
{
|
||||
|
@ -769,19 +769,11 @@ void QThreadPool::clear()
|
||||
d->clear();
|
||||
}
|
||||
|
||||
#if QT_VERSION < QT_VERSION_CHECK(6,0,0)
|
||||
/*!
|
||||
\internal
|
||||
|
||||
Returns \c true if \a thread is a thread managed by this thread pool.
|
||||
*/
|
||||
#else
|
||||
/*!
|
||||
\since 6.0
|
||||
|
||||
Returns \c true if \a thread is a thread managed by this thread pool.
|
||||
*/
|
||||
#endif
|
||||
bool QThreadPool::contains(const QThread *thread) const
|
||||
{
|
||||
Q_D(const QThreadPool);
|
||||
|
@ -496,11 +496,7 @@ QDBusMessage QDBusMessage::createReply(const QVariantList &arguments) const
|
||||
Constructs a new DBus message representing an error reply message,
|
||||
with the given \a name and \a msg.
|
||||
*/
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
QDBusMessage QDBusMessage::createErrorReply(const QString &name, const QString &msg) const
|
||||
#else
|
||||
QDBusMessage QDBusMessage::createErrorReply(const QString name, const QString &msg) const
|
||||
#endif
|
||||
{
|
||||
QDBusMessage reply = QDBusMessage::createError(name, msg);
|
||||
if (d_ptr->msg)
|
||||
|
@ -89,11 +89,7 @@ public:
|
||||
inline QDBusMessage createReply(const QVariant &argument) const
|
||||
{ return createReply(QList<QVariant>() << argument); }
|
||||
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
QDBusMessage createErrorReply(const QString &name, const QString &msg) const;
|
||||
#else
|
||||
QDBusMessage createErrorReply(const QString name, const QString &msg) const;
|
||||
#endif
|
||||
inline QDBusMessage createErrorReply(const QDBusError &err) const
|
||||
{ return createErrorReply(err.name(), err.message()); }
|
||||
QDBusMessage createErrorReply(QDBusError::ErrorType type, const QString &msg) const;
|
||||
|
@ -903,11 +903,7 @@ QImage::QImage(const uchar* data, int width, int height, Format format, QImageCl
|
||||
setColorCount() or setColorTable() before the image is used.
|
||||
*/
|
||||
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
QImage::QImage(uchar *data, int width, int height, qsizetype bytesPerLine, Format format, QImageCleanupFunction cleanupFunction, void *cleanupInfo)
|
||||
#else
|
||||
QImage::QImage(uchar *data, int width, int height, int bytesPerLine, Format format, QImageCleanupFunction cleanupFunction, void *cleanupInfo)
|
||||
#endif
|
||||
:QPaintDevice()
|
||||
{
|
||||
d = QImageData::create(data, width, height, bytesPerLine, format, false, cleanupFunction, cleanupInfo);
|
||||
@ -938,11 +934,7 @@ QImage::QImage(uchar *data, int width, int height, int bytesPerLine, Format form
|
||||
data being changed.
|
||||
*/
|
||||
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
QImage::QImage(const uchar *data, int width, int height, qsizetype bytesPerLine, Format format, QImageCleanupFunction cleanupFunction, void *cleanupInfo)
|
||||
#else
|
||||
QImage::QImage(const uchar *data, int width, int height, int bytesPerLine, Format format, QImageCleanupFunction cleanupFunction, void *cleanupInfo)
|
||||
#endif
|
||||
:QPaintDevice()
|
||||
{
|
||||
d = QImageData::create(const_cast<uchar*>(data), width, height, bytesPerLine, format, true, cleanupFunction, cleanupInfo);
|
||||
|
@ -115,13 +115,8 @@ public:
|
||||
QImage(int width, int height, Format format);
|
||||
QImage(uchar *data, int width, int height, Format format, QImageCleanupFunction cleanupFunction = nullptr, void *cleanupInfo = nullptr);
|
||||
QImage(const uchar *data, int width, int height, Format format, QImageCleanupFunction cleanupFunction = nullptr, void *cleanupInfo = nullptr);
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
QImage(uchar *data, int width, int height, qsizetype bytesPerLine, Format format, QImageCleanupFunction cleanupFunction = nullptr, void *cleanupInfo = nullptr);
|
||||
QImage(const uchar *data, int width, int height, qsizetype bytesPerLine, Format format, QImageCleanupFunction cleanupFunction = nullptr, void *cleanupInfo = nullptr);
|
||||
#else
|
||||
QImage(uchar *data, int width, int height, int bytesPerLine, Format format, QImageCleanupFunction cleanupFunction = nullptr, void *cleanupInfo = nullptr);
|
||||
QImage(const uchar *data, int width, int height, int bytesPerLine, Format format, QImageCleanupFunction cleanupFunction = nullptr, void *cleanupInfo = nullptr);
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_IMAGEFORMAT_XPM
|
||||
explicit QImage(const char * const xpm[]);
|
||||
|
@ -106,12 +106,7 @@ public:
|
||||
KeyboardScheme,
|
||||
UiEffects,
|
||||
SpellCheckUnderlineStyle,
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
TabFocusBehavior,
|
||||
#else
|
||||
TabAllWidgets,
|
||||
TabFocusBehavior = TabAllWidgets,
|
||||
#endif
|
||||
IconPixmapSizes,
|
||||
PasswordMaskCharacter,
|
||||
DialogSnapToDefaultButton,
|
||||
|
@ -841,20 +841,6 @@ QColor::QColor(Spec spec) noexcept
|
||||
\sa setNamedColor(), name(), isValid()
|
||||
*/
|
||||
|
||||
#if QT_VERSION < QT_VERSION_CHECK(6,0,0)
|
||||
/*!
|
||||
\if !defined(qt6)
|
||||
\fn QColor::QColor(const QColor &color)
|
||||
|
||||
Constructs a color that is a copy of \a color.
|
||||
|
||||
\sa isValid()
|
||||
\else
|
||||
\nothing
|
||||
\endif
|
||||
*/
|
||||
#endif
|
||||
|
||||
/*!
|
||||
\fn bool QColor::isValid() const
|
||||
|
||||
|
@ -297,7 +297,7 @@ public: // can't give friendship to a namespace, so it needs to be public
|
||||
: cspec(spec), ct(a1, a2, a3, a4, a5) {}
|
||||
#endif // Q_COMPILER_UNIFORM_INIT
|
||||
};
|
||||
Q_DECLARE_TYPEINFO(QColor, QT_VERSION >= QT_VERSION_CHECK(6,0,0) ? Q_MOVABLE_TYPE : Q_RELOCATABLE_TYPE);
|
||||
Q_DECLARE_TYPEINFO(QColor, Q_MOVABLE_TYPE);
|
||||
|
||||
inline QColor::QColor(QLatin1String aname)
|
||||
{ setNamedColor(aname); }
|
||||
|
@ -118,7 +118,7 @@ private:
|
||||
friend Q_GUI_EXPORT QDataStream &operator<<(QDataStream &, const QTextLength &);
|
||||
friend Q_GUI_EXPORT QDataStream &operator>>(QDataStream &, QTextLength &);
|
||||
};
|
||||
Q_DECLARE_TYPEINFO(QTextLength, QT_VERSION >= QT_VERSION_CHECK(6,0,0) ? Q_PRIMITIVE_TYPE : Q_RELOCATABLE_TYPE);
|
||||
Q_DECLARE_TYPEINFO(QTextLength, Q_PRIMITIVE_TYPE);
|
||||
|
||||
inline QTextLength::QTextLength(Type atype, qreal avalue)
|
||||
: lengthType(atype), fixedValueOrPercentage(avalue) {}
|
||||
|
@ -250,10 +250,6 @@ public:
|
||||
iterator(const QTextDocumentPrivate *priv, int begin, int end, int f) : p(priv), b(begin), e(end), n(f) {}
|
||||
public:
|
||||
iterator() : p(nullptr), b(0), e(0), n(0) {}
|
||||
#if QT_VERSION < QT_VERSION_CHECK(6,0,0)
|
||||
iterator(const iterator &o) : p(o.p), b(o.b), e(o.e), n(o.n) {}
|
||||
iterator &operator=(const iterator &o) = default;
|
||||
#endif
|
||||
|
||||
QTextFragment fragment() const;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user