diff --git a/src/calibre/gui2/actions/polish.py b/src/calibre/gui2/actions/polish.py index 69c8d6fc23..b77849d882 100644 --- a/src/calibre/gui2/actions/polish.py +++ b/src/calibre/gui2/actions/polish.py @@ -432,7 +432,20 @@ class PolishAction(InterfaceAction): return None db = self.gui.library_view.model().db ans = (db.id(r) for r in rows) - return self.get_supported_books(ans) + ans = self.get_supported_books(ans) + for fmts in ans.itervalues(): + for x in fmts: + if x.startswith('ORIGINAL_'): + from calibre.gui2.dialogs.confirm_delete import confirm + if not confirm(_( + 'One of the books you are polishing has an {0} format.' + ' Polishing will use this as the source and overwrite' + ' any existing {1} format. Are you sure you want to proceed?').format( + x, x[len('ORIGINAL_'):]), 'confirm_original_polish', title=_('Are you sure?'), + confirm_msg=_('Ask for this confirmation again')): + return {} + break + return ans def get_supported_books(self, book_ids): from calibre.ebooks.oeb.polish.main import SUPPORTED