Skip to content

forceDisplayUI on iOS doesn't work when there are modal presented view controllers active  #3

@pperera

Description

@pperera

forceDisplayUI should have a parameter for the presenter (the view controller that will be presenting the UI on top)

if this is not possible or desirable then something like the following should be done to ensure it presents correctly

Example written in C# (we use the lib using XamarinIOS - C#) but you should get the idea.

UIViewController vc = new UIViewController();
vc.View.BackgroundColor = UIColor.Green;
UIViewController presenter = UIApplication.SharedApplication.KeyWindow.RootViewController;
while(presenter != null && presenter.PresentedViewController != null)
{
    presenter = presenter.PresentedViewController;
}
presenter?.PresentViewController(vc, true, null);

commenting out the while loop and I get the same behaviour per the current choice sdk

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions