MSVC error C2440: 'static_cast': cannot convert from 'double' to 'PieceNodeAngle'.

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2019-08-07 20:28:36 +03:00
parent 8332d4b15b
commit 4876560b5d

View File

@ -270,7 +270,8 @@ void AbstractTest::VectorFromJson(const QString &json, QVector<VSAPoint> &vector
QJsonValue angleValue = pointObject[angleKey];
if (angleValue.isDouble())
{
point.SetAngleType(static_cast<PieceNodeAngle>(angleValue.toDouble(defaultAngle)));
const int angle = static_cast<int>(angleValue.toDouble(defaultAngle));
point.SetAngleType(static_cast<PieceNodeAngle>(angle));
}
else
{