1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Platform: Remove deprecated code paths that will never be called

This commit is contained in:
reuk 2024-07-03 14:50:08 +01:00
parent 5cdf6abf95
commit a858f91354
No known key found for this signature in database
GPG key ID: FCB43929F012EE5C
6 changed files with 54 additions and 479 deletions

View file

@ -85,24 +85,6 @@ namespace juce
withResponseInfo: (NSDictionary*) responseInfo
completionHandler: (void(^)()) completionHandler;
JUCE_BEGIN_IGNORE_WARNINGS_GCC_LIKE ("-Wdeprecated-declarations")
- (void) application: (UIApplication*) application
didRegisterUserNotificationSettings: (UIUserNotificationSettings*) notificationSettings;
- (void) application: (UIApplication*) application
didReceiveLocalNotification: (UILocalNotification*) notification;
- (void) application: (UIApplication*) application
handleActionWithIdentifier: (NSString*) identifier
forLocalNotification: (UILocalNotification*) notification
completionHandler: (void(^)()) completionHandler;
- (void) application: (UIApplication*) application
handleActionWithIdentifier: (NSString*) identifier
forLocalNotification: (UILocalNotification*) notification
withResponseInfo: (NSDictionary*) responseInfo
completionHandler: (void(^)()) completionHandler;
JUCE_END_IGNORE_WARNINGS_GCC_LIKE
- (void) userNotificationCenter: (UNUserNotificationCenter*) center
willPresentNotification: (UNNotification*) notification
withCompletionHandler: (void (^)(UNNotificationPresentationOptions options)) completionHandler;
@ -328,96 +310,6 @@ JUCE_END_IGNORE_WARNINGS_GCC_LIKE
}
}
JUCE_BEGIN_IGNORE_WARNINGS_GCC_LIKE ("-Wdeprecated-declarations")
- (void) application: (UIApplication*) application
didRegisterUserNotificationSettings: (UIUserNotificationSettings*) notificationSettings
{
ignoreUnused (application);
SEL selector = @selector (application:didRegisterUserNotificationSettings:);
if (_pushNotificationsDelegate != nil && [_pushNotificationsDelegate respondsToSelector:selector])
{
NSInvocation* invocation = [NSInvocation invocationWithMethodSignature: [_pushNotificationsDelegate methodSignatureForSelector: selector]];
[invocation setSelector: selector];
[invocation setTarget: _pushNotificationsDelegate];
[invocation setArgument: &application atIndex: 2];
[invocation setArgument: &notificationSettings atIndex: 3];
[invocation invoke];
}
}
- (void) application: (UIApplication*) application
didReceiveLocalNotification: (UILocalNotification*) notification
{
ignoreUnused (application);
SEL selector = @selector (application:didReceiveLocalNotification:);
if (_pushNotificationsDelegate != nil && [_pushNotificationsDelegate respondsToSelector: selector])
{
NSInvocation* invocation = [NSInvocation invocationWithMethodSignature: [_pushNotificationsDelegate methodSignatureForSelector: selector]];
[invocation setSelector: selector];
[invocation setTarget: _pushNotificationsDelegate];
[invocation setArgument: &application atIndex: 2];
[invocation setArgument: &notification atIndex: 3];
[invocation invoke];
}
}
- (void) application: (UIApplication*) application
handleActionWithIdentifier: (NSString*) identifier
forLocalNotification: (UILocalNotification*) notification
completionHandler: (void(^)()) completionHandler
{
ignoreUnused (application);
SEL selector = @selector (application:handleActionWithIdentifier:forLocalNotification:completionHandler:);
if (_pushNotificationsDelegate != nil && [_pushNotificationsDelegate respondsToSelector: selector])
{
NSInvocation* invocation = [NSInvocation invocationWithMethodSignature: [_pushNotificationsDelegate methodSignatureForSelector: selector]];
[invocation setSelector: selector];
[invocation setTarget: _pushNotificationsDelegate];
[invocation setArgument: &application atIndex:2];
[invocation setArgument: &identifier atIndex:3];
[invocation setArgument: &notification atIndex:4];
[invocation setArgument: &completionHandler atIndex:5];
[invocation invoke];
}
}
- (void) application: (UIApplication*) application
handleActionWithIdentifier: (NSString*) identifier
forLocalNotification: (UILocalNotification*) notification
withResponseInfo: (NSDictionary*) responseInfo
completionHandler: (void(^)()) completionHandler
{
ignoreUnused (application);
SEL selector = @selector (application:handleActionWithIdentifier:forLocalNotification:withResponseInfo:completionHandler:);
if (_pushNotificationsDelegate != nil && [_pushNotificationsDelegate respondsToSelector: selector])
{
NSInvocation* invocation = [NSInvocation invocationWithMethodSignature: [_pushNotificationsDelegate methodSignatureForSelector: selector]];
[invocation setSelector: selector];
[invocation setTarget: _pushNotificationsDelegate];
[invocation setArgument: &application atIndex:2];
[invocation setArgument: &identifier atIndex:3];
[invocation setArgument: &notification atIndex:4];
[invocation setArgument: &responseInfo atIndex:5];
[invocation setArgument: &completionHandler atIndex:6];
[invocation invoke];
}
}
JUCE_END_IGNORE_WARNINGS_GCC_LIKE
- (void) userNotificationCenter: (UNUserNotificationCenter*) center
willPresentNotification: (UNNotification*) notification
withCompletionHandler: (void (^)(UNNotificationPresentationOptions options)) completionHandler