lcl: darwin: allow link under mac os x 10.5, issue #33672

git-svn-id: trunk@57792 -
This commit is contained in:
mattias 2018-05-04 10:53:05 +00:00
parent d70ed14246
commit e18cac9559
3 changed files with 8 additions and 0 deletions

View File

@ -527,7 +527,9 @@ begin
{ Get's a screenshot }
displayID := CGMainDisplayID();
{$IF not defined(MAC_OS_X_VERSION_MIN_REQUIRED) or (MAC_OS_X_VERSION_MIN_REQUIRED >= 1060)}
ScreenImage := CGDisplayCreateImage(displayID);
{$ENDIF}
{ Fills the image description }
ARawImage.Init;

View File

@ -396,6 +396,7 @@ begin
lDataType := ccdtNonStandard;
// See PredefinedClipboardMimeTypes for the most common mime-types
{$IF not defined(MAC_OS_X_VERSION_MIN_REQUIRED) or (MAC_OS_X_VERSION_MIN_REQUIRED >= 1060)}
case AMimeType of
'text/plain':
begin
@ -415,6 +416,9 @@ begin
lDataType := ccdtBitmap;
end;
else
{$ELSE}
begin
{$ENDIF}
lNSStr := NSStringUtf8(AMimeType);
lDataType := ccdtNonStandard;
end;

View File

@ -168,7 +168,9 @@ begin
ARawImage.Description.Init_BPP32_A8R8G8B8_BIO_TTB(ScreenBitmapWidth, ScreenBitmapHeight);
// Take the screenshot
{$IF not defined(MAC_OS_X_VERSION_MIN_REQUIRED) or (MAC_OS_X_VERSION_MIN_REQUIRED >= 1060)}
screenshotImage := CGDisplayCreateImage(CGMainDisplayID()); // Requires 10.6+
{$ENDIF}
// Draw it to our screen bitmap
lRect := CGRectMake(0, 0, ScreenBitmapWidth, ScreenBitmapHeight);