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); }
|
{ value1.swap(value2); }
|
||||||
#define Q_DECLARE_SHARED(TYPE) Q_DECLARE_SHARED_IMPL(TYPE, Q_MOVABLE_TYPE)
|
#define Q_DECLARE_SHARED(TYPE) Q_DECLARE_SHARED_IMPL(TYPE, Q_MOVABLE_TYPE)
|
||||||
#define Q_DECLARE_SHARED_NOT_MOVABLE_UNTIL_QT6(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
|
namespace QTypeTraits
|
||||||
{
|
{
|
||||||
|
@ -769,19 +769,11 @@ void QThreadPool::clear()
|
|||||||
d->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
|
\since 6.0
|
||||||
|
|
||||||
Returns \c true if \a thread is a thread managed by this thread pool.
|
Returns \c true if \a thread is a thread managed by this thread pool.
|
||||||
*/
|
*/
|
||||||
#endif
|
|
||||||
bool QThreadPool::contains(const QThread *thread) const
|
bool QThreadPool::contains(const QThread *thread) const
|
||||||
{
|
{
|
||||||
Q_D(const QThreadPool);
|
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,
|
Constructs a new DBus message representing an error reply message,
|
||||||
with the given \a name and \a msg.
|
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
|
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);
|
QDBusMessage reply = QDBusMessage::createError(name, msg);
|
||||||
if (d_ptr->msg)
|
if (d_ptr->msg)
|
||||||
|
@ -89,11 +89,7 @@ public:
|
|||||||
inline QDBusMessage createReply(const QVariant &argument) const
|
inline QDBusMessage createReply(const QVariant &argument) const
|
||||||
{ return createReply(QList<QVariant>() << argument); }
|
{ return createReply(QList<QVariant>() << argument); }
|
||||||
|
|
||||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
|
||||||
QDBusMessage createErrorReply(const QString &name, const QString &msg) const;
|
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
|
inline QDBusMessage createErrorReply(const QDBusError &err) const
|
||||||
{ return createErrorReply(err.name(), err.message()); }
|
{ return createErrorReply(err.name(), err.message()); }
|
||||||
QDBusMessage createErrorReply(QDBusError::ErrorType type, const QString &msg) const;
|
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.
|
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)
|
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()
|
:QPaintDevice()
|
||||||
{
|
{
|
||||||
d = QImageData::create(data, width, height, bytesPerLine, format, false, cleanupFunction, cleanupInfo);
|
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.
|
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)
|
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()
|
:QPaintDevice()
|
||||||
{
|
{
|
||||||
d = QImageData::create(const_cast<uchar*>(data), width, height, bytesPerLine, format, true, cleanupFunction, cleanupInfo);
|
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(int width, int height, Format format);
|
||||||
QImage(uchar *data, int width, int height, Format format, QImageCleanupFunction cleanupFunction = nullptr, void *cleanupInfo = nullptr);
|
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);
|
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(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);
|
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
|
#ifndef QT_NO_IMAGEFORMAT_XPM
|
||||||
explicit QImage(const char * const xpm[]);
|
explicit QImage(const char * const xpm[]);
|
||||||
|
@ -106,12 +106,7 @@ public:
|
|||||||
KeyboardScheme,
|
KeyboardScheme,
|
||||||
UiEffects,
|
UiEffects,
|
||||||
SpellCheckUnderlineStyle,
|
SpellCheckUnderlineStyle,
|
||||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
|
||||||
TabFocusBehavior,
|
TabFocusBehavior,
|
||||||
#else
|
|
||||||
TabAllWidgets,
|
|
||||||
TabFocusBehavior = TabAllWidgets,
|
|
||||||
#endif
|
|
||||||
IconPixmapSizes,
|
IconPixmapSizes,
|
||||||
PasswordMaskCharacter,
|
PasswordMaskCharacter,
|
||||||
DialogSnapToDefaultButton,
|
DialogSnapToDefaultButton,
|
||||||
|
@ -841,20 +841,6 @@ QColor::QColor(Spec spec) noexcept
|
|||||||
\sa setNamedColor(), name(), isValid()
|
\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
|
\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) {}
|
: cspec(spec), ct(a1, a2, a3, a4, a5) {}
|
||||||
#endif // Q_COMPILER_UNIFORM_INIT
|
#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)
|
inline QColor::QColor(QLatin1String aname)
|
||||||
{ setNamedColor(aname); }
|
{ setNamedColor(aname); }
|
||||||
|
@ -118,7 +118,7 @@ private:
|
|||||||
friend Q_GUI_EXPORT QDataStream &operator<<(QDataStream &, const QTextLength &);
|
friend Q_GUI_EXPORT QDataStream &operator<<(QDataStream &, const QTextLength &);
|
||||||
friend Q_GUI_EXPORT QDataStream &operator>>(QDataStream &, 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)
|
inline QTextLength::QTextLength(Type atype, qreal avalue)
|
||||||
: lengthType(atype), fixedValueOrPercentage(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) {}
|
iterator(const QTextDocumentPrivate *priv, int begin, int end, int f) : p(priv), b(begin), e(end), n(f) {}
|
||||||
public:
|
public:
|
||||||
iterator() : p(nullptr), b(0), e(0), n(0) {}
|
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;
|
QTextFragment fragment() const;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user