Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: src/org/adblockplus/android/ConfigurationActivity.java

Issue 8493083: ABP/Android UI (Closed)
Patch Set: ABP/Android UI Created Oct. 12, 2012, 1:24 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/org/adblockplus/android/ConfigurationActivity.java
===================================================================
new file mode 100644
--- /dev/null
+++ b/src/org/adblockplus/android/ConfigurationActivity.java
@@ -0,0 +1,38 @@
+package org.adblockplus.android;
+
+import android.app.Activity;
+import android.content.Intent;
+import android.net.Uri;
+import android.os.Bundle;
+import android.view.View;
+import android.widget.TextView;
+
+/**
+ * Displays configuration warning message.
+ */
+public class ConfigurationActivity extends Activity
+{
+ @Override
+ public void onCreate(Bundle savedInstanceState)
+ {
+ super.onCreate(savedInstanceState);
+ setContentView(R.layout.configuration);
+ int 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);
+ }
+
+ public void onOk(View view)
+ {
+ finish();
+ }
+
+ public void onHelp(View view)
+ {
+ Uri uri = Uri.parse(getString(R.string.configuring_proxy_url));
+ final Intent intent = new Intent(Intent.ACTION_VIEW, uri);
+ startActivity(intent);
+ finish();
+ }
+}
« no previous file with comments | « src/org/adblockplus/android/BootBroadcastReceiver.java ('k') | src/org/adblockplus/android/Preferences.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld