summaryrefslogtreecommitdiff
path: root/vcl/osx/salinst.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2016-10-05 20:29:06 +0200
committerStephan Bergmann <sbergman@redhat.com>2016-10-05 20:29:04 +0200
commita6c88e4bf1d148ac462c2bcd7061eff602b627d6 (patch)
treef26e7b89f8de36e042041934a50869d9d7ddf97c /vcl/osx/salinst.cxx
parentaf239f5affe82d0c6449e0e8f9828fe587033f02 (diff)
SAL_WNODEPRECATED_DECLARATIONS_PUSH/POP around new macOS 10.12 deprecations
...for now Change-Id: I64a0a8f6a006d75b6f82d7aae570aef414984a78
Diffstat (limited to 'vcl/osx/salinst.cxx')
-rw-r--r--vcl/osx/salinst.cxx27
1 files changed, 27 insertions, 0 deletions
diff --git a/vcl/osx/salinst.cxx b/vcl/osx/salinst.cxx
index 6fb7ca28bafe..d6139c8728fb 100644
--- a/vcl/osx/salinst.cxx
+++ b/vcl/osx/salinst.cxx
@@ -373,6 +373,8 @@ void AquaSalInstance::wakeupYield()
if( mbWaitingYield )
{
SalData::ensureThreadAutoreleasePool();
+SAL_WNODEPRECATED_DECLARATIONS_PUSH
+ // 'NSApplicationDefined' is deprecated: first deprecated in macOS 10.12
NSEvent* pEvent = [NSEvent otherEventWithType: NSApplicationDefined
location: NSZeroPoint
modifierFlags: 0
@@ -382,6 +384,7 @@ void AquaSalInstance::wakeupYield()
subtype: AquaSalInstance::YieldWakeupEvent
data1: 0
data2: 0 ];
+SAL_WNODEPRECATED_DECLARATIONS_POP
if( pEvent )
[NSApp postEvent: pEvent atStart: NO];
}
@@ -620,7 +623,10 @@ SalYieldResult AquaSalInstance::DoYield(bool bWait, bool bHandleAllCurrentEvents
{
sal_uLong nCount = ReleaseYieldMutex();
+SAL_WNODEPRECATED_DECLARATIONS_PUSH
+ // 'NSAnyEventMask' is deprecated: first deprecated in macOS 10.12
pEvent = [NSApp nextEventMatchingMask: NSAnyEventMask untilDate: nil
+SAL_WNODEPRECATED_DECLARATIONS_POP
inMode: NSDefaultRunLoopMode dequeue: YES];
if( pEvent )
{
@@ -638,7 +644,10 @@ SalYieldResult AquaSalInstance::DoYield(bool bWait, bool bHandleAllCurrentEvents
sal_uLong nCount = ReleaseYieldMutex();
NSDate* pDt = AquaSalTimer::pRunningTimer ? [AquaSalTimer::pRunningTimer fireDate] : [NSDate distantFuture];
+SAL_WNODEPRECATED_DECLARATIONS_PUSH
+ // 'NSAnyEventMask' is deprecated: first deprecated in macOS 10.12
pEvent = [NSApp nextEventMatchingMask: NSAnyEventMask untilDate: pDt
+SAL_WNODEPRECATED_DECLARATIONS_POP
inMode: NSDefaultRunLoopMode dequeue: YES];
if( pEvent )
[NSApp sendEvent: pEvent];
@@ -740,6 +749,23 @@ bool AquaSalInstance::AnyInput( VclInputFlags nType )
return false;
unsigned/*NSUInteger*/ nEventMask = 0;
+SAL_WNODEPRECATED_DECLARATIONS_PUSH
+ // 'NSFlagsChangedMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSKeyDownMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSKeyUpMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSLeftMouseDownMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSLeftMouseDraggedMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSLeftMouseUpMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSMouseEnteredMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSMouseExitedMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSOtherMouseDownMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSOtherMouseDraggedMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSOtherMouseUpMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSRightMouseDownMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSRightMouseDraggedMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSRightMouseUpMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSScrollWheelMask' is deprecated: first deprecated in macOS 10.12
+ // 'NSTabletPoint' is deprecated: first deprecated in macOS 10.12
if( nType & VclInputFlags::MOUSE)
nEventMask |=
NSLeftMouseDownMask | NSRightMouseDownMask | NSOtherMouseDownMask |
@@ -752,6 +778,7 @@ bool AquaSalInstance::AnyInput( VclInputFlags nType )
nEventMask |= NSKeyDownMask | NSKeyUpMask | NSFlagsChangedMask;
if( nType & VclInputFlags::OTHER)
nEventMask |= NSTabletPoint;
+SAL_WNODEPRECATED_DECLARATIONS_POP
// TODO: VclInputFlags::PAINT / more VclInputFlags::OTHER
if( !bool(nType) )
return false;