mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-09 16:24:57 +01:00
allow new locations creation from playhead to use default time domain
This commit is contained in:
parent
874a009d76
commit
87dfef28f6
1 changed files with 8 additions and 4 deletions
|
|
@ -1322,16 +1322,20 @@ Editor::marker_menu_set_from_playhead ()
|
||||||
|
|
||||||
if ((l = find_location_from_marker (marker, is_start)) != 0) {
|
if ((l = find_location_from_marker (marker, is_start)) != 0) {
|
||||||
|
|
||||||
#warning NUTEMPO what if the user wants musical time here?
|
timepos_t pos (_session->audible_sample());
|
||||||
|
|
||||||
|
if (default_time_domain() == Temporal::BeatTime) {
|
||||||
|
pos = timepos_t (pos.beats());
|
||||||
|
}
|
||||||
|
|
||||||
if (l->is_mark()) {
|
if (l->is_mark()) {
|
||||||
l->set_start (timepos_t (_session->audible_sample ()), false);
|
l->set_start (pos, false);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (is_start) {
|
if (is_start) {
|
||||||
l->set_start (timepos_t (_session->audible_sample ()), false);
|
l->set_start (pos, false);
|
||||||
} else {
|
} else {
|
||||||
l->set_end (timepos_t (_session->audible_sample ()), false);
|
l->set_end (pos, false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue