X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;ds=sidebyside;f=src%2Fthreadrecon.cpp;h=3c0b223924917e67b351284e8228ca99d69ba4d7;hb=7af7f4eb207891a4c0bfc60233b90847fd9b96cf;hp=c075fb426118ba04081c9bdaa4e95b82d99b4419;hpb=52f2fdc3424cd6b5b77ad1497243e1e06739ffe6;p=ctsim.git diff --git a/src/threadrecon.cpp b/src/threadrecon.cpp index c075fb4..3c0b223 100644 --- a/src/threadrecon.cpp +++ b/src/threadrecon.cpp @@ -9,7 +9,7 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2001 Kevin Rosenberg ** -** $Id: threadrecon.cpp,v 1.15 2001/03/02 21:11:50 kevin Exp $ +** $Id: threadrecon.cpp,v 1.16 2001/03/02 21:32:34 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -149,7 +149,8 @@ ReconstructorSupervisor::onDone() ImageFile* pImageFile = getImageFile(); - wxMutexGuiEnter(); + if (! wxThread::IsMain()) + wxMutexGuiEnter(); ImageFileDocument* pReconDoc = theApp->newImageDoc(); if (! pReconDoc) { sys_error (ERR_SEVERE, "Unable to create image file"); @@ -163,7 +164,8 @@ ReconstructorSupervisor::onDone() rasterView->getFrame()->Show(true); } *theApp->getLog() << m_pszLabel << "\n"; - wxMutexGuiLeave(); + if (! wxThread::IsMain()) + wxMutexGuiLeave(); if (theApp->getAskDeleteNewDocs()) pReconDoc->Modify (true);