require use of BBT_Argument as both parameter and return type from most methods (GUI edition)

This commit is contained in:
Paul Davis 2023-02-12 12:02:33 -07:00
parent 259499fc5f
commit 2c7bfa9ead
6 changed files with 17 additions and 15 deletions

View file

@ -2957,16 +2957,16 @@ Editor::snap_to_bbt (timepos_t const & presnap, Temporal::RoundMode direction, S
if (_grid_type == GridTypeBar) {
TempoMetric m (tmap->metric_at (presnap));
BBT_Time bbt (m.bbt_at (presnap));
BBT_Argument bbt (m.bbt_at (presnap));
switch (direction) {
case RoundDownAlways:
bbt = bbt.round_down_to_bar ();
bbt = BBT_Argument (bbt.reference(), bbt.round_down_to_bar ());
break;
case RoundUpAlways:
bbt = bbt.round_up_to_bar ();
bbt = BBT_Argument (bbt.reference(), bbt.round_up_to_bar ());
break;
case RoundNearest:
bbt = m.round_to_bar (bbt);
bbt = BBT_Argument (bbt.reference(), m.round_to_bar (bbt));
break;
default:
break;