From 15b590e9bf58aa61ba8d0dda4f41be7abcb960a4 Mon Sep 17 00:00:00 2001 From: kevin Date: Fri, 6 May 2022 16:06:24 -0400 Subject: [PATCH] cwPresetSel.h: Add track_timestamp_reset(). --- cwPresetSel.cpp | 6 ++++++ cwPresetSel.h | 1 + 2 files changed, 7 insertions(+) diff --git a/cwPresetSel.cpp b/cwPresetSel.cpp index 2dd3d42..666c5f9 100644 --- a/cwPresetSel.cpp +++ b/cwPresetSel.cpp @@ -755,6 +755,12 @@ cw::rc_t cw::preset_sel::get_value( handle_t h, unsigned fragId, unsigned varId, return rc; } +void cw::preset_sel::track_timestamp_reset( handle_t h ) +{ + preset_sel_t* p = _handleToPtr(h); + p->last_ts_frag = nullptr; +} + bool cw::preset_sel::track_timestamp( handle_t h, const time::spec_t& ts, const cw::preset_sel::frag_t*& frag_Ref ) { preset_sel_t* p = _handleToPtr(h); diff --git a/cwPresetSel.h b/cwPresetSel.h index 34f1d38..a633cdc 100644 --- a/cwPresetSel.h +++ b/cwPresetSel.h @@ -107,6 +107,7 @@ namespace cw // If 'ts' is past the last defined fragment then the last fragment is returned. // If no fragments are defined 'frag_Ref' is set to nullptr. // The return value is true when the value of frag_Ref changes from the previous call. + void track_timestamp_reset( handle_t h ); bool track_timestamp( handle_t h, const time::spec_t& ts, const cw::preset_sel::frag_t*& frag_Ref ); // Return the preset index marked to play on this fragment.