bar camp iphone web hackery

10
iPhone Web-App Hackery Presented by Andy Edmonds @ BarCampAtl08

Upload: andy-edmonds

Post on 22-Apr-2015

1.817 views

Category:

Technology


0 download

DESCRIPTION

 

TRANSCRIPT

Page 1: Bar Camp Iphone Web Hackery

iPhone Web-App Hackery

Presented by Andy Edmonds@ BarCampAtl08

Page 2: Bar Camp Iphone Web Hackery

Demo: iBlipper.com

Page 3: Bar Camp Iphone Web Hackery

Building Blocks

• Orientation Trick• Canvas• Animation options– jQuery– CSS Transforms– Dojo (charts too)

• Working with multitouch– Downlevel mouse experi

ence – jQuery plugin

• Standard UI Starters– UiUI Kit– IUI slide panel

• Community– iphoneWebDev

Page 4: Bar Camp Iphone Web Hackery

Screen Control

• Annoying URL Bar?– Just scroll

• Viewport Tag– Min,max zoom– Initial zoom– Canvas size

• iPhone OS 2.1 introduces ability to go full screen from a home screen bookmark

• Ajaxian• Apple

Page 5: Bar Camp Iphone Web Hackery

Fun Opportunity for Zooming UIs

• New Reader– Zoom to details

• See http://delicious.com/andyed/zui

• Orhttp://en.wikipedia.org/wiki/Zooming_user_interface

Page 6: Bar Camp Iphone Web Hackery

iBlipper CSS Transforms

Use percent markers for timein your CSS.

Page 7: Bar Camp Iphone Web Hackery

Applying CSS Transforms with JS

node.style.webkitAnimationName = 'fade,slide';

node.style.webkitAnimationDuration= “1000,1000”;

Page 8: Bar Camp Iphone Web Hackery

Orientation Trick

var currentWidth;

var currentHeight;var updateLayout = function(){

if (window.innerWidth != currentWidth) {currentWidth = window.innerWidth;

currentHeight = window.innerHeight; var orient = (currentWidth == 320) ? "profile" : "landscape"; document.body.setAttribute("orient", orient);

window.scrollTo(0, 1);

}};

Ugly but functional hack to set up an interval to inspect the window width

Page 9: Bar Camp Iphone Web Hackery

Development and Debugging

• Apple iPhone Simulator• Linked debug console on desktop

Page 10: Bar Camp Iphone Web Hackery

Happy Hacking!

AndyEdhttp://surfmind.com