X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2FSketchPlugin%2FSketchPlugin_Ellipse.cpp;h=098951a853abb74c05e7fee006e6a6e83b5b1b8f;hb=4cb749258f33b7de231da5bb50140407c0599d30;hp=6e88c8191102c0c6e4c7fc1b578a6e81dc88a3a7;hpb=d74c5f916e2c7d0eb1ee2fa128f0458c3d22675f;p=modules%2Fshaper.git diff --git a/src/SketchPlugin/SketchPlugin_Ellipse.cpp b/src/SketchPlugin/SketchPlugin_Ellipse.cpp index 6e88c8191..098951a85 100644 --- a/src/SketchPlugin/SketchPlugin_Ellipse.cpp +++ b/src/SketchPlugin/SketchPlugin_Ellipse.cpp @@ -77,42 +77,14 @@ void SketchPlugin_Ellipse::execute() // Calculate all characteristics of the ellipse. fillCharacteristicPoints(); - // Make visible points related to ellipse characteristics. - int aResultIndex = 0; - SketchPlugin_Sketch::createPoint2DResult(this, aSketch, CENTER_ID(), aResultIndex++); - SketchPlugin_Sketch::createPoint2DResult(this, aSketch, FIRST_FOCUS_ID(), aResultIndex++); - SketchPlugin_Sketch::createPoint2DResult(this, aSketch, SECOND_FOCUS_ID(), aResultIndex++); - SketchPlugin_Sketch::createPoint2DResult(this, aSketch, MAJOR_AXIS_START_ID(), aResultIndex++); - SketchPlugin_Sketch::createPoint2DResult(this, aSketch, MAJOR_AXIS_END_ID(), aResultIndex++); - SketchPlugin_Sketch::createPoint2DResult(this, aSketch, MINOR_AXIS_START_ID(), aResultIndex++); - SketchPlugin_Sketch::createPoint2DResult(this, aSketch, MINOR_AXIS_END_ID(), aResultIndex++); - - // Make auxiliary axes - SketchPlugin_Sketch::createLine2DResult(this, aSketch, - MAJOR_AXIS_START_ID(), MAJOR_AXIS_END_ID(), aResultIndex++); - SketchPlugin_Sketch::createLine2DResult(this, aSketch, - MINOR_AXIS_START_ID(), MINOR_AXIS_END_ID(), aResultIndex++); - - // Mark already created results auxiliary - myAuxiliaryResults.clear(); - const std::list& aResults = results(); - std::list::const_iterator anIt = aResults.begin(); - for (int anIndex = 0; anIt != aResults.end() && anIndex < aResultIndex; ++anIt, ++anIndex) - myAuxiliaryResults.insert(*anIt); - // Make a visible ellipse. - createEllipse(aSketch, aResultIndex); + createEllipse(aSketch, 0); } bool SketchPlugin_Ellipse::isFixed() { return data()->selection(EXTERNAL_ID())->context().get() != NULL; } -bool SketchPlugin_Ellipse::isAuxiliary(ResultPtr theResult) -{ - return myAuxiliaryResults.find(theResult) != myAuxiliaryResults.end(); -} - void SketchPlugin_Ellipse::attributeChanged(const std::string& theID) { // the second condition for unability to move external segments anywhere if (theID == EXTERNAL_ID() || isFixed()) {