X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FXGUI%2FXGUI_Displayer.cpp;h=20a6f721e9f38e7285b3440405e7e18a2edf67e5;hb=00265e8a59b2eff159cef64eef8de47ed4b9b728;hp=7fcc298946e8bd924de520fd175663c1fe95f8a1;hpb=ef523c1c20fecaf086c9f9fe712750ae8e180ec0;p=modules%2Fshaper.git diff --git a/src/XGUI/XGUI_Displayer.cpp b/src/XGUI/XGUI_Displayer.cpp index 7fcc29894..20a6f721e 100644 --- a/src/XGUI/XGUI_Displayer.cpp +++ b/src/XGUI/XGUI_Displayer.cpp @@ -64,6 +64,25 @@ boost::shared_ptr XGUI_Displayer::GetFeature(const TopoDS_Shap return aFeature; } +std::list XGUI_Displayer::GetViewerPrs + (const NCollection_List& theShapes) +{ + std::list aPresentations; + if (theShapes.IsEmpty()) + return aPresentations; + + NCollection_List::Iterator anIt(theShapes); + for (; anIt.More(); anIt.Next()) { + const TopoDS_Shape& aShape = anIt.Value(); + if (aShape.IsNull()) + continue; + boost::shared_ptr aFeature = GetFeature(aShape); + aPresentations.push_back(XGUI_ViewerPrs(aFeature, aShape)); + } + + return aPresentations; +} + void XGUI_Displayer::Erase(boost::shared_ptr theFeature, const bool isUpdateViewer) {