From 8fc7d3315b3317ce7a3bf2ac4f0b3636623e515e Mon Sep 17 00:00:00 2001 From: Peter Hartmann Date: Wed, 24 Feb 2010 16:48:51 +0100 Subject: QUrl: document adding of hash function Reviewed-by: TrustMe --- src/corelib/io/qurl.cpp | 7 +++++++ src/corelib/io/qurl.h | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/corelib/io/qurl.cpp b/src/corelib/io/qurl.cpp index 0290fb8..32f7ac2 100644 --- a/src/corelib/io/qurl.cpp +++ b/src/corelib/io/qurl.cpp @@ -167,6 +167,13 @@ regardless of the Qt::FormattingOptions used. */ +/*! + \fn uint qHash(const QUrl &url) + \since 4.7 + \relates QUrl + + Computes a hash key from the normalized version of \a url. + */ #include "qplatformdefs.h" #include "qurl.h" #include "private/qunicodetables_p.h" diff --git a/src/corelib/io/qurl.h b/src/corelib/io/qurl.h index 906979c..6f8331a 100644 --- a/src/corelib/io/qurl.h +++ b/src/corelib/io/qurl.h @@ -270,9 +270,9 @@ public: inline DataPtr &data_ptr() { return d; } }; -inline uint qHash(const QUrl &uri) +inline uint qHash(const QUrl &url) { - return qHash(uri.toEncoded(QUrl::FormattingOption(0x100))); + return qHash(url.toEncoded(QUrl::FormattingOption(0x100))); } Q_DECLARE_TYPEINFO(QUrl, Q_MOVABLE_TYPE); -- cgit v0.12