r24773 by jghali - #16693: Document Setup dialog does not open while RAM usage keeps increasing

scribus-commit scribus-commit at lists.scribus.net
Mon Nov 29 20:15:57 UTC 2021


Author: jghali
Date: Mon Nov 29 20:15:56 2021
New Revision: 24773

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=24773
Log:
#16693: Document Setup dialog does not open while RAM usage keeps increasing

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

Modified: trunk/Scribus/scribus/ui/prefs_documentsections.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24773&path=/trunk/Scribus/scribus/ui/prefs_documentsections.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/prefs_documentsections.cpp	(original)
+++ trunk/Scribus/scribus/ui/prefs_documentsections.cpp	Mon Nov 29 20:15:56 2021
@@ -8,6 +8,7 @@
 #include <QCheckBox>
 #include <QComboBox>
 #include <QMessageBox>
+#include <QSignalBlocker>
 
 #include "prefs_documentsections.h"
 #include "commonstrings.h"
@@ -49,16 +50,18 @@
 
 void Prefs_DocumentSections::saveGuiToPrefs(struct ApplicationPrefs *prefsData) const
 {
-	prefsData->docSectionMap=m_localSections;
+	prefsData->docSectionMap = m_localSections;
 }
 
 void Prefs_DocumentSections::updateTable()
 {
+	QSignalBlocker blocker(sectionsTable);
+
 	sectionsTable->setRowCount(m_localSections.count());
-	int row=0;
+	int row = 0;
 	for (DocumentSectionMap::Iterator it = m_localSections.begin(); it!= m_localSections.end(); ++it)
 	{
-		uint i=0;
+		uint i = 0;
 		//Name
 		QTableWidgetItem *item0 = new QTableWidgetItem(it->name);
 		sectionsTable->setItem(row, i++, item0);




More information about the scribus-commit mailing list