diff --git a/smileypack.cpp b/smileypack.cpp index f035704e7..52fb3eaac 100644 --- a/smileypack.cpp +++ b/smileypack.cpp @@ -95,8 +95,8 @@ QString SmileyPack::replaceEmoticons(const QString &msg) const int index = msg.indexOf(exp); int offset = 0; - // if a word is key of a smiley, replace it by it's corresponding image in Rich Text - while (index >= 0 || exp.matchedLength() > 0) + // if a word is key of a smiley, replace it by its corresponding image in Rich Text + while (index >= 0) { QString key = exp.cap(); if (lookupTable.contains(key)) diff --git a/smileypack.h b/smileypack.h index 990fcc6a0..d87e177ff 100644 --- a/smileypack.h +++ b/smileypack.h @@ -21,7 +21,7 @@ #include #include -//maps emoticons to smilies +//maps emoticons to smileys class SmileyPack : public QObject { Q_OBJECT