Commit 4accb338 authored by Laurent Montel's avatar Laurent Montel 😁

Use isEmpty() when it's possible

parent 6691eaa6
......@@ -167,7 +167,7 @@ void KgSound::start(const QPointF& pos)
if (d->m_valid)
{
KgOpenALRuntime* runtime = KgOpenALRuntime::instance();
if(runtime->instance()->m_soundsEvents[this].count() > 0)
if(!runtime->instance()->m_soundsEvents[this].isEmpty())
{
if(runtime->instance()->m_soundsEvents[this].last()->replay(pos) == false)
{
......
......@@ -185,7 +185,7 @@ void KMessageClient::processIncomingMessage (const QByteArray &msg)
d->delayedMessages.append(msg);
return;
}
if (d->delayedMessages.count() > 0)
if (!d->delayedMessages.isEmpty())
{
d->delayedMessages.append (msg);
QByteArray first = d->delayedMessages.front();
......
......@@ -190,7 +190,7 @@ void KGameDifficultyPrivate::rebuildActions()
}
}
if (m_customLevels.count()>0) {
if (!m_customLevels.isEmpty()) {
foreach(const QString &s, m_customLevels) {
m_menu->addAction(s);
m_comboBox->addItem(QIcon::fromTheme( QStringLiteral( "games-difficult" )), s);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment