How RIM handed the mobile market over to Apple