// Created on: 2017-06-16 // Created by: Natalia ERMOLAEVA // Copyright (c) 2017 OPEN CASCADE SAS // // This file is part of Open CASCADE Technology software library. // // This library is free software; you can redistribute it and/or modify it under // the terms of the GNU Lesser General Public License version 2.1 as published // by the Free Software Foundation, with special exception defined in the file // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT // distribution for complete text of the license and disclaimer of any warranty. // // Alternatively, this file may be used under the terms of Open CASCADE // commercial license or contractual agreement. #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include // ======================================================================= // function : Constructor // purpose : // ======================================================================= DFBrowserPaneXDE_AttributePaneCreator::DFBrowserPaneXDE_AttributePaneCreator( DFBrowserPane_AttributePaneCreatorAPI* theStandardPaneCreator) : myStandardPaneCreator (theStandardPaneCreator) { } // ======================================================================= // function : CreateAttributePane // purpose : // ======================================================================= DFBrowserPane_AttributePaneAPI* DFBrowserPaneXDE_AttributePaneCreator::CreateAttributePane (Standard_CString theAttributeName) { DFBrowserPane_AttributePaneAPI* aPane = 0; if (DFBrowserPaneXDE_AttributeCommonPane::ProcessAttribute (theAttributeName)) { DFBrowserPane_AttributePaneAPI* aStandardPane = myStandardPaneCreator->CreateAttributePane (theAttributeName); if (!aStandardPane) aStandardPane = createXDEPane (theAttributeName); aPane = new DFBrowserPaneXDE_AttributeCommonPane (aStandardPane); } else aPane = createXDEPane (theAttributeName); return aPane; } // ======================================================================= // function : createXDEPane // purpose : // ======================================================================= DFBrowserPane_AttributePaneAPI* DFBrowserPaneXDE_AttributePaneCreator::createXDEPane (Standard_CString theAttributeName) { DFBrowserPane_AttributePaneAPI* aPane = 0; if (theAttributeName == STANDARD_TYPE (XCAFDoc_ShapeMapTool)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocShapeMapTool(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_Area)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocArea(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_Centroid)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocCentroid(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_Color)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocColor(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_ColorTool)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocColorTool(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_Datum)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocDatum(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_Dimension)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocDimension(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_DimTol)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocDimTol(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_DimTolTool)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocDimTolTool(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_DocumentTool)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocDocumentTool(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_GeomTolerance)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocGeomTolerance(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_GraphNode)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocGraphNode(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_LayerTool)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocLayerTool(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_Location)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocLocation(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_Material)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocMaterial(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_MaterialTool)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocMaterialTool(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_ShapeMapTool)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocShapeMapTool(); else if (theAttributeName == STANDARD_TYPE (XCAFDoc_ShapeTool)->Name()) aPane = new DFBrowserPaneXDE_XCAFDocShapeTool(); return aPane; }