hacks.mozilla.org

a multi-touch drawing demo for Firefox 3.7

Firefox Multitouch at MozChile – Drawing Canvas Experiment from Marcio Galli on Vimeo.

A couple of months ago we featured a video that had some examples of multi-touch working in Firefox. At a recent event in South America, Marcio Galli put together a quick and fun drawing program based on the multi-touch code that we’ll have in a later release of Firefox. What’s really great is that he was able to put this together in just a couple of hours based on the web platform.

There are three main components to the touch support in Firefox:

1. Touch-based scrolling and panning for the browser. This allows you, as a user, to scroll web pages, select text, open menus, select buttons, etc. This is part of Firefox 3.6.

2. Implement a new CSS selector that will tell you if you’re on a touch-enabled device. This is -moz-system-metric(touch-enabled). You can use this in your CSS to adjust the size of UI elements to fit people’s fingers. This is part of Firefox 3.6.

3. Exposing multi-touch data to web pages. This takes the form of DOM events much like mouse events you can catch today. This isn’t part of Firefox 3.6, but is likely to be part of Firefox 3.7.

Although not all of this will be in our next release we thought it would be fun for people to see what will be possible with the release after 3.6.

Note: You can find the sample code on Marcio’s page for the demo.

13 Responses to “a multi-touch drawing demo for Firefox 3.7”


  1. 1 AndyEd

    Got a pointer to a multi-touch build for windows 7?

  2. 2 Daniel Glazman

    Uuuuurrrrrghhhh…. Who decided and who accepted that syntax…

  3. 3 Christopher Blizzard

    @Andy – looking into that. There were some builds up, I’m trying to see if there are newer ones up.

    @Daniel – yeah, we’re talking about changing it to be something more reasonable. There’s a bug open on that – I think roc had the same reaction you did. :) https://bugzilla.mozilla.org/show_bug.cgi?id=522149

  4. 4 Felipe Gomes

    @Andy, you can download the builds as a zip or installer from here:
    http://exchangecode.com/robert/work/try-a808df333211-win32.zip
    http://exchangecode.com/robert/work/try-a808df333211-win32.installer.exe

    or you can download the patch from bugzilla and recompile ( https://bugzilla.mozilla.org/show_bug.cgi?id=508906 )

    Hope that helps!
    Felipe

  5. 5 Jay Patel

    I was able to try out Marcio’s demo with my Lenovo multi-touch x200t with this build:
    http://exchangecode.com/robert/work/try-a808df333211-win32.installer.exe

  6. 6 Ryan

    I think the CSS pseudo selector would work better as a media query e.g.

    @media (-moz-touch-enabled) { }

  7. 7 Spyros

    does this multi-touch feature includes the touchpad found on modern netbooks/laptops ?

  8. 8 Linda Marroquin

    Look at this user interface for multi touch. http://www.youtube.com/watch?v=te9O8HavQpQ

  1. 1 Firefox Logo Drawn Using Firefox Itself | L&C Tech Talk
  2. 2 Firefox 3.7 multi-touch demo in the wild « Position Absolute
  3. 3 Remains of the Day: RIAA Can’t Stop BitTorrent Edition [For What It's Worth] | Superstars Of Gaming
  4. 4 用手指塗鴉畫圖 « Digital Life Coaching
  5. 5 Sarah Doherty » MozCamp Chile and Jornadas Regionales de Software Libre 2009

Leave a Reply