allow auto start in non-root mode
This commit is contained in:
@@ -232,7 +232,7 @@ object Shadowsocks {
|
||||
if (pref != null) {
|
||||
val status = getActivity.getSharedPreferences(Key.status, Context.MODE_PRIVATE)
|
||||
val isRoot = status.getBoolean(Key.isRoot, false)
|
||||
if (Seq(Key.isAutoConnect, Key.isGlobalProxy, Key.isTrafficStat, Key.proxyedApps)
|
||||
if (Seq(Key.isGlobalProxy, Key.isTrafficStat, Key.proxyedApps)
|
||||
.contains(name)) {
|
||||
pref.setEnabled(enabled && isRoot)
|
||||
} else {
|
||||
@@ -855,7 +855,7 @@ class Shadowsocks
|
||||
for (name <- Shadowsocks.FEATRUE_PREFS) {
|
||||
val pref = findPreference(name)
|
||||
if (pref != null) {
|
||||
if (Seq(Key.isAutoConnect, Key.isGlobalProxy, Key.isTrafficStat, Key.proxyedApps)
|
||||
if (Seq(Key.isGlobalProxy, Key.isTrafficStat, Key.proxyedApps)
|
||||
.contains(name)) {
|
||||
pref.setEnabled(enabled && isRoot)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user