Platform Actions

Custom Intents Platform Actions are specialized actions that are specific to the BlueFletch Launcher and can be used in addition to standard Android intents.

Supported Actions

The following is a complete list of the Platform Actions supported by Launcher with configuration examples.

  • Delay

  • Clear Cache

  • Enable/Disable Package

  • Delete Files

  • Mute/Unmute/Adjust Audio

  • Applying Platform XML

  • Login

  • Rotate Launcher to Portrait/Landscape Mode

  • Clear Storage

Delay

This is a unique Platform action. It is custom to BlueFletch Launcher, but it uses the typeIntent d.

To delay executing further intents for a set period of time, use a delay intent, with the time to delay set as "data" in milliseconds.

{
    "typeIntent": "d",
    "data": "5000"
}

Clear Cache

An action value of CLEARCACHE will cause Launcher to invoke the Platform Clear Cache on the specified package.

{
    "action": "CLEARCACHE",
    "package": "com.android.chrome",
    "typeIntent": "p"
}

Enable a Package

An action value of ENABLE will cause the specified package to be enabled.

{
    "action": "ENABLE",
    "typeIntent": "p",
    "package" : "com.some.package"
}

Disable a Package

An action value of DISABLE will cause the specified package to be disabled.

{
    "action": "DISABLE",
    "typeIntent": "p",
    "package" : "com.some.package"
}

Delete Files

An action value of DELETE_FILES will delete the file(s) at the specified path as specified in the "data" field. This action does support the wildcard operator * which allows for multiple files to be deleted.

{
    "action": "DELETE_FILES",
    "typeIntent": "p",
    "data": "/sdcard/Download/*.pdf"
}

Mute Audio

An action value of MUTE_AUDIO will cause the audio on a device to be muted. This does not affect 'Alarm' audio.

{
    "action": "MUTE_AUDIO",
    "typeIntent": "p"
}

Unmute Audio

An action value of UNMUTE_AUDIO will cause the audio on a device to be unmuted. This does not affect 'Alarm' audio.

{
    "action": "UNMUTE_AUDIO",
    "typeIntent": "p"
}

Adjust Audio

An action value of ADJUST_AUDIO will cause the audio on a device to be changed and allows for specifying the percentage of max audio per type of audio. The individual audio stream to affect should be specified within the "extras" section.

Valid "extras":

  • notification: Affects the volume of audio streams for notification sounds.

  • music: Affects the volume of audio streams for music playback.

  • ring: Affects the volume of audio streams for the phone ring.

  • system: Affects the volume of audio streams for system sounds.

  • dtm: Affects the volume of audio streams for DTMF Tones.

  • call: Affects the volume of audio streams for phone calls.

  • alarm: Affects identify the volume of audio streams for alarms.

  • others: A special override that when used, can affect any audio stream not specified within the extras.

{
    "action": "ADJUST_AUDIO",
    "typeIntent": "p",
    "extras" : {
        "notification": 90,
        "alarm": 100,
        "others": 50
    }
}

Applying Platform XML

The action XML allows for invoking platform-specific XML (currently supports the Zebra platform's StageNow™ XML tooling). Use the "data" field to specify the XML file location, either located on the device sdcard or managed within Launcher assets.

This example is retrieving the XML file from the /sdcard/... local file path:

{
    "action": "XML",
    "typeIntent": "p",
    "data": "/sdcard/Download/ems/gloveInput.xml"
}

This example is using the Assets Manager to download/manage the XML file:

{
    "action": "XML",
    "typeIntent": "p",
    "data": "assets:stylusInput"
}

Login

Using an action value of LOGIN allows for controlling when Launcher starts the device login flow.

{
    "action": "LOGIN",
    "typeIntent": "p"
}

Available in Launcher 3.7.7

Rotate Launcher to Portrait Mode

An action value of com.bluefletch.launcher.ACTION_ROTATE_PORTRAIT will force rotation of the Launcher Home screen to portrait mode.

{
    "action": "com.bluefletch.launcher.ACTION_ROTATE_PORTRAIT",
    "typeIntent": "p"
}

Available in Launcher 3.21.17.

Rotate Launcher to Landscape Mode

An action value of com.bluefletch.launcher.ACTION_ROTATE_LANDSCAPE will force rotation of the Launcher Home screen to landscape mode.

{
    "action": "com.bluefletch.launcher.ACTION_ROTATE_LANDSCAPE",
    "typeIntent": "p"
}

Available in Launcher 3.21.17.

Clear Storage

An action value of CLEAR_STORAGE will clear all cache and user data to which the OEM's SDK has access. Applying via the logout or postLogout array will usually (dependent on the app vendor) clear all user data for that app from the prior session.

{
    "action": "CLEAR_STORAGE",
    "package": "com.example.package",
    "typeIntent": "p"
}

Available in Launcher 3.24.20.

Last updated