// If the key guard has been displayed, exit this activity. This returns
// us to the login page requiring the user to enter his password again
// before getting access again to his secrets.
KeyguardManager key_guard = (KeyguardManager) getSystemService(
KEYGUARD_SERVICE);
boolean isInputRestricted = key_guard.inKeyguardRestrictedInputMode();
if (isInputRestricted) {
Log.d(LOG_TAG, "SecretsListActivity.checkKeyguard finishing");
finish();
}