{"id":7733,"date":"2016-01-13T16:41:44","date_gmt":"2016-01-12T22:41:44","guid":{"rendered":"http:\/\/www.moonmile.net\/blog\/?p=7733"},"modified":"2016-01-13T16:43:05","modified_gmt":"2016-01-13T07:43:05","slug":"xamarin-forms-%e3%81%a7%e3%83%89%e3%83%a9%e3%83%83%e3%82%b0%e3%82%92%e5%ae%9f%e8%a3%85%e3%81%97%e3%82%88%e3%81%86%ef%bc%88uwp%e7%b7%a8%ef%bc%89","status":"publish","type":"post","link":"https:\/\/www.moonmile.net\/blog\/archives\/7733","title":{"rendered":"Xamarin.Forms \u3067\u30c9\u30e9\u30c3\u30b0\u3092\u5b9f\u88c5\u3057\u3088\u3046\uff08UWP\u7de8\uff09"},"content":{"rendered":"<p>\nXamarin.Forms \u3067\u30c9\u30e9\u30c3\u30b0\u3092\u5b9f\u88c5\u3057\u3088\u3046\uff08\u306e\u3046\u308a\u3093\u7de8\uff09<br \/>\n<a href=\"http:\/\/www.moonmile.net\/blog\/archives\/7653\">http:\/\/www.moonmile.net\/blog\/archives\/7653<\/a><br \/>\nXamarin.Forms \u3067\u30c9\u30e9\u30c3\u30b0\u3092\u5b9f\u88c5\u3057\u3088\u3046\uff08Android\u7de8\uff09<br \/>\n<a href=\"http:\/\/www.moonmile.net\/blog\/archives\/7667\">http:\/\/www.moonmile.net\/blog\/archives\/7667<\/a><br \/>\nXamarin.Forms \u3067\u30c9\u30e9\u30c3\u30b0\u3092\u5b9f\u88c5\u3057\u3088\u3046\uff08Xamarin.Forms on Android\u7de8\uff09<br \/>\n<a href=\"http:\/\/www.moonmile.net\/blog\/archives\/7670\">http:\/\/www.moonmile.net\/blog\/archives\/7670<\/a><br \/>\nXamarin.Forms \u3067\u30c9\u30e9\u30c3\u30b0\u3092\u5b9f\u88c5\u3057\u3088\u3046\uff08Xamarin.Forms on iOS\u7de8\uff09<br \/>\n<a href=\"http:\/\/www.moonmile.net\/blog\/archives\/7723\">http:\/\/www.moonmile.net\/blog\/archives\/7723<\/a><br \/>\nXamarin.Forms \u3067\u30c9\u30e9\u30c3\u30b0\u3092\u5b9f\u88c5\u3057\u3088\u3046\uff08Xamarin.Forms on WinPhone\u7de8\uff09<br \/>\n<a href=\"http:\/\/www.moonmile.net\/blog\/archives\/7728\">http:\/\/www.moonmile.net\/blog\/archives\/7728<\/a>\n<\/p>\n<p>\n\u306e\u7d9a\u304d\u3067\u3059\u3002\n<\/p>\n<p>\nXamarin.Forms \u306f 2.0 \u304b\u3089\u30e6\u30cb\u30d0\u30fc\u30b5\u30eb\u30a2\u30d7\u30ea\uff08UWP\uff09\u3092\u6271\u3048\u308b\u3088\u3046\u306b\u306a\u3063\u305f\u30cf\u30ba\u306a\u306e\u3067\u3001\u3053\u308c\u3092\u4f5c\u3063\u3066\u307f\u307e\u3059\u3002\n<\/p>\n<p>\nAdding a Universal Windows Platform (UWP) App &#8211; Xamarin<br \/>\n<a href=\"https:\/\/developer.xamarin.com\/guides\/xamarin-forms\/windows\/getting-started\/universal\/\">https:\/\/developer.xamarin.com\/guides\/xamarin-forms\/windows\/getting-started\/universal\/<\/a>\n<\/p>\n<p>\n\u3092\u53c2\u8003\u306b\u3057\u3066\u3001\n<\/p>\n<p>\n&#8211; App.xaml.cs \u306b Xamarin.Forms.Forms.Init(e); \u3092\u8ffd\u52a0<br \/>\n&#8211; MainPage.xaml \u306b using:Xamarin.Forms.Platform.UWP \u3092\u8ffd\u52a0<br \/>\n&#8211; MainPage.xaml.cs \u306b LoadApplication(new BoxDragXF.App()); \u3092\u8ffd\u52a0\n<\/p>\n<p>\n\u3059\u308b\u3068\u52d5\u304d\u307e\u3059\u3002\n<\/p>\n<p>\nAndroid \u3084 iOS \u3068\u540c\u3058\u3088\u3046\u306b\u30c9\u30e9\u30c3\u30b0\u3055\u305b\u305f\u3044\u306e\u3067\u3001Windows Phone 8.1 \u3068\u540c\u3058\u3088\u3046\u306b BoxExRenderer \u30af\u30e9\u30b9\u3092\u4f5c\u308a\u307e\u3059\u3002\n<\/p>\n<pre class=\"brush: csharp; title: ; notranslate\" title=\"\">\r\n&#x5B;assembly: ExportRenderer(typeof(BoxViewEx), typeof(BoxExRenderer))]\r\nnamespace BoxDragXF.UWP\r\n{\r\n    class BoxExRenderer : Xamarin.Forms.Platform.UWP.BoxViewRenderer\r\n    {\r\n        protected override void OnElementChanged(ElementChangedEventArgs&lt;BoxView&gt; e)\r\n        {\r\n            base.OnElementChanged(e);\r\n            this.ManipulationDelta += BoxExRenderer_ManipulationDelta1;\r\n            this.ManipulationMode = Windows.UI.Xaml.Input.ManipulationModes.All;\r\n        }\r\n\r\n        private void BoxExRenderer_ManipulationDelta1(object sender, Windows.UI.Xaml.Input.ManipulationDeltaRoutedEventArgs e)\r\n        {\r\n            var el = this.Element as BoxViewEx;\r\n            el.OnManipulationDelta(el, new BoxDragXF.ManipulationDeltaRoutedEventArgs(el, e.Delta.Translation.X, e.Delta.Translation.Y));\r\n        }\r\n    }\r\n}\r\n<\/pre>\n<p>\n\u307b\u3068\u3093\u3069\u3001WinPhone \u7248\u3068\u540c\u3058\u3067\u3059\u306d\u3002<br \/>\n\u3053\u308c\u304c\u52d5\u304f\u3068\u3001Windows IoT Core \u306e UWP \u3082\u540c\u3058\u3088\u3046\u306b\u52d5\u304f\u306e\u3067\u3001\u81ea\u4f5c\u30bf\u30d6\u30ec\u30c3\u30c8\u3092\u4f5c\u3063\u305f\u308a\u3001Surface \u3092\u4f7f\u3063\u305f\u5834\u5408\u3067\u3082\u5171\u901a\u5316\u3067\u304d\u307e\u3059\u3002Android\/iPhone\/Surface \u306e UI \u304c Xamarin.Forms \u3067\u4e00\u62ec\u3067\u4f5c\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\n<\/p>\n<p>\n\u52d5\u304b\u3057\u305f\u3068\u304d\u306e\u52d5\u753b\u306f\u3053\u3061\u3089\u3067\u3059\u3002\n<\/p>\n<div style=\"width: 640px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-7733-1\" width=\"640\" height=\"480\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"http:\/\/www.moonmile.net\/blog\/wp-content\/uploads\/2016\/01\/2016-01-13-UWP-Drag.mp4?_=1\" \/><a href=\"http:\/\/www.moonmile.net\/blog\/wp-content\/uploads\/2016\/01\/2016-01-13-UWP-Drag.mp4\">http:\/\/www.moonmile.net\/blog\/wp-content\/uploads\/2016\/01\/2016-01-13-UWP-Drag.mp4<\/a><\/video><\/div>\n<p><h2>\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9<\/h2>\n<\/p>\n<p><a href=\"https:\/\/github.com\/moonmile\/BoxDrag\">https:\/\/github.com\/moonmile\/BoxDrag<\/a><\/p>\n<p>\n\u306b\u3042\u308a\u307e\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Xamarin.Forms \u3067\u30c9\u30e9\u30c3\u30b0\u3092\u5b9f\u88c5\u3057\u3088\u3046\uff08\u306e\u3046\u308a\u3093\u7de8\uff09 http:\/\/www.moonmile.net\/blog\/archives\/7653 Xamarin.Forms \u3067\u30c9\u30e9\u30c3\u30b0\u3092\u5b9f\u88c5\u3057\u3088\u3046\uff08Android\u7de8 &hellip; <a href=\"https:\/\/www.moonmile.net\/blog\/archives\/7733\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[3],"tags":[],"class_list":["post-7733","post","type-post","status-publish","format-standard","hentry","category-dev"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/posts\/7733","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/comments?post=7733"}],"version-history":[{"count":2,"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/posts\/7733\/revisions"}],"predecessor-version":[{"id":7736,"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/posts\/7733\/revisions\/7736"}],"wp:attachment":[{"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/media?parent=7733"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/categories?post=7733"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.moonmile.net\/blog\/wp-json\/wp\/v2\/tags?post=7733"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}