windows 10 universal windows platform - jug ru...
TRANSCRIPT
![Page 1: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/1.jpg)
Windows 10Universal Windows Platform
Michael SamarinFuturice Oy
@MichaelSamarin
![Page 2: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/2.jpg)
http://windows.Microsoft.com
Phone Small Tablet2-in-1s
(Tablet or Laptop)Desktops
& All-in-OnesPhablet Large TabletClassic Laptop
Xbox IoTSurface Hub Holographic
Windows 10
![Page 3: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/3.jpg)
http://windows.Microsoft.com
Easy for users to get & stay current
Unified core and app platform
The convergence journey
Windows 10
ConvergedOS kernel
Convergedapp model
![Page 4: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/4.jpg)
http://windows.Microsoft.com
Universal Windows Platform
One Operating SystemOne Windows core for all devices
One App PlatformApps run across every family
One Dev CenterSingle submission flow and dashboard
One Store Global reach, local monetization Consumers, Business & Education
![Page 5: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/5.jpg)
http://windows.Microsoft.com
Windows Core
The refactored common core
One hardware platform
Universal hardware driver
Standard network and I/OPhoneDevice
XboxDevice
DesktopDevice
Windows Core
DesktopSKU
PhoneSKU
XboxSKU
![Page 6: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/6.jpg)
http://windows.Microsoft.com
One Windows
Desktop
SKU
PC
2 in 1
Mobile
SKU
Tablet
Phablet
Phone
Xbox
SKU
Xbox
IoT
SKU
Band
IoT headless
SKU
Raspberry Pi
Home
Automation
Surface Hub
SKU
Surface Hub
Holographic
SKU
HoloLens
![Page 7: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/7.jpg)
Each family adds features to the one it inherits
![Page 8: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/8.jpg)
One simple, unified, integrated development environment
![Page 9: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/9.jpg)
http://windows.Microsoft.com
Visual Studio 15 IDE
Every project typeDesktop, Windows, Phone, Service, Web, Game, More…
Every developer taskCode edit, Architecture design, UX design, Debug, Profile, Review, Test, More…
Every development languageC++/CX, C#, Visual Basic, JavaScript, XAML, HTML, More…
Visual Studio OnlineSource repository, project management, bug tracking, More…
![Page 10: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/10.jpg)
http://windows.Microsoft.com
Blend for Visual Studio 15
The XAML Developer’s IDEAlways part of Visual Studio
Uses the Visual Studio shell
Full auto-complete & intellisense
• Validation
• Snippets
• Peek
File & solution management
Resource management
Data management
Animation
States
![Page 11: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/11.jpg)
http://windows.Microsoft.com
Visual Studio 2015 Editions
EnterpriseArchitecture Modeling, Diagnostics, VSO/ALM & Release Management
ProfessionalArchitecture Validation, VSO/ALM & Feedback Management
Community EditionsVisual Studio Professional Edition
![Page 12: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/12.jpg)
http://windows.Microsoft.com
Developer unlock
![Page 13: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/13.jpg)
http://windows.Microsoft.com
Where can I develop?
Windows 10Requires Visual Studio 2015
Windows 8.1 & Windows Server 2012 R2The Visual Studio designer does not function
Debugging requires a Windows 10 device or Remote Debugging Tools
![Page 14: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/14.jpg)
http://windows.Microsoft.com
Universal Windows Platform
A single API surfaceA guaranteed API surface
The same on all devices
PhoneDevice
XboxDevice
DesktopDevice
Windows Core
Universal Windows Platform
![Page 15: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/15.jpg)
Apps don't target Windows 10, apps target the platform
![Page 16: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/16.jpg)
http://windows.Microsoft.com
<TargetPlatform
Name="Microsoft.Universal"
minVersion="10.0.10069.0"
maxVersionTested="10.0.10190.0"/>
![Page 17: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/17.jpg)
The Universal Windows Platform can update at its own cadence
![Page 18: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/18.jpg)
http://windows.Microsoft.com
Windows app
A single binary Running on any device
Testing for capabilities
Adjusting to devices
PhoneDevice
XboxDevice
DesktopDevice
Windows Core
Universal Windows Platform
Windows App
![Page 19: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/19.jpg)
DEMO
Hello UWP
![Page 20: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/20.jpg)
Adaptive Code
![Page 21: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/21.jpg)
http://windows.Microsoft.com
What are Adaptive Apps?
Windows apps adapt to different versions of the platform
Windows apps adapt to different types of devices
Windows apps adapt to different screen sizes
Adaptive UI handles different screens
Adaptive Code can "light up" your app to conditionally execute code only when running on specific device families and/or particular versions of platform/extension APIsConditionally take advantage of unique device capabilities
Use newer APIs while still supporting down-level clients
![Page 22: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/22.jpg)
Looking back toWindows 8.1
![Page 23: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/23.jpg)
http://windows.Microsoft.com
Windows 8.1 Universal: Shared code, two binaries
Windows
Binary Phone
Binary
![Page 24: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/24.jpg)
http://windows.Microsoft.com
Not all APIs were available everywhere
![Page 25: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/25.jpg)
http://windows.Microsoft.com
Compilation directives
C# Syntax
#if WINDOWS_PHONE_APP
Windows.Phone.UI.Input.HardwareButtons
.BackPressed += this.HardwareButtons_BackPressed;#endif
C++ Syntax
#if WINAPI_FAMILY==WINAPI_FAMILY_PHONE_APP_backPressedEventToken = HardwareButtons
::BackPressed += ref new EventHandler<BackPressedEventArgs^> (this, &NavigationHelper::HardwareButton_BackPressed);
#endif
![Page 26: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/26.jpg)
Looking Forward to UWP
![Page 27: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/27.jpg)
http://windows.Microsoft.com
Universal Windows Platform
A single API surfaceA guaranteed API surface
The same on all devices
PhoneDevice
XboxDevice
DesktopDevice
Windows Core
Universal Windows Platform
![Page 28: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/28.jpg)
http://windows.Microsoft.com
Declare Device Family Dependencies
Dependency on a single device family:<Dependencies>
<TargetDeviceFamily Name="Windows.Universal" minVersion="10.0.10069.0" maxVersionTested="10.5.0.0" />
</Dependencies>
On more than one:<Dependencies>
<TargetDeviceFamily Name="Windows.Desktop" minVersion="10.0.10069.0" maxVersionTested="10.5.0.0" />
<TargetDeviceFamily Name="Windows.Universal" minVersion="10.0.10069.0" maxVersionTested="10.5.0.0" />
</Dependencies>
![Page 29: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/29.jpg)
Introducing Platform Extension SDKs
![Page 30: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/30.jpg)
http://windows.Microsoft.com
Platform extensions
Device-specific APIFamily-specific capabilities
Compatible across devices
Unique update cadence
PhoneDevice
XboxDevice
DesktopDevice
Windows Core
Universal Windows Platform
Windows App
Phoneextension
Xboxextension
Desktopextension
![Page 31: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/31.jpg)
Extensions don't invalidate binaries on other devices
![Page 32: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/32.jpg)
DEMO
Extensions SDKs in VS 15
![Page 33: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/33.jpg)
http://windows.Microsoft.com
Extension SDKs
UWP
Windows Core Windows Core Windows Core Windows Core
UWP UWP UWP
Desktop Mobile Xbox More…
![Page 34: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/34.jpg)
http://windows.Microsoft.com
Testing for capabilities
IsApiContractPresentIsEnumNamedValuePresentIsEventPresentIsMethodPresentIsPropertyPresentIsReadOnlyPropertyPresentIsTypePresentIsWriteablePropertyPresent
Windows.Foundation.Metadata.ApiInformation
![Page 35: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/35.jpg)
http://windows.Microsoft.com
Test capabilities at runtime
var api = "Windows.Phone.UI.Input.HardwareButtons";
if (Windows.Foundation.Metadata.ApiInformation.IsTypePresent(api))
{
Windows.Phone.UI.Input.HardwareButtons.CameraPressed
+= CameraButtonPressed;
}
![Page 36: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/36.jpg)
The ApiInformation API tests for capabilities at runtime.
![Page 37: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/37.jpg)
http://windows.Microsoft.com
Which Extension SDKs Do I Need?
Many Apps need no Extension SDKs at allThe Windows Universal Core APIs cover nearly all common app needs
Use APIs in Extension SDKs to ‘light up’ your app when running on a specific device family
![Page 38: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/38.jpg)
http://windows.Microsoft.com
Identifying the Extension SDK
MSDN docs:
![Page 39: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/39.jpg)
http://windows.Microsoft.com
Exploring API Contracts
![Page 40: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/40.jpg)
Adaptive Code and API versions
![Page 41: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/41.jpg)
http://windows.Microsoft.com
Using Specific Versions of an API
Adaptive code techniques are not only for handling device family-specific code
You write your app against a base UWP version, but 6 months later, UWP v.Next ships to users machinesApplies to Extension SDKs and Packages as well – new versions may offer new functionality
You want to keep supporting customers who haven’t updated yet, but take advantage of up-level APIs for those who have
![Page 42: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/42.jpg)
http://windows.Microsoft.com
Package Dependency
<Dependencies>
<PackageDependency
Name="Microsoft.WinJS 1.0"
Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
minVersion ="1.5.0.0" />
</Dependencies>
![Page 43: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/43.jpg)
http://windows.Microsoft.com
Gate use of up-level APIs
var contract = "Devices.Scanners.ScannerDeviceContract";
int majorVersionRequired = 3;
if (Windows.Foundation.Metadata.ApiInformation.
IsApiContractPresent(contract, majorVersionRequired ))
{
// Call the API that is present in V3 and above
...
}
else
{
// Your original code supporting users who haven’t upgraded yet
...
}
![Page 44: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/44.jpg)
Adaptive design and UI
![Page 45: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/45.jpg)
http://windows.Microsoft.com
![Page 46: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/46.jpg)
http://windows.Microsoft.com
![Page 47: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/47.jpg)
http://windows.Microsoft.com
![Page 48: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/48.jpg)
http://windows.Microsoft.com
Adaptive design
Phone (portrait)
Tablet (landscape) / Desktop
![Page 49: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/49.jpg)
http://windows.Microsoft.com
Tailored design
Phone (portrait)
Tablet (landscape) / Desktop
![Page 50: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/50.jpg)
http://windows.Microsoft.com
Continuum for Convertibles and PhonesContinuum for convertibles and Phones
![Page 51: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/51.jpg)
http://windows.Microsoft.com
Scaling algorithm
![Page 52: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/52.jpg)
http://windows.Microsoft.com
Planning your design
PhoneViewing Distance: 16.3”
Tablets and 2 in 1Viewing Distance:
20”
Small and Large LaptopsViewing Distance:
24.5”
Small and Large Desktop MonitorsViewing Distance:
28”
TVViewing Distance:
84”
5” 8” 13”
![Page 53: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/53.jpg)
http://windows.Microsoft.com
Physical versus effective pixel
4” Phone
480x854
5” Phone
720x1280
6” Phone
1080x1920
4” Phone
480x854
5” Phone
720x1280
6” Phone
1080x1920
![Page 54: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/54.jpg)
http://windows.Microsoft.com
Effective pixel
Effective PixelPhysical Pixel
![Page 55: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/55.jpg)
Ignore scale, resolution, & dpi.Design in Effective Pixels
![Page 56: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/56.jpg)
http://windows.Microsoft.com
Snap points
phablet & tablet
desktopphone
• limited landscape support• one frame at a time• sys tray on the left• steering wheel on the right• 4+ actions on the bottom• tabs are centered
• limited landscape support• one frame at a time• sys tray on the left• steering wheel on the right• 4+ actions on the bottom• single column stops scaling• tabs are centered
• full landscape support• two frames• actions at the top• one “…” visible -TBD• tabs are left aligned• Show search field if search was
represented as an icon on smaller devices
• full landscape support• three frames• compact navpane• actions at the top• one “…” visible• tabs left aligned
548 720 1024320epx
![Page 57: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/57.jpg)
Nothing is stopping you from creating a multi-headed solution
![Page 58: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/58.jpg)
http://windows.Microsoft.com
Dedicated, targeted apps
![Page 59: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/59.jpg)
Adaptive tooling
![Page 60: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/60.jpg)
http://windows.Microsoft.com
Visual States
Define XAML viewsUnique layout for distinct states
Simplify animationAutomatically implement state transitions
Build in BlendDesign and preview states and transitions
![Page 61: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/61.jpg)
Visual states let designers define many looks of a view
![Page 62: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/62.jpg)
Adaptive triggers are a zero-code solution
![Page 63: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/63.jpg)
http://windows.Microsoft.com
Adaptive triggers
Code-free state transition
Two built-in triggersMinWindowHeight (Taller than this)
MinWindowWidth (Wider than this)
<VisualState x:Name="VisualState500min"><VisualState.StateTriggers>
<AdaptiveTrigger MinWindowWidth="501" /></VisualState.StateTriggers>
</VisualState>
![Page 64: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/64.jpg)
http://windows.Microsoft.com
How to set the visual state
VisualStateManager.Goto(element, state, transition)
public MainPage(){
this.InitializeComponent();this.SizeChanged += (s, e) =>{
var state = "VisualState000min";if (e.NewSize.Width > 500)
state = "VisualState500min";else if (e.NewSize.Width > 800)
state = "VisualState800min";else if (e.NewSize.Width > 1000)
state = "VisualState1000min";VisualStateManager.GoToState(this, state, true);
};}
![Page 65: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/65.jpg)
DEMO
Visual states
![Page 66: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/66.jpg)
Managed languages are more efficient than ever
![Page 67: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/67.jpg)
Every Windows app will be compiled with .Net Native
![Page 68: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/68.jpg)
http://windows.Microsoft.com
.NET Native
Next generation compiler in the cloud Every Windows apps, only Windows app (right now)
Apps use the standard C++ optimizerAs optimizer performance improves, so does .Net native
Apps with .Net bootstrapperIncludes garbage collection
There is no runtimeThis is machine code
![Page 69: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/69.jpg)
http://windows.Microsoft.com
Real benefits with .Net Native
50% faster average startup time
14% less average memory usage
![Page 70: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/70.jpg)
More information:
MVA Course:
A Developer Guide to Windows 10
June 8 - 12
MVP Webcast Windows 10 Developer Readiness:
http://aka.ms/Win10MVP
![Page 71: Windows 10 Universal Windows Platform - JUG Ru Grouppublic.jugru.org/dotnext/2015/piter/samarin.pdf · 2016-07-11 · The Windows Universal Core APIs cover nearly all common app needs](https://reader030.vdocuments.site/reader030/viewer/2022040614/5f093fc87e708231d425ef47/html5/thumbnails/71.jpg)