Skip to content

Commit

Permalink
Merge pull request #450 from mwoehlke-kitware/show-busy-on-load-mesh
Browse files Browse the repository at this point in the history
Show busy cursor while loading mesh
  • Loading branch information
mleotta committed May 3, 2021
2 parents 8af5994 + 7525429 commit 60ca98f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions gui/WorldView.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@

#include <QDebug>
#include <QFileInfo>
#include <QGuiApplication>
#include <QMenu>
#include <QTimer>
#include <QToolButton>
Expand Down Expand Up @@ -1006,11 +1007,15 @@ void WorldView::loadMesh(QString const& path)
return;
}

QGuiApplication::setOverrideCursor(Qt::WaitCursor);

// Create the vtk pipeline and read the mesh
vtkNew<vtkPLYReader> reader;
reader->SetFileName(qPrintable(path));
reader->Update();

QGuiApplication::restoreOverrideCursor();

this->setMesh(reader->GetOutput());
}

Expand Down

0 comments on commit 60ca98f

Please sign in to comment.