r14760 by fschmid - Better error reporting for the "placeVectorFile" command.

scribus-commit scribus-commit at lists.scribus.net
Thu Feb 18 10:51:04 CET 2010


Revision: 14760
Author: fschmid
Date: 2010-02-18T09:48:33.766223Z
Commit message: Better error reporting for the "placeVectorFile" command.

Changeset: 
M  /trunk/Scribus/scribus/plugins/scriptplugin/svgimport.cpp

Diffs:
Index: scribus/plugins/scriptplugin/svgimport.cpp
===================================================================
--- scribus/plugins/scriptplugin/svgimport.cpp	(revision 14759)
+++ scribus/plugins/scriptplugin/svgimport.cpp	(revision 14760)
@@ -33,7 +33,10 @@
 	QFileInfo fi = QFileInfo(fName);
 	QString ext = fi.suffix().toLower();
 	if (!allFormatsV.contains(ext))
+	{
+		PyErr_SetString(PyExc_Exception, "Requested Import plugin not available");
 		return NULL;
+	}
 	FileLoader *fileLoader = new FileLoader(fName);
 	int testResult = fileLoader->TestFile();
 	delete fileLoader;
@@ -59,7 +62,7 @@
 	}
 	else
 	{
-		PyErr_SetString(PyExc_Exception, "Requested Import plugin not available");
+		PyErr_SetString(PyExc_Exception, "Requested File cannot be imported");
 		return NULL;
 	}
 //	Py_INCREF(Py_None);




More information about the scribus-commit mailing list