[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [kregexpeditor] src: Use nullptr
From:       Montel Laurent <null () kde ! org>
Date:       2017-05-26 5:57:23
Message-ID: E1dE8FX-0008Ux-9o () code ! kde ! org
[Download RAW message or body]

Git commit 0a08ee3dd26a74b5b261dfe266b1b398afebaa39 by Montel Laurent.
Committed on 26/05/2017 at 05:57.
Pushed by mlaurent into branch 'master'.

Use nullptr

M  +2    -2    src/KMultiFormListBox/widgetwindow.cpp
M  +1    -1    src/altnregexp.cpp
M  +1    -1    src/lookaheadregexp.h
M  +1    -1    src/widgetfactory.cpp

https://commits.kde.org/kregexpeditor/0a08ee3dd26a74b5b261dfe266b1b398afebaa39

diff --git a/src/KMultiFormListBox/widgetwindow.cpp b/src/KMultiFormListBox/widgetwindow.cpp
index a904099..d783ee9 100644
--- a/src/KMultiFormListBox/widgetwindow.cpp
+++ b/src/KMultiFormListBox/widgetwindow.cpp
@@ -57,7 +57,7 @@ void WidgetWindow::init(KMultiFormListBoxFactory *factory, QListWidget *lb, KMul
     lay->setSpacing(-1);
     lay->setMargin(0);
 
-    if (widget != 0) {
+    if (widget != nullptr) {
         myWidget = widget;
         widget->setParent(frame);
     } else {
@@ -70,7 +70,7 @@ void WidgetWindow::init(KMultiFormListBoxFactory *factory, QListWidget *lb, KMul
 
     lay->addWidget(myWidget);
 
-    if (widget != 0) {
+    if (widget != nullptr) {
         initialShow = false;
         myListboxItem = new WindowListboxItem(listbox, myWidget->idxString(), this);
     } else {
diff --git a/src/altnregexp.cpp b/src/altnregexp.cpp
index 84b6f6e..3e61cac 100644
--- a/src/altnregexp.cpp
+++ b/src/altnregexp.cpp
@@ -63,7 +63,7 @@ bool AltnRegExp::load(QDomElement top, const QString &version)
         }
 
         RegExp *regexp = WidgetFactory::createRegExp(child.toElement(), version);
-        if (regexp == 0) {
+        if (regexp == nullptr) {
             return false;
         }
         addRegExp(regexp);
diff --git a/src/lookaheadregexp.h b/src/lookaheadregexp.h
index ee5a3ce..e7bf8aa 100644
--- a/src/lookaheadregexp.h
+++ b/src/lookaheadregexp.h
@@ -32,7 +32,7 @@ public:
         POSITIVE, NEGATIVE
     };
 
-    LookAheadRegExp(bool selected, TYPE tp, RegExp *child = 0);
+    LookAheadRegExp(bool selected, TYPE tp, RegExp *child = nullptr);
 
     bool check(ErrorMap &, bool first, bool last) override;
     int precedence() const override
diff --git a/src/widgetfactory.cpp b/src/widgetfactory.cpp
index 0f179e2..0b122b0 100644
--- a/src/widgetfactory.cpp
+++ b/src/widgetfactory.cpp
@@ -48,7 +48,7 @@ bool WidgetFactory::isContainer(RegExpType tp)
 
 RegExpWidget *WidgetFactory::createWidget(RegExpEditorWindow *win, QWidget *parent, RegExpType type)
 {
-    RegExpWidget *widget = 0;
+    RegExpWidget *widget = nullptr;
 
     switch (type) {
     case TEXT:
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic