mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-21 15:41:35 +02:00
Simplify conversion from temperature to color in OptionsView
This commit is contained in:
committed by
Tamás Bálint Misius
parent
a715f5d71a
commit
561fc17431
@@ -437,8 +437,7 @@ void OptionsView::UpdateAmbientAirTempPreview(float airTemp, bool isValid)
|
|||||||
{
|
{
|
||||||
if (isValid)
|
if (isValid)
|
||||||
{
|
{
|
||||||
auto c = RGB<uint8_t>::Unpack(HeatToColour(airTemp));
|
ambientAirTempPreview->Appearance.BackgroundInactive = RGB<uint8_t>::Unpack(HeatToColour(airTemp)).WithAlpha(0xFF);
|
||||||
ambientAirTempPreview->Appearance.BackgroundInactive = ui::Colour(c.Red, c.Green, c.Blue);
|
|
||||||
ambientAirTempPreview->SetText("");
|
ambientAirTempPreview->SetText("");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Reference in New Issue
Block a user