Resources | developer.brewmp.com Resources | developer.brewmp.com

Developer

resources

Integrate the device UI with IWallpaper

The manufacturer must integrate the device's UI with IWallpaper such that settings modified by Brew MP applications are reflected on the idle screen and any settings the user modifies through the device's settings menu are accurately exposed through the IWallpaper interface. In this section, we assume the device has the following two applications that may require integration with IWallpaper:

Idle application - For the purposes of this document, the idle application is the application on the device that is responsible for displaying the device's idle screen. We assume this application is also responsible for displaying the wallpaper.

Settings application - For the purposes of this document, the settings application is the application that is responsible for displaying the settings menu and allowing the user to configure various device settings, including wallpaper settings.

Proper integration of IWallpaper support requires integration with each of these applications.

Idle application

  • The idle application must call IWallpaper_GetWallpaper() and display the image file returned by this method as the wallpaper image.
  • The idle application must call IWallpaper_OnActiveWallpaperChange() to register an ISignal that will be set whenever there is a change to the wallpaper image setting. When the ISignal is set, the Idle application must call IWallpaper_GetWallpaper() to determine the new wallpaper setting and update the wallpaper that is displayed with the new image.
  • The idle application must call IWallpaper_ActivateType() whenever the display orientation changes. If the device supports separate configuration of portrait and landscape wallpaper images, this will trigger setting the ISignal object registered with IWallpaper_OnActiveWallpaperChange(). The idle screen will subsequently read the active wallpaper setting and update the display to show the new wallpaper.

Settings application

  • When presenting the user with a UI that allows the user to choose a wallpaper, the settings application must enumerate all valid image files from each of the directories specified in the wpDirs file.
  • When the user changes the wallpaper setting, the settings application must call IWallpaper_SetWallpaper() to set the wallpaper setting and trigger setting the ISignal object that was registered by the idle application.