Skip to content

Commit

Permalink
+ fix some warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed May 30, 2015
1 parent 351e7aa commit a12f700
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions src/Mod/Sketcher/App/Constraint.cpp
Expand Up @@ -131,19 +131,20 @@ void Constraint::Restore(XMLReader &reader)
AlignmentType = (InternalAlignmentType) reader.getAttributeAsInteger("InternalAlignmentType");
else
AlignmentType = Undef;

// read the third geo group if present
if (reader.hasAttribute("Third")) {
Third = reader.getAttributeAsInteger("Third");
ThirdPos = (PointPos) reader.getAttributeAsInteger("ThirdPos");
}

// Read the distance a constraint label has been moved
if (reader.hasAttribute("LabelDistance"))
LabelDistance = (float)reader.getAttributeAsFloat("LabelDistance");

if (reader.hasAttribute("LabelPosition"))
LabelPosition = (float)reader.getAttributeAsFloat("LabelPosition");

if (reader.hasAttribute("IsDriving"))
isDriving = (bool)reader.getAttributeAsInteger("IsDriving");
isDriving = reader.getAttributeAsInteger("IsDriving") ? true : false;
}
2 changes: 1 addition & 1 deletion src/Mod/Sketcher/Gui/CommandConstraints.cpp
Expand Up @@ -3476,7 +3476,7 @@ void CmdSketcherToggleDrivingConstraint::activated(int iMsg)
// issue the actual commands to toggle
doCommand(Doc,"App.ActiveDocument.%s.toggleDriving(%d) ",selection[0].getFeatName(),ConstrId);
}
catch(const Base::Exception& e) {
catch(const Base::Exception&) {
succesful--;
}
}
Expand Down

0 comments on commit a12f700

Please sign in to comment.