r23854 by jghali - Code cleanup

scribus-commit scribus-commit at lists.scribus.net
Fri May 29 19:08:44 UTC 2020


Author: jghali
Date: Fri May 29 19:08:44 2020
New Revision: 23854

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=23854
Log:
Code cleanup

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

Modified: trunk/Scribus/scribus/ui/storyeditor.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23854&path=/trunk/Scribus/scribus/ui/storyeditor.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/storyeditor.cpp	(original)
+++ trunk/Scribus/scribus/ui/storyeditor.cpp	Fri May 29 19:08:44 2020
@@ -3485,8 +3485,6 @@
 void StoryEditor::SaveTextFile()
 {
 	m_blockUpdate = true;
-	QString loadEnc;
-	QString fileName;
 	PrefsContext* dirs = prefsManager.prefsFile->getContext("dirs");
 	QString wdir = dirs->get("story_save", prefsManager.appPrefs.pathPrefs.documents);
 	CustomFDialog dia(this, wdir, tr("Save as"), tr("Text Files (*.txt);;All Files (*)"), fdShowCodecs|fdHidePreviewCheckBox);
@@ -3496,10 +3494,10 @@
 		m_blockUpdate = false;
 		return;
 	}
-	loadEnc = dia.optionCombo->currentText();
+	QString loadEnc = dia.optionCombo->currentText();
 	if (loadEnc == "UTF-16")
 		loadEnc = "ISO-10646-UCS-2";
-	fileName = dia.selectedFile();
+	QString fileName = dia.selectedFile();
 	if (!fileName.isEmpty())
 	{
 		dirs->set("story_save", fileName.left(fileName.lastIndexOf("/")));




More information about the scribus-commit mailing list