{"id":261851,"date":"2015-07-20T13:09:02","date_gmt":"2015-07-20T09:09:02","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=261851"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=261851","title":{"rendered":"UINavigationController \u0438 \u0441 \u0447\u0435\u043c \u0435\u0433\u043e \u0435\u0434\u044f\u0442: \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u044b, \u0441\u0443\u0431\u043a\u043b\u0430\u0441\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u0437\u0430\u0449\u0438\u0442\u0430 \u043e\u0442 \u0434\u0432\u043e\u0439\u043d\u044b\u0445 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432 \u0438 \u043c\u043d\u043e\u0433\u043e\u0435 \u0434\u0440\u0443\u0433\u043e\u0435"},"content":{"rendered":"<p>             \u042f \u043d\u0435 \u043f\u0440\u0435\u0442\u0435\u043d\u0434\u0443\u044e \u043d\u0430 \u0438\u0441\u0442\u0438\u043d\u0443 \u0432 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0439 \u0438\u043d\u0441\u0442\u0430\u043d\u0446\u0438\u0438, \u043d\u043e \u0438 \u0432 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u043a\u043e\u0435-\u0447\u0435\u0433\u043e \u0432\u0441\u0435-\u0442\u0430\u043a\u0438 \u0441\u043c\u044b\u0441\u043b\u044e. \u041f\u043e\u0441\u0435\u043c\u0443 \u0440\u0435\u0448\u0438\u043b \u043f\u043e\u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u0441 \u0432\u0430\u043c\u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u043c\u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430\u043c\u0438 \u043f\u0440\u043e\u0434\u0435\u043b\u0430\u043d\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b, \u043f\u043e\u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u043d\u0435\u043a\u043e\u0439 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0435\u0439 \u0437\u043d\u0430\u043d\u0438\u044f \u043e \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430\u0445, \u0442\u0430\u043a \u0441\u043a\u0430\u0437\u0430\u0442\u044c. \u041c\u043e\u0436\u0435\u0442 \u044d\u0442\u043e \u0438 \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u043a\u0430\u043a\u043e\u0439-\u043b\u0438\u0431\u043e \u0438\u0437 \u0431\u0440\u0435\u043d\u043d\u044b\u0445 \u043e\u0431\u043e\u043b\u043e\u0447\u0435\u043a, \u0441\u043f\u043e\u0441\u043e\u0431\u043d\u044b\u0445 \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u0430\u043b\u0435\u0435 \u043c\u043e\u0438\u043c\u0438 \u0447\u0438\u0442\u0430\u0442\u0435\u043b\u044f\u043c\u0438, \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0431\u043e\u043b\u0435\u0435 \u0441\u043e\u0432\u0435\u0440\u0448\u0435\u043d\u043d\u044b\u0439 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u044b\u0439 \u043f\u0440\u043e\u0434\u0443\u043a\u0442.<\/p>\n<p>  \u041f\u0440\u0435\u0434\u043c\u0435\u0442\u043e\u043c \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440, \u0430 \u0438\u043c\u0435\u043d\u043d\u043e \u043a\u043b\u0430\u0441\u0441 UINavigationController \u0438\u0437 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0433\u043e \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430 UIKit \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0430\u043c \u043b\u044e\u0431\u0435\u0437\u043d\u043e \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 Apple.<\/p>\n<h4>\u0412\u043a\u0440\u0430\u0442\u0446\u0435 \u043e&#8230;<\/h4>\n<p>  \u00ab\u041a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u00bb \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u2014 \u043d\u0435\u043a\u0438\u0439 \u043a\u043b\u0430\u0441\u0441, \u0438\u043d\u043a\u0430\u043f\u0441\u0443\u043b\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u043b\u043e\u0433\u0438\u043a\u0443, \u0441\u043e\u0433\u043b\u0430\u0441\u043d\u043e \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0438 (\u0435\u0449\u0435 \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u043e\u0439 \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u043e\u043c) <a href=\"https:\/\/ru.wikipedia.org\/wiki\/Model-View-Controller\">MVC<\/a>. <\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/ec6\/282\/c34\/ec6282c340604845bb93e94407745c4e.png\"\/><\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/41a\/537\/33f\/41a53733f3174ee7aa6161bd58e2fed6.jpg\"\/><\/p>\n<p>  \u041d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 (<a href=\"https:\/\/developer.apple.com\/library\/ios\/documentation\/UIKit\/Reference\/UINavigationController_Class\/\">UINavigationController<\/a>) \u2014 \u043a\u043b\u0430\u0441\u0441 \u0432\u044b\u0441\u043e\u043a\u043e\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u0438, \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0438\u0435\u0440\u0430\u0440\u0445\u0438\u044e \u0434\u0440\u0443\u0433\u0438\u0445 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u0432 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0439, \u043c\u0435\u0436\u0434\u0443 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f\u043c\u0438(\u0432\u044c\u044e\u0448\u043a\u0430\u043c\u0438\/UIView) \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u043f\u043e\u0441\u043e\u0431\u0435\u043d \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0442\u044c \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u044e (\u0432 \u0447\u0435\u043c \u0435\u0433\u043e, \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0430 \u0438 \u0441\u043e\u0441\u0442\u043e\u0438\u0442!), \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u044f \u0432 \u043d\u0443\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c\u0443 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0443. \u041a\u0440\u043e\u043c\u0435 \u044d\u0442\u043e\u0433\u043e \u2014 \u043a\u043e\u043c\u043f\u043e\u0437\u0438\u0446\u0438\u043e\u043d\u043d\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u0443\u044e \u043f\u0430\u043d\u0435\u043b\u044c (UINavigationBar), \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u043d\u0430 \u044d\u043a\u0440\u0430\u043d\u0435, \u0438 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043c\u0435\u043d\u044f\u0435\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0434\u0430\u043d\u043d\u043e\u0439 \u043f\u0430\u043d\u0435\u043b\u0438: \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430. <br \/>  <a name=\"habracut\"><\/a><br \/>  \u0412 \u043b\u044e\u0431\u043e\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0438\u0437 \u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c, \u043a\u0430\u043a \u0442\u0435\u043a\u0443\u0449\u0438\u0439 navigation Item, \u0442\u0430\u043a \u0438 navigation Bar: <code>self.navigationItem<\/code><br \/>  <code>self.navigationController.navigationBar<\/code><\/p>\n<p>  \u0418\u0435\u0440\u0430\u0440\u0445\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430 \u2014 \u0432\u0441\u0435\u0433\u0434\u0430 \u0434\u0440\u0435\u0432\u043e\u0432\u0438\u0434\u043d\u0430\u044f:<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/132\/10c\/bc2\/13210cbc202845ee9a03c941fa35d811.png\"\/><\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/1ed\/a72\/27f\/1eda7227fc5d4714bdcc1a670ff06a78.png\"\/><\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/979\/e81\/886\/979e81886e584998900e42d45bc22e32.png\"\/><\/p>\n<h4>\u041f\u0440\u0435\u0434\u044b\u0441\u0442\u043e\u0440\u0438\u044f<\/h4>\n<p>  \u041c\u043e\u0435 \u0437\u043d\u0430\u043a\u043e\u043c\u0441\u0442\u0432\u043e \u0441 \u044d\u0442\u0438\u043c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u043c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u043e\u043d\u0430\u0447\u0430\u043b\u0443 \u0431\u044b\u043b\u043e \u043f\u043e\u0432\u0435\u0440\u0445\u043d\u043e\u0441\u0442\u043d\u044b\u043c, \u043d\u043e \u043f\u043e\u0441\u043b\u0435 \u043e\u0434\u043d\u043e\u0433\u043e \u0441\u043b\u0443\u0447\u0430\u044f \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0443\u0433\u043b\u0443\u0431\u0438\u0442\u044c\u0441\u044f. \u0414\u0435\u043b\u043e \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u0432 \u043e\u0434\u043d\u043e\u043c \u043c\u043e\u0435\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438, \u0432 \u0440\u0430\u0437\u043d\u044b\u0445 \u043c\u0435\u0441\u0442\u0430\u0445, \u0432 \u0441\u0432\u044f\u0437\u0438 \u0441 \u0431\u043e\u043b\u044c\u0448\u0438\u043c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e\u043c \u0430\u0441\u0438\u043d\u0445\u0440\u043e\u043d\u043d\u043e\u0441\u0442\u0438, \u043d\u0435\u0441\u043b\u0430\u0431\u043e\u0439 \u0441\u0432\u044f\u0437\u043d\u043e\u0441\u0442\u044c\u044e \u2014 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u043b\u043e \u043a\u0443\u0447\u0430 \u0432\u0441\u044f\u043a\u043e\u0433\u043e \u043d\u0435\u043f\u043e\u0442\u0440\u0435\u0431\u0441\u0442\u0432\u0430 \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430\u0445 \u043e\u0442 \u043e\u0434\u043d\u043e\u0433\u043e \u044d\u043a\u0440\u0430\u043d\u0430 \u043a \u0434\u0440\u0443\u0433\u043e\u043c\u0443, \u0434\u0430 \u0438 \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u043b\u0438 \u0434\u0432\u043e\u0439\u043d\u044b\u0435 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u044b, \u043f\u0440\u0438 \u0431\u044b\u0441\u0442\u0440\u044b\u0445 \u043a\u0430\u0441\u0430\u043d\u0438\u044f\u0445 (\u0442\u0430\u0447\u0430\u0445). \u0414\u043e \u044d\u0442\u043e\u0433\u043e \u043c\u043d\u0435 \u0443\u0434\u0430\u0432\u0430\u043b\u043e\u0441\u044c \u0443\u0441\u043f\u0435\u0448\u043d\u043e \u0441\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c\u0441\u044f \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u043c\u0438 \u043e\u0431\u0445\u043e\u0434\u043d\u044b\u043c\u0438 \u043f\u0443\u0442\u044f\u043c\u0438, \u043d\u043e \u043a\u0443\u0434\u0430 \u0443\u0436 \u043c\u044b \u0431\u044b \u0434\u0435\u043b\u0438\u0441\u044c \u0431\u0435\u0437 \u0441\u0442\u0440\u0435\u043c\u043b\u0435\u043d\u0438\u044f \u043a \u0441\u043e\u0432\u0435\u0440\u0448\u0435\u043d\u043d\u043e\u043c\u0443\u2026<\/p>\n<p>  \u0412 \u043e\u0434\u0438\u043d \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u043c\u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043f\u0440\u0435\u043a\u0440\u0430\u0442\u0438\u0442\u044c \u0434\u0432\u043e\u0439\u043d\u043e\u0439 \u043f\u0435\u0440\u0435\u0445\u043e\u0434 (\u0447\u0435\u0440\u0435\u0437 2 \u0443\u0440\u043e\u0432\u043d\u044f \u0438\u0435\u0440\u0430\u0440\u0445\u0438\u0438, \u043f\u043e\u0441\u043b\u0435 \u0441\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u043d\u0438\u044f \u043a\u043d\u043e\u043f\u043a\u0438 \u043d\u0430\u0437\u0430\u0434, \u0438 \u0431\u044b\u0441\u0442\u0440\u043e\u0433\u043e \u0441\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u043d\u0438\u044f). \u0421\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043b\u043e\u0441\u044c \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0443 \u0432 \u043c\u043e\u043c\u0435\u043d\u0442 \u0441\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430. \u041f\u043e\u0441\u043b\u0435 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f \u0432\u044b\u044f\u0441\u043d\u0438\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 2 \u0441\u043f\u043e\u0441\u043e\u0431\u0430 \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c:<\/p>\n<p>  1) \u0421\u043e\u0437\u0434\u0430\u0442\u044c \u043a\u043d\u043e\u043f\u043a\u0443 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e, \u043f\u043e\u0432\u0435\u0441\u0438\u0442\u044c \u043d\u0430 \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d \u0431\u0430\u0440, \u043f\u0440\u0438\u043a\u0440\u0435\u043f\u0438\u0442\u044c \u043a \u043d\u0435\u0439 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u0441\u0435\u043b\u0435\u043a\u0442\u043e\u0440 (\u043c\u0435\u0442\u043e\u0434-\u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a), \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u044f\u0432\u043d\u043e \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0442\u044c \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0443 \u0438 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c \u043e\u0434\u0438\u043d \u0438\u0437 \u043c\u0435\u0442\u043e\u0434\u043e\u0432, \u043f\u043e \u0442\u0438\u043f\u0443 <a href=\"https:\/\/developer.apple.com\/library\/ios\/documentation\/UIKit\/Reference\/UINavigationController_Class\/#\/\/apple_ref\/occ\/instm\/UINavigationController\/popViewControllerAnimated:\">popViewControllerAnimated:<\/a>;<br \/>  2) \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b, \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u044e\u0449\u0438\u0439 \u0434\u0435\u043b\u0435\u0433\u0430\u0442\u0430 \u0434\u043b\u044f \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043f\u0430\u043d\u0435\u043b\u0438 UINavigationBarDelegate.<\/p>\n<p>  \u041a \u0441\u043e\u0436\u0430\u043b\u0435\u043d\u0438\u044e, \u0443 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u043f\u043e\u0434\u0445\u043e\u0434\u0430 \u0431\u044b\u043b \u044f\u0432\u043d\u044b\u0439 \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u043a: \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u044f \u043a\u043d\u043e\u043f\u043a\u0443 \u0438 \u0432\u0435\u0448\u0430\u044f \u0435\u0435 \u043d\u0430 \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d \u0431\u0430\u0440, \u044f \u043d\u0435 \u0441\u043c\u043e\u0433 \u0431\u044b \u0434\u043e\u0431\u0438\u0442\u044c\u0441\u044f \u043b\u0435\u0433\u043a\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 \u0441\u0442\u0440\u0435\u043b\u043e\u0447\u043a\u0438 \u0438 \u043a\u043d\u043e\u043f\u043a\u0438 \u043d\u0430\u0437\u0430\u0434 (\u0443 \u043c\u0435\u043d\u044f \u043f\u0440\u043e\u0441\u0442\u043e \u043d\u0435 \u0431\u044b\u043b\u043e \u044d\u0442\u043e\u0439 \u0438\u043a\u043e\u043d\u043a\u0438, \u043e\u043d\u0430 \u043f\u043e\u0445\u043e\u0434\u0443 \u0431\u0435\u0440\u0435\u0442\u0441\u044f \u0438\u0437 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0445 asset-\u043e\u0432 (\u043d\u0430\u0431\u043e\u0440\u043e\u0432)).<\/p>\n<p>  \u041f\u043e\u0441\u043b\u0435 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043f\u0440\u043e\u0431 \u0432\u044b\u044f\u0441\u043d\u0438\u043b\u043e\u0441\u044c, \u0447\u0442\u043e UINavigationBarDelegate \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442, \u0447\u0442\u043e\u0431\u044b \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0434\u0435\u043b\u0435\u0433\u0430\u0442\u0430 \u0431\u044b\u043b \u0442\u043e\u043b\u044c\u043a\u043e UINavigationController, \u0438 \u044f \u0440\u0435\u0448\u0438\u043b\u0441\u044f \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u0432\u0441\u0435-\u0442\u0430\u043a\u0438 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u043e\u0434\u043a\u043b\u0430\u0441\u0441 \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0437\u0432\u0435\u0440\u044f.<\/p>\n<h4>\u041e \u0434\u0435\u043b\u0435\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438, \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438 \u0438 \u0437\u0430\u0449\u0438\u0442\u043d\u043e\u043c \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438, UINavigationControllerDelegate\/UInavigationBarDelegate<\/h4>\n<p>  <a href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD_%D0%B4%D0%B5%D0%BB%D0%B5%D0%B3%D0%B8%D1%80%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D1%8F\">\u0414\u0435\u043b\u0435\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435<\/a> \u2014 \u043e\u0434\u0438\u043d \u0438\u0437 \u0444\u0443\u043d\u0434\u0430\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u043e\u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0441\u0443\u0442\u044c \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u043c\u044b \u0434\u0435\u043b\u0435\u0433\u0438\u0440\u0443\u0435\u043c (\u043f\u0435\u0440\u0435\u043d\u0430\u0437\u043d\u0430\u0447\u0430\u0435\u043c) \u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435 \u0437\u0430 \u043a\u0430\u043a\u0438\u0435-\u043b\u0438\u0431\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u043d\u0430 \u043a\u043b\u0430\u0441\u0441 \u0434\u0435\u043b\u0435\u0433\u0430\u0442\u0430. \u041a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e \u0434\u043b\u044f objective-c:<\/p>\n<p>  \u041a\u043b\u0430\u0441\u0441 \u0434\u0435\u043b\u0435\u0433\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u0435 -&gt; \u043a\u043b\u0430\u0441\u0441-\u0434\u0435\u043b\u0435\u0433\u0430\u0442<br \/>   \u2014 \u043d\u0430\u0437\u043d\u0430\u0447\u0430\u0435\u043c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b \u043a\u043b\u0430\u0441\u0441\u0443-\u0434\u0435\u043b\u0435\u0433\u0430\u0442\u0443, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440  \u2014 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u043c \u0432\u0441\u0435 \u043c\u0435\u0442\u043e\u0434\u044b \u0441\u043e \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u043e\u043c  @required<br \/>  \u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u0435\u0442\u043e\u0434\u044b, \u043f\u043e\u043c\u0435\u0447\u0435\u043d\u043d\u044b\u0435 \u043a\u043b\u044e\u0447\u0435\u0432\u044b\u043c \u0441\u043b\u043e\u0432\u043e\u043c  @optional<br \/>   \u2014 \u043d\u0430\u0437\u043d\u0430\u0447\u0430\u0435\u043c \u043a\u043b\u0430\u0441\u0441\u0443, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u0435\u043b\u0435\u0433\u0438\u0440\u0443\u0435\u0442 \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u0435, \u044d\u0442\u043e\u0442 \u0434\u0435\u043b\u0435\u0433\u0430\u0442 \u0447\u0435\u0440\u0435\u0437 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u043e \u0434\u0435\u043b\u0435\u0433\u0430\u0442\u0430 (\u0443 \u043a\u043b\u0430\u0441\u0441\u0430 \u0434\u0435\u043b\u0435\u0433\u0438\u0440\u0443\u044e\u0449\u0435\u0433\u043e \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u043e, \u0447\u0442\u043e-\u0442\u043e \u0432\u0440\u043e\u0434\u0435  @property (assign, nonatomic) id delegate;)<br \/>   \u2014 \u043f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e, \u0435\u0441\u043b\u0438 \u043c\u044b \u043f\u0438\u0448\u0435\u043c \u043f\u0435\u0440\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441, \u0442\u043e \u0432 \u043d\u0443\u0436\u043d\u044b\u0445 \u043c\u0435\u0441\u0442\u0430\u0445 \u0442\u044f\u0433\u0430\u0435\u043c \u043c\u0435\u0442\u043e\u0434\u044b, \u043d\u0435 \u0437\u0430\u0431\u044b\u0432\u0430\u044f \u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u043f\u043e \u0442\u0438\u043f\u0443  <\/p>\n<pre><code class=\"objectivec\">if(self.delegate && [self.delegate conformsToProtocol:@protocol(MyProtocol)] && [self.delegate respondsToSelector: @selector(aMethod)]){         [delegate aMethod]; } <\/code><\/pre>\n<p>  \u0412 \u043e\u0431\u0449\u0435\u043c, \u0447\u0435\u043c \u044d\u0442\u043e \u043f\u043e\u0445\u043e\u0436\u0435 \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u043e\u0434\u0438\u043d \u043e\u0431\u044a\u0435\u043a\u0442 \u043d\u0430\u043d\u0438\u043c\u0430\u0435\u0442 \u0434\u0440\u0443\u0433\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442, \u0447\u0442\u043e\u0431\u044b \u044d\u0442\u043e\u0442 \u043e\u0431\u044a\u0435\u043a\u0442 \u043e\u0431\u044a\u044f\u0441\u043d\u0438\u043b \u0435\u043c\u0443, \u0447\u0442\u043e \u0434\u0435\u043b\u0430\u0442\u044c \u0438 \u043a\u0430\u043a \u043f\u043e\u0441\u0442\u0443\u043f\u0430\u0442\u044c \u0432 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0445 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u044f\u0445. \u0422\u0430\u043a-\u0442\u043e\u2026<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/f31\/d44\/5be\/f31d445bebf74652bfaec3493f75ad0d.jpg\"\/><\/p>\n<p>  \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043d\u043e\u0432\u043e\u0433\u043e \u043f\u043e\u0434\u043a\u043b\u0430\u0441\u0441\u0430 \u043d\u0430 objective-c \u043b\u044e\u0431\u044f\u0442 \u043e\u0431\u0437\u044b\u0432\u0430\u0442\u044c \u00ab\u0441\u0443\u0431\u043a\u043b\u0430\u0441\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435\u043c\u00bb, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0435 \u0431\u0443\u0434\u0443 \u0441\u0438\u043b\u044c\u043d\u043e \u043e\u0442\u0445\u043e\u0434\u0438\u0442\u044c \u043e\u0442 \u044d\u0442\u0438\u0445 \u043a\u0430\u043d\u043e\u043d\u043e\u0432.<\/p>\n<p>  \u0412 \u0447\u0435\u043c \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u043e \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043f\u043e\u0434\u043a\u043b\u0430\u0441\u0441\u0430? \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u044f \u0434\u0443\u043c\u0430\u043b \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0432 \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0434\u043d\u0443 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u044e, \u043d\u043e \u043f\u043e\u0441\u043b\u0435 \u043f\u0440\u0438\u0448\u0435\u043b \u043a \u0432\u044b\u0432\u043e\u0434\u0443, \u0447\u0442\u043e \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043b\u0443\u0447\u0448\u0435 \u0446\u0435\u043d\u0442\u0440\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0432\u0441\u0435 \u0441\u0445\u043e\u0436\u0438\u0435 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u0438, \u0432\u043d\u0435\u0434\u0440\u0438\u0442\u044c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0435 \u043a\u0443\u0441\u043a\u0438 \u043a\u043e\u0434\u0430 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0432 \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d, \u0447\u0442\u043e\u0431\u044b \u0438\u0437\u0431\u0430\u0432\u0438\u0442\u044c\u0441\u044f \u043e\u0442 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u043d\u0430 \u043a\u043e\u0440\u043d\u044e \u0438 \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0434\u0440\u0443\u0433\u0438\u0445 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u0439. \u0415\u0449\u0435 \u043e\u0434\u043d\u043e \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u043e \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0446\u0435\u043d\u0442\u0440\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e (\u0432 \u043e\u0434\u043d\u043e\u043c \u043c\u0435\u0441\u0442\u0435 \u043a\u043e\u0434\u0430) \u043f\u0438\u0441\u0430\u0442\u044c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043e\u0434, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u043e\u0431\u0449\u0438\u043c \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u043c\u043e\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u2014 \u043e\u0442\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u043c\u0443\u043b\u044c\u0442\u0438\u0442\u0430\u0447)<\/p>\n<p>  \u041f\u043e\u0447\u0442\u0438 \u0432\u0441\u0435 \u043c\u0435\u0442\u043e\u0434\u044b \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438 \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0430\u0447\u0438\u043d\u0430\u044e\u0442\u0441\u044f \u0441 \u043f\u0440\u0438\u0441\u0442\u0430\u0432\u043e\u043a push\/pop, \u0447\u0442\u043e-\u0442\u043e \u0432\u0440\u043e\u0434\u0435 \u043f\u0440\u043e\u0442\u043e\u043b\u043a\u043d\u0443\u0442\u044c\/\u0432\u044b\u0442\u043e\u043b\u043a\u043d\u0443\u0442\u044c (\u043d\u0435 \u043a\u0430\u043a \u0432 Git-e \u0430\u043d\u0442\u043e\u043d\u0438\u043c\u044b push\/pull), \u043d\u043e \u0442\u0430\u043a\u043e\u0432\u0430 \u0431\u044b\u043b\u0430 \u043f\u0440\u0438\u043d\u044f\u0442\u0430\u044f \u043d\u0435 \u043c\u043d\u043e\u0439 \u043a\u043e\u043d\u0432\u0435\u043d\u0446\u0438\u044f \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u0438\u044f \u0446\u0435\u043b\u0435\u0432\u044b\u0445 \u043c\u0435\u0442\u043e\u0434\u043e\u0432. \u041f\u0430\u0440\u0443 \u0441\u043b\u043e\u0432 \u043f\u0440\u043e UINavigationBar. \u041e\u043d \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0441\u0445\u043e\u0436\u0443\u044e \u0438\u0435\u0440\u0430\u0440\u0445\u0438\u044e, \u043d\u043e NavigationItem-\u043e\u0432. \u042d\u0442\u0438 Item-\u044b \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0442 \u0438\u0437 \u0441\u0435\u0431\u044f \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b UINavigationBar-a (\u043a \u0441\u0430\u0431\u0432\u044c\u044e\u0448\u043a\u0430\u043c \u044d\u0442\u043e\u0433\u043e \u0431\u0430\u0440\u0430, \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e, \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043d\u0435\u0442. \u0414\u0430 \u0438 \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u044f\u0432\u043d\u043e \u043d\u0435 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u043a\u0430\u043a\u0438\u043c-\u043b\u0438\u0431\u043e \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0438\u0445 \u0434\u043e\u0441\u0442\u0430\u0432\u0430\u0442\u044c\/\u043c\u0435\u043d\u044f\u0442\u044c <code> frame\/bounds\/alpha <\/code> UINavigationBar-a (\u043e\u043d \u0432\u0441\u0435-\u0442\u0430\u043a\u0438 \u043d\u0430\u0441\u043b\u0435\u0434\u0443\u0435\u0442\u0441\u044f \u043e\u0442 UIView)). \u0422\u043e \u0435\u0441\u0442\u044c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d \u0431\u0430\u0440 \u0432\u0441\u0435-\u0442\u0430\u043a\u0438 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0438 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c\u0438 navigationItem-\u0430\u043c\u0438, \u0430 \u0432\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u0435 \u2014 \u043e\u0442 \u043b\u0443\u043a\u0430\u0432\u043e\u0433\u043e. \u041a \u0447\u0435\u043c\u0443 \u0432\u0441\u0435 \u044d\u0442\u043e? \u0410 \u043a \u0442\u043e\u043c\u0443, \u0447\u0442\u043e UINavigationBarDelegate \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0434\u043e\u0441\u0442\u0443\u043f \u043a 4-\u043c \u043c\u0435\u0442\u043e\u0434\u0430\u043c: <\/p>\n<pre><code class=\"objectivec\">- (BOOL)navigationBar:(UINavigationBar *)navigationBar        shouldPushItem:(UINavigationItem *)item; - (void)navigationBar:(UINavigationBar *)navigationBar           didPushItem:(UINavigationItem *)item;  - (BOOL)navigationBar:(UINavigationBar *)navigationBar         shouldPopItem:(UINavigationItem *)item; - (void)navigationBar:(UINavigationBar *)navigationBar            didPopItem:(UINavigationItem *)item; <\/code><\/pre>\n<p>  \u0422\u043e\u043b\u044c\u043a\u043e \u0438\u0437 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u044f \u0443\u0436\u0435 \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u043f\u0440\u0435\u0434\u0435\u043b\u044c\u043d\u043e \u044f\u0441\u043d\u043e, \u0447\u0442\u043e \u044d\u0442\u043e \u043c\u0435\u0442\u043e\u0434\u044b \u043f\u043e \u0442\u0438\u043f\u0443 will\/did. \u041f\u0435\u0440\u0432\u044b\u0439 \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0434 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435\u043c, \u0432\u0442\u043e\u0440\u043e\u0439 \u2014 \u043f\u043e\u0441\u043b\u0435. \u0422\u043e\u043b\u044c\u043a\u043e \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043f\u0435\u0440\u0432\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 \u043f\u043e \u0442\u0438\u043f\u0443 should, \u0435\u0449\u0435 \u0438 \u044f\u0432\u043b\u044f\u0435\u0442 \u043e\u0442\u0432\u0435\u0442 \u043d\u0430 \u0432\u043e\u043f\u0440\u043e\u0441: \u00ab\u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043b\u0438 \u044d\u0442\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435?\u00bb \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u043c\u0435\u0442\u043e\u0434 should \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0434 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0435\u0439 \u0437\u0430\u043c\u0435\u043d\u044b item-a navigationBar-a, \u0430 \u043c\u0435\u0442\u043e\u0434 did \u2014 \u043f\u043e\u0441\u043b\u0435. \u0418\u0441\u0445\u043e\u0434\u044f \u0438\u0437 \u0437\u0430\u0434\u0430\u0447\u0438, \u043f\u0435\u0440\u0432\u043e\u0439 \u043c\u043e\u0435\u0439 \u0438\u0434\u0435\u0435\u0439 \u0431\u044b\u043b\u043e \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0435 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0432 \u043c\u0435\u0442\u043e\u0434\u0435 should, \u0438 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c \u0432 \u043c\u0435\u0442\u043e\u0434\u0435 did. \u041c\u0435\u0442\u043e\u0434\u044b push \u043e\u0437\u043d\u0430\u0447\u0430\u044e\u0442 \u0434\u0432\u0438\u0436\u0435\u043d\u0438\u0435 \u0432\u043d\u0438\u0437 \u043f\u043e \u0438\u0435\u0440\u0430\u0440\u0445\u0438\u0438 (\u043a \u0431\u043e\u043b\u0435\u0435 \u0447\u0430\u0441\u0442\u043d\u043e\u043c\u0443), \u0430 \u043c\u0435\u0442\u043e\u0434\u044b pop \u2014 \u0432 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438 \u043a \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u043c\u0443. <\/p>\n<p>  \u041e\u0434\u043d\u0430 \u0438\u0437 \u043a\u043b\u044e\u0447\u0435\u0432\u044b\u0445 \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0439 <a href=\"http:\/\/habrahabr.ru\/post\/191548\/\">\u0437\u0430\u0449\u0438\u0442\u043d\u043e\u0433\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f<\/a> \u043f\u0440\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/201826\/\">\u0430\u0441\u0438\u043d\u0445\u0440\u043e\u043d\u043d\u043e\u0441\u0442\u0438<\/a> \u2014 \u00ab\u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u043c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u0438\u043b\u0438 \u0431\u043b\u043e\u043a\u0438\u0440\u0443\u0435\u043c \u043f\u0440\u043e\u043c\u0435\u0436\u0443\u0442\u043e\u0447\u043d\u044b\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f\u00bb. \u041f\u0440\u043e\u043c\u0435\u0436\u0443\u0442\u043e\u0447\u043d\u044b\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f (intermediate states) \u0432\u0441\u0435\u0433\u0434\u0430 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043e\u0434\u043d\u0438\u043c \u0438\u0437 \u0433\u043b\u0430\u0432\u043d\u044b\u0445 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u043e\u0432 \u0431\u0430\u0433\u043e\u0432 \u0432 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0430\u0445. \u0422\u0430\u043a \u043a\u0430\u043a \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u043f\u043e \u0441\u0432\u043e\u0435\u0439 \u0441\u0443\u0442\u0438 \u2014 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0430\u0441\u0438\u043d\u0445\u0440\u043e\u043d\u043d\u043e\u0435 (\u0442\u043e \u0435\u0441\u0442\u044c \u043d\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u0435\u043d \u0442\u043e\u0447\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0432\u0440\u0435\u043c\u0435\u043d\u0438, \u043a\u043e\u0433\u0434\u0430 \u0432\u044b\u0437\u043e\u0432\u0435\u0442\u0441\u044f \u043a\u0443\u0441\u043e\u043a \u043a\u043e\u0434\u0430, \u043e\u0437\u043d\u0430\u0447\u0430\u044e\u0449\u0438\u0439 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f, \u0432\u0441\u043b\u0435\u0434\u0441\u0442\u0432\u0438\u0435 \u0447\u0435\u0433\u043e \u0435\u0433\u043e \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0441\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u043a\u0443\u0441\u043a\u0430\u043c\u0438 \u043a\u043e\u0434\u0430. \u0410\u0441\u0438\u043d\u0445\u0440\u043e\u043d\u043d\u044b\u0439 \u043a\u043e\u0434 \u0432\u0441\u0435\u0433\u0434\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0432 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435), \u0442\u043e \u0435\u0433\u043e \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u044d\u043a\u0440\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c! <\/p>\n<p>  \u041f\u043e \u0437\u0430\u0449\u0438\u0442\u043d\u043e\u043c\u0443 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044e \u0442\u0435\u043e\u0440\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0447\u0430\u0441\u0442\u044c \u0432\u043f\u043e\u043b\u043d\u0435 \u0441\u0435\u0431\u0435 \u043d\u0435\u043f\u043b\u043e\u0445\u043e \u043e\u043f\u0438\u0441\u0430\u043d\u0430 \u0432 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e\u043c \u0447\u0442\u0438\u0432\u0435 <a href=\"http:\/\/www.ozon.ru\/context\/detail\/id\/3159814\/\">\u00ab\u0421\u043e\u0432\u0435\u0440\u0448\u0435\u043d\u043d\u044b\u0439 \u043a\u043e\u0434\u00bb<\/a><\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/e37\/c8f\/217\/e37c8f2179fe47dfb50a79e4bb342eb4.png\"\/><\/p>\n<p>  \u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430 (segue) \u0441 \u043e\u0434\u043d\u043e\u0433\u043e \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0433\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043a \u0434\u0440\u0443\u0433\u043e\u043c\u0443 \u0442\u043e\u0436\u0435 \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f, \u043a\u0430\u043a \u0432\u044b\u044f\u0441\u043d\u0438\u043b\u043e\u0441\u044c, \u043e\u043d\u043e \u043e\u0442\u043b\u0438\u0447\u043d\u043e \u043e\u0442 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u043f\u0430\u043d\u0435\u043b\u0438. \u0414\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 UINavigationBar-a \u0441\u0442\u0430\u0442\u0438\u0447\u043d\u0430 \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u043e\u0439<br \/>  <code>extern const CGFloat UINavigationControllerHideShowBarDuration;<\/code><\/p>\n<p>  \u0410 \u0434\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u0430. \u041e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u043f\u0440\u0438\u0447\u0438\u043d\u0430 \u044d\u0442\u043e\u0433\u043e \u2014 \u043c\u0435\u0442\u043e\u0434\u044b viewDidLoad\/viewWillAppear:\/\u043c\u0435\u0442\u043e\u0434\u044b \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u044f \u043c\u0430\u043a\u0435\u0442\u0430 (layout-a) \u043f\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u0430\u043c \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u044f (\u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f\u043c\/constraint-\u0430\u043c). \u0421\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430 \u2014 \u0442\u043e\u0436\u0435 \u043d\u0443\u0436\u043d\u043e \u044d\u043a\u0440\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c. <\/p>\n<p>  \u0423 UINavigationController-a \u0435\u0441\u0442\u044c \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b \u0434\u0435\u043b\u0435\u0433\u0430\u0442\u0430 UINavigationControllerDelegate. \u041e\u043d \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 6 \u043c\u0435\u0442\u043e\u0434\u043e\u0432, 4 \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0445 \u0441 transition-\u0430\u043c\u0438, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0438\u043c\u0438 \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0442\u0435\u043a\u0443\u0449\u0443\u044e \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e (\u043d\u043e Available ios 7.0 + \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0433\u043e\u0432\u043e\u0440\u0438\u0442, \u0447\u0442\u043e \u043e\u043d\u0438 \u0435\u0449\u0435 \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u044b), \u0430 \u0432\u043e\u0442 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 2 \u2014 \u043f\u0440\u043e\u0441\u0442\u043e \u043a\u043b\u0430\u0434\u0435\u0437\u044c).<\/p>\n<pre><code class=\"objectivec\">- (void)navigationController:(UINavigationController *)navigationController       willShowViewController:(UIViewController *)viewController                     animated:(BOOL)animated; - (void)navigationController:(UINavigationController *)navigationController        didShowViewController:(UIViewController *)viewController                     animated:(BOOL)animated; <\/code><\/pre>\n<p>  \u0421\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u043d\u0430\u0447\u0430\u043b\u0430 \u0438 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u044f \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 \u043f\u043e\u044f\u0432\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f.<\/p>\n<h4>\u041e \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430\u0445 (Segues)<\/h4>\n<p>  \u0425\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0431\u044b \u0435\u0449\u0435 \u043f\u0430\u0440\u0443 \u0441\u043b\u043e\u0432 \u043e \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430\u0445 (segue), \u0432 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0435 \u0432\u0440\u0435\u043c\u044f \u043e\u043d\u0438 \u0441\u0442\u0430\u043b\u0438 \u0443\u0434\u043e\u0431\u043d\u043e\u0439 \u0438 \u043c\u043e\u0434\u043d\u043e\u0439 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0435\u0439, \u0442\u0430\u043a \u043a\u0430\u043a \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u043d\u0430 \u0441\u0442\u043e\u0440\u0438\u0431\u043e\u0430\u0440\u0434\u0435 \u0442\u0432\u043e\u0440\u0438\u0442\u044c \u0447\u0443\u0434\u0435\u0441\u0430. \u0420\u0430\u043d\u0435\u0435 \u0434\u043b\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043b\u043e\u0441\u044c \u0438\u043d\u0441\u0442\u0430\u043d\u0446\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u044d\u043a\u0437\u0435\u043c\u043f\u043b\u044f\u0440 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430, \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c \u043d\u0443\u0436\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0432 \u043e\u0431\u044a\u0435\u043a\u0442, \u0438 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043c\u0435\u0442\u043e\u0434 <a href=\"https:\/\/developer.apple.com\/library\/ios\/documentation\/UIKit\/Reference\/UINavigationController_Class\/index.html#\/\/apple_ref\/occ\/instm\/UINavigationController\/pushViewController:animated:\">pushViewController:animated:<\/a>, \u0442\u0435\u043f\u0435\u0440\u044c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u00ab\u0441\u0435\u0433\u0443\u00bb \u043d\u0430 \u0441\u0442\u043e\u0440\u0438\u0431\u043e\u0430\u0440\u0434\u0435, \u043d\u0430 \u044d\u043a\u0448\u0435\u043d, \u0435\u0441\u043b\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u2014 \u043f\u043e\u0432\u0435\u0441\u0438\u0442\u044c \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440, \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c. \u0412 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 segue navigation controller-a \u0432\u0441\u0435\u0433\u0434\u0430 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u044e\u0442\u0441\u044f \u043a\u0430\u043a push (\u043d\u0435 \u043a\u0430\u043a modal \u0438\u043b\u0438 \u0447\u0442\u043e-\u0442\u043e \u0434\u0440\u0443\u0433\u043e\u0435).<\/p>\n<p>  \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u0441 \u043b\u044e\u0431\u044b\u043c \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u043c \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0432 \u043a\u043e\u0434\u0435, \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 3 \u043c\u0435\u0442\u043e\u0434\u0430 UIViewController-a:   <\/p>\n<pre><code class=\"objectivec\">- (void)prepareForSegue:(UIStoryboardSegue *)segue                  sender:(id)sender; - (BOOL)shouldPerformSegueWithIdentifier:(NSString *)identifier                                   sender:(id)sender; - (void)performSegueWithIdentifier:(NSString *)identifier                             sender:(id)sender; <\/code><\/pre>\n<p>  \u041f\u0435\u0440\u0432\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043f\u0435\u0440\u0435\u0434 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043a\u0430\u043a\u0438\u0435-\u043b\u0438\u0431\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u043c \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u0434 \u0435\u0433\u043e \u043f\u043e\u044f\u0432\u043b\u0435\u043d\u0438\u0435\u043c, \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0435 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u044b (<code>identifier<\/code> \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430 \u0438 <code>destinationViewController<\/code>).<\/p>\n<p>  \u0412\u0442\u043e\u0440\u043e\u0439 \u043c\u0435\u0442\u043e\u0434 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442, \u043a\u0440\u043e\u043c\u0435 \u043f\u0440\u043e\u0447\u0435\u0433\u043e, \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0442\u044c \u0438\u043b\u0438 \u043f\u0440\u0435\u0440\u0432\u0430\u0442\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430.<\/p>\n<p>  \u0422\u0440\u0435\u0442\u0438\u0439 \u043c\u0435\u0442\u043e\u0434 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u0432 \u043a\u043e\u0434\u0435, \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u043e\u043d \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043a\u043e\u0434 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430 \u0441 <code>pushViewController:animated:<\/code>.<\/p>\n<p>  \u0421\u0430\u043c\u043e\u0435 \u0433\u043b\u0430\u0432\u043d\u043e\u0435 \u0437\u0434\u0435\u0441\u044c \u0442\u043e, \u0447\u0442\u043e \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u044b push \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e segue \u0432\u044b\u0437\u044b\u0432\u0430\u044e\u0442 \u043e\u0434\u043d\u0438 \u0438 \u0442\u0435 \u0436\u0435 \u043c\u0435\u0442\u043e\u0434\u044b \u0438\u0437 navigationController-a (\u0435\u0441\u043b\u0438 \u043e\u043d \u0435\u0441\u0442\u044c):<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/84c\/11a\/050\/84c11a050d8f470bbf2780ca7f4f8000.png\"\/><\/p>\n<p>  \u0427\u0442\u043e \u0435\u0449\u0435 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e \u0437\u0434\u0435\u0441\u044c? \u0421\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 \u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u044b\u0435 \u043e\u0431\u0440\u0430\u0442\u043d\u044b\u0435 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u044b (unwind segue), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0442 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u044b \u043e\u0431\u0440\u0430\u0442\u043d\u043e \u043f\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430\u043c (\u043e\u043d\u0438 \u0442\u0430\u043a\u0436\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043c\u0435\u0442\u043e\u0434\u044b pop). \u0418 \u0443 \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0438\u0437 UIStoryboardSegue \u0435\u0441\u0442\u044c \u043c\u0435\u0442\u043e\u0434 perform, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0442\u044c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0430 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0441\u0443\u0431\u043a\u043b\u0430\u0441\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f UIStoryboardSegue.<\/p>\n<p>  \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432 (segue) \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0441\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u043e\u0439 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u044f \u0441 \u043e\u0434\u043d\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043a \u0434\u0440\u0443\u0433\u043e\u043c\u0443.<\/p>\n<h4>\u041e target-action \u043c\u043e\u0434\u0435\u043b\u0438, \u043e \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f (User Interaction)<\/h4>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/5a8\/e29\/364\/5a8e2936465e4341b2462423c0a82bda.png\"\/><\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/3f4\/edf\/8bd\/3f4edf8bd77f4b799b669b7ea136d243.png\"\/><\/p>\n<p>  \u0418 \u0435\u0449\u0435 \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0433\u0440\u0430\u043c\u043e\u0442\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043f\u043e\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u043d\u0443\u044e \u0437\u0430\u0434\u0430\u0447\u0443 \u2014 \u043f\u0430\u0440\u0443 \u0441\u043b\u043e\u0432 \u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u043c \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0438 \u0441 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c. \u041a\u043e\u0433\u0434\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043a\u0430\u0441\u0430\u0435\u0442\u0441\u044f \u044d\u043a\u0440\u0430\u043d\u0430, \u0433\u0435\u043d\u0435\u0440\u0438\u0442\u0441\u044f \u0438 \u0432\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0435\u0442\u0441\u044f touch event, \u043a \u0441\u043e\u0436\u0430\u043b\u0435\u043d\u0438\u044e UIEvent \u043d\u0435 \u0438\u043c\u0435\u0435\u0442 \u043e\u0442\u043a\u0440\u044b\u0442\u043e\u0433\u043e \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0442\u043e\u0440\u0430, \u0442\u0430\u043a \u0447\u0442\u043e \u043c\u044b \u043d\u0435 \u0438\u043c\u0435\u0435\u043c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u043b\u0435\u0433\u043a\u043e \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u043d\u0430\u0448\u0438 \u0441\u043e\u0431\u044b\u0442\u0438\u044f \u043a\u0430\u0441\u0430\u043d\u0438\u044f \u043a \u044d\u043a\u0440\u0430\u043d\u0443 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430, \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u044d\u043c\u0443\u043b\u0438\u0440\u0443\u044f \u0434\u0430\u043d\u043d\u0443\u044e \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u044e. \u041a\u043e\u043d\u0442\u0440\u043e\u043b\u044b \u0432\u043e \u0432\u0441\u0435\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438 \u0440\u0435\u0430\u0433\u0438\u0440\u0443\u044e\u0442 \u043d\u0430 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0441\u043e\u0431\u044b\u0442\u0438\u044f (event-\u044b), \u0438\u043c \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u043d\u044b\u0435, \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0447\u0435\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u0438\u043d\u0442\u0435\u0440\u0430\u043a\u0442\u0438\u0432\u043d\u044b\u043c \u0438 \u0440\u0435\u0430\u0433\u0438\u0440\u0443\u044e\u0449\u0438\u043c \u043d\u0430 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f.<\/p>\n<p>  \u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u043d\u0430 \u0441\u043e\u0431\u044b\u0442\u0438\u044f \u0443\u0436\u0435 \u043f\u0440\u0435\u0434\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u044b (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043a\u043e\u0433\u0434\u0430 \u043c\u044b \u0434\u0435\u043b\u0430\u0435\u043c touch down \u043f\u043e \u043a\u043d\u043e\u043f\u043a\u0435 \u2014 \u043a\u043d\u043e\u043f\u043a\u0430 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u0442 \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 highlighted (\u043f\u043e\u0434\u0441\u0432\u0435\u0447\u0435\u043d\u0430), \u0438 \u043c\u0435\u043d\u044f\u0435\u0442 \u0432\u043d\u0435\u0448\u043d\u0438\u0439 \u0432\u0438\u0434). \u041c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u0435\u0440\u0435\u0445\u0432\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0441\u043e\u0431\u044b\u0442\u0438\u044f, \u0438 \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u0438\u0445, \u043a\u0430\u043a \u043d\u0430\u043c \u0432\u0437\u0434\u0443\u043c\u0430\u0435\u0442\u0441\u044f, \u043d\u0430\u0437\u043d\u0430\u0447\u0430\u044f \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438, \u0447\u0435\u0440\u0435\u0437 \u0441\u0435\u043b\u0435\u043a\u0442\u043e\u0440\u044b. \u0421\u0435\u043b\u0435\u043a\u0442\u043e\u0440 \u0445\u0440\u0430\u043d\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0445\u044d\u0448-\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0435\u0435 \u0431\u044b\u0441\u0442\u0440\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0439 \u0441 \u043d\u0438\u043c \u043c\u0435\u0442\u043e\u0434 \u0438\u0437 \u0445\u044d\u0448-\u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0441\u0435\u043b\u0435\u043a\u0442\u043e\u0440\u043e\u0432 \u043a\u043b\u0430\u0441\u0441\u0430. \u0412\u0441\u0435 Event-\u044b \u043d\u0430\u0437\u043d\u0430\u0447\u0430\u044e\u0442\u0441\u044f \u0438 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u044e\u0442\u0441\u044f (\u0435\u0441\u043b\u0438 \u043d\u0435 \u043e\u0448\u0438\u0431\u0430\u044e\u0441\u044c) \u0432 \u043d\u0435\u0434\u0440\u0430\u0445 \u043a\u043b\u0430\u0441\u0441\u0430 UIApplication, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0438\u043c\u0435\u0435\u0442 2 \u0432\u0430\u0436\u043d\u044b\u0445 \u043c\u0435\u0442\u043e\u0434\u0430  <\/p>\n<pre><code class=\"objectivec\">- (void)sendEvent:(UIEvent *)event; - (BOOL)sendAction:(SEL)action                 to:(id)target               from:(id)sender           forEvent:(UIEvent *)event;  <\/code><\/pre>\n<p>  \u0412 \u043e\u0431\u0449\u0435\u043c, \u044d\u0442\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f <a href=\"https:\/\/developer.apple.com\/library\/ios\/documentation\/General\/Conceptual\/Devpedia-CocoaApp\/TargetAction.html\">target-action<\/a> \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u0430:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/1cb\/a0a\/bf1\/1cba0abf1ac24af599beb5ecd959c2e0.png\"\/><\/p>\n<p>  \u0421\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 2 \u0441\u043f\u043e\u0441\u043e\u0431\u0430 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0435 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435: \u043f\u0435\u0440\u0432\u044b\u0439 \u2014 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0441\u043e\u0431\u044b\u0442\u0438\u0439 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u043c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u043c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f (\u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043e\u043c); \u0432\u0442\u043e\u0440\u043e\u0439 \u2014 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0438 \u0441\u043e\u0431\u044b\u0442\u0438\u0439 \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0438\u0437 \u043e\u0431\u044a\u0435\u043a\u0442\u0430-\u044d\u043a\u0437\u0435\u043c\u043f\u043b\u044f\u0440\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f.<\/p>\n<p>  1\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 (\u0443 \u043a\u0430\u0436\u0434\u043e\u0433\u043e View \u0435\u0441\u0442\u044c \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u043e userInteractionEnabled):  <\/p>\n<pre><code class=\"objectivec\">self.navigationController.navigationBar.userInteractionEnabled = NO;  self.someButton.userInteractionEnabled = YES; <\/code><\/pre>\n<p>  2\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 (\u043e\u0431\u044a\u0435\u043a\u0442 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0441\u0438\u043d\u0433\u043b\u0442\u043e\u043d\u043e\u043c):  <\/p>\n<pre><code class=\"objectivec\">[[UIApplication sharedApplication] beginIgnoringInteractionEvents]; [[UIApplication sharedApplication] endIgnoringInteractionEvents]; <\/code><\/pre>\n<p>  \u0422\u0430\u043a \u043a\u0430\u043a \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u043d\u0443\u0436\u0434\u0430 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043b\u044e\u0431\u043e\u0435 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 (\u043d\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e \u043f\u0440\u0438 \u043d\u0430\u0436\u0430\u0442\u0438\u0438 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e \u043f\u043e \u043a\u0430\u043a\u043e\u0439 \u043a\u043d\u043e\u043f\u043a\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u043e\u043f\u0430\u0441\u043d\u044b\u0439 \u043a\u043e\u0434 (\u0441\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u0434\u0430\u043b\u0435\u0435 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u043c)), \u0442\u043e \u043d\u0430\u043c \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442 \u0432\u0442\u043e\u0440\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431.<\/p>\n<h4>\u0412\u043d\u0435\u0448\u043d\u0438\u0439 \u0432\u0438\u0434 navigation-bar-a<\/h4>\n<p>  \u041a\u0430\u043a \u0432\u044b, \u043c\u043e\u0436\u0435\u0442, \u0437\u043d\u0430\u0435\u0442\u0435, \u043d\u0430\u0438\u043b\u0443\u0447\u0448\u0430\u044f \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430 \u2014 \u044d\u0442\u043e \u0437\u0430\u0434\u0430\u0432\u0430\u0442\u044c \u0432\u043d\u0435\u0448\u043d\u0438\u0439 \u0432\u0438\u0434 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e UIAppearance, \u043d\u043e \u0431\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f \u043f\u043e\u0434\u043e\u0431\u043d\u043e\u043c\u0443 \u043f\u043e\u0434\u043a\u043b\u0430\u0441\u0441\u0443, \u043c\u043e\u0436\u043d\u043e \u0438 \u043e\u0442\u043a\u0430\u0437\u0430\u0442\u044c\u0441\u044f \u043e\u0442 \u043d\u0435\u0435, \u0435\u0441\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u0435\u0437\u0434\u0435 \u044d\u0442\u043e\u0442 \u043f\u043e\u0434\u043a\u043b\u0430\u0441\u0441. \u041a \u0442\u043e\u043c\u0443-\u0436\u0435 \u0438\u043d\u043a\u0430\u043f\u0441\u0443\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u0443 \u043b\u043e\u0433\u0438\u043a\u0443 (\u0441\u043e\u043a\u0440\u044b\u0442\u044c) \u0432\u043d\u0443\u0442\u0440\u0438 \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0432\u0435\u0441\u044c\u043c\u0430 \u0433\u0440\u0430\u043c\u043e\u0442\u043d\u044b\u043c \u0440\u0435\u0448\u0435\u043d\u0438\u0435\u043c. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442 \u043c\u0435\u0442\u043e\u0434 <code>awakeFromNib<\/code>. \u0421\u0430\u043c\u043e\u043b\u0438\u0447\u043d\u043e \u044f \u043d\u0435 \u043f\u044b\u0442\u0430\u043b\u0441\u044f \u0434\u0435\u043b\u0430\u0442\u044c \u0442\u0430\u043a\u043e\u0435, \u043d\u043e \u043f\u043e\u0434\u0441\u043c\u043e\u0442\u0440\u0435\u043b \u0443 \u0434\u0440\u0443\u0433\u0438\u0445. \u042d\u0442\u043e \u0431\u044b\u043b \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0441\u043e\u0432\u0435\u0442. <\/p>\n<h4>\u041c\u0443\u043b\u044c\u0442\u0438\u0442\u0430\u0447<\/h4>\n<p>  \u0415\u0441\u043b\u0438 \u043a\u043e\u043c\u0443-\u0442\u043e \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e \u043f\u0440\u043e \u043c\u0443\u043b\u044c\u0442\u0438\u0442\u0430\u0447 (\u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0431\u044b\u043b\u043e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u043d\u0430\u0436\u0430\u0442\u044c \u043f\u043e\u0434\u0440\u044f\u0434 2 \u043a\u043d\u043e\u043f\u043a\u0438):  <\/p>\n<pre><code class=\"objectivec\">- (void) makeExclusiveTouchToSubviews:(UIView*)view {     for (UIView * currentSubtView in [view subviews]) {         currentSubView.multipleTouchEnabled  = NO;         currentSubView.exclusiveTouch = YES;         [self makeExclusiveTouchToSubviews:currentSubView];     } } <\/code><\/pre>\n<p>  PS. \u0435\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0441\u0438\u0438\u043c \u0447\u0443\u0434\u043e\u043c, \u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435\u0441\u044c \u043d\u0430 \u0441\u0432\u043e\u0439 \u0441\u0442\u0440\u0430\u0445 \u0438 \u0440\u0438\u0441\u043a, \u044f \u0434\u0430\u043b\u0435\u043a\u043e \u043d\u0435 \u0432\u0441\u0435 \u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u043b \u0438\u0437 \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u0438\u043c\u0435\u043b\u043e\u0441\u044c, \u0442\u0430\u043a \u0447\u0442\u043e \u0434\u043b\u044f \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u0439 \u0432\u0430\u043c \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e, \u0434\u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c \u0441\u0430\u043c\u0438\u043c. \u041a\u043b\u0430\u0441\u0441\u044b Utility\/GAIClient \u043d\u0435 \u043f\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0442\u0441\u044f (\u0438\u0437 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0431\u0435\u0440\u0435\u0442\u0441\u044f \u043c\u0435\u0442\u043e\u0434 \u043d\u0430 \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043c\u0443\u043b\u044c\u0442\u0438\u0442\u0430\u0447\u0430, \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u2014 \u043e\u0442\u0441\u044b\u043b\u0430\u0435\u0442\u0441\u044f non-crash \u0440\u0435\u043f\u043e\u0440\u0442 \u043d\u0430 GoogleAnalytics).<\/p>\n<h4>\u0420\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b<\/h4>\n<p>  \u0411\u044b\u043b\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043e:  <\/p>\n<ul>\n<li>\u0421\u043f\u043e\u0441\u043e\u0431 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u044b \u0431\u044b\u0441\u0442\u0440\u043e \u0432\u0440\u0443\u0447\u043d\u0443\u044e (\u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0430\u0434\u043e\u0431\u043d\u043e\u0441\u0442\u0438);<\/li>\n<li>3 \u0443\u0440\u043e\u0432\u043d\u044f \u0437\u0430\u0449\u0438\u0442\u044b \u043e\u0442 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432:<br \/>   \u0430) \u043d\u0430 \u0443\u0440\u043e\u0432\u043d\u0435 \u043c\u0435\u0442\u043e\u0434\u043e\u0432 should navigationBarDelegate;<\/li>\n<\/ul>\n<p>   \u0432) \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f, \u0435\u0441\u043b\u0438 \u043d\u0430\u0447\u0430\u043b\u0430\u0441\u044c \u0445\u043e\u0442\u044f-\u0431\u044b \u043e\u0434\u043d\u0430 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0430\u044f \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f, \u0438 \u0440\u0430\u0437\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435\u043c, \u0435\u0441\u043b\u0438 \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u043b\u0438\u0441\u044c \u0432\u0441\u0435;<br \/>   \u0432\u0448\u0438\u0442\u0430\u044f \u0437\u0430\u0449\u0438\u0442\u0430 \u043e\u0442 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u044d\u043a\u0448\u0435\u043d\u043e\u0432 \u0441\u0440\u0430\u0437\u0443 2\u0445 \u043a\u043d\u043e\u043f\u043e\u043a (\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u043e\u043c \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043c\u0443\u043b\u044c\u0442\u0438\u0442\u0430\u0447\u0430);<br \/>   \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u0434\u0435\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u0435\u0441\u043b\u0438 \u0447\u0442\u043e-\u0442\u043e \u043f\u043e\u0448\u043b\u043e \u043d\u0435 \u0442\u0430\u043a;<br \/>   \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0440\u0435\u043f\u043e\u0440\u0442\u0430, \u0435\u0441\u043b\u0438 \u0447\u0442\u043e-\u0442\u043e \u043f\u043e\u0448\u043b\u043e \u043d\u0435 \u0442\u0430\u043a.<\/p>\n<p>  <\/p>\n<h4>\u0412\u043e\u0437\u043d\u0438\u043a\u0448\u0438\u0435 \u043d\u044e\u0430\u043d\u0441\u044b \u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b<\/h4>\n<p>  1-\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0431\u044b\u043b\u0430 \u0441\u0432\u044f\u0437\u0430\u043d\u0430 \u0441 \u0442\u0435\u043c, \u0447\u0442\u043e \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u044f\u0432\u043d\u043e\u0433\u043e \u0438 \u043d\u0435\u044f\u0432\u043d\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432 (\u0432\u043e \u0432\u0442\u043e\u0440\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0447\u0435\u0440\u0435\u0437 navigation bar-\u043a\u043d\u043e\u043f\u043a\u0443 \u00abBack\u00bb) \u0432\u043e \u0432\u0442\u043e\u0440\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f \u043c\u0435\u0442\u043e\u0434 <code>popToViewController:animated:<\/code>, \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u044f\u0432\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c, \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043b\u0438 \u0443\u0436\u0435 \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u0441 \u043e\u0434\u043d\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u043d\u0430 \u0434\u0440\u0443\u0433\u043e\u0439;<\/p>\n<p>  2-\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u2014 \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u0435 navigation-bar-a \u043d\u0430 iOS 7.0. \u041d\u0430 \u044d\u0442\u043e\u0439 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0435 \u0434\u043b\u044f \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0433\u043e \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u0434\u0435\u043b\u0435\u0433\u0430\u0442 \u043d\u0430\u0437\u043d\u0430\u0447\u0430\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 (\u0438 \u0435\u0441\u043b\u0438 \u043c\u044b \u0435\u0449\u0435 \u0440\u0430\u0437 \u043f\u044b\u0442\u0430\u0435\u043c\u0441\u044f \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u2014 \u0433\u0435\u043d\u0435\u0440\u0438\u0442 \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 (exception)).<\/p>\n<p>  3-\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u2014 \u043d\u0430 7\u0439 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0435 \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u043f\u0440\u0430\u0432\u044b\u0439 \u0441\u0432\u0430\u0439\u043f interactivePopGestureRecognizer, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u044b \u043d\u0430\u0437\u0430\u0434 (\u043e\u043d \u0432\u044b\u0437\u044b\u0432\u0430\u043b \u0442\u043e\u043b\u044c\u043a\u043e \u043c\u0435\u0442\u043e\u0434 navigation controller delegate will, \u0438\u0437-\u0437\u0430 \u0447\u0435\u0433\u043e \u043d\u0430\u043c\u0435\u0440\u0442\u0432\u043e \u0431\u043b\u043e\u0447\u0438\u043b \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0435 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435).<\/p>\n<p>  4-\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u2014 \u0432 \u043a\u0440\u0430\u0439\u043d\u0435 \u0440\u0435\u0434\u043a\u0438\u0445 \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u044f\u0445 \u043c\u043e\u0433\u043b\u0430 \u0432\u043e\u0437\u043d\u0438\u043a\u043d\u0443\u0442\u044c \u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u044c, \u0447\u0442\u043e \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u043b\u0441\u044f \u043f\u0440\u043e\u0442\u0438\u0432\u043e\u043f\u043e\u043b\u043e\u0436\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 (\u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u0434\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u043b\u0430 \u0431\u044b\u0442\u044c \u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u0447\u0435\u0433\u043e \u0441\u0430\u043c\u043e\u0432\u043e\u0441\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u044e\u0449\u0435\u0439\u0441\u044f). \u0411\u044b\u043b\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043e \u043f\u043e\u0434\u043e\u0431\u0438\u0435 \u0442\u0430\u0439\u043c\u0435\u0440\u0430, \u0441 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u043c-\u0434\u0435\u0431\u043b\u043e\u043a\u0438\u0440\u0430\u0442\u043e\u0440\u043e\u043c.<\/p>\n<h4>\u0421\u043a\u0430\u0447\u0430\u0442\u044c\/\u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c<\/h4>\n<p>  <a href=\"https:\/\/github.com\/huktoDev\/navigationControllerRepo.git\">Git Repo \u043d\u0430 GitHub-e<\/a><\/p>\n<p>  \u041b\u0438\u0441\u0442\u0438\u043d\u0433\u0438 \u043a\u043e\u0434\u0430:  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">HUNavigationController.h<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"objectivec\">\/\/ \/\/  HUNavigationController.m \/\/ \/\/  Created by HuktoDev on 03.07.15. \/\/   #import &lt;UIKit\/UIKit.h&gt;  \/* \u041f\u043e\u0434\u043a\u043b\u0430\u0441\u0441 NavigationController-a, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u0446\u0435\u043d\u0442\u0440\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0439 \u0437\u0430\u0449\u0438\u0442\u044b \u0432\u0441\u0435\u0445 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u0432 \u043e\u0442 \u0434\u0432\u043e\u0439\u043d\u044b\u0445 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432, \u0438 \u043e\u0442 \u043c\u0443\u043b\u044c\u0442\u0438\u0442\u0430\u0447\u0430.    \u041c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u0437\u0430\u0449\u0438\u0442\u044b \u043e\u0442 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d, \u043a\u0430\u043a \u043f\u043e\u043b\u043d\u043e\u0435 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f (event-\u043e\u0432 \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438) \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043d\u044b\u0445 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0439, \u044e\u0442\u0430\u043a\u0438\u0445 \u043a\u0430\u043a   \u0430) \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 navigation-\u0431\u0430\u0440\u0430   \u0431) \u0430\u043d\u0438\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432 \u043c\u0435\u0436\u0434\u0443 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f\u043c\u0438        \u041d\u0430 \u0441\u043b\u0443\u0447\u0430\u0439 \u043d\u0435 \u0441\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u043d\u0438\u044f \u0434\u0435\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f - \u0430\u043a\u043a\u0443\u0440\u0430\u0442\u043d\u043e \u0432\u0448\u0438\u0442 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u0440\u0430\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u044d\u043a\u0440\u0430\u043d\u0430 \u043f\u043e \u0442\u0430\u0439\u043c\u0435\u0440\u0443 \u043f\u043e\u0441\u043b\u0435 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0438      \u0435\u0441\u043b\u0438 \u043f\u0440\u043e\u0438\u0437\u043e\u0439\u0434\u0435\u0442 \u0434\u043b\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0430 - \u043e\u0442\u0441\u044b\u043b\u0430\u0435\u0442 \u0440\u0435\u043f\u043e\u0440\u0442 \u0432 \u0433\u0443\u0433\u043b \u0430\u043d\u0430\u043b\u0438\u0442\u0438\u043a\u0441*\/   #warning \u0421\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0432\u043e\u0439 \u043e\u0441\u043e\u0431\u044b\u0439 \u0442\u0438\u043f \u043b\u043e\u0433\u043e\u0432 \u0434\u043b\u044f \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d\u0430  @interface HUNavigationController : UINavigationController &lt;UINavigationBarDelegate, UINavigationControllerDelegate, UIGestureRecognizerDelegate&gt;  @property (assign, nonatomic) BOOL isBarPopProcessing; @property (assign, nonatomic) BOOL isBarPushProcessing; @property (assign, nonatomic) BOOL isTransitionControllerProcessing;  @property (assign, nonatomic) BOOL isBlockedInteraction;  -(void)blockAllInteraction; -(BOOL)restoreAllInteraction; -(void)makeExclusiveTouchToViewController:(UIViewController*)viewController;  \/* \u043c\u0435\u0442\u043e\u0434 \u0434\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u043b\u0438 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u044b\u0439 \u043f\u0443\u0448\/\u043f\u043e\u043f*\/ -(BOOL)isNeedNavigationBarActionBlocking;  -(BOOL)isInteractionDisabled;   @end  <\/code><\/pre>\n<p>  <\/div>\n<\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">HUNavigationController.m<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"objectivec\">\/\/ \/\/  HUNavigationController.m \/\/ \/\/  Created by HuktoDev on 03.07.15. \/\/  #import &quot;HUNavigationController.h&quot;  @implementation HUNavigationController{     NSTimer *timerCheckBlocking;     NSDate *dateStartBlocking; }  #pragma mark - UIViewController cycle  - (void)viewDidLoad {     [super viewDidLoad];          \/\/\u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u0431\u0443\u043b\u0435\u0432\u044b\u0445 \u0444\u043b\u0430\u0433\u043e\u0432     self.isBarPopProcessing = NO;     self.isBarPushProcessing = NO;     self.isTransitionControllerProcessing = NO;          self.isBlockedInteraction = NO;          \/\/\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0434\u0435\u043b\u0435\u0433\u0430\u0442\u043e\u0432     self.delegate = self;          \/\/\u043d\u0430 7\u0439 \u043f\u0440\u043e\u0448\u0438\u0432\u043a\u0435 - \u0434\u0435\u043b\u0435\u0433\u0430\u0442 \u043d\u0430\u0437\u043d\u0430\u0447\u0430\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438, \u0438\u043d\u0430\u0447\u0435 \u044d\u043a\u0441\u0435\u043f\u0448\u0435\u043d     if(!self.navigationBar.delegate){         self.navigationBar.delegate = self;     }          \/\/\u0440\u0430\u0437\u043b\u043e\u0447\u0438\u0442\u044c \u0432\u0441\u0435, \u0447\u0442\u043e \u043d\u0443\u0436\u043d\u043e     self.navigationBar.userInteractionEnabled = YES;          [self endIgnoringIf:[self isInteractionDisabled]];          \/\/\u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0442\u0430\u0439\u043c\u0435\u0440 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0438     timerCheckBlocking = [NSTimer scheduledTimerWithTimeInterval:0.1 target:self selector:@selector(checkBlocking) userInfo:nil repeats:YES]; }  \/*\u00a0\u0432 iOS 7 - \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0430\u0432\u044b\u0439 \u0441\u0432\u0430\u0439\u043f \u0434\u043b\u044f \u0432\u043e\u0437\u0432\u0440\u0430\u0442\u0430 \u043a \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u043c\u0443 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0443 (\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u043e\u0434\u043e\u0431\u043d\u043e\u0433\u043e \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u044f *\/ -(void)viewWillAppear:(BOOL)animated{     [super viewWillAppear:animated];          if ([self respondsToSelector:@selector(interactivePopGestureRecognizer)]){         self.interactivePopGestureRecognizer.enabled = NO;         self.interactivePopGestureRecognizer.delegate = self;     } }  -(void)viewWillDisappear:(BOOL)animated{     [super viewWillDisappear:animated];          if ([self respondsToSelector:@selector(interactivePopGestureRecognizer)]){         self.interactivePopGestureRecognizer.enabled = YES;         self.interactivePopGestureRecognizer.delegate = nil;     } }  -(void)viewDidDisappear:(BOOL)animated{     [super viewDidDisappear:animated];          \/\/\u043f\u0440\u0438 \u0441\u043e\u043a\u0440\u044b\u0442\u0438\u0438 \u043d\u0430\u0432\u0438\u0433\u0435\u0439\u0448\u0435\u043d\u0430 - \u043f\u043e\u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u0432\u0441\u044f\u043a\u0438\u0439 \u0441\u043b\u0443\u0447\u0430\u0439 \u0441\u043d\u044f\u0442\u044c \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0443 \u0438 \u043e\u0442\u043c\u0435\u043d\u0438\u0442\u044c \u0442\u0430\u0439\u043c\u0435\u0440     [self endIgnoringIf:[self isInteractionDisabled] ]; }  #pragma mark - UIGestureRecognizerDelegate - (BOOL)gestureRecognizerShouldBegin:(UIGestureRecognizer *)gestureRecognizer{     return NO; }  \/*\u043f\u0435\u0440\u0435\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043c\u0435\u0442\u043e\u0434\u043e\u0432 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0433\u043e navigation-a (\u043e\u0434\u0438\u043d \u0438\u0437 \u0443\u0440\u043e\u0432\u043d\u0435\u0439 \u0437\u0430\u0449\u0438\u0442\u044b \u043e\u0442 \u043d\u0435\u0436\u0435\u043b\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432) *\/ #pragma mark - UINavigationController segues methods wrappers -  -(UIViewController *)popViewControllerAnimated:(BOOL)animated{     if([self isNeedNavigationBarActionBlocking]){         return nil;     }else{         return [super popViewControllerAnimated:animated];     } }  - (NSArray *)popToViewController:(UIViewController *)viewController animated:(BOOL)animated{     if([self isNeedNavigationBarActionBlocking]){         return [NSArray array];     }else{         return [super popToViewController:viewController animated:animated];     } }  -(NSArray *)popToRootViewControllerAnimated:(BOOL)animated{     if([self isNeedNavigationBarActionBlocking]){         return [NSArray array];     }else{         return [super popToRootViewControllerAnimated:animated];     } }  -(void)pushViewController:(UIViewController *)viewController animated:(BOOL)animated{     if(![self isNeedNavigationBarActionBlocking]){         [super pushViewController:viewController animated:animated];     } }   #pragma mark - UINavigationBarDelegate  -(BOOL)navigationBar:(UINavigationBar *)navigationBar shouldPopItem:(UINavigationItem *)item{          \/\/\u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f \u043a\u043d\u043e\u043f\u043e\u043a back bar button (\u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043f\u0435\u0440\u0435\u0445\u043e\u0434)     \/\/\u0435\u0441\u043b\u0438 \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u044b\u0439 \u0431\u0430\u0442\u0442\u043e\u043d - \u0442\u043e \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u0443\u0436\u0435 \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442 \u0438\u0434\u0442\u0438, \u0438 \u0442\u043e\u0433\u0434\u0430 \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c, \u0438 \u0432\u0435\u0440\u043d\u0443\u0442\u044c YES          \/\/\u0431\u043b\u043e\u043a\u0438\u0440\u0443\u0435\u043c \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u0432\u044b\u0437\u043e\u0432\u044b \u043c\u0435\u0442\u043e\u0434\u043e\u0432 \u0434\u0435\u043b\u0435\u0433\u0430\u0442\u0430 navigation bar-a     if(self.isBarPopProcessing || self.isBarPushProcessing){         return NO;     }          self.isBarPopProcessing = YES;          \/\/\u0434\u043b\u044f \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432 \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e back) (\u0443 \u0442\u0435\u0445, \u0443 \u043a\u043e\u0433\u043e \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f popViewControllerAnimated, \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0435\u0449\u0435 \u043d\u0435 \u0437\u0430\u0431\u043b\u043e\u0447\u0435\u043d\u044b \u0438\u043d\u0442\u0435\u0440\u044d\u043a\u0448\u0435\u043d\u044b     if(! self.isTransitionControllerProcessing && ! self.isBlockedInteraction){         [super popViewControllerAnimated:YES];     }          [self blockAllInteraction];     return YES; }  \/* \u043c\u0435\u0442\u043e\u0434 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u044f \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 \u0430\u0439\u0442\u0435\u043c\u0430 \u0431\u0430\u0440\u0430 (\u043f\u043e\u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u0440\u0430\u0437\u043b\u043e\u0447\u0438\u0442\u044c \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435)*\/ - (void)navigationBar:(UINavigationBar *)navigationBar didPopItem:(UINavigationItem *)item{     self.isBarPopProcessing = NO;     [self restoreAllInteraction]; }  - (BOOL)navigationBar:(UINavigationBar *)navigationBar shouldPushItem:(UINavigationItem *)item{          \/\/\u0435\u0441\u043b\u0438 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u0431\u0430\u0440\u0430 \u0435\u0449\u0435 \u0438\u0434\u0435\u0442 - \u043d\u0435 \u0441\u043e\u0432\u0435\u0440\u0448\u0430\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 (\u0434\u043b\u044f \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u044b\u0445 \u043a\u043d\u043e\u043f\u043e\u043a, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0438\u0445 segue\/push - \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0432\u0441\u0435\u0433\u0434\u0430 \u0432 \u043a\u043e\u0434\u0435 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u0434\u043e\u043b\u0436\u043d\u0430 \u0441\u0442\u043e\u044f\u0442\u044c \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430     \/\/\u0437\u0430\u0449\u0438\u0442\u0430 \u043e\u0442 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0432\u044b\u0437\u043e\u0432\u043e\u0432 \u043c\u0435\u0442\u043e\u0434\u0430     if(self.isBarPopProcessing || self.isBarPushProcessing){         return NO;     }          self.isBarPushProcessing = YES;     [self blockAllInteraction];     return YES; }  \/* \u043c\u0435\u0442\u043e\u0434 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u044f \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 \u0430\u0439\u0442\u0435\u043c\u0430 \u0431\u0430\u0440\u0430 (\u043f\u043e\u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u0440\u0430\u0437\u043b\u043e\u0447\u0438\u0442\u044c \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435)*\/ - (void)navigationBar:(UINavigationBar *)navigationBar didPushItem:(UINavigationItem *)item{          self.isBarPushProcessing = NO;     [self restoreAllInteraction]; }  #pragma mark - UINavigationControllerDelegate  \/* \u043d\u0430\u0447\u0430\u043b\u043e \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 \u043b\u044e\u0431\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u0438\u0435\u0440\u0430\u0440\u0445\u0438\u0438, \u0438 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u0435 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438. \u041e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043c\u0443\u043b\u044c\u0442\u0438\u0442\u0430\u0447\u0430 \u043f\u0440\u0438 \u043a\u0430\u0436\u0434\u043e\u043c \u043f\u043e\u044f\u0432\u043b\u0435\u043d\u0438\u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430. \u0410\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0430 \u043f\u0440\u0438 \u043d\u0430\u0447\u0430\u043b\u0435 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438, \u0440\u0430\u0437\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0430 \u043f\u0440\u0438 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u0438*\/  - (void)navigationController:(UINavigationController *)navigationController willShowViewController:(UIViewController *)viewController animated:(BOOL)animated{     NSLog(@&quot;WILL SHOW&quot;);     self.isTransitionControllerProcessing = YES;          \/\/\u043c\u0435\u0441\u0442\u043e, \u0433\u0434\u0435 \u043c\u043e\u0436\u043d\u043e \u0446\u0435\u043d\u0442\u0440\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c \u043e\u0431\u0449\u0438\u0439 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u043a\u043e\u0434 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 (\u043e\u0431\u0449\u0438\u0439 viewWillAppear:)     [self makeExclusiveTouchToViewController:viewController];     [self blockAllInteraction]; } - (void)navigationController:(UINavigationController *)navigationController didShowViewController:(UIViewController *)viewController animated:(BOOL)animated{          NSLog(@&quot;DID SHOW&quot;);     \/\/\u043c\u0435\u0441\u0442\u043e, \u0433\u0434\u0435 \u043c\u043e\u0436\u043d\u043e \u0446\u0435\u043d\u0442\u0440\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c \u043e\u0431\u0449\u0438\u0439 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 \u043a\u043e\u0434 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 (\u043e\u0431\u0449\u0438\u0439 viewDidAppear:)          self.isTransitionControllerProcessing = NO;     [self restoreAllInteraction]; }  #pragma mark - User Interaction manage  \/* \u0431\u043b\u043e\u043a\u0438\u0440\u0430\u0442\u043e\u0440\/\u0434\u0435\u0431\u043b\u043e\u043a\u0438\u0440\u0430\u0442\u043e\u0440   *\/  -(void)blockAllInteraction{     NSLog(@&quot;TRY TO BLOCK ALL INTERACTION&quot;);          \/\/\u0435\u0441\u043b\u0438 \u0435\u0449\u0435 \u043d\u0435 \u0437\u0430\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u043e \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 - \u043e\u0442\u043c\u0435\u043d\u0438\u0442\u044c \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u0439 \u0442\u0430\u0439\u043c\u0435\u0440 \u0440\u0430\u0437\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0438, \u0437\u0430\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u0442\u044c, \u0438 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043d\u043e\u0432\u044b\u0439 2\u0445-\u0441\u0435\u043a\u0443\u043d\u0434\u043d\u044b\u0439 \u0442\u0430\u0439\u043c\u0435\u0440 \u043d\u0430 \u0434\u0435\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0443          if(! [self isInteractionDisabled]){                  NSLog(@&quot;ATTEMPT SUCCESS BLOCK INTERACTION&quot;);                  [NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(restoreAllInteraction) object:nil];         [[UIApplication sharedApplication] beginIgnoringInteractionEvents];         self.isBlockedInteraction = YES;          [self checkBlocking];         [self performSelector:@selector(restoreAllInteraction) withObject:nil afterDelay:2.f];     } }  -(BOOL)restoreAllInteraction{     NSLog(@&quot;TRY TO RESTORE ALL INTERACTION&quot;);          \/\/\u043e\u0442\u043c\u0435\u043d\u0438\u0442\u044c \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u0439 \u0440\u0435\u043a\u0432\u0435\u0441\u0442 \u043d\u0430 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435, \u043f\u043e\u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435, \u0435\u0441\u043b\u0438 \u043d\u0438\u043a\u0430\u043a\u0430\u044f \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u0431\u043e\u043b\u0435\u0435 \u043d\u0435 \u0438\u0434\u0435\u0442 \u0438 \u0445\u043e\u0442\u044c \u0447\u0442\u043e-\u043b\u0438\u0431\u043e \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0437\u0430\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c     \/\/\u0435\u0441\u043b\u0438 \u043d\u0435 \u0443\u0434\u0430\u0435\u0442\u0441\u044f - \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0442\u0430\u0439\u043c\u0435\u0440 \u043d\u0430 \u0431\u0443\u0434\u0443\u0449\u0435\u0435 \u043d\u0430 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 (\u0431\u0443\u0434\u0435\u0442 \u0440\u0435\u043a\u0443\u0440\u0441\u0438\u0432\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c\u0441\u044f, \u043f\u043e\u043a\u0430 \u043d\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u0441\u044f \u0443\u0441\u043b\u043e\u0432\u0438\u044f          [NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(restoreAllInteraction) object:nil];          BOOL isRestoreSuccess = [self endIgnoringIf:(! self.isBarPopProcessing && ! self.isBarPushProcessing && [self isInteractionDisabled] && ! self.isTransitionControllerProcessing)];     if(isRestoreSuccess){         NSLog(@&quot;ATTEMPT SUCCESS RESTORE INTERACTION&quot;);          [self checkBlocking];         return YES;     }else{         if([self isInteractionDisabled] ){             [self performSelector:@selector(restoreAllInteraction) withObject:nil afterDelay:2.f];         }         return NO;     } }  \/* \u043a\u043e\u043d\u0434\u0438\u0448\u0435\u043d\u044b, 1) \u043f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0439, \u0434\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0442\u043e\u0433\u043e, \u043c\u043e\u0436\u043d\u043e \u043b\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u0432 \u043a\u043e\u0434\u0435 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430*\/ -(BOOL)isNeedNavigationBarActionBlocking{     return (self.isBarPopProcessing || self.isBarPushProcessing || self.isTransitionControllerProcessing); }  \/* \u043c\u0435\u0442\u043e\u0434, \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0442\u043e\u0447\u043a\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u0442\u0435\u043a\u0443\u0449\u0435\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f*\/ -(BOOL)isInteractionDisabled{     return (self.isBlockedInteraction || [UIApplication sharedApplication].isIgnoringInteractionEvents); }  \/* \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u0435\u043c \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u0442\u044c user interaction, \u0435\u0441\u043b\u0438 \u0443\u0441\u043b\u043e\u0432\u0438\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f*\/ -(BOOL)endIgnoringIf:(BOOL)condition{     if(condition){         [[UIApplication sharedApplication] endIgnoringInteractionEvents];         self.isBlockedInteraction = NO;         [NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(restoreAllInteraction) object:nil];         return YES;     }else{         return NO;     } }  #pragma mark - Multitouch block  \/* \u043c\u0435\u0442\u043e\u0434 \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043c\u0443\u043b\u044c\u0442\u0438\u0442\u0430\u0447\u0430*\/  -(void)makeExclusiveTouchToViewController:(UIViewController*)viewController{     [Utility makeExclusiveTouchToSubviews:viewController.view]; }  #pragma mark - Google analytics reports \/* \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c, \u0435\u0441\u043b\u0438 \u0438\u043d\u0442\u0435\u0440\u0432\u0430\u043b \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043a\u0438 \u0434\u043b\u0438\u0442\u0441\u044f \u0431\u043e\u043b\u0435\u0435 10 \u0441\u0435\u043a\u0443\u043d\u0434 - \u043e\u0442\u043e\u0441\u043b\u0430\u0442\u044c \u0440\u0435\u043f\u043e\u0440\u0442 \u0432 \u0433\u0443\u0433\u043b \u0430\u043d\u0430\u043b\u0438\u0442\u0438\u043a\u0441*\/  -(void)checkBlocking{          if(!dateStartBlocking && [self isBlockedInteraction]){         dateStartBlocking = [NSDate date];     }else if(dateStartBlocking && ! [self isBlockedInteraction]){         NSLog(@&quot;interface was blocked on %.1f seconds&quot;, -([dateStartBlocking timeIntervalSinceNow]));         dateStartBlocking = nil;     }else if(dateStartBlocking && [self isBlockedInteraction]){         NSTimeInterval intervalBlocking = [dateStartBlocking timeIntervalSinceNow];         if(intervalBlocking &gt; 10.f){             \/\/\u043c\u043e\u0436\u043d\u043e \u0441\u043e\u0431\u0438\u0440\u0430\u0442\u044c \u043b\u043e\u0433\u0438, \u0438 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u043b\u043e\u0433\u0438, \u0430 \u043d\u0435 \u0441\u0442\u0435\u043a\u0442\u0440\u0435\u0439\u0441\u044b             [self sendInteractionBlockingReport];             if([timerCheckBlocking isValid]){                 [timerCheckBlocking invalidate];             }             dateStartBlocking = nil;         }     } }  -(void)sendInteractionBlockingReport{     NSLog(@&quot;ERROR INTERFACE LOCK !!!&quot;);     NSString *descriptionLockReport = [NSString stringWithFormat:@&quot;controller %@ block interaction \\nvars : \\nisBarPopProcessing %i \\nisBarPushProcessing %i \\nisTransitionControllerProcessing %i \\nisBlockedInteraction %i&quot;, self.visibleViewController, self.isBarPopProcessing, self.isBarPushProcessing, self.isTransitionControllerProcessing, self.isBlockedInteraction];     [[GAIClient sharedInstance] sendReportNonFailExceptionWithDescription:descriptionLockReport]; }  #pragma mark - Destruction  -(void)dealloc{     \/\/\u043f\u0440\u0438 \u043e\u0447\u0438\u0441\u0442\u043a\u0435 \u043f\u0430\u043c\u044f\u0442\u0438 - \u0440\u0430\u0437\u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u0430\u0442\u044c, \u0435\u0441\u043b\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f (\u043a\u0440\u0438\u0442\u0438\u0447\u043d\u043e)     [self endIgnoringIf: [self isInteractionDisabled]];     if([timerCheckBlocking isValid]){         [timerCheckBlocking invalidate];     } }  @end  <\/code><\/pre>\n<p>  <\/div>\n<\/div>\n<div class=\"clear\"><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/263069\/\"> http:\/\/habrahabr.ru\/post\/263069\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>             \u042f \u043d\u0435 \u043f\u0440\u0435\u0442\u0435\u043d\u0434\u0443\u044e \u043d\u0430 \u0438\u0441\u0442\u0438\u043d\u0443 \u0432 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0439 \u0438\u043d\u0441\u0442\u0430\u043d\u0446\u0438\u0438, \u043d\u043e \u0438 \u0432 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u043a\u043e\u0435-\u0447\u0435\u0433\u043e \u0432\u0441\u0435-\u0442\u0430\u043a\u0438 \u0441\u043c\u044b\u0441\u043b\u044e. \u041f\u043e\u0441\u0435\u043c\u0443 \u0440\u0435\u0448\u0438\u043b \u043f\u043e\u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u0441 \u0432\u0430\u043c\u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u043c\u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430\u043c\u0438 \u043f\u0440\u043e\u0434\u0435\u043b\u0430\u043d\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b, \u043f\u043e\u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u043d\u0435\u043a\u043e\u0439 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0435\u0439 \u0437\u043d\u0430\u043d\u0438\u044f \u043e \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430\u0445, \u0442\u0430\u043a \u0441\u043a\u0430\u0437\u0430\u0442\u044c. \u041c\u043e\u0436\u0435\u0442 \u044d\u0442\u043e \u0438 \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u043a\u0430\u043a\u043e\u0439-\u043b\u0438\u0431\u043e \u0438\u0437 \u0431\u0440\u0435\u043d\u043d\u044b\u0445 \u043e\u0431\u043e\u043b\u043e\u0447\u0435\u043a, \u0441\u043f\u043e\u0441\u043e\u0431\u043d\u044b\u0445 \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u0430\u043b\u0435\u0435 \u043c\u043e\u0438\u043c\u0438 \u0447\u0438\u0442\u0430\u0442\u0435\u043b\u044f\u043c\u0438, \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0431\u043e\u043b\u0435\u0435 \u0441\u043e\u0432\u0435\u0440\u0448\u0435\u043d\u043d\u044b\u0439 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u044b\u0439 \u043f\u0440\u043e\u0434\u0443\u043a\u0442.<\/p>\n<p>  \u041f\u0440\u0435\u0434\u043c\u0435\u0442\u043e\u043c \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440, \u0430 \u0438\u043c\u0435\u043d\u043d\u043e \u043a\u043b\u0430\u0441\u0441 UINavigationController \u0438\u0437 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0433\u043e \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430 UIKit \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0430\u043c \u043b\u044e\u0431\u0435\u0437\u043d\u043e \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 Apple.<\/p>\n<h4>\u0412\u043a\u0440\u0430\u0442\u0446\u0435 \u043e&#8230;<\/h4>\n<p>  \u00ab\u041a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u00bb \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u2014 \u043d\u0435\u043a\u0438\u0439 \u043a\u043b\u0430\u0441\u0441, \u0438\u043d\u043a\u0430\u043f\u0441\u0443\u043b\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u043b\u043e\u0433\u0438\u043a\u0443, \u0441\u043e\u0433\u043b\u0430\u0441\u043d\u043e \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0438 (\u0435\u0449\u0435 \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u043e\u0439 \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u043e\u043c) <a href=\"https:\/\/ru.wikipedia.org\/wiki\/Model-View-Controller\">MVC<\/a>. <\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/ec6\/282\/c34\/ec6282c340604845bb93e94407745c4e.png\"\/><\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/41a\/537\/33f\/41a53733f3174ee7aa6161bd58e2fed6.jpg\"\/><\/p>\n<p>  \u041d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 (<a href=\"https:\/\/developer.apple.com\/library\/ios\/documentation\/UIKit\/Reference\/UINavigationController_Class\/\">UINavigationController<\/a>) \u2014 \u043a\u043b\u0430\u0441\u0441 \u0432\u044b\u0441\u043e\u043a\u043e\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u0438, \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0438\u0435\u0440\u0430\u0440\u0445\u0438\u044e \u0434\u0440\u0443\u0433\u0438\u0445 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u0432 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0439, \u043c\u0435\u0436\u0434\u0443 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f\u043c\u0438(\u0432\u044c\u044e\u0448\u043a\u0430\u043c\u0438\/UIView) \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u043f\u043e\u0441\u043e\u0431\u0435\u043d \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0442\u044c \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u044e (\u0432 \u0447\u0435\u043c \u0435\u0433\u043e, \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0430 \u0438 \u0441\u043e\u0441\u0442\u043e\u0438\u0442!), \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u044f \u0432 \u043d\u0443\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c\u0443 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0443. \u041a\u0440\u043e\u043c\u0435 \u044d\u0442\u043e\u0433\u043e \u2014 \u043a\u043e\u043c\u043f\u043e\u0437\u0438\u0446\u0438\u043e\u043d\u043d\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u043e\u043d\u043d\u0443\u044e \u043f\u0430\u043d\u0435\u043b\u044c (UINavigationBar), \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u043d\u0430 \u044d\u043a\u0440\u0430\u043d\u0435, \u0438 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043c\u0435\u043d\u044f\u0435\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0434\u0430\u043d\u043d\u043e\u0439 \u043f\u0430\u043d\u0435\u043b\u0438: \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430.   <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-261851","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/261851","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=261851"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/261851\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=261851"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=261851"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=261851"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}