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

Delta Between Two Patch Sets: src/org/adblockplus/android/ConfigurationActivity.java

Issue 5697499218051072: Usage of new API, cleanups (reduced) (Closed)
Left Patch Set: Created April 11, 2014, 1:31 p.m.
Right Patch Set: Even more review issues fixed. Created April 28, 2014, 10:18 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « src/org/adblockplus/android/AndroidWebRequest.java ('k') | src/org/adblockplus/android/CrashHandler.java » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 /* 1 /*
2 * This file is part of Adblock Plus <http://adblockplus.org/>, 2 * This file is part of Adblock Plus <http://adblockplus.org/>,
3 * Copyright (C) 2006-2014 Eyeo GmbH 3 * Copyright (C) 2006-2014 Eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 18 matching lines...) Expand all
29 * Displays configuration warning message. 29 * Displays configuration warning message.
30 */ 30 */
31 public class ConfigurationActivity extends Activity 31 public class ConfigurationActivity extends Activity
32 { 32 {
33 private int port; 33 private int port;
34 34
35 @Override 35 @Override
36 public void onCreate(final Bundle savedInstanceState) 36 public void onCreate(final Bundle savedInstanceState)
37 { 37 {
38 super.onCreate(savedInstanceState); 38 super.onCreate(savedInstanceState);
39 this.setContentView(R.layout.configuration); 39 setContentView(R.layout.configuration);
40 this.port = this.getIntent().getIntExtra("port", 0); 40 port = getIntent().getIntExtra("port", 0);
41 final String msg1 = this.getString(R.string.msg_notraffic); 41 final String msg1 = getString(R.string.msg_notraffic);
42 final String msg2 = this.getString(R.string.msg_configuration); 42 final String msg2 = getString(R.string.msg_configuration);
43 ((TextView)this.findViewById(R.id.message_text)).setText(Html.fromHtml(msg1 + " " + msg2)); 43 ((TextView) findViewById(R.id.message_text)).setText(Html.fromHtml(msg1 + " " + msg2));
44 } 44 }
45 45
46 public void onOk(final View view) 46 public void onOk(final View view)
47 { 47 {
48 this.finish(); 48 finish();
49 } 49 }
50 50
51 public void onHelp(final View view) 51 public void onHelp(final View view)
52 { 52 {
53 final Intent intent; 53 final Intent intent;
54 if (ProxyService.NATIVE_PROXY_SUPPORTED) 54 if (ProxyService.NATIVE_PROXY_SUPPORTED)
55 { 55 {
56 intent = new Intent(this, ProxyConfigurationActivity.class).putExtra("port ", this.port); 56 intent = new Intent(this, ProxyConfigurationActivity.class).putExtra("port ", port);
57 } 57 }
58 else 58 else
59 { 59 {
60 final Uri uri = Uri.parse(this.getString(R.string.configuring_proxy_url)); 60 final Uri uri = Uri.parse(getString(R.string.configuring_proxy_url));
61 intent = new Intent(Intent.ACTION_VIEW, uri); 61 intent = new Intent(Intent.ACTION_VIEW, uri);
62 } 62 }
63 this.startActivity(intent); 63 startActivity(intent);
64 this.finish(); 64 finish();
65 } 65 }
66 } 66 }
LEFTRIGHT

Powered by Google App Engine
This is Rietveld