1 /* 2 * Copyright (C) 2017 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.settings.development.qstile; 18 19 import android.content.Context; 20 21 import com.android.internal.logging.nano.MetricsProto; 22 import com.android.settings.R; 23 import com.android.settings.dashboard.DashboardFragment; 24 import com.android.settingslib.core.AbstractPreferenceController; 25 26 import java.util.ArrayList; 27 import java.util.List; 28 29 public class DevelopmentTileConfigFragment extends DashboardFragment { 30 private static final String TAG = "DevelopmentTileConfig"; 31 32 @Override getLogTag()33 protected String getLogTag() { 34 return TAG; 35 } 36 37 @Override getPreferenceScreenResId()38 protected int getPreferenceScreenResId() { 39 return R.xml.development_tile_settings; 40 } 41 42 @Override createPreferenceControllers(Context context)43 protected List<AbstractPreferenceController> createPreferenceControllers(Context context) { 44 final List<AbstractPreferenceController> controllers = new ArrayList<>(); 45 controllers.add(new DevelopmentTilePreferenceController(context)); 46 return controllers; 47 } 48 49 @Override getMetricsCategory()50 public int getMetricsCategory() { 51 return MetricsProto.MetricsEvent.DEVELOPMENT_QS_TILE_CONFIG; 52 } 53 } 54