Hidden among the other news announced at Google I/O today, Google has also added the ability for developers to use the Google Maps API directly on Android Wear. The feature, which comes as part of Play Services 7.5, aims to offer users a wearable-designed Google Maps experience and was detailed in a blog post.

Samsung U28E590D 28-Inch 4K Monitor

Google says that the Maps API on Android Wear is very similar to the Maps API on Android, which should ensure that developers are comfortable with the platform. Google also notes that Maps API keys are interchangeable between mobile apps and Wear apps, as long as they share the same package name.

Google has made several enhancements to the Maps API to ensure that it’s fully functional on Android Wear. For instance, Maps on Android Wear has a variety of capabilities, including finding the nearest coffee shop, giving directions, tracking fitness activity, and more.

Google has also ensured that the way users exit Maps-based applications on Android Wear is seamless.

On Android Wear, users can usually exit an application if they swipe from left to right. If you don’t need to include an interactive map, this swipe-to-dismiss approach should work for your app too. However, if you want to allow the user to pan the map in any direction, the maps component will automatically disable the swipe-to-dismiss gesture and your application will need to handle how users will exit the application. The recommended approach is to implement the standard long-press-to-dismiss gesture. Using the Android Wear support library, this is quite simple.

More details are available in Google’s official announcement post and in the video below. If you are a developer, be sure to check them both out.

About the Author