building with sencha & touch higher standards

51
Building with Sencha & Touch Higher Standards Sencha Framework & Best Practices Presented at: Nextbridge LHR C1 May 10, 2012

Upload: arvid

Post on 14-Feb-2016

30 views

Category:

Documents


1 download

DESCRIPTION

Presented at: Nextbridge LHR C1 May 10, 2012. Building with Sencha & Touch Higher Standards. Sencha Framework & Best Practices. Questions regarding previous session?. ?. RECAPE. We need platform?. PhoneGap. PhoneGap Api Reference. What is missing?. User Experience. Here comes?. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Building with  Sencha  &  Touch  Higher Standards

Building with Sencha & Touch Higher StandardsSencha Framework & Best Practices

Presented at:Nextbridge LHR C1May 10, 2012

Page 2: Building with  Sencha  &  Touch  Higher Standards

Questions regarding previous session?

?

Page 3: Building with  Sencha  &  Touch  Higher Standards

RECAPE

Page 4: Building with  Sencha  &  Touch  Higher Standards

We need platform?

PhoneGap

Page 5: Building with  Sencha  &  Touch  Higher Standards

PhoneGap Api Reference

Page 6: Building with  Sencha  &  Touch  Higher Standards

What is missing?

User Experience

Page 7: Building with  Sencha  &  Touch  Higher Standards

Here comes?

Mobile UI Libraries

Page 8: Building with  Sencha  &  Touch  Higher Standards

A lot of things available

jQuery Mobile jQTouch

iUI Choclate Chip

Page 9: Building with  Sencha  &  Touch  Higher Standards

Framework?

Choice Is all Yours

Page 10: Building with  Sencha  &  Touch  Higher Standards

Its all up to you?

ChooseWhich fits you?

Page 11: Building with  Sencha  &  Touch  Higher Standards

AGENDAToday’s

Page 12: Building with  Sencha  &  Touch  Higher Standards

Topics we will cover in this presentation

• Sencha Touch• Application Demonstration in Sencha

Touch

PART 1

Page 13: Building with  Sencha  &  Touch  Higher Standards

Topics we will cover in this presentation

• Best Practices for Mobile Development– Things to remember– Best Practices in Mobile Development

PART 2

Page 14: Building with  Sencha  &  Touch  Higher Standards

TOPIC 1Sencha Touch Framework

Page 15: Building with  Sencha  &  Touch  Higher Standards

Overview

• Sencha Touch Intro• Core Features• Components• Containers• Layouts• Hello World App• Application Demonstration

Page 16: Building with  Sencha  &  Touch  Higher Standards

Sencha Touch Intro

• High performance HTML5 mobile application framework with world-class user experiences.

• Build fast and impressive apps that work on iOS, Android, BlackBerry and more.

• Over 50 built-in components• Very easy to learn• License Options

– free commercial & open source licenses for application development.– paid commercial license for OEM uses.

• Current Version 2.0.1

Page 17: Building with  Sencha  &  Touch  Higher Standards

Core Features

• Built-in MVC system• Rich collection of components• Layouts• Config System• Animations & Touch events• Device Profiles• Native Packaging

– Android & IOS currently• Sencha Command (included Sencha Touch SDK)• Sencha Touch Charts• Rich Documentation (30 guides, 6 full example apps included, API docs, Component examples,

Guides, Videos etc)

Page 18: Building with  Sencha  &  Touch  Higher Standards

Components

• Most of the visual classes you interact with in Sencha Touch are Components.

• Every Component in Sencha Touch is a subclass of Component.• Components are grouped into four categories

Page 19: Building with  Sencha  &  Touch  Higher Standards

Components

• Navigation components– Toolbar– Button– TitleBar– SegmentedButton– Title– Spacer

• Form components– Panel– FieldSet– Checkbox– Hidden– Slider– Text– Picker– Date

Page 20: Building with  Sencha  &  Touch  Higher Standards

Components

• Store-bound components• DataView• Carousel• List• NestedList

• General components• Panel• TabPanel• Viewport• Img• Map• Audio• Video• Sheet• ActionSheet• MessageBox

Page 21: Building with  Sencha  &  Touch  Higher Standards

Containers

• A Container has all of the abilities of Component, but lets you nest other Components inside it.

• Most apps have a single top-level Container called a Viewport.

• Containers give the following extra functionality– Adding child Components at instantiation and run time– Removing child Components– Specifying a layout

Page 22: Building with  Sencha  &  Touch  Higher Standards

Layouts

• Layouts describes how components are placed (arrangement/positioning) inside containers.– HBox – VBox– Card– Fit

Page 23: Building with  Sencha  &  Touch  Higher Standards

Hello World

<!DOCTYPE HTML><html> <head> <title>Hello World</title> <link rel="stylesheet" type="text/css" href="css/sencha-touch.css" /> <script type="text/javascript" src="js/sencha-touch-all.js"></script> </head> <body> <script type="text/javascript">

Ext.setup({onReady: function() {var panel = Ext.create('Ext.Panel', {html: ‘Hello World'}); Ext.Viewport.add(panel);}

}); </script> </body></html>

Page 24: Building with  Sencha  &  Touch  Higher Standards

TOPIC 2Application Demonstration in Sencha Touch

Page 25: Building with  Sencha  &  Touch  Higher Standards

Application Demonstration

• Store Finder • Kitchen Sink (comes with Sencha Touch)

Page 26: Building with  Sencha  &  Touch  Higher Standards

Questions

?

Page 27: Building with  Sencha  &  Touch  Higher Standards

BEST PRACTICES IN MOBILE DEVELOPMENT

Page 28: Building with  Sencha  &  Touch  Higher Standards

TOPIC 3Things to remember

Page 29: Building with  Sencha  &  Touch  Higher Standards

1. Things to remember

Page 30: Building with  Sencha  &  Touch  Higher Standards

1. Things to remember

Alice in Wonderland

Page 31: Building with  Sencha  &  Touch  Higher Standards

1. Things to remember: Alice in Wonderland

To be a Mobile

Developer

Be Explorativ

e

Accept New

things

Ready for

uncertain events

Be Social

Page 32: Building with  Sencha  &  Touch  Higher Standards

2. Things to remember

Don’t have Quad Core

Don’t have Gigz RAM

Don’t have Tera

Memory

Don’t have an easy replacement

MOBILE Don’t

Page 33: Building with  Sencha  &  Touch  Higher Standards

TOPIC 4Best Practices in Mobile Development

Page 34: Building with  Sencha  &  Touch  Higher Standards

3. Things to remember

Do not blindly mimic designs intended to run on desktop devices

Page 35: Building with  Sencha  &  Touch  Higher Standards

4. Things to remember

Revise courses of OOP

Avoid procedural

Programming

Page 36: Building with  Sencha  &  Touch  Higher Standards

Avoid procedural Programming

What if you have to manage 100 items linked on multiple places?

Page 37: Building with  Sencha  &  Touch  Higher Standards

Avoid procedural Programming

You will think of Pointers

Procedural with Arrays OOP with Data Structures

Page 38: Building with  Sencha  &  Touch  Higher Standards

Avoid procedural Programming

You will think of Pointers

Procedural with Arrays OOP with Data Structures

Page 39: Building with  Sencha  &  Touch  Higher Standards

4. Things to remember

Revise courses of OSAvoid

Synchronous approach

for some cases

Page 40: Building with  Sencha  &  Touch  Higher Standards

Avoid parallel programming

What if you have to process the search meanwhile offer user to

navigate to some features

Page 41: Building with  Sencha  &  Touch  Higher Standards

Avoid parallel programming

If you think in JSRemote Calls

Synchronous AJAX

Page 42: Building with  Sencha  &  Touch  Higher Standards

5. Things to remember

Revise courses of OOAD

Use OOP Design Patterns

Page 43: Building with  Sencha  &  Touch  Higher Standards

Design Patterns

OOAD

Functor

WrapperSingletonIteratorObservers

Factory

…..

Page 44: Building with  Sencha  &  Touch  Higher Standards

Design Patterns: How to use?

•Application SettingsSingletone•Call for Web servicesAdapter•Mimic Application server sideWrapper•User interaction with dataObservers•Displaying List DataIterators•……….…..

Page 45: Building with  Sencha  &  Touch  Higher Standards

6. Things to remember

Use data compression

during transfer

Page 46: Building with  Sencha  &  Touch  Higher Standards

7. Things to remember

Use Local Storage but carefully

Page 47: Building with  Sencha  &  Touch  Higher Standards

8. Things to remember

Provide Auto Sign In functionality

Page 48: Building with  Sencha  &  Touch  Higher Standards

9. Things to remember

Avoid heavy usage of Keypad

Page 49: Building with  Sencha  &  Touch  Higher Standards

10. Things to remember

Always Respect

User &

User Experience

Page 50: Building with  Sencha  &  Touch  Higher Standards

Now its your turn to speak

Page 51: Building with  Sencha  &  Touch  Higher Standards

BUILDING WITH SENCHA & TOUCH HIGHER STANDARDS

Sencha Framework & Best Practices

Designed & Presented by:Nazar HussainTraining Manager

Co-Presenter:

Muhammad AzeemSenior Software Engineer

Presented at:Nextbridge LHR C1May 10, 2012