void updateConfiguration() { Configuration newConfig = getResources().getConfiguration(); if (newConfig.orientation != mCreationOrientation) { mCallback.recreateMe(newConfig); } else if (newConfig.hardKeyboardHidden != mKeyboardHidden) { mKeyboardHidden = newConfig.hardKeyboardHidden; final boolean isKeyboardOpen = mKeyboardHidden == Configuration.HARDKEYBOARDHIDDEN_NO; if (mUpdateMonitor.isKeyguardBypassEnabled() && isKeyboardOpen) { mCallback.goToUnlockScreen(); } } }
/** {@inheritDoc} */ public void cleanUp() { mUpdateMonitor.removeCallback(this); // this must be first mLockPatternUtils = null; mUpdateMonitor = null; mCallback = null; }