Renamed Rate graph code

This commit is contained in:
str4d
2013-11-08 19:41:17 +00:00
parent a057e4a512
commit b6d6258e95
3 changed files with 7 additions and 7 deletions

View File

@ -156,7 +156,7 @@ public abstract class I2PActivityBase extends ActionBarActivity implements
startActivity(log);
break;
case 4:
Intent active = new Intent(I2PActivityBase.this, GraphActivity.class);
Intent active = new Intent(I2PActivityBase.this, RateGraphActivity.class);
startActivity(active);
break;
case 5:

View File

@ -5,7 +5,7 @@ import java.util.List;
import java.util.TreeSet;
import net.i2p.android.router.R;
import net.i2p.android.router.fragment.GraphFragment;
import net.i2p.android.router.fragment.RateGraphFragment;
import net.i2p.android.router.service.StatSummarizer;
import net.i2p.android.router.service.SummaryListener;
import net.i2p.stat.Rate;
@ -18,7 +18,7 @@ import android.support.v7.app.ActionBar;
import android.widget.ArrayAdapter;
import android.widget.SpinnerAdapter;
public class GraphActivity extends I2PActivityBase {
public class RateGraphActivity extends I2PActivityBase {
private static final String SELECTED_RATE = "selected_rate";
@Override
@ -56,7 +56,7 @@ public class GraphActivity extends I2PActivityBase {
public boolean onNavigationItemSelected(int position, long itemId) {
String rateName = rates[position];
long period = periods[position];
GraphFragment f = GraphFragment.newInstance(rateName, period);
RateGraphFragment f = RateGraphFragment.newInstance(rateName, period);
getSupportFragmentManager().beginTransaction()
.replace(R.id.main_fragment, f, rates[position]).commit();
return true;

View File

@ -24,7 +24,7 @@ import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
public class GraphFragment extends I2PFragmentBase {
public class RateGraphFragment extends I2PFragmentBase {
// redraws a plot whenever an update is received:
private class MyPlotUpdater implements Observer {
Plot plot;
@ -48,8 +48,8 @@ public class GraphFragment extends I2PFragmentBase {
private XYPlot _ratePlot;
private MyPlotUpdater _plotUpdater;
public static GraphFragment newInstance(String name, long period) {
GraphFragment f = new GraphFragment();
public static RateGraphFragment newInstance(String name, long period) {
RateGraphFragment f = new RateGraphFragment();
Bundle args = new Bundle();
args.putString(RATE_NAME, name);
args.putLong(RATE_PERIOD, period);