Settings.Secure.DEFAULT_INPUT_METHOD), false, this,
UserHandle.USER_ALL);
resolver.registerContentObserver(Settings.System.getUriFor(
- "fancy_rotation_anim"), false, this,
+ OverlayTesting.ENABLED_SETTING), false, this,
UserHandle.USER_ALL);
updateSettings();
}
}
@Override
public void onDebug() {
- if (OverlayTesting.ENABLED) {
+ if (OverlayTesting.enabled) {
OverlayTesting.toggleForceOverlay(mFocusedWindow, mContext);
}
}
mHasSoftInput = hasSoftInput;
updateRotation = true;
}
+ OverlayTesting.enabled = Settings.System.getIntForUser(resolver,
+ OverlayTesting.ENABLED_SETTING, 0, UserHandle.USER_CURRENT) != 0;
}
if (updateRotation) {
updateRotation(true);
}
private int updateHideybarsLw(int tmpVisibility) {
- if (OverlayTesting.ENABLED) {
+ if (OverlayTesting.enabled) {
tmpVisibility = OverlayTesting.applyForced(mFocusedWindow, tmpVisibility);
}
boolean statusBarHasFocus =
// TODO temporary helper that allows testing overlay bars on existing apps
private static final class OverlayTesting {
- static final boolean ENABLED = true;
+ static String ENABLED_SETTING = "overlay_testing_enabled";
+ static boolean enabled = false;
private static final HashSet<String> sForced = new HashSet<String>();
private static String parseActivity(WindowState win) {