IPAL21558 In Group creation dialog, selection of sub-shapes in OB, viewer and dialog is not well syncronized

This commit is contained in:
dmv 2010-02-05 09:29:39 +00:00
parent b7e3214ee5
commit 7f1598797a
3 changed files with 14 additions and 0 deletions

View File

@ -30,6 +30,8 @@
#include <SalomeApp_Application.h> #include <SalomeApp_Application.h>
#include <SalomeApp_Study.h> #include <SalomeApp_Study.h>
#include "LightApp_DataOwner.h"
#include <SUIT_Desktop.h> #include <SUIT_Desktop.h>
#include <SUIT_Session.h> #include <SUIT_Session.h>
#include <SUIT_ViewWindow.h> #include <SUIT_ViewWindow.h>
@ -99,6 +101,13 @@ QVariant GEOMGUI_Selection::parameter( const int ind, const QString& p ) const
return LightApp_Selection::parameter( ind, p ); return LightApp_Selection::parameter( ind, p );
} }
// the method to skip temporary objects from selection (called from LightApp)
bool GEOMGUI_Selection::processOwner( const LightApp_DataOwner* theOwner)
{
return !theOwner->entry().contains("_");
}
QString GEOMGUI_Selection::typeName( const int index ) const QString GEOMGUI_Selection::typeName( const int index ) const
{ {
if ( isComponent( index ) ) if ( isComponent( index ) )

View File

@ -34,6 +34,7 @@
#include CORBA_SERVER_HEADER(GEOM_Gen) #include CORBA_SERVER_HEADER(GEOM_Gen)
class LightApp_SelectionMgr; class LightApp_SelectionMgr;
class LightApp_DataOwner;
class GEOMGUI_EXPORT GEOMGUI_Selection : public LightApp_Selection class GEOMGUI_EXPORT GEOMGUI_Selection : public LightApp_Selection
{ {
@ -43,6 +44,8 @@ public:
virtual QVariant parameter( const int, const QString& ) const; virtual QVariant parameter( const int, const QString& ) const;
virtual QVariant parameter( const QString& ) const; virtual QVariant parameter( const QString& ) const;
virtual bool processOwner( const LightApp_DataOwner* );
private: private:
bool isVisible( const int ) const; bool isVisible( const int ) const;

View File

@ -1530,6 +1530,8 @@ void GeometryGUI::contextMenuPopup( const QString& client, QMenu* menu, QString&
GEOM::GEOM_Object_var aGeomObj = GEOM::GEOM_Object::_narrow(anObj); GEOM::GEOM_Object_var aGeomObj = GEOM::GEOM_Object::_narrow(anObj);
if (CORBA::is_nil(aGeomObj) || aGeomObj->GetType() != GEOM_IMPORT) if (CORBA::is_nil(aGeomObj) || aGeomObj->GetType() != GEOM_IMPORT)
isImported = false; isImported = false;
} else {
isImported = false;
} }
} }