QtBase: #ifdef out definitions of deprecated methods
Some of the deprecated methods didn't have their definitions guarded by if QT_DEPRECATED_SINCE(MAJ, MIN) This patch fixes such cases over all QtBase. Task-number: QTBUG-104857 Pick-to: 6.4 6.3 6.2 Change-Id: I0106128f3a35a30c9f2949819f39076e773559e7 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Marc Mutz <marc.mutz@qt.io>
This commit is contained in:
parent
c0a5f17679
commit
12535b0c03
@ -4430,6 +4430,7 @@ QTouchEvent::QTouchEvent(QEvent::Type eventType,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if QT_DEPRECATED_SINCE(6, 0)
|
||||||
/*!
|
/*!
|
||||||
\deprecated [6.0] Use another constructor.
|
\deprecated [6.0] Use another constructor.
|
||||||
|
|
||||||
@ -4449,6 +4450,7 @@ QTouchEvent::QTouchEvent(QEvent::Type eventType,
|
|||||||
for (QEventPoint &point : m_points)
|
for (QEventPoint &point : m_points)
|
||||||
QMutableEventPoint::setDevice(point, device);
|
QMutableEventPoint::setDevice(point, device);
|
||||||
}
|
}
|
||||||
|
#endif // QT_DEPRECATED_SINCE(6, 0)
|
||||||
|
|
||||||
Q_IMPL_EVENT_COMMON(QTouchEvent)
|
Q_IMPL_EVENT_COMMON(QTouchEvent)
|
||||||
|
|
||||||
|
@ -430,6 +430,7 @@ QPointF QEventPoint::normalizedPosition() const
|
|||||||
return (globalPosition() - geom.topLeft()) / geom.width();
|
return (globalPosition() - geom.topLeft()) / geom.width();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if QT_DEPRECATED_SINCE(6, 0)
|
||||||
/*!
|
/*!
|
||||||
\deprecated [6.0] Use globalPressPosition() instead.
|
\deprecated [6.0] Use globalPressPosition() instead.
|
||||||
|
|
||||||
@ -467,7 +468,7 @@ QPointF QEventPoint::lastNormalizedPos() const
|
|||||||
return QPointF();
|
return QPointF();
|
||||||
return (globalLastPosition() - geom.topLeft()) / geom.width();
|
return (globalLastPosition() - geom.topLeft()) / geom.width();
|
||||||
}
|
}
|
||||||
|
#endif // QT_DEPRECATED_SINCE(6, 0)
|
||||||
|
|
||||||
/*! \internal
|
/*! \internal
|
||||||
This class is explicitly shared, which means if you construct an event and
|
This class is explicitly shared, which means if you construct an event and
|
||||||
|
@ -145,6 +145,7 @@ QPointingDevice::QPointingDevice(QPointingDevicePrivate &d, QObject *parent)
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if QT_DEPRECATED_SINCE(6, 0)
|
||||||
/*!
|
/*!
|
||||||
\internal
|
\internal
|
||||||
\deprecated [6.0] Please use the constructor rather than setters.
|
\deprecated [6.0] Please use the constructor rather than setters.
|
||||||
@ -195,6 +196,7 @@ void QPointingDevice::setMaximumTouchPoints(int c)
|
|||||||
Q_D(QPointingDevice);
|
Q_D(QPointingDevice);
|
||||||
d->maximumTouchPoints = c;
|
d->maximumTouchPoints = c;
|
||||||
}
|
}
|
||||||
|
#endif // QT_DEPRECATED_SINCE(6, 0)
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
Returns the pointer type.
|
Returns the pointer type.
|
||||||
|
@ -717,8 +717,10 @@ void QSurfaceFormat::setColorSpace(const QColorSpace &colorSpace)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if QT_DEPRECATED_SINCE(6, 0)
|
||||||
/*!
|
/*!
|
||||||
\overload
|
\overload
|
||||||
|
\deprecated [6.0] Use setColorSpace(QColorSpace) instead.
|
||||||
|
|
||||||
Sets the colorspace to one of the predefined values.
|
Sets the colorspace to one of the predefined values.
|
||||||
|
|
||||||
@ -737,6 +739,7 @@ void QSurfaceFormat::setColorSpace(ColorSpace colorSpace)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif // QT_DEPRECATED_SINCE(6, 0)
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\return the color space.
|
\return the color space.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user