Windows Phone 8.1 商店 VS Windows Phone 8.1 Silverlight

Windows Phone 8.1 商店 VS Windows Phone 8.1 Silverlight

问题描述:

当我创建新的 Windows Phone 项目时,我可以选择创建Windows Phone"或Windows Phone Silverlight"应用程序.我知道它们有不同的运行时和不同的 API.我的印象是微软想要统一 Windows 和 Windows Phone 平台,那么为什么还要有 Silverlight 版本呢?它带来什么好处?另外,如果我想为 Windows Phone 创建一个应用程序并且从来没有计划将它带到 Windows,我应该选择什么,Silverlight 还是 Windows Phone?

When I create new Windows Phone project I have an option to create a "Windows Phone" or "Windows Phone Silverlight" app. I know that they have different runtimes and different APIs. I was under the impression that Microsoft wants to unify Windows and Windows Phone platforms so why is there even a Silverlight version? What benefits does it bring? Also, if I want to create an app just for Windows Phone and never have plans to bring it to Windows, what should I choose, Silverlight or Windows Phone?

我建议您使用Windows Phone"(非 Silverlight).这是新的 API,适用于 Windows 和 Windows Phone.在某些时候,您可能想要移植应用程序或为 Windows 创建一个新的应用程序,并且您已经知道 API(并且移植将方式更容易).此外,新 API 很可能会获得更多更新和添加的功能,并且在某些时候您甚至可能*更新它(因为不再支持旧 API,或者因为它没有您需要的某些功能)).

I'd suggest you go with "Windows Phone" (non-Silverlight). It's the new API, which works for both Windows and Windows Phone. At some point you may want to port the app or create a new one for Windows and you'll already know the API (and porting will be way easier). Also, the new API will most likely get more updates and features added, and at some point you may even be forced to update to it (either because the old one is no longer supported, or because it does not have some features that you need).

正如在其他答案中所说 - Silverlight 选项仅用于向后兼容,并且可能会及时淘汰.也就是说 - 如果您已经了解 API 并且拥有许多用于 WP Silverlight 的库(您的或其他的),那很好,但如果您刚刚开始 - 您最好采用新技术.

As it was said in the other answers - the Silverlight option is there only for backward compatibility and is likely to be phased out in time. That is - it's good if you already know the API and have many libraries (yours or others) for WP Silverlight, but if you're just starting - you'd better go for the new technology.

编辑

在两种类型的应用之间进行选择之前,还需要考虑另一件事.某些功能仅在 Silverlight 应用程序中可用,而其他功能(数量较少)- 仅在 Xaml 应用程序中可用.这是一篇关于差异的一些信息的文章:将您的 Windows Phone 8 应用程序迁移到 Windows 运行时 XAML 应用程序

There is one other thing to consider before choosing between the two types of apps. Some features are only available in a Silverlight app, and others (smaller amount) - only in a Xaml app. Here's an article with some info on the differences: Migrating your Windows Phone 8 app to a Windows Runtime XAML app