From ae62c5717e0ca6e90f484cf6d25dbd48907b7c40 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Tue, 20 Apr 2021 08:26:23 +0200 Subject: [PATCH] Documentation: Fix broken links to QIODeviceBase::OpenMode Previously, QIODeviceBase was not visible in the documentation and the links from QIODevice::open() were broken. Fix by fully qualifying the arguments. Change-Id: I43960ac2ff436251cc3bfad862d82f937b9bd4b1 Reviewed-by: Paul Wicking (cherry picked from commit 1b1844afef81520520ba75146f835a7dbbbb5fd6) Reviewed-by: Qt Cherry-pick Bot --- src/corelib/io/qiodevice.cpp | 12 ++++++------ src/corelib/io/qiodevice.h | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/corelib/io/qiodevice.cpp b/src/corelib/io/qiodevice.cpp index 0bea68acc58..d07897141c8 100644 --- a/src/corelib/io/qiodevice.cpp +++ b/src/corelib/io/qiodevice.cpp @@ -527,7 +527,7 @@ bool QIODevice::isSequential() const \sa OpenMode */ -QIODevice::OpenMode QIODevice::openMode() const +QIODeviceBase::OpenMode QIODevice::openMode() const { return d_func()->openMode; } @@ -539,7 +539,7 @@ QIODevice::OpenMode QIODevice::openMode() const \sa openMode(), OpenMode */ -void QIODevice::setOpenMode(OpenMode openMode) +void QIODevice::setOpenMode(QIODeviceBase::OpenMode openMode) { Q_D(QIODevice); #if defined QIODEVICE_DEBUG @@ -589,7 +589,7 @@ bool QIODevice::isTextModeEnabled() const default, this function returns \c false if openMode() returns \c NotOpen. - \sa openMode(), OpenMode + \sa openMode(), QIODeviceBase::OpenMode */ bool QIODevice::isOpen() const { @@ -774,9 +774,9 @@ bool QIODevicePrivate::allWriteBuffersEmpty() const otherwise returns \c false. This function should be called from any reimplementations of open() or other functions that open the device. - \sa openMode(), OpenMode + \sa openMode(), QIODeviceBase::OpenMode */ -bool QIODevice::open(OpenMode mode) +bool QIODevice::open(QIODeviceBase::OpenMode mode) { Q_D(QIODevice); d->openMode = mode; @@ -797,7 +797,7 @@ bool QIODevice::open(OpenMode mode) First emits aboutToClose(), then closes the device and sets its OpenMode to NotOpen. The error string is also reset. - \sa setOpenMode(), OpenMode + \sa setOpenMode(), QIODeviceBase::OpenMode */ void QIODevice::close() { diff --git a/src/corelib/io/qiodevice.h b/src/corelib/io/qiodevice.h index e4388b89726..fd97e8d1e5b 100644 --- a/src/corelib/io/qiodevice.h +++ b/src/corelib/io/qiodevice.h @@ -78,7 +78,7 @@ public: #endif virtual ~QIODevice(); - OpenMode openMode() const; + QIODeviceBase::OpenMode openMode() const; void setTextModeEnabled(bool enabled); bool isTextModeEnabled() const; @@ -95,7 +95,7 @@ public: int currentWriteChannel() const; void setCurrentWriteChannel(int channel); - virtual bool open(OpenMode mode); + virtual bool open(QIODeviceBase::OpenMode mode); virtual void close(); // ### Qt 7 - QTBUG-76492: pos() and seek() should not be virtual, and @@ -159,7 +159,7 @@ protected: virtual qint64 skipData(qint64 maxSize); virtual qint64 writeData(const char *data, qint64 len) = 0; - void setOpenMode(OpenMode openMode); + void setOpenMode(QIODeviceBase::OpenMode openMode); void setErrorString(const QString &errorString);