Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

SVProgressHUD appears behind the formsheet #89

Closed
SSA111 opened this Issue · 7 comments

3 participants

@SSA111

As the title says is SVProgressHUD appearing behind the formsheet. The SVProgressHUD is added to UIWindowLevelNormal. Any idea how I can show the progresshud over the formsheet?
Thanks in advance.

@m1entus
Owner

Change place where you adding SVProgressHud, use application keyWindow because form sheet is presented on external window

@SSA111

I have tried changing the windowLevel to the keyWindow. But the HUD still appears behind the formsheet. I add the HUD to the keywindow like so:
UIWindow *keyWindow = [[[UIApplication sharedApplication] windows] objectAtIndex:0];
[keyWindow addSubview:self.overlayView];

@m1entus
Owner

SVProgressHUD:

for (UIWindow *window in frontToBackWindows)
if (window.windowLevel == UIWindowLevelNormal) {
[window addSubview:self.overlayView];
break;
}
}
Use window level same as in my library

@m1entus m1entus closed this
@danielwischer

Any chance this issue could be resolved? i read the comments here but i cannot figure out, how to resolve this issue.

@m1entus
Owner

SVProgressHUD is adding HUD always to UIWindowLevelNormal, but form sheet is presented always above normal window. You have to add SVProgressHUD to form sheet window level to see it.

UIWindowLevel const MZFormSheetBackgroundWindowLevelAboveStatusBar = 1002;
UIWindowLevel const MZFormSheetBackgroundWindowLevelBelowStatusBar = 2;

@m1entus
Owner

Hi guys i have added some class to support SVProgressHUD, 1fe6126 , if you want to have SVProgressHUD working just add it to your project.

@danielwischer

Awesome, thank you so much

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.