X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;ds=inline;f=src%2FSalomeApp%2FSalomeApp_DoubleSpinBox.cxx;h=9611f2ff4be00e1214ca8f0623d40a91fb83539c;hb=38d4b2d7696e9e2d347c7f38f29459baa347cde6;hp=541ff70444ad159fc1741fa1b6493165cd61da5f;hpb=d26f738c9c427a45409bacf3848fd8c224edf6ed;p=modules%2Fgui.git diff --git a/src/SalomeApp/SalomeApp_DoubleSpinBox.cxx b/src/SalomeApp/SalomeApp_DoubleSpinBox.cxx index 541ff7044..9611f2ff4 100644 --- a/src/SalomeApp/SalomeApp_DoubleSpinBox.cxx +++ b/src/SalomeApp/SalomeApp_DoubleSpinBox.cxx @@ -20,8 +20,10 @@ // File: SalomeApp_DoubleSpinBox.cxx // Author: Oleg UVAROV // -#include // this include must be first (see PyInterp_base.h)! -#include + +#ifndef DISABLE_PYCONSOLE + #include // this include must be first (see PyInterp_base.h)! +#endif #include "SalomeApp_DoubleSpinBox.h" #include "SalomeApp_Application.h" @@ -434,9 +436,9 @@ SalomeApp_DoubleSpinBox::SearchState SalomeApp_DoubleSpinBox::findVariable( cons { if( studyDS->IsString( aName ) ) { - PyConsole_Console* pyConsole = app->pythonConsole(); - PyConsole_Interp* pyInterp = pyConsole->getInterp(); - PyLockWrapper aLock = pyInterp->GetLockWrapper(); +#ifndef DISABLE_PYCONSOLE + PyConsole_Interp* pyInterp = app->getPyInterp(); + PyLockWrapper aLock; // Acquire GIL std::string command; command = "import salome_notebook ; "; command += "salome_notebook.notebook.setAsReal(\""; @@ -448,6 +450,7 @@ SalomeApp_DoubleSpinBox::SearchState SalomeApp_DoubleSpinBox::findVariable( cons { return IncorrectType; } +#endif } value = studyDS->GetReal( aName ); return Found; @@ -503,7 +506,7 @@ bool SalomeApp_DoubleSpinBox::isAcceptNames() const */ void SalomeApp_DoubleSpinBox::setShowTipOnValidate( const bool flag ) { - myShowTip = myShowTip; + myShowTip = flag; } /*!