Android Wallpaper example

This example is the use case of the Kanzi Android framework (droidfw) in a viewless context, specifically as the renderer of WallpaperService.

You can find the example in the <KanziWorkspace>/Examples/Android/Wallpaper directory.

Running the example

To run the example:

  1. Since this application contains only a WallpaperService and no activities, when you launch the application, it issues the error:

    Could not identify launch activity: Default Activity not found
    

    To avoid the error, in Kanzi Studio:

    1. In the Library > Build Configurations, select Wallpaper.

    2. In the Properties, set the Launch Application property to disabled.

  2. Connect your Android device to your computer.

  3. In the Kanzi Studio main menu select File > Export > Build Android Package.

    Kanzi Studio creates an Android package from your Kanzi Studio project, deploys, and runs it on your Android device.

    ../../_images/build-android-package3.png
  4. On your Android device, set the application as wallpaper. Keep in mind that this example does not show in the applications drawer of a device.

    1. Open the wallpaper settings by long-pressing anywhere on the device home screen.

    2. Go to the Live wallpapers directory and select Kanzi Wallpaper.

    3. Tap SET WALLPAPER and select the option that you want to use.

See also

Developing with the Kanzi Android framework (droidfw)

Examples