From 8eb545904d1fb42e65ae7e68cda29453b3b4f785 Mon Sep 17 00:00:00 2001 From: Laurent Rineau Date: Wed, 13 Jan 2016 16:48:08 +0100 Subject: [PATCH] Use the WaitCursor cursor while opening a file or while evaluating a script. --- Polyhedron/demo/Polyhedron/MainWindow.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Polyhedron/demo/Polyhedron/MainWindow.cpp b/Polyhedron/demo/Polyhedron/MainWindow.cpp index 844f3df0ea8..a3532134f1d 100644 --- a/Polyhedron/demo/Polyhedron/MainWindow.cpp +++ b/Polyhedron/demo/Polyhedron/MainWindow.cpp @@ -936,7 +936,9 @@ void MainWindow::open(QString filename) // << filename << "\", with following content:\n" // << program; } + QApplication::setOverrideCursor(Qt::WaitCursor); evaluate_script(program, filename); + QApplication::restoreOverrideCursor(); return; } #endif @@ -996,7 +998,10 @@ void MainWindow::open(QString filename) settings.setValue("OFF open directory", fileinfo.absoluteDir().absolutePath()); + QApplication::setOverrideCursor(Qt::WaitCursor); CGAL::Three::Scene_item* scene_item = load_item(fileinfo, find_loader(load_pair.first)); + QApplication::restoreOverrideCursor(); + if(scene_item != 0) { this->addToRecentFiles(fileinfo.absoluteFilePath()); }