iphone - How does UIView nextResponder know what the UIViewController is? -


Just as a matter of curiosity, how does the implementation of the next regender method of the UIView class show which UIIUIUI is the controller Who manages the scene? The UIResponder documentation tells this, and I can see it work, but I do not quite understand it. To do the best of your knowledge, a UIView does not have a reference for its controller, so what is happening behind the scenes? Or am I just not clear at all?

I am still very new to objective-and-iPhone development, so I should apologize if this is clear, but I'm very excited.

Thank you!

This view is different from the hierarchy; the respondent chain may look like this:

  First Responder & gt; View hierarchy & gt; Window & gt; Window Rep & gt; Etc. ...  

However, the objects can automatically insert into the Response Chain and that is what the UIWUUUUUTUL controller does. From Docs:

Because controllers are strictly bound to the scenes they see, they are also part of the response chain used to handle events. View controllers themselves are descendants of the UIResponder class and are inserted into the Respondent series between the managed view and its supervision.

In Big Cocoa, this is done using the -setNextResponder: method This method is not public in cocoa touch, but still this is what UIViewController does.


Comments

Popular posts from this blog

MySql variables and php -

url rewriting - How to implement the returnurl like SO in PHP? -

Which Python client library should I use for CouchdB? -