summaryrefslogtreecommitdiffstats
path: root/src/corelib/doc
diff options
context:
space:
mode:
authorAndre Hartmann <aha_1980@gmx.de>2020-01-04 16:03:35 +0100
committerAndre Hartmann <aha_1980@gmx.de>2020-01-09 02:33:08 +0100
commit1edf8bc46542ad302085b9e957c8c3c31c7db9da (patch)
treea292b9e079067cd86f70ae7b0fa6bf80cf50141d /src/corelib/doc
parent7b092b3fe3c9960a2e2866a3b03818fe63bbbac4 (diff)
QObject: Replace more 0 and NULL with nullptr
... in docs, comments, and warnings. Also adopt some occurrences around there and in the snippets. Change-Id: Icc0aa0868cadd8ec2270dda794bf83cd7ab84160 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Diffstat (limited to 'src/corelib/doc')
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp b/src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp
index 1966f8195a..43bcc22720 100644
--- a/src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp
@@ -71,7 +71,7 @@ QTimer *timer = qobject_cast<QTimer *>(obj);
// timer == (QObject *)obj
QAbstractButton *button = qobject_cast<QAbstractButton *>(obj);
-// button == 0
+// button == nullptr
//! [3]
@@ -144,7 +144,7 @@ class MyObject : public QObject
Q_OBJECT
public:
- MyObject(QObject *parent = 0);
+ MyObject(QObject *parent = nullptr);
protected:
void timerEvent(QTimerEvent *event) override;
@@ -322,7 +322,7 @@ QObject::connect: Cannot queue arguments of type 'MyType'
//! [26]
-disconnect(myObject, 0, 0, 0);
+disconnect(myObject, nullptr, nullptr, nullptr);
//! [26]
@@ -332,7 +332,7 @@ myObject->disconnect();
//! [28]
-disconnect(myObject, SIGNAL(mySignal()), 0, 0);
+disconnect(myObject, SIGNAL(mySignal()), nullptr, nullptr);
//! [28]
@@ -342,7 +342,7 @@ myObject->disconnect(SIGNAL(mySignal()));
//! [30]
-disconnect(myObject, 0, myReceiver, 0);
+disconnect(myObject, nullptr, myReceiver, nullptr);
//! [30]
@@ -391,7 +391,7 @@ class MyClass : public QObject
Q_OBJECT
public:
- MyClass(QObject *parent = 0);
+ MyClass(QObject *parent = nullptr);
~MyClass();
enum Priority { High, Low, VeryHigh, VeryLow };
@@ -467,7 +467,7 @@ QObject::connect(socket, &QTcpSocket::connected, [=] () {
//! [46]
//! [47]
-disconnect(myObject, &MyObject::mySignal(), 0, 0);
+disconnect(myObject, &MyObject::mySignal(), nullptr, nullptr);
//! [47]
//! [48]
@@ -505,7 +505,7 @@ class MyClass : public QWidget
Q_OBJECT
public:
- MyClass(QWidget *parent = 0);
+ MyClass(QWidget *parent = nullptr);
~MyClass();
bool event(QEvent* ev) override