Finally able to reproduce the problem of ghost dialogs that stick around after being closed, with the add a custom new source dialog. Workaround of calling deleteLater() seems to do the trick.

This commit is contained in:
Kovid Goyal 2014-08-31 20:32:38 +05:30
parent db3ab1d874
commit 1ce34a51af
2 changed files with 7 additions and 3 deletions

View File

@ -491,8 +491,11 @@ class Scheduler(QObject):
def customize_feeds(self, *args):
from calibre.gui2.dialogs.user_profiles import UserProfiles
d = UserProfiles(self._parent, self.recipe_model)
d.exec_()
d.break_cycles()
try:
d.exec_()
d.break_cycles()
finally:
d.deleteLater()
def do_download(self, urn):
self.lock.lock()

View File

@ -1048,7 +1048,8 @@ def edit_metadata(db, row_list, current_row, parent=None, view_slot=None,
set_current_callback=set_current_callback)
return d.changed, d.rows_to_refresh
finally:
d.hide() # possible workaround for bug reports of occasional ghost edit metadata dialog on windows
# possible workaround for bug reports of occasional ghost edit metadata dialog on windows
d.deleteLater()
if __name__ == '__main__':
from calibre.gui2 import Application as QApplication