r21373 by craig -

scribus-commit scribus-commit at lists.scribus.net
Fri Jun 10 21:39:45 UTC 2016


Author: craig
Date: Fri Jun 10 21:39:45 2016
New Revision: 21373

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=21373
Log:
#13890: Reset layer combobox and mouse X/Y positions when last doc closes

Modified:
    trunk/Scribus/scribus/scribus.cpp

Modified: trunk/Scribus/scribus/scribus.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21373&path=/trunk/Scribus/scribus/scribus.cpp
==============================================================================
--- trunk/Scribus/scribus/scribus.cpp	(original)
+++ trunk/Scribus/scribus/scribus.cpp	Fri Jun 10 21:39:45 2016
@@ -1318,6 +1318,12 @@
 
 void ScribusMainWindow::setStatusBarMousePosition(double xp, double yp)
 {
+	if (!HaveDoc)
+	{
+		mainWindowXPosDataLabel->clear();
+		mainWindowYPosDataLabel->clear();
+		return;
+	}
 	if (doc->Pages->count() == 0)
 		return;
 	double xn = xp;
@@ -4328,6 +4334,8 @@
 	updateLayerMenu();
 	updateTableMenuActions();
 	rebuildScrapbookMenu();
+	mainWindowXPosDataLabel->clear();
+	mainWindowYPosDataLabel->clear();
 	//not running view's togglePreview as we don't want to affect the doc settings.
 	scrActions["viewPreviewMode"]->setChecked(false);
 	appModeHelper->setPreviewMode(false);
@@ -7295,10 +7303,14 @@
 
 void ScribusMainWindow::updateLayerMenu()
 {
-	if (doc==NULL)
-		return;
 	bool b = layerMenu->blockSignals(true);
 	layerMenu->clear();
+	if (doc==NULL)
+	{
+		layerMenu->blockSignals(b);
+		return;
+	}
+
 	QStringList newNames;
 	doc->orderedLayerList(&newNames);
 	for (QStringList::Iterator it=newNames.begin(); it!=newNames.end(); ++it)




More information about the scribus-commit mailing list