mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-14 13:30:48 +03:00
0030268: Inspectors - improvements in VInspector plugin
# Dump for OCCT objects. It improves perfomance during the dump parsing in inspector items. A cache creating for property view values. # ItemPresentableObject has no custom children due to the dump children count is not fixed (e.g. computed selections count) # GetStream() has been replaced by initStream() + Stream() # VInspector_ViewModel::FindPointers do nothing as it was poor performance of it when it parses BVH tree.
This commit is contained in:
@@ -133,9 +133,9 @@ void SelectMgr_Selection::DumpJson (Standard_OStream& theOStream, const Standard
|
||||
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, myEntityIter);
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, myMode);
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, myUpdateStatus);
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, mySelectionState);
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, myBVHUpdateStatus);
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, mySensFactor);
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, myUpdateStatus);
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, myBVHUpdateStatus);
|
||||
OCCT_DUMP_FIELD_VALUE_NUMERICAL (theOStream, myIsCustomSens);
|
||||
}
|
||||
|
@@ -202,10 +202,10 @@ int MessageModel_ItemAlert::initRowCount() const
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void MessageModel_ItemAlert::GetStream (Standard_OStream& OS) const
|
||||
void MessageModel_ItemAlert::initStream (Standard_OStream& OS) const
|
||||
{
|
||||
Handle(Message_AlertExtended) anExtendedAlert = Handle(Message_AlertExtended)::DownCast (getAlert());
|
||||
if (anExtendedAlert.IsNull() || anExtendedAlert->Attribute().IsNull())
|
||||
|
@@ -74,10 +74,6 @@ public:
|
||||
//! \return number of children.
|
||||
Standard_EXPORT virtual int initRowCount() const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& OS) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual bool SetStream (const Standard_SStream& theSStream, Standard_Integer& theStartPos,
|
||||
@@ -109,6 +105,10 @@ protected:
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& OS) const Standard_OVERRIDE;
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
//! \param theRow the child row position
|
||||
//! \param theColumn the child column position
|
||||
|
@@ -200,10 +200,10 @@ Handle(Message_Report) MessageModel_ItemReport::FindReport (const MessageModel_I
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void MessageModel_ItemReport::GetStream (Standard_OStream& theOStream) const
|
||||
void MessageModel_ItemReport::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(Message_Report) aReport = GetReport();
|
||||
if (aReport.IsNull())
|
||||
|
@@ -78,10 +78,6 @@ public:
|
||||
//! Returns report of the item
|
||||
static Handle(Message_Report) FindReport (const MessageModel_ItemBasePtr& thetItem);
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual bool SetStream (const Standard_SStream& theSStream, Standard_Integer& theStartPos,
|
||||
@@ -92,6 +88,10 @@ protected:
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
//! \param theRow the child row position
|
||||
//! \param theColumn the child column position
|
||||
|
@@ -54,6 +54,7 @@ void TreeModel_ItemBase::Reset()
|
||||
//myProperties = 0;
|
||||
}
|
||||
myCachedValues.clear();
|
||||
myStream.str ("");
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
@@ -112,7 +113,7 @@ QVariant TreeModel_ItemBase::cachedValue (const int theItemRole) const
|
||||
|
||||
QVariant aValueToCache;
|
||||
if (theItemRole == TreeModel_ItemRole_RowCountRole)
|
||||
aValueToCache = initRowCount() + m_iStreamChildren;
|
||||
aValueToCache = initRowCount() + const_cast<TreeModel_ItemBase*>(this)->initStreamRowCount();
|
||||
else
|
||||
aValueToCache = initValue (theItemRole);
|
||||
|
||||
@@ -128,13 +129,22 @@ void TreeModel_ItemBase::Init()
|
||||
{
|
||||
m_bInitialized = true;
|
||||
|
||||
initStream(myStream);
|
||||
initStreamRowCount();
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : initStreamRowCount
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
int TreeModel_ItemBase::initStreamRowCount()
|
||||
{
|
||||
//NCollection_List<Standard_Integer> aHierarchicalValues;
|
||||
int aStreamChildrenCount = 0;
|
||||
if (Column() == 0)
|
||||
{
|
||||
//NCollection_IndexedDataMap<TCollection_AsciiString, TCollection_AsciiString> aValues;
|
||||
Standard_SStream aStream;
|
||||
GetStream (aStream);
|
||||
initStream (aStream);
|
||||
if (!Standard_Dump::Text (aStream).IsEmpty())
|
||||
{
|
||||
if (!myProperties)
|
||||
@@ -168,6 +178,7 @@ void TreeModel_ItemBase::Init()
|
||||
//if (aHierarchicalValues.Size() == 1)
|
||||
}
|
||||
m_iStreamChildren = aStreamChildrenCount;//aHierarchicalValues.Extent();
|
||||
return m_iStreamChildren;
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
|
@@ -102,7 +102,7 @@ public:
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
virtual void GetStream (Standard_OStream& theOStream) const { (void)theOStream; }
|
||||
const Standard_SStream& Stream() const { return myStream; }
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
@@ -181,14 +181,22 @@ protected:
|
||||
//! \return number of children. It should be reimplemented in child
|
||||
virtual int initRowCount() const = 0;
|
||||
|
||||
//! \return number of children. It should be reimplemented in child
|
||||
Standard_EXPORT int initStreamRowCount();
|
||||
|
||||
//! Return data value for the role. It should be reimplemented in child
|
||||
//! \param theItemRole a value role
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
virtual void initStream (Standard_OStream& theOStream) const { (void)theOStream; }
|
||||
|
||||
protected:
|
||||
Handle(TreeModel_ItemProperties) myProperties; //!< the properties
|
||||
int m_iStreamChildren; //!< the count of stream items
|
||||
Standard_SStream myStream; //!< stream value
|
||||
|
||||
private:
|
||||
|
||||
|
@@ -31,8 +31,9 @@ IMPLEMENT_STANDARD_RTTIEXT(TreeModel_ItemProperties, Standard_Transient)
|
||||
|
||||
void TreeModel_ItemProperties::Init ()
|
||||
{
|
||||
Standard_SStream aStream;
|
||||
Item()->GetStream (aStream);
|
||||
myRowValues.Clear();
|
||||
|
||||
const Standard_SStream& aStream = Item()->Stream();
|
||||
|
||||
NCollection_IndexedDataMap<TCollection_AsciiString, Standard_DumpValue> aValues;
|
||||
TCollection_AsciiString aStreamText = Standard_Dump::Text (aStream);
|
||||
@@ -43,19 +44,6 @@ void TreeModel_ItemProperties::Init ()
|
||||
Standard_DumpValue aKeyValue;
|
||||
if (!aStreamParent)
|
||||
{
|
||||
Standard_SStream aStream;
|
||||
Item()->GetStream (aStream);
|
||||
|
||||
//aKey = aValues.FindKey (1);
|
||||
//aKeyValue = aValues.FindFromIndex (1);
|
||||
|
||||
//// one row value, like gp_XYZ, without additional { for type
|
||||
//aValues.Clear();
|
||||
//if (!Standard_Dump::SplitJson (aKeyValue.myValue, aValues))
|
||||
//{
|
||||
// aKeyValue = Standard_DumpValue (aStreamText, 1);
|
||||
//}
|
||||
|
||||
Handle(Standard_Transient) anItemObject = Item()->GetObject();
|
||||
aKey = anItemObject.IsNull() ? "Dump" : anItemObject->DynamicType()->Name();
|
||||
aKeyValue = Standard_DumpValue (aStreamText, 1);
|
||||
@@ -83,20 +71,24 @@ void TreeModel_ItemProperties::Init ()
|
||||
if (Standard_Dump::HasChildKey (aValue.myValue))
|
||||
myChildren.Add (aValues.FindKey (anIndex), aValue);
|
||||
else
|
||||
myValues.Add (aValues.FindKey (anIndex), aValue);
|
||||
{
|
||||
TreeModel_RowValue aRowValue (aValue.myStartPosition, aValues.FindKey (anIndex).ToCString(), aValue.myValue.ToCString());
|
||||
myRowValues.Add (myRowValues.Size() + 1, aRowValue);
|
||||
}
|
||||
}
|
||||
if (myRowValues.Size() == 1)
|
||||
{
|
||||
Quantity_Color aColor;
|
||||
if (Convert_Tools::ConvertStreamToColor (aStream, aColor))
|
||||
{
|
||||
Standard_Real aRed, aGreen, aBlue;
|
||||
aColor.Values (aRed, aGreen, aBlue, Quantity_TOC_RGB);
|
||||
|
||||
//aValues.Clear();
|
||||
//if (!Standard_Dump::SplitJson (myStreamValue.myValue, aValues))
|
||||
//{
|
||||
// return;
|
||||
//}
|
||||
//for (Standard_Integer anIndex = 1; anIndex <= aValues.Size(); anIndex++)
|
||||
//{
|
||||
// Standard_DumpValue aValue = aValues.FindFromIndex (anIndex);
|
||||
// if (!Standard_Dump::HasChildKey (aValue.myValue))
|
||||
// myValues.Add (aValues.FindKey (anIndex), aValue);
|
||||
//}
|
||||
int aDelta = 255;
|
||||
myRowValues.ChangeFromIndex (1).myCustomValues.insert ((int)Qt::BackgroundRole, QColor((int)(aRed * aDelta),
|
||||
(int)(aGreen * aDelta), (int)(aBlue * aDelta)));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
@@ -109,7 +101,7 @@ void TreeModel_ItemProperties::Reset()
|
||||
myStreamValue = Standard_DumpValue();
|
||||
|
||||
myChildren.Clear();
|
||||
myValues.Clear();
|
||||
myRowValues.Clear();
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
@@ -119,7 +111,7 @@ void TreeModel_ItemProperties::Reset()
|
||||
|
||||
int TreeModel_ItemProperties::RowCount() const
|
||||
{
|
||||
return Values().Size();
|
||||
return RowValues().Size();
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
@@ -131,24 +123,16 @@ QVariant TreeModel_ItemProperties::Data (const int theRow, const int theColumn,
|
||||
{
|
||||
if (theColumn == 1 && theRole == Qt::BackgroundRole)
|
||||
{
|
||||
Quantity_Color aColor;
|
||||
Standard_SStream aStream;
|
||||
Item()->GetStream (aStream);
|
||||
if (Convert_Tools::ConvertStreamToColor (aStream, aColor))
|
||||
{
|
||||
Standard_Real aRed, aGreen, aBlue;
|
||||
aColor.Values (aRed, aGreen, aBlue, Quantity_TOC_RGB);
|
||||
|
||||
int aDelta = 255;
|
||||
return QColor((int)(aRed * aDelta), (int)(aGreen * aDelta), (int)(aBlue * aDelta));
|
||||
}
|
||||
const QMap<int, QVariant>& aCachedValues = RowValues().FindFromIndex (theRow + 1).myCustomValues;
|
||||
if (aCachedValues.contains ((int)theRole))
|
||||
return aCachedValues[(int)theRole];
|
||||
}
|
||||
|
||||
if (theRole != Qt::DisplayRole && theRole != Qt::ToolTipRole)
|
||||
return QVariant();
|
||||
|
||||
if (theColumn == 0) return Values().FindKey (theRow + 1).ToCString();
|
||||
else if (theColumn == 1) return Values().FindFromIndex (theRow + 1).myValue.ToCString();
|
||||
if (theColumn == 0) return RowValues().FindFromIndex (theRow + 1).myKey;
|
||||
else if (theColumn == 1) return RowValues().FindFromIndex (theRow + 1).myValue;
|
||||
|
||||
return QVariant();
|
||||
}
|
||||
@@ -171,7 +155,7 @@ ViewControl_EditType TreeModel_ItemProperties::GetEditType (const int, const int
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
|
||||
bool TreeModel_ItemProperties::SetData (const int theRow, const int theColumn, const QVariant& theValue, int)
|
||||
bool TreeModel_ItemProperties::SetData (const int /*theRow*/, const int theColumn, const QVariant& /*theValue*/, int)
|
||||
{
|
||||
if (theColumn == 0)
|
||||
return false;
|
||||
@@ -184,27 +168,27 @@ bool TreeModel_ItemProperties::SetData (const int theRow, const int theColumn, c
|
||||
if (!aParent)
|
||||
return false;
|
||||
|
||||
Standard_SStream aStream;
|
||||
Item()->GetStream (aStream);
|
||||
//const Standard_SStream& aStream = Item()->Stream();
|
||||
|
||||
//TCollection_AsciiString aStreamValue = Standard_Dump::Text (aStream);
|
||||
|
||||
Standard_DumpValue aValue = Values().FindFromIndex (theRow + 1);
|
||||
Standard_Integer aStartPos = aValue.myStartPosition;
|
||||
Standard_Integer aLastPos = aStartPos + aValue.myValue.Length() - 1;
|
||||
//Standard_DumpValue aValue = Values().FindFromIndex (theRow + 1);
|
||||
//Standard_Integer aStartPos = aValue.myStartPosition;
|
||||
//Standard_Integer aLastPos = aStartPos + aValue.myValue.Length() - 1;
|
||||
|
||||
aStream.str ("");
|
||||
//aStream << aStreamValue.SubString (1, aStartPos - 1);
|
||||
aStream << theValue.toString().toStdString().c_str();
|
||||
//if (aLastPos + 1 <= aStreamValue.Length())
|
||||
// aStream << aStreamValue.SubString (aLastPos + 1, aStreamValue.Length());
|
||||
//aStream.str ("");
|
||||
////aStream << aStreamValue.SubString (1, aStartPos - 1);
|
||||
//aStream << theValue.toString().toStdString().c_str();
|
||||
////if (aLastPos + 1 <= aStreamValue.Length())
|
||||
//// aStream << aStreamValue.SubString (aLastPos + 1, aStreamValue.Length());
|
||||
|
||||
//TCollection_AsciiString aStreamValue_debug = Standard_Dump::Text (aStream);
|
||||
////TCollection_AsciiString aStreamValue_debug = Standard_Dump::Text (aStream);
|
||||
|
||||
Item()->SetStream (aStream, aStartPos, aLastPos);
|
||||
Item()->Reset();
|
||||
//Item()->SetStream (aStream, aStartPos, aLastPos);
|
||||
//Item()->Reset();
|
||||
|
||||
return true;
|
||||
//return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
@@ -219,9 +203,7 @@ void TreeModel_ItemProperties::GetPresentations (const int theRow, const int the
|
||||
|
||||
if (theRow < 0) // full presentation
|
||||
{
|
||||
Standard_SStream aStream;
|
||||
Item()->GetStream (aStream);
|
||||
|
||||
const Standard_SStream& aStream = Item()->Stream();
|
||||
Convert_Tools::ConvertStreamToPresentations (aStream, 1, -1, thePresentations);
|
||||
return;
|
||||
}
|
||||
|
@@ -24,6 +24,7 @@
|
||||
#include <Standard_Transient.hxx>
|
||||
|
||||
#include <NCollection_IndexedDataMap.hxx>
|
||||
#include <NCollection_IndexedMap.hxx>
|
||||
#include <NCollection_List.hxx>
|
||||
|
||||
#include <TCollection_AsciiString.hxx>
|
||||
@@ -52,6 +53,18 @@ class TreeModel_ItemProperties : public Standard_Transient
|
||||
TreeModel_DimType_Columns //! defines number of columns
|
||||
};
|
||||
|
||||
//! container of values in a row of property table
|
||||
struct TreeModel_RowValue
|
||||
{
|
||||
TreeModel_RowValue (const Standard_Integer theValueStartPosition, const QVariant theKey, QVariant theValue)
|
||||
: myValueStartPosition (theValueStartPosition), myKey (theKey), myValue (theValue) {}
|
||||
|
||||
Standard_Integer myValueStartPosition; //!< start position of the key
|
||||
QVariant myKey; //!< value in the first column
|
||||
QVariant myValue; //!< value in the second column
|
||||
QMap<int, QVariant> myCustomValues; //!< custom values, e.g. key is Background, value is defined color
|
||||
};
|
||||
|
||||
public:
|
||||
//! Constructor
|
||||
TreeModel_ItemProperties() {}
|
||||
@@ -129,7 +142,10 @@ public:
|
||||
const TCollection_AsciiString& StreamValue() const { return myStreamValue.myValue; }
|
||||
|
||||
//! Returns children stream values
|
||||
const NCollection_IndexedDataMap<TCollection_AsciiString, Standard_DumpValue>& Values() const { initItem(); return myValues; }
|
||||
//const NCollection_IndexedDataMap<TCollection_AsciiString, Standard_DumpValue>& Values() const { initItem(); return myValues; }
|
||||
|
||||
//! Returns children stream values
|
||||
const NCollection_IndexedDataMap<Standard_Integer, TreeModel_RowValue>& RowValues() const { initItem(); return myRowValues; }
|
||||
|
||||
//! Returns children stream values
|
||||
const NCollection_IndexedDataMap<TCollection_AsciiString, Standard_DumpValue>& Children() const { initItem(); return myChildren; }
|
||||
@@ -146,8 +162,9 @@ private:
|
||||
TCollection_AsciiString myKey; //!< the item key
|
||||
Standard_DumpValue myStreamValue; //!< the stream value
|
||||
NCollection_IndexedDataMap<TCollection_AsciiString, Standard_DumpValue> myChildren; //!< the children
|
||||
NCollection_IndexedDataMap<Standard_Integer, TreeModel_RowValue> myRowValues; //!< the values
|
||||
|
||||
NCollection_IndexedDataMap<TCollection_AsciiString, Standard_DumpValue> myValues; //!< the values
|
||||
//NCollection_IndexedDataMap<TCollection_AsciiString, Standard_DumpValue> myValues; //!< the values
|
||||
};
|
||||
|
||||
#endif
|
@@ -43,7 +43,7 @@ void TreeModel_ItemStream::Init()
|
||||
//if (!aStreamParent)
|
||||
//{
|
||||
// Standard_SStream aStream;
|
||||
// Parent()->GetStream (aStream);
|
||||
// Parent()->Stream (aStream);
|
||||
|
||||
// NCollection_IndexedDataMap<TCollection_AsciiString, TCollection_AsciiString> aValues;
|
||||
// Standard_Dump::SplitJson (Standard_Dump::Text (aStream), aValues);
|
||||
@@ -96,6 +96,7 @@ void TreeModel_ItemStream::Init()
|
||||
aStreamChildrenCount = myProperties->Children().Extent();
|
||||
}
|
||||
m_iStreamChildren = aStreamChildrenCount;//aHierarchicalValues.Extent();
|
||||
initStream (myStream);
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
@@ -109,6 +110,7 @@ void TreeModel_ItemStream::Reset()
|
||||
|
||||
//myChildren.Clear();
|
||||
|
||||
myStream.str ("");
|
||||
TreeModel_ItemBase::Reset();
|
||||
}
|
||||
|
||||
@@ -155,10 +157,10 @@ QVariant TreeModel_ItemStream::initValue (const int theItemRole) const
|
||||
//}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void TreeModel_ItemStream::GetStream (Standard_OStream& theOStream) const
|
||||
void TreeModel_ItemStream::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
if (!Properties())
|
||||
return;
|
||||
|
@@ -73,11 +73,10 @@ public:
|
||||
//const NCollection_IndexedDataMap<TCollection_AsciiString, TCollection_AsciiString>& GetChildren() const
|
||||
// { initItem(); return myChildren; }
|
||||
|
||||
protected:
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
virtual void initStream (Standard_OStream& theOStream) const;
|
||||
|
||||
//! Initialize the current item. It creates a backup of the specific item information
|
||||
//! Do nothing as context has been already set into item
|
||||
|
@@ -136,10 +136,10 @@ void VInspector_ItemBVHTree::initItem() const
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemBVHTree::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemBVHTree::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
opencascade::handle<BVH_Tree<Standard_Real, 3> > aBVHTree = GetTree();
|
||||
if (aBVHTree.IsNull())
|
||||
|
@@ -54,10 +54,6 @@ public:
|
||||
opencascade::handle<BVH_Tree<Standard_Real, 3> > GetTree() const
|
||||
{ return opencascade::handle<BVH_Tree<Standard_Real, 3> >::DownCast (GetObject()); }
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
@@ -71,6 +67,10 @@ protected:
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//! Build presentation shape
|
||||
//! \return generated shape of the item parameters
|
||||
virtual TopoDS_Shape buildPresentationShape() Standard_OVERRIDE;
|
||||
|
@@ -160,10 +160,10 @@ TreeModel_ItemBasePtr VInspector_ItemContext::createChild (int theRow, int theCo
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemContext::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemContext::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(AIS_InteractiveContext) aContext = GetContext();
|
||||
if (aContext.IsNull())
|
||||
|
@@ -51,10 +51,6 @@ public:
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//! Inits the item, fills internal containers
|
||||
Standard_EXPORT virtual void Init() Standard_OVERRIDE;
|
||||
|
||||
@@ -67,6 +63,10 @@ protected:
|
||||
//! Do nothing as context has been already set into item
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
|
@@ -64,10 +64,10 @@ void VInspector_ItemGraphic3dCamera::Reset()
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemGraphic3dCamera::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemGraphic3dCamera::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(Graphic3d_Camera) aCamera = GetCamera();
|
||||
if (aCamera.IsNull())
|
||||
@@ -93,7 +93,7 @@ void VInspector_ItemGraphic3dCamera::initItem() const
|
||||
// =======================================================================
|
||||
int VInspector_ItemGraphic3dCamera::initRowCount() const
|
||||
{
|
||||
Handle(Graphic3d_Camera) aCamera = GetCamera(); // we need Init() call for having GetStream() filled
|
||||
Handle(Graphic3d_Camera) aCamera = GetCamera(); // we need Init() call for having Stream() filled
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@@ -54,10 +54,6 @@ public:
|
||||
//! Resets cached values
|
||||
Standard_EXPORT virtual void Reset() Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
//! Build presentation shape
|
||||
//! \return generated shape of the item parameters
|
||||
@@ -81,6 +77,10 @@ protected:
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
|
@@ -104,10 +104,10 @@ QVariant VInspector_ItemGraphic3dGroup::initValue (const int theItemRole) const
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemGraphic3dGroup::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemGraphic3dGroup::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(Graphic3d_Group) aGroup = GetGroup();
|
||||
if (aGroup.IsNull())
|
||||
|
@@ -56,10 +56,6 @@ public:
|
||||
//! Resets cached values
|
||||
Standard_EXPORT virtual void Reset() Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Initialize the current item. It creates a backup of the specific item information
|
||||
@@ -75,6 +71,10 @@ protected:
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
|
@@ -133,7 +133,9 @@ QVariant VInspector_ItemPresentableObject::initValue (int theItemRole) const
|
||||
// =======================================================================
|
||||
int VInspector_ItemPresentableObject::initRowCount() const
|
||||
{
|
||||
if (Column() != 0)
|
||||
return 0;
|
||||
|
||||
/*if (Column() != 0)
|
||||
return 0;
|
||||
|
||||
int aNbProperties = 2; // "Properties", "Presentations"
|
||||
@@ -151,7 +153,7 @@ int VInspector_ItemPresentableObject::initRowCount() const
|
||||
int aNbSelected = !anIO.IsNull() ? anIO->Selections().Size() : 0;
|
||||
#endif
|
||||
|
||||
return aNbProperties + aNbSelected;
|
||||
return aNbProperties + aNbSelected;*/
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
@@ -160,12 +162,13 @@ int VInspector_ItemPresentableObject::initRowCount() const
|
||||
// =======================================================================
|
||||
TreeModel_ItemBasePtr VInspector_ItemPresentableObject::createChild (int theRow, int theColumn)
|
||||
{
|
||||
if (theRow == 0)
|
||||
return TreeModel_ItemBasePtr();
|
||||
/*if (theRow == 0)
|
||||
return VInspector_ItemFolderObject::CreateItem (currentItem(), theRow, theColumn);
|
||||
if (theRow == 1)
|
||||
return VInspector_ItemPresentations::CreateItem (currentItem(), theRow, theColumn);
|
||||
else
|
||||
return VInspector_ItemSelectMgrSelection::CreateItem(currentItem(), theRow, theColumn);
|
||||
return VInspector_ItemSelectMgrSelection::CreateItem(currentItem(), theRow, theColumn);*/
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
@@ -273,10 +276,10 @@ void VInspector_ItemPresentableObject::GetPresentations (NCollection_List<Handle
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemPresentableObject::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemPresentableObject::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(AIS_InteractiveObject) anIO = GetInteractiveObject();
|
||||
if (anIO.IsNull())
|
||||
|
@@ -64,10 +64,6 @@ public:
|
||||
//! \thePresentations [out] container of presentation handles to be visualized
|
||||
Standard_EXPORT virtual void GetPresentations (NCollection_List<Handle(Standard_Transient)>& thePresentations);
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
@@ -82,6 +78,10 @@ protected:
|
||||
//! \return the value
|
||||
virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
//! \param theRow the child row position
|
||||
//! \param theColumn the child column position
|
||||
|
@@ -117,10 +117,10 @@ int VInspector_ItemPrs3dAspect::initRowCount() const
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemPrs3dAspect::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemPrs3dAspect::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(Prs3d_BasicAspect) anAspect = GetAspect();
|
||||
if (anAspect.IsNull())
|
||||
|
@@ -78,7 +78,7 @@ protected:
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
//! \param theRow the child row position
|
||||
|
@@ -159,10 +159,10 @@ void VInspector_ItemPrs3dDrawer::initItem() const
|
||||
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemPrs3dDrawer::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemPrs3dDrawer::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(Prs3d_Drawer) aDrawer = GetDrawer();
|
||||
if (aDrawer.IsNull())
|
||||
|
@@ -63,10 +63,6 @@ public:
|
||||
TCollection_AsciiString& theName,
|
||||
Standard_Boolean& theOwnAspect) const;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
@@ -81,6 +77,10 @@ protected:
|
||||
//! \return the value
|
||||
virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
//! \param theRow the child row position
|
||||
//! \param theColumn the child column position
|
||||
|
@@ -156,10 +156,10 @@ void VInspector_ItemSelectBasicsEntityOwner::initItem() const
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemSelectBasicsEntityOwner::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemSelectBasicsEntityOwner::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(SelectMgr_EntityOwner) anEntityOwner = getEntityOwner();
|
||||
if (anEntityOwner.IsNull())
|
||||
|
@@ -52,10 +52,6 @@ public:
|
||||
//! Returns the current entity owner
|
||||
Handle(SelectBasics_EntityOwner) EntityOwner() const { return myOwner; }
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
//! \return number of children.
|
||||
virtual int initRowCount() const Standard_OVERRIDE{ return 0; }
|
||||
@@ -68,6 +64,10 @@ protected:
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
//! Build presentation shape
|
||||
//! \return generated shape of the item parameters
|
||||
|
@@ -104,10 +104,10 @@ void VInspector_ItemSelectMgrBaseFrustum::initItem() const
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemSelectMgrBaseFrustum::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemSelectMgrBaseFrustum::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(SelectMgr_BaseFrustum) aFrustum = GetFrustum();
|
||||
|
||||
|
@@ -53,10 +53,6 @@ public:
|
||||
Standard_EXPORT Handle(SelectMgr_BaseFrustum) GetFrustum() const
|
||||
{ return Handle(SelectMgr_BaseFrustum)::DownCast (GetObject()); }
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
@@ -70,6 +66,10 @@ protected:
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
|
@@ -141,10 +141,10 @@ opencascade::handle<BVH_Tree<Standard_Real, 3> > VInspector_ItemSelectMgrSelecta
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemSelectMgrSelectableObjectSet::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemSelectMgrSelectableObjectSet::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
SelectMgr_SelectableObjectSet aSet;
|
||||
if (!GetSelectableObjectSet (aSet))
|
||||
|
@@ -58,10 +58,6 @@ public:
|
||||
//! Returns child BVH tree of the row
|
||||
opencascade::handle<BVH_Tree<Standard_Real, 3> > GetBVHTree (const int theRow, TCollection_AsciiString& theName) const;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
@@ -75,6 +71,10 @@ protected:
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
|
@@ -120,10 +120,10 @@ Standard_Boolean VInspector_ItemSelectMgrSelectingVolumeManager::GetViewerSelect
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemSelectMgrSelectingVolumeManager::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemSelectMgrSelectingVolumeManager::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
SelectMgr_SelectingVolumeManager aVolumeManager;
|
||||
if (!GetViewerSelector (aVolumeManager))
|
||||
|
@@ -57,10 +57,6 @@ public:
|
||||
//! Returns frustum Frustum for row = 0, FrustumSet for row = 1
|
||||
Handle(SelectMgr_BaseFrustum) GetFrustum (const int theRow) const;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
@@ -74,6 +70,10 @@ protected:
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
|
@@ -156,10 +156,10 @@ void VInspector_ItemSelectMgrSensitiveEntity::Reset()
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemSelectMgrSensitiveEntity::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemSelectMgrSensitiveEntity::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(SelectMgr_SensitiveEntity) anEntity = GetSensitiveEntity();
|
||||
if (anEntity.IsNull())
|
||||
|
@@ -55,10 +55,6 @@ public:
|
||||
//! Resets cached values
|
||||
Standard_EXPORT virtual void Reset() Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
@@ -72,6 +68,10 @@ protected:
|
||||
//! \return the value
|
||||
virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Creates a child item in the given position.
|
||||
|
@@ -216,10 +216,10 @@ void VInspector_ItemSelectMgrViewerSelector::initItem() const
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemSelectMgrViewerSelector::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemSelectMgrViewerSelector::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(SelectMgr_ViewerSelector) aViewerSelector = GetViewerSelector();
|
||||
if (aViewerSelector.IsNull())
|
||||
|
@@ -95,11 +95,11 @@ protected:
|
||||
//! \return the value
|
||||
Standard_EXPORT virtual QVariant initValue (const int theItemRole) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
//! Build presentation shape
|
||||
//! \return generated shape of the item parameters
|
||||
|
@@ -127,10 +127,10 @@ void VInspector_ItemV3dViewer::Reset()
|
||||
}
|
||||
|
||||
// =======================================================================
|
||||
// function : GetStream
|
||||
// function : initStream
|
||||
// purpose :
|
||||
// =======================================================================
|
||||
void VInspector_ItemV3dViewer::GetStream (Standard_OStream& theOStream) const
|
||||
void VInspector_ItemV3dViewer::initStream (Standard_OStream& theOStream) const
|
||||
{
|
||||
Handle(V3d_Viewer) aViewer = GetViewer();
|
||||
if (aViewer.IsNull())
|
||||
|
@@ -59,11 +59,11 @@ public:
|
||||
Standard_EXPORT Handle(V3d_Viewer) GetViewer() const
|
||||
{ return Handle(V3d_Viewer)::DownCast (GetObject()); }
|
||||
|
||||
protected:
|
||||
//! Returns stream value of the item to fulfill property panel.
|
||||
//! \return stream value or dummy
|
||||
Standard_EXPORT virtual void GetStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
Standard_EXPORT virtual void initStream (Standard_OStream& theOStream) const Standard_OVERRIDE;
|
||||
|
||||
protected:
|
||||
//! Initialize the current item. It is empty because Reset() is also empty.
|
||||
virtual void initItem() const Standard_OVERRIDE;
|
||||
|
||||
|
@@ -112,6 +112,8 @@ void VInspector_ViewModel::FindPointers (const QStringList& thePointers,
|
||||
const QModelIndex& theParent,
|
||||
QModelIndexList& theFoundIndices)
|
||||
{
|
||||
return; // should be used after GetObject of items is improved, as it takes a lot of time on BVH item
|
||||
|
||||
if (thePointers.isEmpty())
|
||||
return;
|
||||
|
||||
|
@@ -109,7 +109,7 @@ void ViewControl_PropertyView::Init (ViewControl_TableModelValues* theTableValue
|
||||
aTable->Init (theTableValues);
|
||||
ViewControl_Tools::SetDefaultHeaderSections (aTable->GetTableView(), Qt::Horizontal);
|
||||
}
|
||||
aTable->SetActive (theTableValues);
|
||||
aTable->SetActive (theTableValues != 0);
|
||||
|
||||
if (theTableValues)
|
||||
myAttributesStack->setCurrentWidget (myTableWidget);
|
||||
|
Reference in New Issue
Block a user