1 package com.xtremelabs.robolectric.shadows; 2 3 import android.app.KeyguardManager; 4 import com.xtremelabs.robolectric.internal.Implementation; 5 import com.xtremelabs.robolectric.internal.Implements; 6 7 @Implements(KeyguardManager.KeyguardLock.class) 8 public class ShadowKeyGuardLock { 9 private boolean keyguardEnabled = true; 10 11 @Implementation disableKeyguard()12 public void disableKeyguard() { 13 keyguardEnabled = false; 14 } 15 16 @Implementation reenableKeyguard()17 public void reenableKeyguard() { 18 keyguardEnabled = true; 19 } 20 isEnabled()21 public boolean isEnabled() { 22 return keyguardEnabled; 23 } 24 } 25