mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Busy cursor when fixing/prettying all files
This commit is contained in:
parent
7a7878f21c
commit
4077030da1
@ -319,10 +319,14 @@ class Boss(QObject):
|
||||
else:
|
||||
if not self.check_dirtied():
|
||||
return
|
||||
QApplication.setOverrideCursor(QCursor(Qt.WaitCursor))
|
||||
try:
|
||||
self.add_savepoint(_('Fix HTML'))
|
||||
fix_all_html(current_container())
|
||||
self.update_editors_from_container()
|
||||
self.set_modified()
|
||||
finally:
|
||||
QApplication.restoreOverrideCursor()
|
||||
|
||||
def pretty_print(self, current):
|
||||
if current:
|
||||
@ -334,10 +338,14 @@ class Boss(QObject):
|
||||
else:
|
||||
if not self.check_dirtied():
|
||||
return
|
||||
QApplication.setOverrideCursor(QCursor(Qt.WaitCursor))
|
||||
try:
|
||||
self.add_savepoint(_('Beautify files'))
|
||||
pretty_all(current_container())
|
||||
self.update_editors_from_container()
|
||||
self.set_modified()
|
||||
finally:
|
||||
QApplication.restoreOverrideCursor()
|
||||
|
||||
def mark_selected_text(self):
|
||||
ed = self.gui.central.current_editor
|
||||
|
Loading…
x
Reference in New Issue
Block a user