Ignore:
Timestamp:
07/28/16 01:09:29 (7 years ago)
Author:
Maciej Komosinski
Message:

Renamed:
Model::getShape() ==> Model::getShapeType()
Model::SHAPE_OLD ==> Model::SHAPE_BALL_AND_STICK
Model::SHAPE_NEW ==> Model::SHAPE_SOLIDS
Part::SHAPE_DEFAULT ==> Part::SHAPE_BALL_AND_STICK
Joint::SHAPE_DEFAULT ==> Joint::SHAPE_BALL_AND_STICK
Joint::SHAPE_SOLID ==> Joint::SHAPE_FIXED

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/frams/model/model.h

    r522 r544  
    119119
    120120public:
    121         enum Shape { SHAPE_UNKNOWN, SHAPE_ILLEGAL, SHAPE_OLD, SHAPE_NEW };
     121        enum ShapeType { SHAPE_UNKNOWN, SHAPE_ILLEGAL, SHAPE_BALL_AND_STICK, SHAPE_SOLIDS };
    122122protected:
    123         Shape shape;
     123        ShapeType shape;
    124124
    125125        void updateNeuroRefno(); // set Neuro::refno for all neurons
     
    156156        int isValid() const { return buildstatus == valid; }
    157157        int getErrorPosition(bool includingwarnings = false);
    158         Shape getShape() { return shape; }
     158        ShapeType getShapeType() const { return shape; }
    159159
    160160        void updateRefno(); // set ::refno for all elements
     
    359359
    360360        /** create new Part and add it to the model. @see addPart()  */
    361         Part *addNewPart(Part::Shape shape = Part::SHAPE_DEFAULT) { return addPart(new Part(shape)); }
     361        Part *addNewPart(Part::Shape shape = Part::SHAPE_BALL_AND_STICK) { return addPart(new Part(shape)); }
    362362        /** create new Joint and add it to the model. @see addJoint() */
    363         Joint *addNewJoint(Part *p1 = NULL, Part *p2 = NULL, Joint::Shape shape = Joint::SHAPE_DEFAULT) { Joint *j = addJoint(new Joint()); j->shape = shape; if ((p1 != NULL) && (p2 != NULL)) j->attachToParts(p1, p2); return j; }
     363        Joint *addNewJoint(Part *p1 = NULL, Part *p2 = NULL, Joint::Shape shape = Joint::SHAPE_BALL_AND_STICK) { Joint *j = addJoint(new Joint()); j->shape = shape; if ((p1 != NULL) && (p2 != NULL)) j->attachToParts(p1, p2); return j; }
    364364        /** create new Neuro and add it to the model. @see addNeuro() */
    365365        Neuro *addNewNeuro() { return addNeuro(new Neuro()); }
Note: See TracChangeset for help on using the changeset viewer.