title: Counter not getting resumed when an activity is resumed
body: <p>I have a counter in my activity A and on finish of it, I have to perform some actions. The problem is the counter is getting reset when I move onto another activity and then come back to this activity A, which shouldn't happen. Why is it so?</p>
  
  <p>My Counter class is:</p>
  
  <pre><code>private class Counter extends CountDownTimer {
  
          public Counter(long millisInFuture, long countDownInterval) {
              super(millisInFuture, countDownInterval);
          }
  
          public void onFinish() {
              //perform some actions
          }
  
          public void onTick(long millisUntilFinished) {
              int minute = (int) (millisUntilFinished / (1000 * 60));
              int sec = (int) ((millisUntilFinished - (minute * 60 * 1000)) / 1000);
              minuteText.setText("" + minute);
              secondText.setText("" + sec);
              }
          }
      }
  </code></pre>
  
  <p>I call my counter in <code>onCreate()</code> as:</p>
  
  <pre><code>new Counter(countdowntime * 60 * 1000), 1000).start();
  </code></pre>
  
  <p>How to solve this issue? Please reply. Thanks in advance.</p>