whitelist is more sensible here than blacklist
This commit is contained in:
parent
f86c33d0e5
commit
f284acbf19
21
src/core.py
21
src/core.py
|
@ -380,19 +380,12 @@ class Core():
|
||||||
|
|
||||||
def createProjectFile(self, filepath, window=None):
|
def createProjectFile(self, filepath, window=None):
|
||||||
'''Create a project file (.avp) using the current program state'''
|
'''Create a project file (.avp) using the current program state'''
|
||||||
forbiddenSettingsKeys = [
|
settingsKeys = [
|
||||||
'currentProject',
|
'componentDir',
|
||||||
'outputAudioBitrate',
|
'inputDir',
|
||||||
'outputAudioCodec',
|
'outputDir',
|
||||||
'outputContainer',
|
'presetDir',
|
||||||
'outputFormat',
|
'projectDir',
|
||||||
'outputFrameRate',
|
|
||||||
'outputHeight',
|
|
||||||
'outputPreset',
|
|
||||||
'outputVideoBitrate',
|
|
||||||
'outputVideoCodec',
|
|
||||||
'outputVideoFormat',
|
|
||||||
'outputWidth',
|
|
||||||
]
|
]
|
||||||
try:
|
try:
|
||||||
if not filepath.endswith(".avp"):
|
if not filepath.endswith(".avp"):
|
||||||
|
@ -411,7 +404,7 @@ class Core():
|
||||||
|
|
||||||
f.write('\n[Settings]\n')
|
f.write('\n[Settings]\n')
|
||||||
for key in self.settings.allKeys():
|
for key in self.settings.allKeys():
|
||||||
if key not in forbiddenSettingsKeys:
|
if key in settingsKeys:
|
||||||
f.write('%s=%s\n' % (key, self.settings.value(key)))
|
f.write('%s=%s\n' % (key, self.settings.value(key)))
|
||||||
|
|
||||||
if window:
|
if window:
|
||||||
|
|
Reference in New Issue