forked from openlp/openlp
Amend check for files and delete if not used any more
Fixes: https://launchpad.net/bugs/891781
This commit is contained in:
parent
2247a67442
commit
d5331f50b3
@ -370,7 +370,7 @@ class ThemeManager(QtGui.QWidget):
|
|||||||
|
|
||||||
def onExportTheme(self):
|
def onExportTheme(self):
|
||||||
"""
|
"""
|
||||||
Save the theme in a zip file
|
Export the theme in a zip file
|
||||||
"""
|
"""
|
||||||
item = self.themeListWidget.currentItem()
|
item = self.themeListWidget.currentItem()
|
||||||
if item is None:
|
if item is None:
|
||||||
@ -625,7 +625,7 @@ class ThemeManager(QtGui.QWidget):
|
|||||||
theme_dir = os.path.join(self.path, name)
|
theme_dir = os.path.join(self.path, name)
|
||||||
check_directory_exists(theme_dir)
|
check_directory_exists(theme_dir)
|
||||||
theme_file = os.path.join(theme_dir, name + u'.xml')
|
theme_file = os.path.join(theme_dir, name + u'.xml')
|
||||||
if imageTo and self.oldBackgroundImage and \
|
if self.oldBackgroundImage and \
|
||||||
imageTo != self.oldBackgroundImage:
|
imageTo != self.oldBackgroundImage:
|
||||||
delete_file(self.oldBackgroundImage)
|
delete_file(self.oldBackgroundImage)
|
||||||
outfile = None
|
outfile = None
|
||||||
|
Loading…
Reference in New Issue
Block a user