feat(ui): handle border colors in backdrop generator

This commit is contained in:
fallenoak 2023-02-21 17:39:04 -06:00
parent 1a4022eb31
commit 728ad2242d
No known key found for this signature in database
GPG Key ID: 7628F8E61AEA070D

View File

@ -137,7 +137,9 @@ void CBackdropGenerator::LoadXML(XMLNode* node, CStatus* status) {
// TODO // TODO
} else if (!SStrCmpI(child->GetName(), "BorderColor", STORM_MAX_STR)) { } else if (!SStrCmpI(child->GetName(), "BorderColor", STORM_MAX_STR)) {
// TODO CImVector borderColor = { 0 };
LoadXML_Color(child, borderColor);
this->SetBorderVertexColor(borderColor);
} else { } else {
status->Add( status->Add(
@ -151,7 +153,39 @@ void CBackdropGenerator::LoadXML(XMLNode* node, CStatus* status) {
} }
void CBackdropGenerator::SetBorderVertexColor(const CImVector& borderColor) { void CBackdropGenerator::SetBorderVertexColor(const CImVector& borderColor) {
// TODO this->m_borderColor = borderColor;
if (this->m_leftTexture) {
this->m_leftTexture->SetVertexColor(borderColor);
}
if (this->m_rightTexture) {
this->m_rightTexture->SetVertexColor(borderColor);
}
if (this->m_topTexture) {
this->m_topTexture->SetVertexColor(borderColor);
}
if (this->m_bottomTexture) {
this->m_bottomTexture->SetVertexColor(borderColor);
}
if (this->m_topLeftTexture) {
this->m_topLeftTexture->SetVertexColor(borderColor);
}
if (this->m_topRightTexture) {
this->m_topRightTexture->SetVertexColor(borderColor);
}
if (this->m_bottomLeftTexture) {
this->m_bottomLeftTexture->SetVertexColor(borderColor);
}
if (this->m_bottomRightTexture) {
this->m_bottomRightTexture->SetVertexColor(borderColor);
}
} }
void CBackdropGenerator::SetOutput(CSimpleFrame* frame) { void CBackdropGenerator::SetOutput(CSimpleFrame* frame) {