Showing posts with label javascript. Show all posts
Showing posts with label javascript. Show all posts

Thursday, 28 November 2013

Handheld Conference 2013: port80 fringe event

Last year’s Handheld Conference was a great event, with several of the sessions winning awards as the best talks of the year.

This year, it’s got bigger and even comes with a fringe event the night before, in collaboration with Port80 events.

I’ll be blogging the main event sessions later, but here’s my notes from the Handheld mini/port80 event.

The ethics of making software

Graham Lee @secboffin

  • XML is like violence: if it doesn’t get you what you want, you’re not using enough of it
  • EULA: “we make no warranty that on this software” => this sh*t doesn’t work — and we’re not going to tell you until after you’ve bought it
  • we’re in an industry that wants to be grown-up — we get to choose the moral direction as well as the technical direction
  • we do have responsibility — raising awareness is the first step

Modifying Treasure Island

Alyson Fielding @alysonf

  • what happens if you put technology into a physical book (without a screen)?
  • making an enchanted object
  • lilypad arduino works well with books: it uses needle & conductive thread rather than wire & solder so it’s gentler on the book
  • “the library of lost books”
    • each rescued book is being sent to a different artist to be given a new lease of life
  • wanted to hide the technology so it feels like magic
  • triggering audio in a gesture controlled physical book
  • what happens if you get a book talking to a phone
    • hide arduino in the spine
    • zigbee to talk to phone (via Redpark cable)
    • battery to power it (mainly zigbee…)
    • accelerometer to detect position
  • initial story: book speaks what position it’s in
    • can also tweet…
  • further stories: recognising more complex 3D gestures, e.g. a hug
  • connected with a story engine
    • telling a story based on user interaction
    • crucially: also respond when the user does something different

Why don’t things just work any more?

Barry Scott @bazscott

  • fixing things:
    • easy bug reporting — value the people who report bugs
    • prioritise fixes
  • crippled behaviour:
    • flash, linkjacking, doorslams
    • watch user behaviour — and listen to them
  • bastards:
    • sample newspaper website: “the only way I can monetise the site is by getting people to download the app, so I don’t care about showing the content”…
    • shortsighted, brand will wither, people won’t come back
    • advertising cigarettes & gambling to kids (or any kind of advertising to 3 year olds…)
  • times higher education survey on link rot
    • 99% of web pages change in a year
    • 70% of links from 12 years of Harvard Legal are broken

Nodecopter

Andrew Nesbitt @teabass

  • invented by Felix Geisendörfer in 2012
  • Parrot AR Drone 2.0
  • runs busybox linux
  • node.js module: npm install ar-drone
  • watch out for going out of range
    • the drone will just continue going…
  • andrew created a node module to pick up serial input from xbox controller — used to control AR drone
  • then picked up front-facing camera and displayed on a web page
  • running both scripts at the same time allows you a first-person control of the drone
  • make it dance to dubstep:
    • using dance.js to pick up drops in an mp3 from the HTML5 audio API
  • face detection from front-facing video
    • using OpenCV on video from the video in the browser
  • lots of other examples on nodecopter.com
  • substack contributes a lot of stuff
    • including virus-copter
    • scans wifi for other drones — ssh’s to them
  • if you attach a phone you can theoretically control the drone from anywhere in the world
    • but you come under the same laws as cruise missiles…
  • voxel-drone is a simulated drone inside voxel, a minecraft clone in javascript & webgl
    • but it doesn’t have momentum…
    • voxel-drone stops instantly
    • the real drone takes about 2 metres to stop from full speed
  • why?
    • teaching programming via engaging javascript
    • did a coderdojo for 12-15 year old kids
    • chasing parents around, ballet moves
    • making controllers from tin foil and makeymakeys
  • upcoming events: probably one every month in the UK in the new year

Thursday, 25 October 2012

MomoLondon: HTML vs Native

A lively and exciting debate (despite the old material!), well-run by Ewan MacLeod, Editor, Mobile Industry Review @ew4n

Panel

Team HTML5

  • Andrew Betts @triblondon
    • HTML5 apps for FT
  • Simon Arora, Biz Dev Mgr, Keynote DeviceAnywhere @devanywhere
    • Initially all about native
    • More and more customers asking for HTML5
    • More platforms with a single codebase
    • No need for appstore or marketplace certification
    • Wider reach to monetise services
  • Jose Valles, Head of Bluevia @josevalles49
    • Been an HTML5 supporter for a long time
    • Launching FirefoxOS device

Team Native

  • Alex Caccia, President, Marmalade @marmaladeapps
    • one of the leading cross-platform build platforms
    • take advantage of ARM instruction set…
    • two of top three games in US app store built using marmalade
    • HTML5 just doesn’t provide enough power - need native for performance
    • HTML5 does not solve fragmentation
  • Chris Book, Bardowl @bookmeister
    • native gives close access to device APIs
    • deal with different network situations
    • HTML5 doesn’t work for audio streaming and caching
  • Nick Barnett, CEO, Mippin @docnickb
    • make app builders for operators and manufacturers
    • provide both HTML5 and native app builders
    • it’s more about the business model and distribution
      • if you want to be in the app store, you have to be native

Last app you paid for?

  • AB: Open House London
    • because their website is appalling and doesn’t work
  • SA: Travel Deluxe
    • native london travel
  • JV: probably a skateboarding app, or tripit or spotify
  • AC: Expense Calculator
  • CB: New Star Soccer
    • 10 games free, then in-app purchases
  • NB: International Rules of Yacht Racing
    • native

All native apps. If you want to buy an app, it has to be in an app store…

What about Facebook?

  • AC: Hardware platform is moving faster than anything else
    • If you come up against an issue, you’re against the browser
    • The only way past is to know the details of the insides of the browser
    • Can’t solve it by logic (terrible for project management!)

FT web app UX

  • EM: FT webapp has to go through local cache expanding step before starting
  • AB: equivalent to installing an app from the store
    • if you say no, it still works; but in a potentially limited way
    • actually a benefit: allows levels of access

Stats from deviceanywhere

  • SA: out of 100 customers, top 25 are looking at HTML5
    • have a lot of enterprise customers
    • looking to increase their reach
  • NB: these customers already have iOS and Android apps?
  • SA: yes, looking to extend reach across devices without decent appstores

HSBC Business Banking

  • EM: it’s an utterly crap HTML5 experience
    • banks say they’d love to do HTML5, but security say no!
  • JV: why then do they have online banking?
    • want to keep customer experience
  • CB: native NatWest app is better than web experience…
    • haven’t been able to update their website in 12 years!
    • loads of apps where you use native app first rather than web site
      • e.g. Hailo, National Rail Enquiries
  • NB: cross-platform HTML5 is a nonsense
    • at Mippin, we build web app builders for each platform separately
  • AB: that’s just ‘cos you’re not doing it very well!
    • FT use same codebase for Android, iPhone, iPad
  • NB: but Windows Phone 7 UX is completely different from iOS
    • customers expect something different
    • so you need to write your UI differently anyway
    • may as well write it natively each time

How do we resolve vested interests? And designing for format?

  • AB: each format and each channel will have differing expectations
    • if you define your constraints narrowly enough, natively will always be better
    • if you have a broad strategy and vision, then web technology will win
    • what about TV? what about kiosks?
    • a single web technology solution will adapt to those situations
    • single code base works with touch, keyboard and gestures too!
    • at a recent hackday, FT Labs connected a Kinect and controlled the app without touching the screen
    • the FT webapp works in the way that the people reading the paper are used to — independent of device expectations
  • AC: want a fine degree of control over what it looks like and how it behaves
    • in gaming environment, you really want to make the app shine
  • CB: isn’t this all about the 30% that Apple want to take out of the subscription?
  • AB: it’s not (exclusively) about the 30% — it’s more about a direct relationship with the customer
    • enables customers to switch devices without losing their subscription
  • CB: but Spotify have native apps and still go cross platform whilst keeping relationship with customers
  • AB: if Apple changed their rules to say that Spotify would have to give a percentage of their revenue, then Spotify would be stuffed
  • NB: if the Daily Mail went the FT route would people get their news elsewhere?

Is it fair to say that HTML5 is destroying usability of mobile platforms?

  • JV: no, it’s building something
  • CB: Google Maps browser version just not as good as previous native version

Hybrids?

  • NB: mippin use unique per platform wrappers
    • PhoneGap works well for iOS, not so well for Android
    • BlackBerry has WebWorks
    • hardcore gaming is a pretty specialist use case
  • CA: use the right tool for the right job
    • SDK supports HTML5 content within an app
    • and then you can switch out and use the native with ease
  • Audience: built a PhoneGap app and was appalled by performance
    • scrolling 50-100 names was just not good enough

Native provides consistent experience?

  • Spotify on some platforms lets you order playlist, Android doesn’t
  • if been written on HTML5, then would have worked fine
  • AB: people put 70% of budget into iOS
    • then 20% into Android
    • then 5% into Windows and Blackberry…
    • not surprising that non-iOS apps are crap

Discovery…

  • JV: 700K apps in Apple appstore, so discovery there is hard too
    • don’t see a difference
  • AB: FT not in a unique position – shared by lots of big brands
    • for small companies, app store is probably a good thing
    • FT have specialist native apps in the store which point users in the direction of the web app

Prisoners of the market owners?

  • NB: usual retail model: retailer takes 30-40% of revenue
    • and benefits can be considerable!
    • if you’re in Brazil in 2 years time with Boot2Gecko devices, then the mindset could be completely different
  • Dan Appelquist: isn’t that the issue — app stores are dragging us back into the old model that the open internet is breaking us out of
  • CB: yes, the dominance is worrying
    • but it’s a business making opportunity for startups
  • CA: native is not closed
    • hardware manufacturers trying to make best user experience

Security in native?

  • CB: difficult to securely store offline data
    • premium audio streaming is not yet possible in HTML5
  • EM: a bank developer said “the security people want a native app for encryption reasons”
  • AB: why does the online banking not just work on the phone?
    • yes, you can have encrypted storage, but do you need it

Best way in for mobile development

  • NB: use an app template toolkit for a size that fits
    • learn to be a mobile developer…
  • what if you just want to see your idea?
  • CA: most dangerous word when you start is “just”…
  • AB: the reason for the standard layouts on web is ads
    • have to build the design to fit the adverts
    • there’s been a boost in design creativity from moving to new formats
    • you can take that newfound focus on user experience and bring it back to the desktop
    • you’d never expect a mobile app to have big gutters down the side
    • unless it’s an iOS 5 app on an iPhone 5…

Notifications

  • NB: issue for HTML5 apps
  • AB: W3C working on notifications as a spec…

New users from India, China & Brazil won’t be in Apple or Google’s ecosystem

  • NB: won’t be a technology decision — more of a distribution

Javascript libraries?

  • NB: 85% of development in HTML5 apps goes into javascript

Great new debugging suites for Android Chrome and iOS Safari

  • Dominic Travers: great time to develop HTML5 apps!

Will we still be arguing in 5 years’ time?

  • AB: native will always be able to innovate faster
    • web will be behind, but standardised
    • FT’s Android app is partly native for performance
    • as soon as the browser catches up, they’ll remove the native part

Announcements

  • W3C coremob.org community group
  • UKTI Competition Final 29th October
  • 7th Anniversary in November

Tuesday, 4 October 2011

Over The Air 2011: The FT Web app - We've Got a Website for That

Andrew Betts, Assanka @triblondon

  • An app is:
    • responsive design
    • responsive to human interface (mouse, keyboard, touchscreen, TV remote, …)
  • The Daily app is now generating less than 50 tweets a day (and still going down)
    • Down from over 200
  • iPad web app also works on other devices
    • not just tablets – phones too
    • currently only accessibly on iPad
    • works on Android & QNX but not released yet
    • Android imminent, QNX a few months
  • server serves the same code to all devices
    • client does customisation and caches as much as it can
    • so can go offline and still access pages
  • FT web app
    • 8 months with 3 people
    • then additional 4 months with same people to get Android & Playbook

issues

  • flowed columns and flowing text around fixed elements
    • adobe webkit fork has great flow additions - but not available on devices
    • css3 template layouts – but again not supported
    • so have to measure content and cut it into positioned containers using Javascript
  • content balancing
    • always show a whole number of items across the width
    • done by classifying devices into four groups according to screen size
      • small, medium, large, large wide
  • podcast pages
    • want to keep playing audio even when move to another page
    • put audio player at the top of the DOM, so not altered
    • entire app is in a single page – just swap content in and out
  • swiping between sections
    • continuous carousel made out of three divs
    • middle one is always the current
    • outer ones are preloaded as required
    • implemented swipes using touch gestures
    • have to do your own gesture interpretation
      • distinguish between slow drags and flings

tools

  • playbook has remote web debugging
  • WeinRE can do similar, but can’t debug Javascript
  • TouchScroll allows you to keep headers fixed and snap to columns when swiping across
  • web debugging proxies (e.g. Charles)
  • use desktop for layout, but real device for interaction (swiping)

discoveries

  • people use native apps differently
    • they tap lightly and fast
    • the web browser waits for fast taps in case there’s a double tap to zoom
    • if you don’t want double tap to zoom
    • Assanka made fastclick

offline access

  • launching app offline
    • need to specify URLs in app manifest
    • if you change a single file, all of the manifest needs to be re-downloaded
    • store as little as possible
    • the more you store, the longer your app will take to launch
    • iOS manifest is buggy – you can get name conflicts with other webapps
      • so make sure you give your manifest a custom name
    • development is hell – things get cached the whole time
      • instead, add a comment that changes every minute (for dev)
      • still leaves you time to refresh a few times to check the cacheing
  • manifest is no good for editorial content
    • local storage is much faster than SQLite
    • so if you only access by key then use it
    • you need permission to store > 5Mb
    • strategy:
      • launch app from web, just store <= 5Mb and prompt to save to home screen
      • saved from home screen, immediately ask for 50Mb and never ask again
    • images downloaded from server as base64 encoded strings
      • can combine images into single requests
      • and can then gzip the whole thing
      • stored in local SQLite
      • rendered into DOM as a data: URI
      • base64 transfer also avoids operator image recompression!
  • analytics
    • can’t use Google analytics
    • log user actions into local DB
    • POST the log when requesting updated content
    • on the server, rewrite the log into an Apache format access log

unresolved issues

  • SSL security: no browser chrome, so no browser padlock
    • trusted, because we tell you…
  • Social media integration – OAuth in separate window doesn’t work
    • have to reload completely when return to app
  • offline adverts:
    • not technically hard, but ad server companies don’t know how to deal with them
    • can’t retract the ad
    • can’t measure clicks
    • can’t click through at all…
  • automated QA – selenium doesn’t really work
    • ended up using lots of people and lots of devices

platforms

  • Android is by far the poorest web environment when compared with iOS and QNX
    • mainly due to lack of hardware-accelerated CSS transitions
    • so FT have a native Android app which has a single native component – the gallery to enable swiping
    • the rest of the app is HTML/CSS/JS
  • QNX has a native app too, but only to have a home screen icon and to provide distribution

Q&A

  • upset Apple?
    • probably not – FT are specific market
  • differences between web app and native
    • web has more sections than native ever had
    • web app preloads content, so people swipe more often
    • as a result web app gets much more interaction
  • is not appearing in the app store an issue?
    • yes, but instead making tactical native apps
    • e.g. FT Top 100 Companies – tells users if you want the full edition, go to the web app

Over The Air 2011: Exploding the Gap Between Web and Native

James Hugman - Engineer at Future Platforms @jhugman

  • Web vs Native is a false dilemma
    • the answer is: it depends, or it’s both
  • often a lot of display in UI
  • story of the glastonbury app
    • Orange app for iPhone, Android and Nokia
  • three/four phases of content:
    • before (and before embargo)
    • during
    • after
  • lots of data
    • 3000 bands, 65 stages – timings could change

experimentation & research

  • assumed offline and native UI
  • but native was too expensive for three platforms
  • how do you make native in web technologies?
    • every phone has a different web view
    • Android users don’t like seeing iPhone UX
    • and Android back button can exit app if you’re not careful
    • there is no release cycle of WebKit
      • manufacturers just take the trunk and fix bugs
    • dev and cpu time spent getting UI just right
  • Titanium: write your UI in Javascript, render natively
    • ListViews either don’t look right, or leak memory
    • doesn’t always deal with latest design patterns – can’t override platform-specific behaviours
  • Impact for iOS: javascript talks to OpenGL
    • experimental & proprietary
    • morphed into appMobi’s DirectCanvas
  • game{closure}
    • pre-alpha – HTML5
    • also node.js
    • debug your mobile app and your browser app all in the same browser
  • but Game UI is not platform UI
    • easier to make cross-platform game UI as the UI is brand-specific, not platform specific
  • important to get events passing between rendering and UI logic
    • all frameworks bundle their own Javascript engine
    • Android users don’t like big apps – Titanium hello world is 6Mb!

new platform

  • Kirin requirements:
    • native, platform appropriate UIs
    • minimal download
  • design:
    • native UI
    • JS application logic
    • native platform
  • advantages:
    • raw events processed natively
    • only app-specific events passed through to app
  • “the keyhole”
    • instantiate an invisible web-view
    • build proxies for objects
    • javascript calls into native and the other way
  • modular javascript using CommonJS
    • each screen has its own module (one file each)
  • threading using asynchronous APIs, inspired by node.js
  • native-specific features available as services
    • e.g. Location, SQL, Network access
    • same Javascript to native bridge
    • JS just uses a require(...)

releasing as open source

  • available now on github
  • as a 0.5 release
  • apache license
  • looking for feedback
  • iOS and Android only at the moment (Qt coming later)
  • Windows Phone 7 might come later

Q&A

  • testing & debugging:
    • build script runs node.js
      • so can include unit tests at build time with assert
      • have console access
      • no actual debugger
  • why port model code – isn’t it simple?
    • but if using database on device, then model not so portable (Core Data doesn’t port well)
  • porting pain? scaling to iPad?
    • most of pain was electronic programme guide
    • download & syncing

Wednesday, 10 February 2010

O2 Litmus: Palm Pre Developer Event Part Two

This was the second O2 Litmus and Palm developer event in London. It was kind of hard to follow up on the first event at which all attendees got free Palm Pre’s, but they certainly did a good job. The food and beer was just as good as before and Dion and Ben know how to get developers on side.

First up was O2 with some updates on Litmus:

O2 Telefonica & Litmus

  • 7,000 customers now signed up for O2 Litmus
    • tech-savvy users willing to test new apps and provide ideas
    • To me this is the real strength of Litmus — it’s not just a developer program encouraging new apps. O2 are making use of the biggest advantage they have over a “dumb pipe” — their relationship with their customers
  • one shared mobile advertising org through whole of telefonica — starting to propose new advertising models:
    • click to call
    • click to receive an SMS
    • click to locate
    • receive an MMS with a map showing direction from where you are to the advertised location
  • developing O2 Priority Ticketing app
    • already available for iPhone
    • available on Palm in next 4-6 weeks through Litmus first
  • may open out ideas for developer community to build
    • especially around existing brands that don’t have a mobile presence
    • some private APIs may be available…

Palm Developer Evangelists

Ben Galbraith & Dion Almaer

  • app store growing fast (but linearly) since October, with slight acceleration
  • now up to 1,500 apps

Plug-in Developer Kit (PDK)

  • mechanism you can use to extend existing web environment — provides a plugin mechanism to the browser
  • will have a Flash plugin available to ship in Feb.
  • write code in C++ and have it available to the WebOS environment

Distribution

  • app data streams are available
  • visualisations appearing already:
    • Nicholas Felton — visualization guru
    • Project Appetite
      • allows you to send apps to the phone…
    • WebOS Schools
  • can get through app review in a couple of hours
    • that’s quick! where’s their team?
  • app catalog can act as intermediary, so can turn off a bad app
    • provides a quality source of apps
    • though you don’t have to go through the app store to make your app available

Editing — Project Ares

  • uses Mozilla Bespin (accent on the “e”), which Dion and Ben were involved with when they were working for Mozilla
  • enables you to drag and drop interfaces and build apps just using a browser

Incentives: Hot Apps Promotion

  • Most downloaded applications from Feb 1 to May 31
  • Separate pots for Free and Paid apps
    • Top 1: $100K
    • Top 20: $10K
    • Top 200: $1K
  • Will create a leaderboard in March
  • Can probably launch an app as late as April and still get a prize

European payment for app store

  • not here yet…
  • credit card to begin with
  • will follow up with operator billing, but can’t give any timings…
  • want to give as many options as possible to consumers
  • in-app purchases on roadmap too
  • app catalog releases may be restricted from their own purchase mechanisms to avoid confusion

Coding example

  • works a bit like rails
  • palm-generate -t hello.app <dir>
  • using palm-run wrapper script
  • can have multiple stages with multiple scenes
    • another stage might be notification stage
  • sources.json is where the first-assistant.js is loaded
  • prototype.js comes built-in
    • prototype can observe events and Mojo provides the touch events
  • can use standard media selectors to have different layouts per device
  • emulator is unable to play video
  • emulator always in charging battery mode
  • can see the source of all the Palm widgets
  • can turn on webkit inspector (palm-run -i) to dig in to any of the apps on the phone
  • although Mojo is the first attempt, you don’t have to use it — there are others… (pastrykit… :-) )

Q&A

  • push notifications?
    • Mojo messaging coming
    • provides unified mechanism for apps to work together to go to the network
    • saves battery life…
    • full multitasking with UI notifications
  • accelerated CSS transforms?
    • still coming soon…

Thursday, 12 November 2009

Apple iPhone Tech Talk London 2009: Integrating Web Content into iPhone Apps

Vicki Murley — Safari Technologies Evangelist vicki@apple.com

  • iTunes Music Store home page & GarageBand lessons are both HTML-based — included into mac apps
  • UIWebKit is not Safari — doesn’t support new windows & tabs + different memory management

Loading local resources

  • webview load: baseUrl should be initial path so that relative URLs work
  • can’t refer to local resources in remote content
    • but can have overrides in local resources

Performance optimisation

  • minimise the total number of UIWebViews
    • use AJAX
    • build views offscreen then animate them in, and delete unused
    • see examples in DashCode
  • no explicit cache control, so can’t free up memory easily
    • but can set javascript objects to null

Authentication

  • can embed in URL, e.g. http://user:password@www.example.com
  • to prompt the user, use NSUrl APIs
    • get didReceiveAuthenticationChallenge
    • can persist credentials for session

Javascript to Objective-C and back

  • evaluating javascript in Objective-C:
    • try to keep javascript simple — just a function call to a separate file
    • make sure .js files are copied, not compiled
  • can go the other way round too:
    • use Javascript to change to a custom URL (still http:// though)
    • use webview delegate: shouldStartLoadWithRequest
    • return NO to say stop processing

using images more effectively

  • be aware that file size is not memory size — especially for JPEGs
    • in memory, images are stored as pixel by pixel values — no compression at all
  • use generated images through CSS
    • CSS gradients — they support transparency too
    • CSS masks — properties analogous to background
    • can use gradients or SVG images for masks
    • CSS reflections: -webkit-box-reflect
    • again, use gradient as final parameter
  • iPhone uses Helvetica Neue for standard interface
  • make buttons using CSS:
    • round corners: 10px is about right
    • add slight shadow behind text: text-shadown: 0px 0px 8px black;
    • border at bottom: -webkit-box-shadow: 0px 2px gray;
    • white overlaying gradient
    • disable standard text behaviour:
      • -webkit-tap-highlight-color: transparent
      • -webkit-touch-callout: none
      • -webkit-user-select: none
    • also make it behave like a button when you press it
    • have an enabled and disabled backgroundColor using onTouch
  • see DashCode for other examples

  • even if you have larger resources in total, having fewer separate resources can make the page load faster

CSS transitions

  • see PosterCircle & FingerTips for examples on Apple Developer Safari site
  • can animate multiple CSS properties — just add them to the -webkit-transition-property property
  • can also adjust timing and have a transition delay
    • delay to have things appear in a staggered fashion
  • there’s also a shorthand -webkit-transition style
  • see a good example: Falling Leaves and iPhone Safari source code

CSS animation

  • define and name animation keyframes first
  • then use them in CSS properties
  • can apply multiple animations on a single style
    • each property becomes an index-based list

Local storage in SQLite

  • check availability with window.openDatabase

Wednesday, 4 November 2009

O2 Litmus: Palm Pre Mobile Web Developer Event

Tonight was a really impressive event organised by O2 Litmus. The two guys from Palm did a very good job presenting WebOS and Palm’s plans for the future. The food and drink was excellent. And they even gave us a Palm Pre each to take home! Certainly makes me want to at least try out making an app.

As usual, here’s my notes for the evening in a vaguely coherent manner…

  • webkit appearing all over the place on mobile
  • as well as opera (there were a couple of people from Opera at the event)
  • HTML 5 is providing standardisation for web applications in the same way that HTML provided standardisation for web documents
  • web applications are escaping the browser:
  • why not flash, javafx or silverlight?
  • because:
  • “When you improve things by an order of magnitude, you haven't made something better — you've made something new” — Stephen Levy
  • Palm Pre uses V8 javascript engine, just like Chrome
  • WebWorkers provide background threads
    • came from Gears worker pool
    • invented to stop database access causing hangs
  • Chrome uses WebWorkers for extensions
  • Firefox hasn’t implemented SQLite, but may go for a JSON-based database, like CouchDB
  • CSS Transforms
  • “it’s not javascript people don’t like, it’s dealing with cross-browser issues”
    • anyone mention IE…?
  • “it’s not just going to be developing apps for Palm — it’s making things for the web”

some detail

  • Mojo Framework is open-source
  • Mojo uses prototype.js at the moment, but will be made nicer to use other alternatives later
  • dashboard items and popups are just DOM items
  • want to integrate apps into system — background apps

security

  • web browser provides normal web sandbox
  • applications get access to native services
  • certain APIs still need permissions granted
    • e.g. location
    • can get app to ask when API is used
  • would like to push local APIs to browser windows
  • apps are packaged and signed
    • working with developers to encrypt apps in different ways
    • would anticipate that developers would be able to opt-in to encrypt their app
    • protect against people uploading a copy of an app as their own
    • balanced against the benefit of view source on the web

app store

  • Palm would like a “web app store” to emerge
  • Palm doesn’t feel that it’s the right company to make this move
  • creating a Palm catalogue & developer program for mid-December
    • charging $50 for each app to be in the catalogue — as a spam filter
    • money goes to funding developing programme & catalogue service
    • interested in finding other “friction points”
  • can get an immediate acceptance into the web distribution of the Palm app catalogue
    • submit and get a URL straight away
    • can email/tweet other people
    • no review process
  • opening up the backend too — feeds of all the apps and charts
  • would like digg-style rating
  • a developer can choose to make an app available for specific markets
  • also aiming to provide metrics for developers, so they can see how users are choosing or not choosing their apps
  • payment:
    • right now they have PayPal
    • would like to support several options
    • want to decrease the friction

BONDI & others

  • palm works with them
  • including W3C widgets & geo
  • Palm way will be there originally, but will be switched out when
  • order depending on developer requests
  • native-accelerated CSS transforms are higher at the moment
  • “Palm pays us, but they didn’t pay us enough to sell out”

supporting open source

  • waiving cost for anyone working open source
  • $99 for developer

testing

  • O2 Litmus will be recruiting Palm Pre users for testing availability
  • DeviceAnywhere will feature Palm Pre in O2 VDL

feedback

  • devrel@palm.com
  • they already use Jira and want to open it something to the public soon
  • homebrew community will patch things before Palm do it themselves
  • there are differing viewpoints internally…

personal usage

  • like multi-tasking
  • don’t like UI latency
    • hardware is roughly equivalent to the iPhone 3GS
    • don’t have access to hardware GPU — so CSS Transforms is really important
    • will happen with a over-the-air software upgrade

multiple devices

  • Palm Pixi seems a lot nicer
  • different screen size (80 pixels shorter)
  • should design liquid layouts…
  • the future is devices in all kinds of form factors

tooling

  • there are tools for Flash — what about tools for WebGL, etc?
  • mozilla is making tools
  • e.g. Atlas from 280North
  • this week there may be something new released…
  • should flash be a native platform for apps on Palm Pre?
    • nearly supported for web pages — Adobe has shown something working already

Saturday, 3 October 2009

OverTheAir '09: Fluid Layouting Techniques for Widget Development

Daniel Herzog

Original slides:

My notes…

  • There’s one web — “You don’t want .mobi — it wasn’t a big success”
  • widgets should be cross-platform
    • should take a small amount of space on the desktop, but be bigger (full screen) on mobile
  • Vodafone widget engine is based on Opera 9

Fonts

  • use media queries to switch to high dpi mode, e.g.
      @media all and (-o-touch) {
          a {padding: 1em}
      }
    • uses opera-specific -o-touch
  • alternative:
      @media all and (min-resolution: 200dpi) {
          body {font-size: 22px}
      }
      .myDiv {margin: 1em;}

Images

  • should use them at native resolution, loaded from server…
  • if you’re desperate, use image scaling using screen width percentages

UI-Elements

  • use dynamic images, or scalable SVG
  • SVG works across most browsers, apart from IE (but may change in 2009)
  • Google working on SVG Web — uses Flash plugin to render SVG content
    • But if widget engine doesn’t support SVG, it may not support Flash either
  • Daniel uses Illustrator to create initial SVG, then uses TextMate to hand edit it…
    • Can also use Inkscape but the UI is horrible

More resolutions…

  • Portrait & landscape, docked mode (also in portrait and landscape!)
  • Deal with these using window.resizeTo
  • Call this initially and when the orientation changes

Future

  • We’re in trouble — widget runtimes need to return real dpi/ppi values
  • Not possible at the moment since developers assume that 10pt is a certain number of pixels
  • Would be nice to have an extra CSS property for the real dpi

And another thing… zooming widgets

  • Zooming enlarges pixels — see Opera for an example
  • But SVG still scales effectively
  • Another example: WidgetCity is a widget version of Sim City!

Friday, 4 April 2008

OverTheAir: WICD -- Daniel Herzog (Vodafone)

Two profiles: WICD Full & WICD Mobile. Full gives you SVG full and full XHTML, CSS & EcmaScript.

Mobile requires EcmaScript 3rd edition Compact Mobile (no eval) as well as CSS & XHTML

Browsers that support it:

  • Opera 9.5 beta 1
  • Safari 3.1
  • Firefox 3 beta 5 (though not officially, yet)

Big feature in WICD SVG is rightsizing

  • if the browser just defines the width as a percentage
  • go ask the SVG for its aspect ratio
  • assign the height appropriately

WICD also includes media queries. These include things such as dpi which can be very useful on smaller devices. Opera will update media queries in real-time when resizing the browser window :-)

Can interact with SVG and XHTML — e.g. hover over a link and get the SVG to respond immediately; also create SVG animated circular radius over a clicked point on a google map.

SVG has Javascript within it so can encapsulate functions within. Can then address each object’s methods from javascript in the XHTML page.

SVG:

Object.prototype.myAnim = new animatorClass();

XHTML Javascript:

document.objectOfTypeMyAnim.animatorClassMethod(params)

At the moment, designers have Illustrator to create static images. Animations are harder to create. Debugging is now easier using Firebug. There’s another tool called Inkscape available for Linux, Mac & Windows. It’s getting better all the time.

Sunday, 25 November 2007

BarCamp London: First view of the new BBC home page - Richard Hodgson

This hasn’t been released yet, but was shown to us in beta form. It looks good — most people liked it — and it’s a portal style page with drag & drop customisable widgets. Here’s some of the discussion points that were raised…

People pay license fee — feel that they have a bit of ownership

Traditional media — people want reassurance of seeing some news and editorial content on the front page

Simon Willison: have you tried using Flash cookies? — doesn’t go away when clear browser cookies, also cross-browser

BBC have to support all browsers with all capabilities

Currently fixed width to 960px and centered — bbc stats show very few using 800x600 (having a JS bug that records screen size + browser width)

  • various people commenting that liquid layouts are possible (even with drag & drop widgets) but harder
  • Richard Hodgson revealed that the BBC had tried out a liquid layout (complete with the widgets) but had settled on the fixed width for the moment

Has drag and drop widgets between columns — can turn widgets on and off

Doing an iterative process — rather than usual BBC all-at-once

Part of a larger BBC initiative to get faster at designing web sites, e.g. design pattern layout

  • full grid layouts, shared by the designers

Aiming for a streaming iPlayer widget on home page, probably by July

Getting rid of grey bar across the top of all BBC pages (yey!)

The page changes the background colours of all widgets when you change to a different tab for the main content — controversial — no real point

BarCamp London: Tools I use for Front End Development - Natalie Down

TextMate to write HTML + server side

  • New From Template
  • or HTML mode then doctype tab-->

Image Editing with the GIMP or Picnik (online)

Microformats

  • nice bookmarklet available to pick them up (cross browser)

Warnings

HTML Tidy as a Firefox plugin

  • gives good warnings and has refreshable source

Webdev toolbar

  • quickest way to disable javascript
  • good for accessibility

CSS

CSSEdit

  • can group CSS styles in sidebar — uses comments in source
  • dragging and rearranging in sidebar, rearranges text in source
  • can rename group names in source; sidebar updates automatically
  • don’t really use CSSEdit preview — use Firebug instead

Squarefree

  • Test styles — pops up a separate window for adding CSS
  • Better than Firebug for changing large amounts of styles as it stays when refresh main page
  • Another one to show grey backgrounds — lighter for more heavily nested

Firebug

  • can edit layout directly in layout view
  • can grab bits in console and then click on them

Javascript

Firebug useful for checking for memory leaks

  • use Profile over a period of time

Can test out CSS class changes by hand, before you run the

YSlow — has JSLint built-in for checking poor Javascript style

Insert jQuery bookmarklet

IE Javascript debugging:

Colours

Color Schemer Studio (costs something small)

  • screen colour picker

Color Blender (meyerweb.com/eric/toold/color-blend/

Testing

Using IE in Parallels

  • can install Bonjour on Windows — automatically detects local webserver

Source control

svnX provides Tortoise-like behaviour for OS X