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

  • SEARCH
  • Home
  • 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 7900825
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T09:03:43+00:00 2026-06-03T09:03:43+00:00

Reading the documentation on the changes to UIViewControllers in iOS, I trying to figure

  • 0

Reading the documentation on the changes to UIViewControllers in iOS, I trying to figure out how the interaction between presenting modal view controllers works inside of a custom container view controller. Ultimately, what I would like to be able to do is reliably walk through a chain of presented view controllers, even if some of those controllers are being presented by child view controllers.

(I am working on a library, not on an app, so I am not creating the hierarchies I will be interacting with. I am simply trying to ensure that my library will work correctly within different types of hierarchies.)

So my question is boils down to, what happens when someone tries to present a view controller from a child view controller?

[childViewController presentViewController:viewController animated:YES completion:nil];

Since a presented view controller is intended to “take over” interaction until it is dismissed, it would make sense to me that the presentation request would be forward to its parent (or actually, up the chain of parentViewControllers until it reaches a view controller with no parentViewController) and then be displayed from that view controller. Otherwise, it seems as if the developer could do things like present modal view controllers from two different children, etc. which seems to me problematic. (Which presented view controller would take precedence, for example?).

Furthermore, if the above were true, it seems like it would have some implications. If the parent view controller is displaying a presented view controller, what would this return?

[childViewController presentedViewController];

Would it be nil because the parent is displaying it? Or could this request be forwarded to the parent, so that the parentViewController and any of its childViewControllers would all have the same results?

Anyway, I have a sample project ready to go to start running some scenarios, but I am curious if there is any documentation I have missed? Or if someone already knows about the way that this interaction takes place?

  • 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-03T09:03:44+00:00Added an answer on June 3, 2026 at 9:03 am

    I worked on a container view controller a while ago and found out that the default implementation checks if parentViewController exists, and if it does it passes the message on to the parent.

    I couldn’t find any documentation on it, so you can’t rely on it 100%.

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

Sidebar

Related Questions

I am trying to teach myself Python by reading documentation. I am trying to
I'm trying to figure out how to allow users to click on a Google+
I'm new to Java, and while reading documentation so far I can't find any
Reading the documentation for the spawn gem it states: By default, spawn will use
reading the documentation for java org.w3c.dom.ls it seems as a Element only can be
Reading through documentation, I found following: 1.9.1 1.8.4 1.8.2 A version of 1.8.2 select
Reading the documentation it seems this might not be possible, but it seems that
When reading some documentation about assertions, I found: java -ea -dsa Enables assertions in
I was reading the documentation: You need to decide how many children can be
I've tried reading the documentation, but there is no explanation of what is limit,

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.