Introducing Remote Views and the App Widget Manager

The RemoteViews class is used to describe and manipulate a View hierarchy that's hosted within another application process. This lets you change a property, or run a method, on a View running as part of another application.

For example, the Views within App Widgets are hosted within a separate process (generally the home screen), so Remote Views can be used to modify the widget UI from the Intent Receiver running within your application.

The AppWidgetManager is used to update App Widgets and provide details related to them.

Using Remote Views with the App Widget Manager, you can modify the appearance of the Views supported by the App Widget framework. Among other things, you can change the visibility, text, or image values, and add click listeners.

This section describes how to create new Remote Views from within and without the onUpdate method of an App Widget Provider. It also demonstrates how to use Remote Views to update widget UI and add interactivity to your widgets.

Was this article helpful?

0 0
Mobile Apps Made Easy

Mobile Apps Made Easy

Quick start guide to skyrocket your offline and online business success with mobile apps. If you know anything about mobile devices, you’ve probably heard that famous phrase coined by one of the mobile device’s most prolific creators proclaiming that there’s an app for pretty much everything.

Get My Free Training Guide

Post a comment