Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5be383fb authored by Ale Nijamkin's avatar Ale Nijamkin Committed by Android (Google) Code Review
Browse files

Merge "Fixes i18n issue with shortcut names." into udc-dev

parents a9868f63 18bd504b
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -52,8 +52,7 @@ constructor(
    override val key: String
        get() = BuiltInKeyguardQuickAffordanceKeys.CAMERA

    override val pickerName: String
        get() = context.getString(R.string.accessibility_camera_button)
    override fun pickerName(): String = context.getString(R.string.accessibility_camera_button)

    override val pickerIconResourceId: Int
        get() = R.drawable.ic_camera
+1 −1
Original line number Diff line number Diff line
@@ -99,7 +99,7 @@ constructor(

    override val key: String = BuiltInKeyguardQuickAffordanceKeys.DO_NOT_DISTURB

    override val pickerName: String = context.getString(R.string.quick_settings_dnd_label)
    override fun pickerName(): String = context.getString(R.string.quick_settings_dnd_label)

    override val pickerIconResourceId: Int = R.drawable.ic_do_not_disturb

+1 −2
Original line number Diff line number Diff line
@@ -75,8 +75,7 @@ constructor(
    override val key: String
        get() = BuiltInKeyguardQuickAffordanceKeys.FLASHLIGHT

    override val pickerName: String
        get() = context.getString(R.string.quick_settings_flashlight_label)
    override fun pickerName(): String = context.getString(R.string.quick_settings_flashlight_label)

    override val pickerIconResourceId: Int
        get() = R.drawable.ic_flashlight_off
+1 −1
Original line number Diff line number Diff line
@@ -54,7 +54,7 @@ constructor(

    override val key: String = BuiltInKeyguardQuickAffordanceKeys.HOME_CONTROLS

    override val pickerName: String by lazy { context.getString(component.getTileTitleId()) }
    override fun pickerName(): String = context.getString(component.getTileTitleId())

    override val pickerIconResourceId: Int by lazy { component.getTileImageId() }

+6 −2
Original line number Diff line number Diff line
@@ -31,8 +31,6 @@ interface KeyguardQuickAffordanceConfig {
    /** Unique identifier for this quick affordance. It must be globally unique. */
    val key: String

    val pickerName: String

    val pickerIconResourceId: Int

    /**
@@ -42,6 +40,12 @@ interface KeyguardQuickAffordanceConfig {
     */
    val lockScreenState: Flow<LockScreenState>

    /**
     * Returns a user-visible [String] that should be shown as the name for the option in the
     * wallpaper picker / settings app to select this quick affordance.
     */
    fun pickerName(): String

    /**
     * Returns the [PickerScreenState] representing the affordance in the settings or selector
     * experience.
Loading