23
©2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential. Develop mobile applications with AIR 2.5 James Ward & Michaël Chaize | Platform Evangelists

Devoxx 2010: Develop mobile applications with Flex

Embed Size (px)

DESCRIPTION

Presentation by James Ward and Michaël Chaize for Devoxx 2010.

Citation preview

Page 1: Devoxx 2010: Develop mobile applications with Flex

©2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Con�dential.

Develop mobile applications with AIR 2.5James Ward & Michaël Chaize | Platform Evangelists

Page 2: Devoxx 2010: Develop mobile applications with Flex

©2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Con�dential.

James Ward & Michaël Chaize

2

@mchaize

RIAgora.comjamesward.com

@riacowboy

Page 3: Devoxx 2010: Develop mobile applications with Flex

Flex on mobile ?

Page 4: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

Native Applications

iOS

NativeApp

NativeApp

NativeApp

NativeApp

NativeApp

NativeApp

Page 5: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

AIR Flash Player

Abstraction Layer

iOS

Flex Application

Page 6: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Con�dential.

Technologic partners

Open Screen Project

Content providers

Page 7: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Con�dential.

Flash Player 10.1

Flash Player 10.1

Google TV

Page 8: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Con�dential.

Adobe AIR 2.5 = native applications = multiple screens

Page 9: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

AIR extends the bene�ts of Flash Player

Geo-LocationSQLite

Application Update FrameworkApplication Lifecycle

.AIR File format for multi-screen applicationsEnhanced Application Security model

Marketplace DistributionMobile Hardware So�key Support

File-System Access (if allowed)MediaLibrary API

Native Extensibility

!Richer and more engaging user experiences out of the browser

!Empower Flash developers to deploy applications in app catalogs

!Leverage desktop AIR app ecosystem

!Shared codebase and porting with Flash Player

ActionScript3 SupportMemory, ba�ery & CPU optimizations

Audio/Video hardware decodingOptimized SWF management

Multi-touch and GesturesHardware Acceleration

Mobile Text input

Page 10: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

Deploying AIR Android Applications

Chroma Circuit.apkChroma Circuit.air

! AIR Applications are packaged up as .APK �les! Will be distributed through Android Market and other catalogs! AIR Application upgrade mechanism through Android Market

! AIR Runtime will be distributed in Android Market as Shared Library! Users will have to download the Runtime once for all AIR applications! Upgrade through the Android Market

Android Market Android Device

Page 11: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

AIR for iOS

! Export SWF to IPK

! Cross-Compiles AIR Runtime and App to native Objective-C Bytecode

! Uses LLVM

! Many AIR APIs are implemented

! Some APIs not possible (Loader.loadBytes)

Page 12: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

AIR for BlackBerry PlayBook

h�p://us.blackberry.com/developers/tablet/devresources.jsp

WIN A PLAYBOOK !!!

Page 13: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Con�dential.

TOUR DE MOBILE FLEX

Page 14: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

Mobile Applications in "Hero"

14

s:TabbedMobileApplication s:MobileApplications:Application

Page 15: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved. 1

MobileApplication and TabbedMobileApplication

! View stack metaphor

! View

! ViewNavigator / TabbedViewNavigator

! Built-in mobile navigation experience

! Action bar

! Back bu�on

! Transitions

! APIs

15

Page 16: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

ViewNavigator API

! navigator.pushView();

! navigator.popView();

! navigator.popToFirstView()

! navigator.activeView;

16 2

Page 17: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

ActionBar

<s:View xmlns:fx=h�p://ns.adobe.com/mxml/2009 … title=”Expenses"> <s:navigationContent> <s:Bu�on icon="@Embed('assets/home.png')"/> </s:navigationContent> <s:actionContent> <s:Bu�on label=”+"/> </s:actionContent> </s:View>

17 3

navigationContent titleContent actionContent

Page 18: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

Components that have Mobile Skins

! Bu�on

! CheckBox

! DataGroup

! Group/HGroup/VGroup/TileGroup

! Image/BitmapImage

! Label List

! RadioBu�on/RadioBu�onGroup

! Scroller

! TextArea

! TextInput

18

Page 19: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

View Lifecycle

! Alternative option: destructionPolicy=“none”

19

View becomes active

ViewCreated

Another view becomes active

View DestroyedUser navigates back to view

View Recreated

data

3B

Page 20: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved.

Mobile ItemRenderers

! MobileItemRenderer

! MobileIconItemRenderer

<s:MobileIconItemRenderer

labelField="lastName"

messageField="title"

iconField="picture"

decoratorClass=”phoneIcon">

20 4

Page 21: Devoxx 2010: Develop mobile applications with Flex

© 2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Con�dential.

LET’S CODE A FLEX MOBILE APP

Page 22: Devoxx 2010: Develop mobile applications with Flex

labs.adobe.comDownload Flash Builder “Burrito” and Flex “Hero”

Get the source code ofTour de Mobile Flex

Check the Flex “Hero” tutorials ondeveloper.adobe.com

Free Flex 4 trainings in Belgium and seminarshttp://bit.ly/ria_update

Page 23: Devoxx 2010: Develop mobile applications with Flex

©2010 Adobe Systems Incorporated. All Rights Reserved. Adobe Con�dential.

Feel free to contact us

23

@mchaize

RIAgora.comjamesward.com

@riacowboy