serializer: bypass bezier adj on keyframe type set

This commit is contained in:
itsmattkc
2022-06-10 09:55:56 -07:00
parent e74bb34d9a
commit 046b1cc498
3 changed files with 9 additions and 4 deletions
+7 -3
View File
@@ -99,7 +99,7 @@ const NodeKeyframe::Type &NodeKeyframe::type() const
void NodeKeyframe::set_type(const NodeKeyframe::Type &type)
{
if (type_ != type) {
type_ = type;
set_type_no_bezier_adj(type);
if (type_ == kBezier) {
// Set some sane defaults if this keyframe existed in the track and was just changed
@@ -120,11 +120,15 @@ void NodeKeyframe::set_type(const NodeKeyframe::Type &type)
}
}
}
emit TypeChanged(type_);
}
}
void NodeKeyframe::set_type_no_bezier_adj(const Type &type)
{
type_ = type;
emit TypeChanged(type_);
}
const QPointF &NodeKeyframe::bezier_control_in() const
{
return bezier_control_in_;