summaryrefslogtreecommitdiffstats
path: root/src/widgets
diff options
context:
space:
mode:
Diffstat (limited to 'src/widgets')
-rw-r--r--src/widgets/kernel/qsizepolicy.cpp3
-rw-r--r--src/widgets/kernel/qsizepolicy.h5
2 files changed, 3 insertions, 5 deletions
diff --git a/src/widgets/kernel/qsizepolicy.cpp b/src/widgets/kernel/qsizepolicy.cpp
index c354d14f5e..fe34ef5982 100644
--- a/src/widgets/kernel/qsizepolicy.cpp
+++ b/src/widgets/kernel/qsizepolicy.cpp
@@ -317,9 +317,8 @@ void QSizePolicy::setControlType(ControlType type) noexcept
*/
/*!
- \fn size_t qHash(QSizePolicy key, size_t seed = 0)
+ \fn size_t QSizePolicy::qHash(QSizePolicy key, size_t seed = 0)
\since 5.6
- \relates QSizePolicy
Returns the hash value for \a key, using
\a seed to seed the calculation.
diff --git a/src/widgets/kernel/qsizepolicy.h b/src/widgets/kernel/qsizepolicy.h
index 5e948175f3..53c7afc906 100644
--- a/src/widgets/kernel/qsizepolicy.h
+++ b/src/widgets/kernel/qsizepolicy.h
@@ -43,14 +43,13 @@
#include <QtWidgets/qtwidgetsglobal.h>
#include <QtCore/qobject.h>
#include <QtCore/qalgorithms.h>
+#include <QtCore/qhashfunctions.h>
QT_BEGIN_NAMESPACE
class QVariant;
class QSizePolicy;
-Q_DECL_CONST_FUNCTION inline size_t qHash(QSizePolicy key, size_t seed = 0) noexcept;
-
class Q_WIDGETS_EXPORT QSizePolicy
{
Q_GADGET
@@ -122,7 +121,7 @@ public:
constexpr bool operator==(const QSizePolicy& s) const noexcept { return data == s.data; }
constexpr bool operator!=(const QSizePolicy& s) const noexcept { return data != s.data; }
- friend Q_DECL_CONST_FUNCTION size_t qHash(QSizePolicy key, size_t seed) noexcept { return qHash(key.data, seed); }
+ friend Q_DECL_CONST_FUNCTION size_t qHash(QSizePolicy key, size_t seed = 0) noexcept { return qHash(key.data, seed); }
operator QVariant() const;