X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSketchPlugin%2FSketchPlugin_ConstraintHorizontal.cpp;h=f256187a85b7b916ebb526756f2c7e073b2dc1a8;hb=cd3e66b2f07a49646c344406b7236819d53f5ae9;hp=722ea659a0f96a54bae1f5e9d0fb01b0487e8b39;hpb=01ea17c79bfb3ea775eb282798fc6e5496f2f1c6;p=modules%2Fshaper.git diff --git a/src/SketchPlugin/SketchPlugin_ConstraintHorizontal.cpp b/src/SketchPlugin/SketchPlugin_ConstraintHorizontal.cpp index 722ea659a..f256187a8 100644 --- a/src/SketchPlugin/SketchPlugin_ConstraintHorizontal.cpp +++ b/src/SketchPlugin/SketchPlugin_ConstraintHorizontal.cpp @@ -1,8 +1,21 @@ -// Copyright (C) 2014-20xx CEA/DEN, EDF R&D --> - -// File: SketchPlugin_ConstraintHorizontal.cpp -// Created: 16 Mar 2015 -// Author: Artem ZHIDKOV +// Copyright (C) 2014-2020 CEA/DEN, EDF R&D +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +// #include "SketchPlugin_ConstraintHorizontal.h" @@ -14,6 +27,7 @@ #include #include +//#include #include @@ -23,7 +37,7 @@ SketchPlugin_ConstraintHorizontal::SketchPlugin_ConstraintHorizontal() void SketchPlugin_ConstraintHorizontal::initAttributes() { - data()->addAttribute(SketchPlugin_Constraint::ENTITY_A(), ModelAPI_AttributeRefAttr::type()); + data()->addAttribute(SketchPlugin_Constraint::ENTITY_A(), ModelAPI_AttributeRefAttr::typeId()); } void SketchPlugin_ConstraintHorizontal::execute() @@ -35,9 +49,8 @@ AISObjectPtr SketchPlugin_ConstraintHorizontal::getAISObject(AISObjectPtr thePre if (!sketch()) return thePrevious; - AISObjectPtr anAIS = thePrevious; - /// TODO: Horizontal constraint presentation should be put here + AISObjectPtr anAIS = SketcherPrs_Factory::horisontalConstraint(this, sketch(), + thePrevious); return anAIS; } -