Use single WebkitProxy reset method
This commit is contained in:
parent
c39a835dc2
commit
29d2a5f3e5
@ -163,19 +163,12 @@ public class ProxyUtils {
|
||||
if (mPreferences.getUseProxy()) {
|
||||
initializeProxy(activity);
|
||||
} else {
|
||||
if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.KITKAT_WATCH) {
|
||||
try {
|
||||
WebkitProxy.resetProxy(BrowserApp.class.getName(), activity.getApplicationContext());
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
} else {
|
||||
try {
|
||||
WebkitProxy.resetLollipopProxy(BrowserApp.class.getName(), activity.getApplicationContext());
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
try {
|
||||
WebkitProxy.resetProxy(BrowserApp.class.getName(), activity.getApplicationContext());
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
mI2PProxyInitialized = false;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user