forked from qt-creator/qt-creator
Use isEmpty() instead of count() or size()
Change-Id: I0a89d2808c6d041da0dc41ea5aea58e6e8759bb4 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -400,7 +400,7 @@ void ScxmlDocument::printSCXML()
|
||||
QByteArray ScxmlDocument::content(const QVector<ScxmlTag*> &tags) const
|
||||
{
|
||||
QByteArray result;
|
||||
if (tags.count() > 0) {
|
||||
if (!tags.isEmpty()) {
|
||||
QBuffer buffer(&result);
|
||||
buffer.open(QIODevice::WriteOnly);
|
||||
|
||||
@@ -666,7 +666,7 @@ ScxmlTag *ScxmlDocument::popRootTag()
|
||||
|
||||
void ScxmlDocument::deleteRootTags()
|
||||
{
|
||||
while (m_rootTags.count() > 0)
|
||||
while (!m_rootTags.isEmpty())
|
||||
delete m_rootTags.takeLast();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user