Fixed deprecated declarations warning (#23625)
Summary: Fixed deprecated declarations warning. cc cpojer . [iOS] [Fixed] - Fixed deprecated declarations warning Pull Request resolved: https://github.com/facebook/react-native/pull/23625 Differential Revision: D14205929 Pulled By: cpojer fbshipit-source-id: 5e46f7f598ab1080b93923dcc25c98e1cd4362cd
This commit is contained in:
Родитель
b9d3743cda
Коммит
d2ac9a0698
|
@ -108,9 +108,12 @@ RCT_EXPORT_METHOD(setStyle:(UIStatusBarStyle)statusBarStyle
|
|||
RCTLogError(@"RCTStatusBarManager module requires that the \
|
||||
UIViewControllerBasedStatusBarAppearance key in the Info.plist is set to NO");
|
||||
} else {
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
||||
[RCTSharedApplication() setStatusBarStyle:statusBarStyle
|
||||
animated:animated];
|
||||
}
|
||||
#pragma clang diagnostic pop
|
||||
}
|
||||
|
||||
RCT_EXPORT_METHOD(setHidden:(BOOL)hidden
|
||||
|
@ -120,8 +123,11 @@ RCT_EXPORT_METHOD(setHidden:(BOOL)hidden
|
|||
RCTLogError(@"RCTStatusBarManager module requires that the \
|
||||
UIViewControllerBasedStatusBarAppearance key in the Info.plist is set to NO");
|
||||
} else {
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
||||
[RCTSharedApplication() setStatusBarHidden:hidden
|
||||
withAnimation:animation];
|
||||
#pragma clang diagnostic pop
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче