[processing] modified how user folder is defined

This should have no effect on a normal QGIS desktop installation, but improve using Processing when not running on top of a regular QGIS instance.
This commit is contained in:
volaya 2015-12-15 12:28:47 +01:00
parent 85eebff69b
commit 08a8b6095f

View File

@ -38,8 +38,7 @@ numExported = 1
def userFolder():
userDir = QFileInfo(QgsApplication.qgisUserDbFilePath()).path() \
+ '/processing'
userDir = os.path.join(QgsApplication.qgisSettingsDirPath(), 'processing')
if not QDir(userDir).exists():
QDir().mkpath(userDir)
@ -47,8 +46,7 @@ def userFolder():
def defaultOutputFolder():
folder = os.path.join(os.path.dirname(QgsApplication.qgisUserDbFilePath()),
"processing", "outputs")
folder = os.path.join(userFolder(), "outputs")
if not QDir(folder).exists():
QDir().mkpath(folder)