fix broken edit score reading. Unsigned ints were loaded from XML incorrectly.
This commit is contained in:
@@ -151,7 +151,9 @@ void StepsID::FromSteps( const Steps *p )
|
|||||||
{
|
{
|
||||||
sDescription = p->GetDescription();
|
sDescription = p->GetDescription();
|
||||||
uHash = p->GetHash();
|
uHash = p->GetHash();
|
||||||
} else {
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
sDescription = "";
|
sDescription = "";
|
||||||
uHash = 0;
|
uHash = 0;
|
||||||
}
|
}
|
||||||
@@ -242,7 +244,9 @@ void StepsID::LoadFromNode( const XNode* pNode )
|
|||||||
{
|
{
|
||||||
pNode->GetAttrValue("Description", sDescription);
|
pNode->GetAttrValue("Description", sDescription);
|
||||||
pNode->GetAttrValue("Hash", uHash);
|
pNode->GetAttrValue("Hash", uHash);
|
||||||
} else {
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
sDescription = "";
|
sDescription = "";
|
||||||
uHash = 0;
|
uHash = 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -625,14 +625,14 @@ void XNode::GetValue(CString &out) const { out = m_sValue; }
|
|||||||
void XNode::GetValue(int &out) const { out = atoi(m_sValue); }
|
void XNode::GetValue(int &out) const { out = atoi(m_sValue); }
|
||||||
void XNode::GetValue(float &out) const { out = strtof(m_sValue, NULL); }
|
void XNode::GetValue(float &out) const { out = strtof(m_sValue, NULL); }
|
||||||
void XNode::GetValue(bool &out) const { out = atoi(m_sValue) != 0; }
|
void XNode::GetValue(bool &out) const { out = atoi(m_sValue) != 0; }
|
||||||
void XNode::GetValue(unsigned &out) const { out = (unsigned)atoi(m_sValue) != 0; }
|
void XNode::GetValue(unsigned &out) const { out = (unsigned)atoi(m_sValue); }
|
||||||
void XNode::GetValue(DateTime &out) const { out.FromString( m_sValue ); }
|
void XNode::GetValue(DateTime &out) const { out.FromString( m_sValue ); }
|
||||||
|
|
||||||
void XAttr::GetValue(CString &out) const { out = m_sValue; }
|
void XAttr::GetValue(CString &out) const { out = m_sValue; }
|
||||||
void XAttr::GetValue(int &out) const { out = atoi(m_sValue); }
|
void XAttr::GetValue(int &out) const { out = atoi(m_sValue); }
|
||||||
void XAttr::GetValue(float &out) const { out = strtof(m_sValue, NULL); }
|
void XAttr::GetValue(float &out) const { out = strtof(m_sValue, NULL); }
|
||||||
void XAttr::GetValue(bool &out) const { out = atoi(m_sValue) != 0; }
|
void XAttr::GetValue(bool &out) const { out = atoi(m_sValue) != 0; }
|
||||||
void XAttr::GetValue(unsigned &out) const { out = (unsigned)atoi(m_sValue) != 0; }
|
void XAttr::GetValue(unsigned &out) const { out = (unsigned)atoi(m_sValue); }
|
||||||
void XAttr::GetValue(DateTime &out) const { out.FromString( m_sValue ); }
|
void XAttr::GetValue(DateTime &out) const { out.FromString( m_sValue ); }
|
||||||
|
|
||||||
//========================================================
|
//========================================================
|
||||||
|
|||||||
Reference in New Issue
Block a user