From: Tilman Sauerbeck Date: Wed, 25 Mar 2020 16:22:22 +0000 (+0100) Subject: application: Only reset the model when starting a new recording. X-Git-Url: http://git.code-monkey.de/?a=commitdiff_plain;h=d41f27c211ac96151e175c4241b6a8d866001bea;p=gps-watch.git application: Only reset the model when starting a new recording. Do not reset it when stopping a recording. This lets us view the recording's data (distance only for now) after it has been stopped. --- diff --git a/src/application/main.rs b/src/application/main.rs index 6e8d37d..95a60da 100644 --- a/src/application/main.rs +++ b/src/application/main.rs @@ -334,14 +334,14 @@ pub unsafe extern "C" fn _start() -> ! { if is_recording { logger.start_recording(&prev_tap); + model.reset(); + view = View::Distance; } else { logger.stop_recording(&prev_tap); view = View::Time; } - - model.reset(); } let new_view = if pte24.has_been_held_for_ms(250) {