Skip to content

Commit 9dde83c

Browse files
committed
[Qt] Revert change to set/restore busy cursor
1 parent 169fb81 commit 9dde83c

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

qt/src/MainWindow.cc

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -292,6 +292,9 @@ void MainWindow::pushState(MainWindow::State state, const QString& msg) {
292292
m_stateStack.push(QPair<State, QString> (state, msg));
293293
ui.statusbar->showMessage(msg);
294294
setState(state);
295+
if (state == State::Busy) {
296+
QApplication::setOverrideCursor(Qt::WaitCursor);
297+
}
295298
}
296299

297300
void MainWindow::popState() {
@@ -315,11 +318,6 @@ void MainWindow::setState(State state) {
315318
ui.dockWidgetSources->setEnabled(!isBusy);
316319
ui.dockWidgetOutput->setEnabled(!isBusy);
317320
ui.centralwidget->setEnabled(!isBusy);
318-
if (isBusy) {
319-
QApplication::setOverrideCursor(Qt::WaitCursor);
320-
} else {
321-
QApplication::restoreOverrideCursor();
322-
}
323321
}
324322

325323
void MainWindow::closeEvent(QCloseEvent* ev) {

0 commit comments

Comments
 (0)