xamarin dev days madrid - xamarin.forms

49
Interfaces nativas Cross-Platform con Xamarin.Forms Xamarin Dev Days Madrid

Upload: javier-suarez-ruiz

Post on 12-Jan-2017

1.372 views

Category:

Technology


0 download

TRANSCRIPT

Interfaces nativas Cross-Platform con Xamarin.FormsXamarin Dev Days Madrid

Xamarin Dev Days MadridVisual Studio Technologies & Windows Platform Development MVP

Software Developer Plain ConceptsJavier Surez Ruiz

Blog: http://geeks.ms/blogs/jsuarezEmail: [email protected]: @jsuarezruiz

Xamarin Dev Days Madrid

En nuestro curso online de:10% de descuentowww.campusMVP.es

Usa este cupn en campusMVP.es:

xamarindoVlido hasta el 31 de Diciembre de 2016

Xamarin Dev Days MadridCrear UIs nativas para iOS, Android, y Windows Desde un mismo archivo comn, compartido C#.Conoce Xamarin.Forms

Xamarin Dev Days MadridXamarin + Xamarin.FormsEnfoque tradicional de XamarinCon Xamarin.Forms:Ms cdigo compartido, todo nativo iOS C# UI Windows C# UIAndroid C# UI

Shared C# Backend

Shared UI CodeShared C# Backend

Xamarin Dev Days MadridQu se incluye? 40+ pginas, layouts, y controles (code behind o XAML) Two-way data binding Navegacin API de animaciones Dependency Service Messaging Center

Shared C# Backend

Shared UI Code

Xamarin Dev Days Madrid

6

LayoutsPginasStackAbsoluteRelativeGridContentViewScrollViewFrame

ContentMasterDetailNavigationTabbedCarousel

Xamarin Dev Days MadridInside of a page are layoutsA lot of options from something simple like a stack panel to complex and powerful grids

7

ActivityIndicatorBoxViewButtonDatePickerEditorEntryImageLabelListViewMapOpenGLViewPickerProgressBarSearchBarSliderStepperTableViewTimePickerWebViewEntryCellImageCellSwitchCellTextCellViewCellControles

Xamarin Dev Days MadridYou have more than 40 controls, layouts, and pages to mix and match from.These are all of the controls you have out of the box, you can of course create your own.What is unique is you get the native control and have access to it.Consider an Entry FieldOn iOS it is mapped to UITextFieldAndroid it is EditTextWindows Phoen it is a TextBox8

El ecosistema Xamarin.Forms

Xamarin Dev Days MadridWindowsXamarin.FormsStackPanelStackLayoutTextBoxEntryListBoxListViewCheckBoxSwitchProgressBarActivityIndicatorGridGridLabelLabelButtonButtonImageImageDate/TimePickerDate/TimePicker

Comparativa de controles

Xamarin Dev Days Madrid

10

WindowsXamarin.FormsDataContextBindingContext{Binding Property}{Binding Property}ItemsSourceItemsSourceItemTemplateItemTemplateDataTemplateDataTemplate

Comparativa de enlace a datos

Xamarin Dev Days Madrid

11

Personalizacin de la plataforma

Xamarin Dev Days Madrid

12

UI Nativa desde cdigo compartido

Xamarin Dev Days MadridXamarin.Forms

Demo

Xamarin Dev Days MadridQu hay nuevo?

Xamarin.Forms 2.0!

Xamarin Dev Days MadridXamarin.Formses Open Source!open.xamarin.com

Xamarin Dev Days MadridApple has a developer preview where Xamarin has alphas ready. Google does not offer this. Android versions are usually 4 to 8 weeks out for a stable release, but alphas and betas are usually earlier. Xamarin realizes how important having iOS ready because within 24 hours a large portion of iOS users upgradeAndroid on the other hand is much different. After 4 months on the market Android 4.4 only had 1% adoption

16

RendimientoRendimientoRendimiento

Xamarin Dev Days MadridListView CachingStrategy

Mejora el rendimiendo haciendo scroll El comportamiento antiguo es el usado por defecto

Xamarin Dev Days MadridCompilacin XAMLXAML

RuntimeCompile-timeParsed and inflatedParsed & turned into IL

XAMLC

Xamarin Dev Days MadridBeneficios Carga ms rapida Tamao de la App menor Ver errores XAML en tiempo de compilacin

Xamarin Dev Days MadridRendimiento

Demo

Xamarin Dev Days MadridDiseo & Controles

Xamarin Dev Days MadridData Templates

Xamarin Dev Days MadridData Templates

Demo

Xamarin Dev Days MadridCarouselViewCarouselItemTemplate & DataTemplatesAltamente personalizable & Virtualizado

Xamarin Dev Days MadridCarouselView

Demo

Xamarin Dev Days MadridEfectos I Custom renderer lite Cambia propiedades en el control nativo Opcional stringly-typed

X No mtodos o eventosX No reemplaza el control

Xamarin Dev Days MadridA unique aspect of Xamarin.Forms is an abstraction over the user interface, but what about the platform specific functionality that makes these devices so special?

That is where plugins for Xamarin come in.27

Efectos IIentry.Effects.Add (Effect.Resolve("Xamarin.BorderEffect"));

Xamarin Dev Days MadridA unique aspect of Xamarin.Forms is an abstraction over the user interface, but what about the platform specific functionality that makes these devices so special?

That is where plugins for Xamarin come in.28

Efectos

Demo

Xamarin Dev Days MadridY mucho ms!

Xamarin Dev Days Madrid

XAML Previewer

Xamarin Dev Days MadridXamarin.Forms Previewer

Demo

Xamarin Dev Days Madrid

Navegacin por URL

Xamarin Dev Days MadridConnect Web to MobileSimple cross platform API over:CoreSpotlightNSUserActivityGoogle App Indexing

Navegacin por URL

Demo

Xamarin Dev Days Madrid

Themes

https://developer.xamarin.com/guides/xamarin-forms/themes/

Xamarin Dev Days Madrid

DataPages

https://developer.xamarin.com/guides/xamarin-forms/datapages/

Xamarin Dev Days MadridDataPages

Demo

Xamarin Dev Days MadridNative Embedding

Xamarin Dev Days MadridEasily embed any native control into a Xamarin.Forms layout.

Native Embedding

Xamarin Dev Days MadridJust add it as child to a layout.Exposed as an Extension Method.

Native Embedding

Demo

Xamarin Dev Days MadridNative Views

Aadir vistas nativas directamente en XAML.

Xamarin Dev Days MadridJust add it as child to a layout.Exposed as an Extension Method.

Native Views

Demo

Xamarin Dev Days MadridPlatform Specificsusing Xamarin.Forms.PlatformConfiguration; using Xamarin.Forms.PlatformConfiguration.iOSSpecific; ...

boxView.On().UseBlurEffect(BlurEffectStyle.ExtraLight);

Permiten ejecutar caractersticas especficas de una plataforma sin necesidad de custom renders o efectos.

Xamarin Dev Days MadridJust add it as child to a layout.Exposed as an Extension Method.

Platform Specifics

Demo

Xamarin Dev Days MadridDesarrollado por SamsungBasado en OSS .NET Core Se utiliza Xamarin.Formswww.aka.ms/tizen

Tizen .NET Developer Preview

Xamarin Dev Days Madrid

45

Tizen .NET Developer PreviewExtensin para VS 2017Plantillas y emuladorCorre en ms de 50 mill. de dispositivos

Xamarin Dev Days Madrid

46

Tizen

Demo

Xamarin Dev Days MadridOne more thing

Xamarin Dev Days Madrid10 Minutos de descanso

JavierSurez [email protected]://javiersuarezruiz.wordpress.com@jsuarezruiz

Xamarin Dev Days Madrid

2014 Microsoft Corporation. All rights reserved. Microsoft, Windows, and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.11/26/201649