user32: Use float literals for float operation.

Thomas Faber thomas.faber at reactos.org
Mon Sep 7 03:47:30 CDT 2015


No need to use double math since the variable is float.
Fixes an MSVC warning:
edit.c(634) : warning C4305: '-=' : truncation from 'double' to 'float'


Alternatively, FP math could be completely avoided here using something
like:
			if (current_line->width > 6 * fw / 5)
				next = prev * fw / (current_line->width - fw / 5);
			else
				next = prev * fw / current_line->width;

However that's harder to read so is probably not a good idea.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-user32-Use-float-literals-for-float-operation.patch
Type: text/x-diff
Size: 789 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-patches/attachments/20150907/4c9b4710/attachment-0001.patch>


More information about the wine-patches mailing list