title: multiple countdowns starting at oncewith no end
body: <p><strong>First Problem:</strong> <br>I have 4 Countdowns(which start from different values) that should start when i click on the imageview next to them. But the problem is, when i click the first picture, all 4 countdowns start; when i click the second picture, the second, third and fourth countdowns start and so on.<br>I think I've done something wrong in my switch case but it doesn't show any errors and I can't find the mistake.<br>
  <br><strong>Second Problem:</strong><br>
  When i click the "new game" button, all timers should stop and become 0 but when i click the timers start again and show their old remaining time and the new remaining time.<br>
  <strong>Code:</strong></p>
  
  <pre><code>public class TimerActivity extends Activity implements
      android.view.View.OnClickListener {
  private CountDownTimer countDownTimer;
  private Button button_new_fight;
  public TextView textviewRed;
  public TextView textviewBlue;
  public TextView textviewDragon;
  public TextView textviewBaron;
  public TextView tv;
  public ImageView imageviewRed;
  public ImageView imageviewBlue;
  public ImageView imageviewDragon;
  public ImageView imageviewBaron;
  private boolean timerRedStarted;
  private boolean timerBlueStarted;
  private boolean timerDragonStarted;
  private boolean timerBaronStarted;
  private final long startTimeRed = 300000;
  private final long startTimeBlue = 300000;
  private final long startTimeDragon = 360000;
  private final long startTimeBaron = 420000;
  private final long interval = 1000;
  
  @Override
  public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.timer_layout);
      //binding content to these attributes to work with them
      button_new_fight = (Button) this.findViewById(R.id.button1);
      button_new_fight.setOnClickListener(this);
      textviewRed = (TextView) this.findViewById(R.id.textViewRedTime);
      textviewBlue = (TextView) this.findViewById(R.id.TextViewBlueTimeLeft);
      textviewDragon = (TextView) this.findViewById(R.id.TextViewDragonTimeLeft);
      textviewBaron = (TextView) this.findViewById(R.id.TextViewBaronTimeLeft);
  
      //binding this.imageviews to those of timer_layout.xml
      imageviewRed = (ImageView) this.findViewById(R.id.imageView1);
      imageviewRed.setOnClickListener(this);
      imageviewBlue = (ImageView) this.findViewById(R.id.imageView2);
      imageviewBlue.setOnClickListener(this);
      imageviewDragon = (ImageView) this.findViewById(R.id.imageView3);
      imageviewDragon.setOnClickListener(this);
      imageviewBaron = (ImageView) this.findViewById(R.id.imageView4);
      imageviewBaron.setOnClickListener(this);
  
  }
  
  @Override
  public void onClick(View v) {
  
      switch (v.getId()) {
      case R.id.button1:
          // clear all timers
          if (countDownTimer != null) {
              countDownTimer.cancel();
              countDownTimer = null;
          }
          // start timer red
      case R.id.imageView1:
          if (timerRedStarted == false) {
              countDownTimer = new MyCount(startTimeRed, interval,
                      textviewRed);
              textviewRed.setText(textviewRed.getText()
                      + String.valueOf(startTimeRed));
              countDownTimer.start();
          }
          // start timer blue
      case R.id.imageView2:
          if (timerBlueStarted == false) {
              countDownTimer = new MyCount(startTimeBlue, interval,
                      textviewBlue);
              countDownTimer.start();
          }
          // start timer dragon
      case R.id.imageView3:
          if (timerDragonStarted == false) {
              countDownTimer = new MyCount(startTimeDragon, interval,
                      textviewDragon);
              countDownTimer.start();
          }
          // start timer baron
      case R.id.imageView4:
          if (timerBaronStarted == false) {
              countDownTimer = new MyCount(startTimeBaron, interval,
                      textviewBaron);
              countDownTimer.start();
          }
      }
  }
  </code></pre>
  
  <p>}</p>
  
  <p>class MyCount extends CountDownTimer {</p>
  
  <pre><code>private TextView tv;
  
  public MyCount(long millisInFuture, long countDownInterval, TextView tv) {
      super(millisInFuture, countDownInterval);
      this.tv = tv;
  }
  
  @Override
  public void onTick(long millisUntilFinished) {
      tv.setText("" + millisUntilFinished / 1000);
  }
  </code></pre>