• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2020 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.tv.settings.accounts;
18 
19 import static com.android.tv.settings.overlay.FlavorUtils.X_EXPERIENCE_FLAVORS_MASK;
20 
21 import android.text.TextUtils;
22 
23 import com.android.tv.settings.R;
24 import com.android.tv.settings.slice.SliceActivity;
25 
26 /** Activity for showing users services settings. */
27 public class ManageUserServicesSliceActivity extends SliceActivity {
28     private static final String KEY_USER_ID = "userId";
29 
30     @Override
getSliceUri()31     public String getSliceUri() {
32         String id = getIntent().getStringExtra(KEY_USER_ID);
33         return TextUtils.isEmpty(id)
34                 ? null
35                 : getString(R.string.manage_user_services_slice_uri, id);
36     }
37 
38     @Override
getScreenTitle()39     public String getScreenTitle() {
40         return getString(R.string.manage_user_services_slice_title);
41     }
42 
43     @Override
getAvailableFlavors()44     protected int getAvailableFlavors() {
45         return X_EXPERIENCE_FLAVORS_MASK;
46     }
47 }
48