Use o3tl::convert
commitaadb472a6d37d57279f91038f28047af4278bbbc
authorHossein <hossein@libreoffice.org>
Fri, 19 Nov 2021 21:39:10 +0000 (19 22:39 +0100)
committerMike Kaganski <mike.kaganski@collabora.com>
Sat, 20 Nov 2021 06:13:14 +0000 (20 07:13 +0100)
tree8fb788d1705ae91698e6cf6ac93b42f0d458c460
parent23886b0e023bc27e9ba89f9ab6d1bdf36da022ab
Use o3tl::convert

Used o3tl::convert on nXRes and nYRes to calculate biXPelsPerMeter
and biYPelsPerMeter for the bitmap information header structure pBIH:
https://docs.microsoft.com/en-us/windows/win32/api/wingdi/ns-wingdi-bitmapinfoheader

The values of biXPelsPerMeter and biYPelsPerMeter are always ignored
by the GDI when loading the bitmaps, but in theory they can be
recommendations for the pysical size of a bitmap in some applications.
https://devblogs.microsoft.com/oldnewthing/20130515-00/?p=4363

Change-Id: Ia40f17b7d1c27c094158af89bf15ed2f11bdfc05
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125109
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
extensions/source/scanner/twain32shim.cxx