From: smh Date: Thu, 6 May 2004 07:36:47 +0000 (+0000) Subject: SMH: KERNEL5826 - frozen python console X-Git-Tag: Ecole_Ete_a4~5 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=436012d943fd4b6439c6e40698c14e1d56cb64f0;p=modules%2Fkernel.git SMH: KERNEL5826 - frozen python console --- diff --git a/src/SALOMEGUI/QAD_PyEditor.cxx b/src/SALOMEGUI/QAD_PyEditor.cxx index e7c52baca..4aa41e589 100644 --- a/src/SALOMEGUI/QAD_PyEditor.cxx +++ b/src/SALOMEGUI/QAD_PyEditor.cxx @@ -50,7 +50,7 @@ using namespace std; #ifdef _DEBUG_ -static int MYDEBUG = 1; +static int MYDEBUG = 0; #else static int MYDEBUG = 0; #endif @@ -123,22 +123,23 @@ public: protected: virtual void run(){ + QThread::postEvent(myListener, new QCustomEvent(QAD_PyEditor::SET_WAIT_CURSOR)); + int anId = QAD_PyEditor::PYTHON_OK; if(myCommand != ""){ ThreadLock anEditorLock(myMutex,"TExecCommandThread::anEditorLock"); //ThreadLock aStudyLock(myStudyMutex,"TExecCommandThread::aStudyLock"); ThreadLock aPyLock = GetPyThreadLock("TExecCommandThread::aPyLock"); int ret = myInterp->run( myCommand.latin1() ); if(MYDEBUG) MESSAGE("TExecCommand::run() - myInterp = "< 0) anId = QAD_PyEditor::PYTHON_INCOMPLETE; myListener->myError = myInterp->getverr().c_str(); myListener->myOutput = myInterp->getvout().c_str(); - QThread::postEvent(myListener, new QCustomEvent(anId)); - QThread::postEvent(myListener, new QCustomEvent(QAD_PyEditor::UNSET_CURSOR)); } + QThread::postEvent(myListener, new QCustomEvent(anId)); + QThread::postEvent(myListener, new QCustomEvent(QAD_PyEditor::UNSET_CURSOR)); } private: