X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSALOME_PYQT%2FSALOME_PYQT_GUILight%2FSALOME_PYQT_ModuleLight.cxx;h=e405a40fa9fbc5e9326a85ae33c5d16788676d8f;hb=e7ede3527d1022d9df3cc38cd9d00d2eefb9f80f;hp=9e53d0350ef7e5e232a180645bc2e578e391fe66;hpb=a02bf230b856e127c34d5b1f7b529f0116fc4123;p=modules%2Fgui.git diff --git a/src/SALOME_PYQT/SALOME_PYQT_GUILight/SALOME_PYQT_ModuleLight.cxx b/src/SALOME_PYQT/SALOME_PYQT_GUILight/SALOME_PYQT_ModuleLight.cxx index 9e53d0350..e405a40fa 100644 --- a/src/SALOME_PYQT/SALOME_PYQT_GUILight/SALOME_PYQT_ModuleLight.cxx +++ b/src/SALOME_PYQT/SALOME_PYQT_GUILight/SALOME_PYQT_ModuleLight.cxx @@ -20,8 +20,8 @@ // File : SALOME_PYQT_ModuleLight.cxx // Author : Vadim SANDLER, Open CASCADE S.A.S. (vadim.sandler@opencascade.com) -#include "SALOME_PYQT_DataModelLight.h" #include "SALOME_PYQT_ModuleLight.h" +#include "SALOME_PYQT_DataModelLight.h" #include "SALOME_PYQT_PyModule.h" #include "SALOME_PYQT_Selector.h" @@ -63,7 +63,7 @@ // and to get C API from sip : sipBuildResult for example // -#define INIT_FUNCTION initSalomePyQtGUILight +#define INIT_FUNCTION PyInit_SalomePyQtGUILight #if defined(SIP_STATIC_MODULE) extern "C" void INIT_FUNCTION(); #else @@ -618,18 +618,20 @@ void SALOME_PYQT_ModuleLight::getSelected( DataObjectList& ) const /*! \brief not used yet */ -unsigned long SALOME_PYQT_ModuleLight::getModifiedTime() const -{ - MESSAGE("getModifiedTime"); -} +//unsigned long SALOME_PYQT_ModuleLight::getModifiedTime() const +//{ +// MESSAGE("getModifiedTime"); +// return 0; +//} /*! \brief not used yet */ -SUIT_DataObject* SALOME_PYQT_ModuleLight::root() const -{ - MESSAGE("root"); -} +//SUIT_DataObject* SALOME_PYQT_ModuleLight::root() const +//{ +// MESSAGE("root"); +// return NULL; +//} /*! \brief Used to notify a Python light module of a modification of selection in study (propagation of a remote selection) @@ -656,3 +658,19 @@ void SALOME_PYQT_ModuleLight::setLocalSelected(const QStringList & entries) emit localSelectionChanged(); } +void SALOME_PYQT_ModuleLight::enableSelector() +{ + MESSAGE("enableSelector"); + if (!mySelector) + { + mySelector = new SALOME_PYQT_Selector(this, this->getApp()->selectionMgr()); + } + mySelector->setEnabled(true); +} + +void SALOME_PYQT_ModuleLight::disableSelector() +{ + MESSAGE("disableSelector"); + if (mySelector) + mySelector->setEnabled(false); +}