Rabble.rule: Detecting a swipe in WebKit

Thanks for this, it’s nice and simple but works!

One thing though. I have a site where I want the user to be able to swipe left/right to move between articles, but swiping up down should use the default scrolling action. (It’s probably easier to see than describe.)

This seems to work fine on an iPad, but on my iPhone 3G the vertical scrolling ends up being very jerky. Something is interrupting the default action from happening, but I can’t work out what to tweak to fix this. Any ideas?

22 Jun 2010 at Twitter

  • 8:56pm: Upgraded from WordPress 2.9 to 3.0 with one click. Lovely. Have put off upgrading Movable Type by 0.01 for a month because of the hassle.
  • 5:13pm: Blimey, Screen on the Green has got a lot more plush since I was last here. Also, am only person in cinema. Fear I am looked at as a psycho.
  • 5:07pm: Another sunny day, but grumpy again. So, lemon tart in the sun followed by a movie about a cold-blooded, violent killer. Hmm.
  • 4:19pm: @tomcoates Is there going to be a second series?
  • 3:54pm: @ianbetteridge Then STOP READING THEM! :)
  • 3:17pm: @scottm Thanks for the confirmation. I've tried so many things, with no joy. Maybe it is iOS4...
  • 1:51pm: @revdancatt Hmm, must be some CSS issue as your viewport setting doesn't even do what I'd want in Safari for my site. Ta.
  • 1:14pm: @danhon Seems like it, but I've no idea why the viewport setting doesn't seem to apply when run from the Home screen.
  • 12:59pm: On iPhone, http://guardian.gyford.com/ looks OK in Safari, but is zoomed in when saved to Home screen and run. Can't see why. Anyone know?
  • 12:55pm: @spaceboy Worked on my 3G after a few hours of patience.
  • 10:15am: @infovore Same here with my iPhone backup. Race you!
  • 8:50am: Stopped on the way to the office to play on the piano in Bunhill Fields. Cheered me up. Going to bring some sheet music next time.

Music listened to most that week

  1. Kode9 (8)
  2. Digital Mystikz (6)
  3. Aardvarck (5)
  4. Zomby (4)
  5. Alton Ellis (4)
  6. Sticky (4)
  7. Burning Spear (4)
  8. Terror Danjah (4)
  9. Camera Obscura (3)
  10. Junior Delgado (3)

More at Last.fm...