Made the infill understand a %.

Upgraded to the latest slic3r release.
This commit is contained in:
larsbrubaker 2014-08-11 15:41:38 -07:00
parent fe0a0eb696
commit 430f803f38
4 changed files with 25 additions and 7 deletions

View file

@ -190,11 +190,18 @@ namespace MatterHackers.MatterControl.SlicerConfiguration
{
get
{
if (scale != 1)
double ratio = 0;
if (OriginalValue.Contains("%"))
{
return (MapItem.ParseValueString(base.MappedValue) * scale).ToString();
string withoutPercent = OriginalValue.Replace("%", "");
ratio = MapItem.ParseValueString(withoutPercent) / 100.0;
}
return base.MappedValue;
else
{
ratio = MapItem.ParseValueString(base.MappedValue);
}
return (ratio * scale).ToString();
}
}