Xamarin.iOS上的Splat [0.3.4]:RectangleF和PointF的问题 [英] Splat [0.3.4] on Xamarin.iOS: issues with RectangleF and PointF

查看:107
本文介绍了Xamarin.iOS上的Splat [0.3.4]:RectangleF和PointF的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在Xamarin Studio的Xamarin.iOS项目中拥抱PCL的新乐趣.我为项目创建了PCL核心"库,并添加了 Splat (

I'm trying to embrace the new PCL fun on a Xamarin.iOS project in Xamarin Studio. I created a PCL "Core" library for my project and added Splat (v0.3.4) via NuGet. Then, in a consuming iOS project, I reference my core library. Once I do that, a couple compile errors show up.

其中之一:

Error CS0012: The type `System.Drawing.PointF' is defined in an assembly that is not referenced. Consider adding a reference to assembly `Splat.Portable, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' (CS0012)

多个:

Error CS0029: Cannot implicitly convert type `System.Drawing.PointF [monotouch, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065]' to `System.Drawing.PointF [Splat.Portable, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]' (CS0029)

自v0以来,出现在向Splat的拉动请求中似乎已解决了此问题.3.4命中NuGet.跟随那里的注释,我在iOS项目中添加了对Splat.Portable.dll的引用.当我这样做时,编译错误会更改为抱怨太多类型定义.

It looks like this was addressed in an pull request to Splat that landed since v0.3.4 hit NuGet. Following along with the notes there, I added a reference to Splat.Portable.dll to the iOS project. When I do, the compile errors change up to complain about too many type definitions.

Error CS0433: The imported type `System.Drawing.RectangleF' is defined multiple times (CS0433)
Error CS0433: The imported type `System.Drawing.PointF' is defined multiple times (CS0433)

是否可以使用Xamarin Studio 4.2.1(Xamarin.iOS 7.0.4.209)和Splat 0.3.4来解决这些错误,还是我需要使用其类型转发功能来构建最新的代码?

Is it possible to work around these errors using Xamarin Studio 4.2.1 (Xamarin.iOS 7.0.4.209), and Splat 0.3.4 or do I need to build the latest code with its type-forwarding awesomeness?

推荐答案

是的,明天我将构建新版本的Splat,但从源代码构建也将解决此问题.

Yep, I'll build a new release of Splat tomorrow'ish, but building from source will also solve this.

Splat 1.0已发布,其中包含针对此错误的修复程序

Splat 1.0 is live and contains the fix for this bug

这篇关于Xamarin.iOS上的Splat [0.3.4]:RectangleF和PointF的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆