[tradfri] Fix deprecations in color conversion code (#20868)

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
This commit is contained in:
Holger Friedrich
2026-06-03 21:31:43 +02:00
committed by GitHub
parent 1c54fda178
commit ea22c7f71f
@@ -16,6 +16,7 @@ import org.eclipse.jdt.annotation.NonNullByDefault;
import org.eclipse.jdt.annotation.Nullable;
import org.openhab.core.library.types.HSBType;
import org.openhab.core.library.types.PercentType;
import org.openhab.core.util.ColorUtil;
/**
* The {@link TradfriColor} is used for conversion between color formats.
@@ -87,7 +88,7 @@ public class TradfriColor {
float x = unnormalize(xyX);
float y = unnormalize(xyY);
HSBType converted = HSBType.fromXY(x, y);
HSBType converted = ColorUtil.xyToHsb(new double[] { x, y });
final Integer brightness = this.brightness;
if (brightness == null) {