UX improvement, not showing total time when not recording

This commit is contained in:
Jimmy Shih
2013-12-17 17:20:12 -08:00
parent e31550c524
commit 1dbebf0529
@@ -120,11 +120,14 @@ public class TrackController {
}
handler.removeCallbacks(updateTotalTimeRunnable);
totalTime = isRecording ? getTotalTime() : 0L;
totalTimeTextView.setText(StringUtils.formatElapsedTimeWithHour(totalTime));
if (isRecording && !isPaused) {
totalTimeTimestamp = System.currentTimeMillis();
handler.postDelayed(updateTotalTimeRunnable, ONE_SECOND);
totalTimeTextView.setVisibility(isRecording ? View.VISIBLE : View.INVISIBLE);
if (isRecording) {
totalTime = getTotalTime();
totalTimeTextView.setText(StringUtils.formatElapsedTimeWithHour(totalTime));
if (!isPaused) {
totalTimeTimestamp = System.currentTimeMillis();
handler.postDelayed(updateTotalTimeRunnable, ONE_SECOND);
}
}
}