diff --git a/ChangeLog.txt b/ChangeLog.txt index ca004e8cc..7296e6f86 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -6,6 +6,7 @@ - Tape app. Add action Add separator to menu. - Tape app. Fix crash after switching language. - Fix Valentina app crash after canceling a tool. +- Puzzle app. Fix reading a piece name. # Valentina 0.7.51 April 18, 2022 - Z value change for a layout piece. diff --git a/src/app/puzzle/xml/vplayoutfilereader.cpp b/src/app/puzzle/xml/vplayoutfilereader.cpp index 5d9d1fcc3..7ac1c725f 100644 --- a/src/app/puzzle/xml/vplayoutfilereader.cpp +++ b/src/app/puzzle/xml/vplayoutfilereader.cpp @@ -466,7 +466,7 @@ void VPLayoutFileReader::ReadPiece(const VPPiecePtr &piece) QString uuidStr = ReadAttributeString(attribs, ML::AttrID, QUuid::createUuid().toString()); piece->SetUUID(QUuid(uuidStr)); - piece->SetName(ReadAttributeEmptyString(attribs, ML::AttrGradationLabel)); + piece->SetGradationId(ReadAttributeEmptyString(attribs, ML::AttrGradationLabel)); piece->SetCopyNumber(static_cast(ReadAttributeUInt(attribs, ML::AttrCopyNumber, QChar('1')))); piece->SetHideMainPath(not ReadAttributeBool(attribs, ML::AttrShowSeamline, trueStr)); piece->SetXScale(ReadAttributeDouble(attribs, ML::AttrXScale, QChar('1')));