Expand Minimize Picture-in-picture Power Device Status Voice Recognition Skip Back Skip Forward Minus Plus Play Search
Documentation
Sidebar

Class LockScreenConfig

Hierarchy

java.lang.Object

Package
com.smartdevicelink.managers.lockscreen

Overview

LockScreenConfig
This is set during SdlManager instantiation.
  • enable - if false, don't worry about the other parameters. You are responsible for creating and managing a lockscreen. If true, also set the backgroundColor and appIcon if you want. If you don't set the backgroundColor or appIcon, it will use the defaults.
  • backgroundColor - if using the default lockscreen, you can set this to a color of your choosing
  • appIcon - if using the default lockscreen, you can set your own app icon
  • customView - If you would like to provide your own view, you can pass it in here.
  • Constructors

    LockScreenConfig()

    public LockScreenConfig()
    

    Methods

    setEnabled( boolean enable )

    If set to true, SDL will manage the showing and dismissing of the lock screen for you.
    If false, you must manage the lock screen

    public void setEnabled(boolean enable)
    

    Parameters

    enable
    boolean

    isEnabled()

    Gets whether the lock screen is being managed for you

    public boolean isEnabled()
    

    setBackgroundColor( int resourceColor )

    Set the resource int of the background color. Colors should define colors in your Colors.xml file

    public void setBackgroundColor(int resourceColor)
    

    Parameters

    resourceColor
    resource int of the color

    getBackgroundColor()

    Gets the int reference to the custom lock screen background color

    public int getBackgroundColor()
    

    setAppIcon( int appIconInt )

    int of the drawable icon.

    public void setAppIcon(int appIconInt)
    

    Parameters

    appIconInt
    the drawable of the icon to be displayed on the lock screen

    getAppIcon()

    Gets the resource reference of the icon to be displayed on the lock screen

    public int getAppIcon()
    

    setCustomView( int customViewInt )

    Sets the reference to the custom layout to be used for the lock screen
    If set, the color and icon setters will be ignored

    public void setCustomView(int customViewInt)
    

    Parameters

    customViewInt
    the layout

    getCustomView()

    Gets the reference to the custom lockscreen layout to be used

    public int getCustomView()
    

    showDeviceLogo( boolean deviceLogo )

    Whether or not to show the device's logo on the default lock screen
    The logo will come from the connected hardware, if set by the manufacturer
    If using a Custom View, this will be ignored.

    public void showDeviceLogo(boolean deviceLogo)
    

    Parameters

    deviceLogo
    - boolean

    isDeviceLogoEnabled()

    Get whether or not the device's Logo is shown on the default lock screen
    The logo will come from the connected hardware, if set by the manufacturer

    public boolean isDeviceLogoEnabled()
    

    Inherited Methods

    From Class Methods
    java.lang.Object getClass, hashCode, equals, clone, toString, notify, notifyAll, wait, wait, wait, finalize
    View on GitHub.com
    Previous Section Next Section