Showing/Hiding the text while starting/pausing the loading overlay
This commit is contained in:
parent
d057559353
commit
9be7fef53c
@ -45,6 +45,7 @@
|
||||
Label *infoLabel = [Label label];
|
||||
infoLabel.textAlignment = NSTextAlignmentCenter;
|
||||
infoLabel.translatesAutoresizingMaskIntoConstraints = NO;
|
||||
infoLabel.hidden = true;
|
||||
self.indicatorText = infoLabel;
|
||||
|
||||
[loadingStack addArrangedSubview:infoLabel];
|
||||
@ -84,15 +85,20 @@
|
||||
if(text != nil){
|
||||
self.indicatorText.attributedText = text;
|
||||
self.indicatorText.accessibilityLabel = text.string;
|
||||
self.indicatorText.hidden = false;
|
||||
} else {
|
||||
self.indicatorText.attributedText = nil;
|
||||
self.indicatorText.accessibilityLabel = @"";
|
||||
self.indicatorText.hidden = true;
|
||||
}
|
||||
[self.activityIndicator resumeSpinner];
|
||||
}
|
||||
|
||||
- (void)stopLoading {
|
||||
[self.activityIndicator pauseSpinner];
|
||||
self.indicatorText.hidden = true;
|
||||
self.indicatorText.attributedText = nil;
|
||||
self.indicatorText.accessibilityLabel = @"";
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
Loading…
Reference in New Issue
Block a user