Skip to content

Commit 74abf4a

Browse files
committed
Add conditionals to avoid warnings with UIActivityIndicatorViewStyleWhiteLarge
1 parent 501fb0d commit 74abf4a

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

MBProgressHUD.m

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,12 +372,16 @@ - (void)updateIndicators {
372372
// Update to indeterminate indicator
373373
UIActivityIndicatorView *activityIndicator;
374374
[indicator removeFromSuperview];
375+
#if !TARGET_OS_MACCATALYST
375376
if (@available(iOS 13.0, *)) {
377+
#endif
376378
activityIndicator = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleLarge];
377379
activityIndicator.color = [UIColor whiteColor];
380+
#if !TARGET_OS_MACCATALYST
378381
} else {
379-
activityIndicator = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:0 /* UIActivityIndicatorViewStyleWhiteLarge */];
382+
activityIndicator = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhiteLarge];
380383
}
384+
#endif
381385
[activityIndicator startAnimating];
382386
indicator = activityIndicator;
383387
[self.bezelView addSubview:indicator];

0 commit comments

Comments
 (0)