{"id":3087,"date":"2015-06-14T00:12:29","date_gmt":"2015-06-13T15:12:29","guid":{"rendered":"http:\/\/denasu.com\/blog\/?p=3087"},"modified":"2015-06-14T00:23:05","modified_gmt":"2015-06-13T15:23:05","slug":"wt3%e9%80%b2%e6%8d%97-2","status":"publish","type":"post","link":"https:\/\/denasu.com\/blog\/2015\/06\/diary3087","title":{"rendered":"WT3\u9032\u6357"},"content":{"rendered":"<p>\u5bfe\u6226\u3082\u30ed\u30fc\u30ab\u30eb\u3067\u52d5\u3044\u3066\u304d\u305f\u306e\u3067\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u3092\u4ecb\u3057\u305f\u5bfe\u6226\u3092\u3057\u3066\u307f\u305f\u3002\u304c\uff0c\u7d50\u5c40\u5bfe\u6226\u306f\u3046\u307e\u304f\u3044\u304b\u305a\u3002UX\u3068\u304b\u30d0\u30b0\u3068\u304b\u3044\u308d\u3044\u308d\u8ab2\u984c\u304c\u5206\u304b\u3063\u305f\u306e\u3067\uff0c\u30c6\u30b9\u30c8\u516c\u958b\u306f\u3082\u3046\u5c11\u3057\u4fee\u6b63\u3057\u3066\u304b\u3089\u3002<\/p>\n<p>\u8ab2\u984c\u306e\u4e00\u3064\u3067\uff0cTextBox\u306e\u6319\u52d5\u304c\u304a\u304b\u3057\u3044\u3068\u3044\u3046\u306e\u304c\u3042\u3063\u3066\uff0c\u4ee5\u4e0b\u306e\u3088\u3046\u306aTextBox\u3092\u4f5c\u308b\u3068\uff0cIME\u5909\u63db\u4e2d\u306bIME\u5165\u529b\u3059\u308b\u3068\uff0c\u305d\u308c\u307e\u3067\u306b\u5165\u529b\u3057\u305f\u6587\u5b57\u304c\u6d88\u3048\u3066\u3057\u307e\u3046\u3068\u8a00\u3046\u3082\u306e\u3002\u3069\u3046\u3082UpdateSourceTrigger\u304cIME\u5909\u63db\u6642\u3082Property\u5909\u66f4\u3060\u3068\u601d\u3063\u3066\u304a\u304b\u3057\u306a\u52d5\u4f5c\u3092\u3059\u308b\u3063\u307d\u3044\u3002<\/p>\n<pre class=\"brush:xml\">\r\n<TextBox Text=\"{Binding Name, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}}\"\/>\r\n<\/pre>\n<p>\u56de\u907f\u7b56\u3060\u3051\u3069\uff0cUpdateSourceTrigger\u3092\u624b\u52d5\u3067\u3084\u308c\u3070\u3044\u3044\u304b\u3068\u601d\u3063\u3066\uff0c\u4ee5\u4e0b\u3092\u4f5c\u3063\u3066UpdateSourceTrigger\u3092\u6d88\u3057\u3066\u307f\u305f\u3002<\/p>\n<pre class=\"brush:csharp\">\r\npublic class IMETextBox : TextBox\r\n{\r\n    protected override void OnTextChanged(TextChangedEventArgs e)\r\n    {\r\n        GetBindingExpression(TextBox.TextProperty).UpdateSource();\r\n        base.OnTextChanged(e);\r\n    }\r\n}\r\n<\/pre>\n<p>\u3053\u306e\u5f8cIME\u5909\u63db\u4e2d\u3060\u3063\u305f\u3089UpdateSource\u3057\u306a\u3044\u51e6\u7406\u3092\u4ed8\u3051\u3088\u3046\u3068\u3057\u3066\u305f\u3093\u3060\u3051\u3069\uff0c\u4f55\u6545\u304b\u4e0a\u306e\u30b3\u30fc\u30c9\u3060\u3051\u3067\u3061\u3083\u3093\u3068\u52d5\u3044\u3066\u3057\u307e\u3063\u305f\u3002\u306a\u3093\u304b\u5c06\u6765\u52d5\u304b\u306a\u304f\u306a\u308a\u305d\u3046\u3060\u3051\u3069\u4eca\u306f\u6642\u9593\u304c\u306a\u3044\u306e\u3067\u3053\u308c\u3067\u3002\u9069\u5f53\u306a\u5bfe\u7b56\u306a\u306e\u3067\uff0c\u4f7f\u3046\u5834\u5408\u306fWPF\u306e\u30bd\u30fc\u30b9\u3092\u898b\u3066\u539f\u56e0\u3092\u8abf\u3079\u3066\u304b\u3089\u4f7f\u3063\u3066\u4e0b\u3055\u3044\u3002\u305d\u3057\u3066\u539f\u56e0\u3092\u6559\u3048\u3066\u4e0b\u3055\u3044\u3002\u3002\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5bfe\u6226\u3082\u30ed\u30fc\u30ab\u30eb\u3067\u52d5\u3044\u3066\u304d\u305f\u306e\u3067\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u3092\u4ecb\u3057\u305f\u5bfe\u6226\u3092\u3057\u3066\u307f\u305f\u3002\u304c\uff0c\u7d50\u5c40\u5bfe\u6226\u306f\u3046\u307e\u304f\u3044\u304b\u305a\u3002UX\u3068\u304b\u30d0\u30b0\u3068\u304b\u3044\u308d\u3044\u308d\u8ab2\u984c\u304c\u5206\u304b\u3063\u305f\u306e\u3067\uff0c\u30c6\u30b9\u30c8\u516c\u958b\u306f\u3082\u3046\u5c11\u3057\u4fee\u6b63\u3057\u3066\u304b\u3089\u3002 \u8ab2\u984c\u306e\u4e00\u3064\u3067\uff0cTextBox\u306e\u6319\u52d5\u304c\u304a\u304b\u3057\u3044\u3068\u3044\u3046\u306e\u304c\u3042\u3063\u3066\uff0c\u4ee5\u4e0b\u306e\u3088\u3046\u306aTextBox\u3092\u4f5c\u308b\u3068\uff0cIME\u5909\u63db\u4e2d\u306bIME\u5165\u529b\u3059\u308b\u3068\uff0c\u305d\u308c\u307e\u3067\u306b\u5165\u529b\u3057\u305f\u6587\u5b57\u304c\u6d88\u3048\u3066\u3057\u307e\u3046\u3068\u8a00\u3046\u3082\u306e\u3002\u3069\u3046\u3082UpdateSourceTrigger\u304cIME\u5909\u63db\u6642\u3082Property\u5909\u66f4\u3060\u3068\u601d\u3063\u3066\u304a\u304b\u3057\u306a\u52d5\u4f5c\u3092\u3059\u308b\u3063\u307d\u3044\u3002 \u56de\u907f\u7b56\u3060\u3051\u3069\uff0cUpdateSourceTrigger\u3092\u624b\u52d5\u3067\u3084\u308c\u3070\u3044\u3044\u304b\u3068\u601d\u3063\u3066\uff0c\u4ee5\u4e0b\u3092\u4f5c\u3063\u3066UpdateSourceTrigger\u3092\u6d88\u3057\u3066\u307f\u305f\u3002 public class IMETextBox : TextBox { protected override void OnTextChanged(TextChangedEventArgs e) { GetBindingExpression(TextBox.TextProperty).UpdateSource(); base.OnTextChanged(e); } } \u3053\u306e\u5f8cIME\u5909\u63db\u4e2d\u3060\u3063\u305f\u3089UpdateSource\u3057\u306a\u3044\u51e6\u7406\u3092\u4ed8\u3051\u3088\u3046\u3068\u3057\u3066\u305f\u3093\u3060\u3051\u3069\uff0c\u4f55\u6545\u304b\u4e0a\u306e\u30b3\u30fc\u30c9\u3060\u3051\u3067\u3061\u3083\u3093\u3068\u52d5\u3044\u3066\u3057\u307e\u3063\u305f\u3002\u306a\u3093\u304b\u5c06\u6765\u52d5\u304b\u306a\u304f\u306a\u308a\u305d\u3046\u3060\u3051\u3069\u4eca\u306f\u6642\u9593\u304c\u306a\u3044\u306e\u3067\u3053\u308c\u3067\u3002\u9069\u5f53\u306a\u5bfe\u7b56\u306a\u306e\u3067\uff0c\u4f7f\u3046\u5834\u5408\u306fWPF\u306e\u30bd\u30fc\u30b9\u3092\u898b\u3066\u539f\u56e0\u3092\u8abf\u3079\u3066\u304b\u3089\u4f7f\u3063\u3066\u4e0b\u3055\u3044\u3002\u305d\u3057\u3066\u539f\u56e0\u3092\u6559\u3048\u3066\u4e0b\u3055\u3044\u3002\u3002\u3002<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[2,3],"tags":[8,25],"class_list":["post-3087","post","type-post","status-publish","format-standard","hentry","category-programming","category-computer","tag-weathertyping","tag-wpf"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p4ZThs-NN","_links":{"self":[{"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/posts\/3087","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/comments?post=3087"}],"version-history":[{"count":6,"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/posts\/3087\/revisions"}],"predecessor-version":[{"id":3093,"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/posts\/3087\/revisions\/3093"}],"wp:attachment":[{"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/media?parent=3087"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/categories?post=3087"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/denasu.com\/blog\/wp-json\/wp\/v2\/tags?post=3087"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}