SubSettings.java revision a677ee210c67d13d15ba0663887675bda16354d8
1a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn/* 2a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * Copyright (C) 2011 The Android Open Source Project 3a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * 4a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * Licensed under the Apache License, Version 2.0 (the "License"); 5a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * you may not use this file except in compliance with the License. 6a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * You may obtain a copy of the License at 7a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * 8a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * http://www.apache.org/licenses/LICENSE-2.0 9a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * 10a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * Unless required by applicable law or agreed to in writing, software 11a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * distributed under the License is distributed on an "AS IS" BASIS, 12a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * See the License for the specific language governing permissions and 14a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * limitations under the License. 15a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn */ 16a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn 17a9d11a8593fdc179698ef3b975319903752e262cDianne Hackbornpackage com.android.settings; 18a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn 19a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasaniimport android.app.Fragment; 20a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasaniimport android.util.Log; 21a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasani 22a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasaniimport com.android.settings.ChooseLockGeneric.ChooseLockGenericFragment; 23a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasani 24a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn/** 25a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * Stub class for showing sub-settings; we can't use the main Settings class 26a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn * since for our app it is a special singleTask class. 27a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn */ 28a9d11a8593fdc179698ef3b975319903752e262cDianne Hackbornpublic class SubSettings extends Settings { 293d384f4ca29d031f7ac3c7f0cc0a2f448a277097Amith Yamasani 303d384f4ca29d031f7ac3c7f0cc0a2f448a277097Amith Yamasani @Override 313d384f4ca29d031f7ac3c7f0cc0a2f448a277097Amith Yamasani public boolean onNavigateUp() { 323d384f4ca29d031f7ac3c7f0cc0a2f448a277097Amith Yamasani finish(); 333d384f4ca29d031f7ac3c7f0cc0a2f448a277097Amith Yamasani return true; 343d384f4ca29d031f7ac3c7f0cc0a2f448a277097Amith Yamasani } 35a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasani 36a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasani @Override 37a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasani protected boolean isValidFragment(String fragmentName) { 38a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasani Log.d("SubSettings", "Launching fragment " + fragmentName); 39a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasani return true; 40a677ee210c67d13d15ba0663887675bda16354d8Amith Yamasani } 41a9d11a8593fdc179698ef3b975319903752e262cDianne Hackborn} 42