[Libreoffice-commits] core.git: vcl/quartz
Stephan Bergmann (via logerrit)
logerrit at kemper.freedesktop.org
Fri Jan 3 17:10:18 UTC 2020
vcl/quartz/salgdicommon.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 5b8f505cd11517362b2c4a29c87d802a286a677d
Author: Stephan Bergmann <sbergman at redhat.com>
AuthorDate: Fri Jan 3 14:39:46 2020 +0100
Commit: Stephan Bergmann <sbergman at redhat.com>
CommitDate: Fri Jan 3 18:09:49 2020 +0100
Avoid -Werror,-Wdeprecated-anon-enum-enum-conversion
...with Clang 10 trunk:
> vcl/quartz/salgdicommon.cxx:1299:59: error: bitwise operation between different enumeration types ('CGImageAlphaInfo' and '(anonymous enum at /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGImage.h:51:9)') is deprecated [-Werror,-Wdeprecated-anon-enum-enum-conversion]
> kCGImageAlphaNoneSkipFirst | kCGBitmapByteOrder32Big );
> ~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~
<https://developer.apple.com/documentation/coregraphics/
1455939-cgbitmapcontextcreate> documents the "uint32_t bitmapInfo" parameter of
CGBitmapContextCreate as: "The constants for specifying the alpha channel
information are declared with the CGImageAlphaInfo type but can be passed to
this parameter safely. You can also pass the other constants associated with
the CGBitmapInfo type."
Change-Id: Idee410c65bd022a125a2f5a34cda007a8ca07580
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86175
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman at redhat.com>
diff --git a/vcl/quartz/salgdicommon.cxx b/vcl/quartz/salgdicommon.cxx
index c7cc31a5555f..f5f1aba8b41a 100644
--- a/vcl/quartz/salgdicommon.cxx
+++ b/vcl/quartz/salgdicommon.cxx
@@ -1296,7 +1296,7 @@ Color AquaSalGraphics::getPixel( long nX, long nY )
CGContextRef xOnePixelContext =
CGBitmapContextCreate( &aPixel, 1, 1, 8, 32,
GetSalData()->mxRGBSpace,
- kCGImageAlphaNoneSkipFirst | kCGBitmapByteOrder32Big );
+ uint32_t(kCGImageAlphaNoneSkipFirst) | uint32_t(kCGBitmapByteOrder32Big) );
// update this graphics layer
ApplyXorContext();
More information about the Libreoffice-commits
mailing list