Update Settings app to manipulate now-global settings properly

Change-Id: I6c269051c7d2db87f70f44df74e06456588c3b6f
This commit is contained in:
Christopher Tate
2012-09-07 13:35:31 -07:00
parent 96c2f8c508
commit 5a64c739bf
5 changed files with 30 additions and 30 deletions

View File

@@ -229,13 +229,13 @@ public class SecuritySettings extends SettingsPreferenceFragment
}
private boolean isNonMarketAppsAllowed() {
return Settings.Secure.getInt(getContentResolver(),
Settings.Secure.INSTALL_NON_MARKET_APPS, 0) > 0;
return Settings.Global.getInt(getContentResolver(),
Settings.Global.INSTALL_NON_MARKET_APPS, 0) > 0;
}
private void setNonMarketAppsAllowed(boolean enabled) {
// Change the system setting
Settings.Secure.putInt(getContentResolver(), Settings.Secure.INSTALL_NON_MARKET_APPS,
Settings.Global.putInt(getContentResolver(), Settings.Global.INSTALL_NON_MARKET_APPS,
enabled ? 1 : 0);
}