cleanup of binding and starting TorService
This commit is contained in:
parent
b03cd1a57f
commit
d35fb1bda2
|
@ -72,8 +72,10 @@ public class Orbot extends Activity implements OnLongClickListener, TorConstants
|
||||||
//if Tor binary is not running, then start the service up
|
//if Tor binary is not running, then start the service up
|
||||||
//might want to look at whether we need to call this every time
|
//might want to look at whether we need to call this every time
|
||||||
//or whether binding to the service is enough
|
//or whether binding to the service is enough
|
||||||
|
//bindService();
|
||||||
startService(new Intent(INTENT_TOR_SERVICE));
|
startService(new Intent(INTENT_TOR_SERVICE));
|
||||||
|
|
||||||
|
|
||||||
//something to play with on the UI branch
|
//something to play with on the UI branch
|
||||||
setTheme(android.R.style.Theme_Black_NoTitleBar);
|
setTheme(android.R.style.Theme_Black_NoTitleBar);
|
||||||
|
|
||||||
|
@ -340,7 +342,6 @@ public class Orbot extends Activity implements OnLongClickListener, TorConstants
|
||||||
|
|
||||||
bindService();
|
bindService();
|
||||||
|
|
||||||
updateStatus("");
|
|
||||||
|
|
||||||
if (getIntent() == null)
|
if (getIntent() == null)
|
||||||
return;
|
return;
|
||||||
|
@ -556,7 +557,6 @@ public class Orbot extends Activity implements OnLongClickListener, TorConstants
|
||||||
hideProgressDialog();
|
hideProgressDialog();
|
||||||
|
|
||||||
String lblMsg = getString(R.string.status_activated);
|
String lblMsg = getString(R.string.status_activated);
|
||||||
//+ "\n" + torServiceMsg;
|
|
||||||
|
|
||||||
lblStatus.setText(lblMsg);
|
lblStatus.setText(lblMsg);
|
||||||
|
|
||||||
|
@ -802,7 +802,7 @@ public class Orbot extends Activity implements OnLongClickListener, TorConstants
|
||||||
mService.registerCallback(mCallback);
|
mService.registerCallback(mCallback);
|
||||||
|
|
||||||
//again with the update status?!? :P
|
//again with the update status?!? :P
|
||||||
updateStatus("");
|
updateStatus(null);
|
||||||
|
|
||||||
if (autoStartOnBind)
|
if (autoStartOnBind)
|
||||||
{
|
{
|
||||||
|
@ -852,7 +852,6 @@ public class Orbot extends Activity implements OnLongClickListener, TorConstants
|
||||||
}
|
}
|
||||||
|
|
||||||
//unbind removes the callback, and unbinds the service
|
//unbind removes the callback, and unbinds the service
|
||||||
/*
|
|
||||||
private void unbindService ()
|
private void unbindService ()
|
||||||
{
|
{
|
||||||
if (mIsBound) {
|
if (mIsBound) {
|
||||||
|
@ -876,7 +875,7 @@ public class Orbot extends Activity implements OnLongClickListener, TorConstants
|
||||||
mIsBound = false;
|
mIsBound = false;
|
||||||
|
|
||||||
}
|
}
|
||||||
}*/
|
}
|
||||||
|
|
||||||
private void createProgressDialog (String msg)
|
private void createProgressDialog (String msg)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue