{"id":708,"date":"2012-01-28T00:24:54","date_gmt":"2012-01-27T15:24:54","guid":{"rendered":"http:\/\/redwing.moo.jp\/cocoa\/?p=708"},"modified":"2012-01-28T00:24:54","modified_gmt":"2012-01-27T15:24:54","slug":"%e5%87%a6%e7%90%86%e3%82%92%e4%b8%80%e6%99%82%e5%81%9c%e6%ad%a2%e3%81%99%e3%82%8b%e6%96%b9%e6%b3%95","status":"publish","type":"post","link":"https:\/\/redwing.moo.jp\/cocoa\/archives\/708","title":{"rendered":"\u51e6\u7406\u3092\u4e00\u6642\u505c\u6b62\u3059\u308b\u65b9\u6cd5"},"content":{"rendered":"<p>UITableView \u306e\u30bb\u30eb\u306b UITextField \u3092\u4fdd\u6301\u3057\u305f\u30ab\u30b9\u30bf\u30e0 \u30bb\u30eb\u3092\u7528\u610f\u3057\u3001\u8a2d\u5b9a\u5024\u3092\u5165\u529b\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u305f\u3002<\/p>\n<p><a href=\"http:\/\/redwing.moo.jp\/cocoa\/wp-content\/uploads\/46d6be722ef36ea4f2ab3e5f7fb7769f.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/redwing.moo.jp\/cocoa\/wp-content\/uploads\/46d6be722ef36ea4f2ab3e5f7fb7769f.png\" alt=\"\u30ab\u30b9\u30bf\u30de\u30a4\u30ba UITableViewCell\" title=\"\u30ab\u30b9\u30bf\u30de\u30a4\u30ba UITableViewCell\" width=\"397\" height=\"103\" class=\"alignnone size-full wp-image-730\" srcset=\"https:\/\/redwing.moo.jp\/cocoa\/wp-content\/uploads\/46d6be722ef36ea4f2ab3e5f7fb7769f.png 397w, https:\/\/redwing.moo.jp\/cocoa\/wp-content\/uploads\/46d6be722ef36ea4f2ab3e5f7fb7769f-300x77.png 300w\" sizes=\"auto, (max-width: 397px) 100vw, 397px\" \/><\/a><\/p>\n<p>\u753b\u9762\u306b&#8221;\u767b\u9332&#8221;\u30dc\u30bf\u30f3\u3092\u914d\u7f6e\u3057\u305f\u304c\u3001UITextField \u306b\u8a2d\u5b9a\u5024\u3092\u5165\u529b\u7de8\u96c6\u5f8c\u3001&#8221;\u767b\u9332&#8221;\u30dc\u30bf\u30f3\u3092\u62bc\u4e0b\u3057\u3001\u753b\u9762\u9077\u79fb\u3059\u308b\u3068\u8a2d\u5b9a\u5024\u304c\u4fdd\u5b58\u3055\u308c\u3066\u3044\u306a\u3044\u3068\u3044\u3046\u554f\u984c\u304c\u767a\u751f\u3057\u305f\u3002<\/p>\n<p>\u539f\u56e0\u306f\u3001\u4ee5\u4e0b\u306e\u901a\u308a\u3002<br \/>\nUITextField \u306e UIControlEventEditingDidEndOnExit \u30b3\u30f3\u30c8\u30ed\u30fc\u30eb \u30a4\u30d9\u30f3\u30c8\u3092\u53d6\u5f97\u3057\u3001\u7de8\u96c6\u7d42\u4e86\u3068\u5224\u65ad\u3057\u3066\u5165\u529b\u3055\u308c\u305f\u8a2d\u5b9a\u5024\u3092\u4fdd\u5b58\u3057\u3088\u3046\u3068\u3057\u3066\u3044\u305f\u304c\u3001UIControlEventEditingDidEndOnExit \u306e\u901a\u77e5\u3092\u53d7\u3051\u308b\u524d\u306b&#8221;\u767b\u9332&#8221;\u30dc\u30bf\u30f3\u62bc\u4e0b\u6642\u306e\u51e6\u7406\u304c\u884c\u308f\u308c\u3066\u3044\u305f\u3002<br \/>\n\u7d50\u679c\u3001\u7de8\u96c6\u3057\u305f\u8a2d\u5b9a\u5024\u3092\u4fdd\u5b58\u3059\u308b\u524d\u306b\u753b\u9762\u9077\u79fb\u304c\u884c\u308f\u308c\u3066\u3044\u305f\u306e\u304c\u554f\u984c\u3060\u3068\u5206\u304b\u3063\u305f\u3002<\/p>\n<p>\u3068\u3044\u3046\u308f\u3051\u3067\u3001<br \/>\n\uff08\u5bfe\u51e6\u524d\uff09&#8221;\u767b\u9332&#8221;\u30dc\u30bf\u30f3\u62bc\u4e0b\u51e6\u7406 \u2192 \uff08\u5909\u66f4\u524d\u306e\uff09\u8a2d\u5b9a\u5024 \u4fdd\u5b58 \u2192 UITextField \u7de8\u96c6\u7d42\u4e86\u306e\u901a\u77e5<br \/>\n\uff08\u5bfe\u51e6\u5f8c\uff09UITextField \u7de8\u96c6\u7d42\u4e86\u306e\u901a\u77e5 \u2192 &#8220;\u767b\u9332&#8221;\u30dc\u30bf\u30f3\u62bc\u4e0b\u51e6\u7406 \u2192 \uff08\u5909\u66f4\u5f8c\u306e\uff09\u8a2d\u5b9a\u5024 \u4fdd\u5b58<br \/>\n&#8220;\u5bfe\u51e6\u5f8c&#8221;\u306e\u9806\u756a\u3067\u51e6\u7406\u304c\u884c\u308f\u308c\u308b\u3088\u3046\u306b\u3001NSRunLoop \u30af\u30e9\u30b9\u3092\u5229\u7528\u3057\u3066 UITextField \u7de8\u96c6\u7d42\u4e86\u306e\u901a\u77e5\u3092\u53d7\u3051\u308b\u307e\u3067\u3001\u51e6\u7406\u3092\u4e00\u6642\u505c\u6b62\u3059\u308b\u3088\u3046\u306b\u3057\u305f\u3002<\/p>\n<pre lang=\"objc\" line=\"1\">\r\n\/\/ \u767b\u9332\u30dc\u30bf\u30f3\u304c\u62bc\u4e0b\u3055\u308c\u305f\u969b\u306e\u51e6\u7406\r\n- (void)registerButtonAction\r\n{\r\n    \/\/ \u7de8\u96c6\u7d42\u4e86\u901a\u77e5\u304c\u53d7\u4fe1\u3055\u308c\u308b\u307e\u3067\u5f85\u3064 (0.5\u79d2\u9593\u9694\u3067\u53d7\u4fe1\u78ba\u8a8d\u3059\u308b)\r\n    while (!didEndEditingFlag_) {\r\n        \/\/ \u30bd\u30d5\u30c8\u30ad\u30fc\u30dc\u30fc\u30c9\u304c\u8868\u793a\u3055\u308c\u3066\u3044\u308b\u5834\u5408\u3001\u975e\u8868\u793a\u306b\u3057\u306a\u3044\u3068\u7de8\u96c6\u7d42\u4e86\u901a\u77e5\u304c\u3055\u308c\u306a\u3044\u305f\u3081\u3001\u975e\u8868\u793a\u3068\u3059\u308b\r\n        [editingTextField_ resignFirstResponder];\r\n        \r\n        \/\/ \u51e6\u7406\u3092\u4e00\u6642\u505c\u6b62\u3057 NSRunLoop \u3078\u5236\u5fa1\u3092\u623b\u3059\r\n        \/\/ 0.5\u79d2\u5f8c\u3001\u51e6\u7406\u3092\u518d\u958b\u3059\u308b\r\n        [[NSRunLoop currentRunLoop] runUntilDate:[NSDate dateWithTimeIntervalSinceNow:0.5]];\r\n    }\r\n    \r\n    \/\/ \u8a2d\u5b9a\u60c5\u5831\u30de\u30cd\u30fc\u30b8\u30e3\u3078\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b\r\n    [self writeSettingManagerValue];\r\n     :\r\n     :\r\n\r\n<\/pre>\n<a href=\"https:\/\/twitter.com\/redwing1300?ref_src=twsrc%5Etfw\" class=\"twitter-follow-button\" data-size=\"large\" data-show-count=\"false\">Follow @redwing1300<\/a><script async src=\"https:\/\/platform.twitter.com\/widgets.js\" charset=\"utf-8\"><\/script><!-- AddThis Advanced Settings generic via filter on the_content --><!-- AddThis Share Buttons generic via filter on the_content --><div id=\"redwi-3099691615\" class=\"redwi- redwi-entity-placement\"><script async src=\"\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js?client=ca-pub-9652476346722993\" crossorigin=\"anonymous\"><\/script><ins class=\"adsbygoogle\" style=\"display:block;\" data-ad-client=\"ca-pub-9652476346722993\" \ndata-ad-slot=\"\" \ndata-ad-format=\"auto\"><\/ins>\n<script> \n(adsbygoogle = window.adsbygoogle || []).push({}); \n<\/script>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>UITableView \u306e\u30bb\u30eb\u306b UITextField \u3092\u4fdd\u6301\u3057\u305f\u30ab\u30b9\u30bf\u30e0 \u30bb\u30eb\u3092\u7528\u610f\u3057\u3001\u8a2d\u5b9a\u5024\u3092\u5165\u529b\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u305f\u3002 \u753b\u9762\u306b&#8221;\u767b\u9332&#8221;\u30dc\u30bf\u30f3\u3092\u914d\u7f6e\u3057\u305f\u304c\u3001UITextField \u306b\u8a2d\u5b9a\u5024\u3092\u5165\u529b &hellip; <a href=\"https:\/\/redwing.moo.jp\/cocoa\/archives\/708\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"meta-nav\">&rarr;<\/span><\/a><!-- AddThis Advanced Settings generic via filter on get_the_excerpt --><!-- AddThis Share Buttons generic via filter on get_the_excerpt --><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7,4],"tags":[],"class_list":["post-708","post","type-post","status-publish","format-standard","hentry","category-cocoa","category-xcode4"],"_links":{"self":[{"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/posts\/708","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/comments?post=708"}],"version-history":[{"count":18,"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/posts\/708\/revisions"}],"predecessor-version":[{"id":735,"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/posts\/708\/revisions\/735"}],"wp:attachment":[{"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/media?parent=708"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/categories?post=708"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/redwing.moo.jp\/cocoa\/wp-json\/wp\/v2\/tags?post=708"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}