[In Layman's WP8.1 (Runtime)] The difference between Windows Phone 8.1 and Silverlight 8.1

Source: Internet
Author: User
Tags silverlight

1.2.2 Windows Phone 8.1 Application Model

    Windows Phone 8.1 supports a variety of development languages to develop applications, including C #, VB, JavaScript, and C + +, so the code for this book is primarily developed in the C # language, with some chapters in C + +. Starting with Windows  phone 8.1, if you are developing a common application, you can choose the application models that are: C#/xaml, Vb/xaml, C++/xaml, and JAVASCRIPT/HTML5. Game development is also a framework for using C + + DirectX. Before Windows Phone 8, if you were developing a normal application, you could only take the two development models of C#/xaml and Vb/xaml, while the Windows Phone 8.1 added C++/xaml and JavaScript/ HTML5 support for both of these development models. The three development models of C#/xaml, Vb/xaml and C++/xaml are similar technical frameworks, which are programming languages that use XAML as an interface, and then use c#/vb/c++ as a background development language, noting that C + + is the C + + of C++/CX syntax, is an extension of the Visual C + + component extension syntax, for C++/CX more detailed introduction and explanation can refer to the 22nd chapter. Then the JAVASCRIPT/HTML5 development model is the development language using HTML5 as the interface, and JavaScript as the background development language. Also in Windows Phone 8.1, the Windows Runtime component is provided to share code for a variety of programming languages, such as code implemented in C + + or encapsulated functionality that can be called by the Windows Runtime component to the C#/XAML model's application. Or it can be called to the JAVASCRIPT/HTML5 model application. Within these different programming models, the Windows Runtime component acts as a medium for code sharing across programming languages.

So how do developers choose the application development model for the many application models that Windows Phone 8.1 uses? Microsoft has suggested that developers should choose the language they are familiar with to develop. Using XAML (C #, VB, and C + +) models will have a higher performance than HTML5 if compared from an application performance standpoint. For C #, VB, and C + + three programming languages, the efficiency of Windows Phone 8.1 is similar, because even C + + is the C++/CX syntax to invoke the Windows Runtime Api,windows Runtime architecture is Microsoft Unified Adoption of C /c++ language to encapsulate. The Windows Runtime framework that is invoked in the C # language is the same as that used in C + +. So if you use the common logic of algorithms or graphics processing implemented by standard C + +, it is certainly more efficient for C + +, but in this case C #, VB, and JavaScript applications can invoke these common code in the standard C + + package through the Windows runtime components.

At Windows Phone 7, 7.5, and 8.0, Windows Phone supports only the C#/XAML and VB/XAML application development patterns, while both WPF and Silverlight support only C#/xaml and vb/ XAML development model, and most of the developers are choosing C#/xaml to develop, so the current C#/XAML this development model accumulated technical knowledge is very rich, but also the Windows Phone development is the most popular development model.

1.2.3 The difference between Windows Phone 8.1 and Silverlight 8.1

So the development framework described above is a Windows Phone 8.1 application, which is completely based on the application development model under the Windows Runtime Framework, and in addition we can create an application called Windows Phone Silverlight 8.1 of applications. So first understand why it is necessary to have Windows Phone Silverlight 8.1 This mode of application, in fact Windows Phone Silverlight 8.1 This mode application is designed to be compatible with the current Windows Phone 8 of the code is easy to upgrade, and Windows Phone Silverlight 8.1 application will fully support Windows Phone 8 's original API and features, note windows Phone 8.1 's API to Windows Phone 8 of the API implements a lot of changes, and the next section describes the differences. The Windows Phone Silverlight 8.1 application also supports some of the new APIs and features in Windows Phone 8.1. As you can see, the Windows Phone Silverlight 8.1 project is only for temporary compatibility with the current Windows Phone 8 code for easy upgrades, while the Windows Phone 8.1 app development model is Windows The future direction of the phone, and further integration with the Windows 8.1 development model. So all the code and explanations for this book are for Windows Phone 8.1 applications, not Windows Phone Silverlight 8.1 applications.

1.2.4 API differences for Windows Phone 8.1 and 8.0

The UI framework for Windows Phone 8 is developed based on Silverlight 4.0来, and the application Development framework is based on the. NET Framework and a lite version of the Windows Runtime Framework, while the Windows Phone 8.1 of applications are applications that are fully based on the Windows Runtime Framework, and the Windows Runtime framework that is used is a unified framework for applications that develop Windows store on the Windows 8/8.1 platform. Windows Phone 8.1 and Windows Store applications are all using the Windows Runtime UI framework, so in the application you can also have Windows Phone 8.1 and Windows Store applications to share the UI code for XAML, including templates, controls, pages, and so on. Let's take a look at the major changes and differences in the API for Windows Phone 8.1 and 8.0:

(1) 8.0 of XAML controls are under System.Windows.Controls space, and 8.1 of XAML controls are under the Windows.UI.Xaml namespace.

(2) 8.0 of the application bar is appbarbuttons, and 8.1 is CommandBar.

(3) 8.1 added the ListView and GridView list controls, and 8.0 of the Longlistselector controls were modified to Semanticzoom in 8.1.

(4) 8.0 of the Panorama control is modified in 8.1 to the hub control.

(5) 8.0 the page base class PhoneApplicationPage class is modified in 8.1 to the page class.

(6) 8.1 No longer supports RadialGradientBrush painting brushes.

(7) The Windows.UI.Xaml.UIElement.Clip property of 8.1 only supports geometry of type rectanglegeometry, other geometries are not supported.

(8) The 8.0 popup control MessageBox is modified to Messagedialog in 8.1, and is the mode of the asynchronous invocation.

(9) 8.0 page navigation mode navigationservice.navigate (Uri source[, Object Navigationstate]) is modified in 8.1 to This.Frame.Navigate (typeof ( Aboutpage));

(10) in 8.1, 8.0 of the WebClient class of HTTP programming was canceled, adding the HttpClient class.

(11) For a reference to a namespace in XAML, the syntax "Clr-namespace" is changed to "using".

(12) 8.1 cancels the API for the initiator and selector in 8.0, you can use Windows.System.Launcher to implement some of the functionality.

(13) 8.1 Re-modified the speech API in 8.0.

(14) 8.1 Re-modified the geo-location API in 8.0 and added geo-fencing-related features.

(15) 8.1 The use of the local database SQL Server CE is no longer supported.

(16) 8.1 No longer supports isolated storage APIs, instead only APIs that use app files and app settings.

(17) 8.1 of the background task programming with the new API and mechanism, the original 8.0 of the background task API and operation mechanism are canceled.

(18) 8.1 of the push notification programming and API are also different from 8.0.

(19) 8.1 of Toast notifications, tile notifications, tile implementations, and 8.0 are also different.

(20) Most of the. NET APIs supported in 8.0 (non-Windows runtime APIs) are no longer supported in 8.1.

This article is from the "in-depth Windows Phone 8.1 application Development"

Source code Download: Http://vdisk.weibo.com/s/zt_pyrfNHb99O

Welcome to follow my Weibo @wp forestry Administration public Number: WP Development (No.: WPKAIFA)

WP8.1 Technology Group: 372552293

[In Layman's WP8.1 (Runtime)] The difference between Windows Phone 8.1 and Silverlight 8.1

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.