Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7897175
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T08:05:42+00:00 2026-06-03T08:05:42+00:00

I have code in my app that adds a UIView to the root view

  • 0

I have code in my app that adds a UIView to the root view controller’s view. This view is semi-transparent, and functions as a modal overlay that covers the entire application (the view contains a button that when clicked removes the view from its superview, which is how the user gets back to the main application).

This has worked fine up to now, but now we’re using UIPopoverControllers and attempting to use this same modal overlay to block the main application. The problem is that this UIView is shown behind the popover, instead of on top of it.

Is there any way to add a subview to a root view controller’s view in such a way that it appears on top of any visible UIPopoverControllers, but without dismissing them?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T08:05:43+00:00Added an answer on June 3, 2026 at 8:05 am

    The reference on UIPopoverController states:

    “The popover content is layered on top of your existing content in a special type of window.”

    NSLogging of the subviews-array shows, that the view is not added to the view hierarchy of the viewController that displays it. From my point of view what you are trying to do isn’t possible.

    Here is an idea though:

    You could add your blocking UIView to the contentViewController of the UIPopOverController and use it to set a property on the contentViewController.

    Then you set your main viewController, which actually displays the UIPopoverController, as delegate of the popover and do something like this:

    - (void) popoverControllerShouldDismissPopover:(UIPopoverController*)popoverController
    {
        if(popoverController.contentViewController.yourProperty)
        {
            return YES;
        }
        return NO;
    }
    

    I don’t know how much this helps in your current situation, but maybe it gets you started.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following section of code in an app that I am writing:
I have code that is triggered on launch only after the app is upgraded
I have an app that I need to get the source code to update
I have a legacy PHP/MySQL app that calls mysql_connect(). Tons of existing downstream code
I have the following code that allows my console app to go to the
I have this code: app = new Application(); app.Visible = false; workbook = app.Workbooks.Add(1);
Currently I have this code var App = Ember.Application.create(); App.user = Ember.Object.create({ people: customers
I am working on an app that has a navigation view controller in a
I have this app of mine that contains a section that will allow the
I have a UIView (menuView in code below) of size 320x218 inside a view.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.