Index: src/org/adblockplus/android/ConfigurationActivity.java |
=================================================================== |
--- a/src/org/adblockplus/android/ConfigurationActivity.java |
+++ b/src/org/adblockplus/android/ConfigurationActivity.java |
@@ -21,6 +21,7 @@ |
import android.content.Intent; |
import android.net.Uri; |
import android.os.Bundle; |
+import android.text.Html; |
import android.view.View; |
import android.widget.TextView; |
@@ -29,15 +30,17 @@ |
*/ |
public class ConfigurationActivity extends Activity |
{ |
+ private int port; |
+ |
@Override |
public void onCreate(Bundle savedInstanceState) |
{ |
super.onCreate(savedInstanceState); |
setContentView(R.layout.configuration); |
- int port = getIntent().getIntExtra("port", 0); |
+ port = getIntent().getIntExtra("port", 0); |
String msg1 = getString(R.string.msg_notraffic); |
String msg2 = getString(R.string.msg_configuration, port); |
- ((TextView) findViewById(R.id.message_text)).setText(msg1 + " " + msg2); |
+ ((TextView) findViewById(R.id.message_text)).setText(Html.fromHtml(msg1 + " " + msg2)); |
} |
public void onOk(View view) |
@@ -47,8 +50,16 @@ |
public void onHelp(View view) |
{ |
- Uri uri = Uri.parse(getString(R.string.configuring_proxy_url)); |
- final Intent intent = new Intent(Intent.ACTION_VIEW, uri); |
+ Intent intent; |
+ if (ProxyService.hasNativeProxy) |
+ { |
+ intent = new Intent(this, ProxyConfigurationActivity.class).putExtra("port", port); |
+ } |
+ else |
+ { |
+ Uri uri = Uri.parse(getString(R.string.configuring_proxy_url)); |
+ intent = new Intent(Intent.ACTION_VIEW, uri); |
+ } |
startActivity(intent); |
finish(); |
} |