"Allow Background Starts" prefs also controls the old START_TOR Intent
This commit is contained in:
parent
adf7c09f0e
commit
943edf094b
|
@ -554,9 +554,10 @@ public class OrbotMainActivity extends Activity
|
||||||
.setNegativeButton("Deny", dialogClickListener).show();
|
.setNegativeButton("Deny", dialogClickListener).show();
|
||||||
|
|
||||||
return; //don't null the setIntent() as we need it later
|
return; //don't null the setIntent() as we need it later
|
||||||
}
|
}
|
||||||
else if (action.equals("org.torproject.android.START_TOR"))
|
else if (action.equals("org.torproject.android.START_TOR")
|
||||||
{
|
&& Prefs.allowBackgroundStarts())
|
||||||
|
{
|
||||||
autoStartFromIntent = true;
|
autoStartFromIntent = true;
|
||||||
try {
|
try {
|
||||||
startTor();
|
startTor();
|
||||||
|
@ -569,7 +570,6 @@ public class OrbotMainActivity extends Activity
|
||||||
}
|
}
|
||||||
resultIntent.putExtra(TorServiceConstants.EXTRA_STATUS, torStatus);
|
resultIntent.putExtra(TorServiceConstants.EXTRA_STATUS, torStatus);
|
||||||
setResult(RESULT_OK, resultIntent);
|
setResult(RESULT_OK, resultIntent);
|
||||||
finish();
|
|
||||||
} catch (RemoteException e) {
|
} catch (RemoteException e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue