1 /* 2 * Copyright (C) 2024 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package com.android.systemui.screenshot.resources 18 19 import android.content.Context 20 import androidx.annotation.OpenForTesting 21 import com.android.systemui.dagger.SysUISingleton 22 import com.android.systemui.res.R 23 import javax.inject.Inject 24 25 /** String values from resources, for easy injection. */ 26 @OpenForTesting 27 @SysUISingleton 28 open class Messages @Inject constructor(private val context: Context) { <lambda>null29 open val savingScreenshotAnnouncement by lazy { 30 requireNotNull(context.resources.getString(R.string.screenshot_saving_title)) 31 } 32 <lambda>null33 open val savingToWorkProfileAnnouncement by lazy { 34 requireNotNull(context.resources.getString(R.string.screenshot_saving_work_profile_title)) 35 } 36 <lambda>null37 open val savingToPrivateProfileAnnouncement by lazy { 38 requireNotNull(context.resources.getString(R.string.screenshot_saving_private_profile)) 39 } 40 } 41