From 2e78ff6e5ef9f497ae3eac949ceab6399d4120b7 Mon Sep 17 00:00:00 2001 From: Tim Beaulen Date: Sun, 24 Jun 2007 12:50:58 +0000 Subject: [PATCH] From EBN: Check for QString compares to ""... OOPS! 1 issue found! ./libs/plasma/widgets/lineedit.cpp: line#178 (1) Do not compare a QString to "". Instead use the .isEmpty() method. For example, if(str == "") becomes if(str.isEmpty()) svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=679628 --- widgets/lineedit.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/widgets/lineedit.cpp b/widgets/lineedit.cpp index a72535266..0bb0bc1e0 100644 --- a/widgets/lineedit.cpp +++ b/widgets/lineedit.cpp @@ -175,7 +175,7 @@ void LineEdit::keyPressEvent(QKeyEvent *event) d->oldText = QGraphicsTextItem::toHtml(); emit textChanged(QGraphicsTextItem::toHtml()); } -// if (QGraphicsTextItem::toPlainText().simplified() == "") +// if (QGraphicsTextItem::toPlainText().simplified().isEmtpy()) // QGraphicsTextItem::setHtml(d->defaultText); }