Fix MSVC possible loss of data warning (#645)

This commit is contained in:
Robin Lindén 2023-05-20 00:35:26 +02:00 committed by GitHub
parent b1c53bcd15
commit f1303626f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -32,7 +32,7 @@ LinearGradientNormalized Normalize(LinearGradient gradient) {
// Fill in the two extent, if not provided. // Fill in the two extent, if not provided.
if (!gradient.stops.front().position) { if (!gradient.stops.front().position) {
gradient.stops.front().position = 0; gradient.stops.front().position = 0.f;
} }
if (!gradient.stops.back().position) { if (!gradient.stops.back().position) {
gradient.stops.back().position = 1.f; gradient.stops.back().position = 1.f;