r21319 by craig -

scribus-commit scribus-commit at lists.scribus.net
Sun May 15 22:06:43 UTC 2016


Author: craig
Date: Sun May 15 22:06:43 2016
New Revision: 21319

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=21319
Log:
Remove unnecessary condition

Modified:
    trunk/Scribus/scribus/ui/resourcemanager.cpp

Modified: trunk/Scribus/scribus/ui/resourcemanager.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21319&path=/trunk/Scribus/scribus/ui/resourcemanager.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/resourcemanager.cpp	(original)
+++ trunk/Scribus/scribus/ui/resourcemanager.cpp	Sun May 15 22:06:43 2016
@@ -226,22 +226,20 @@
 	installedTableWidget->setRowCount(dictionaryMap.count());
 	installedTableWidget->setColumnCount(2);
 	installedTableWidget->setSortingEnabled(false);
-	if (dictionaryMap.count()>0)
-	{
-		QMapIterator<QString, QString> i(dictionaryMap);
-		int row=0;
-		while (i.hasNext())
-		{
-			i.next();
-			int column=0;
-			QTableWidgetItem *newItem1 = new QTableWidgetItem(i.key());
-			newItem1->setFlags(newItem1->flags() & ~Qt::ItemIsEditable & ~Qt::ItemIsSelectable);
-			installedTableWidget->setItem(row, column++, newItem1);
-			QTableWidgetItem *newItem2 = new QTableWidgetItem(i.value());
-			newItem2->setFlags(newItem1->flags());
-			installedTableWidget->setItem(row, column++, newItem2);
-			++row;
-		}
+
+	QMapIterator<QString, QString> i(dictionaryMap);
+	int row=0;
+	while (i.hasNext())
+	{
+		i.next();
+		int column=0;
+		QTableWidgetItem *newItem1 = new QTableWidgetItem(i.key());
+		newItem1->setFlags(newItem1->flags() & ~Qt::ItemIsEditable & ~Qt::ItemIsSelectable);
+		installedTableWidget->setItem(row, column++, newItem1);
+		QTableWidgetItem *newItem2 = new QTableWidgetItem(i.value());
+		newItem2->setFlags(newItem1->flags());
+		installedTableWidget->setItem(row, column++, newItem2);
+		++row;
 	}
 	QStringList headers;
 	headers << tr("Description") << tr("Location") ;




More information about the scribus-commit mailing list