[tor-commits] [orbot/master] a couple tweaks to make the long press feel more responsive

n8fr8 at torproject.org n8fr8 at torproject.org
Thu Jun 25 14:59:59 UTC 2015


commit 13d29878f92ec3b7b9176cc68c1e8eb836a0b2ce
Author: Hans-Christoph Steiner <hans at eds.org>
Date:   Tue Jun 9 17:27:01 2015 -0400

    a couple tweaks to make the long press feel more responsive
---
 src/org/torproject/android/OrbotMainActivity.java |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/org/torproject/android/OrbotMainActivity.java b/src/org/torproject/android/OrbotMainActivity.java
index c9c13b0..38d3a80 100644
--- a/src/org/torproject/android/OrbotMainActivity.java
+++ b/src/org/torproject/android/OrbotMainActivity.java
@@ -126,6 +126,7 @@ public class OrbotMainActivity extends Activity
 	}
 
     private void stopTor() {
+        imgStatus.setImageResource(R.drawable.torstarting);
         Intent torService = new Intent(this, TorService.class);
         stopService(torService);
     }
@@ -1118,7 +1119,6 @@ public class OrbotMainActivity extends Activity
     private void startTor () throws RemoteException
     {
         Log.i("OrbotMainActivity", "startTor");
-		sendIntentToService (TorServiceConstants.CMD_START);
 				
 		mTxtOrbotLog.setText("");
 
@@ -1126,6 +1126,8 @@ public class OrbotMainActivity extends Activity
         //might be best to just call updateStatus() instead of directly manipulating UI in this method - yep makes sense
         imgStatus.setImageResource(R.drawable.torstarting);
         lblStatus.setText(getString(R.string.status_starting_up));
+
+        sendIntentToService(TorServiceConstants.CMD_START);
         
         //we send a message here to the progressDialog i believe, but we can clarify that shortly
         Message msg = mStatusUpdateHandler.obtainMessage(STATUS_UPDATE);





More information about the tor-commits mailing list