summaryrefslogtreecommitdiff
path: root/gtk2_ardour/step_editor.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2013-05-21 00:25:04 +0200
committerRobin Gareus <robin@gareus.org>2013-05-21 00:25:04 +0200
commit04967de3afa09bbfc127d3eb052bc8f3dabd8553 (patch)
treed2932ea1fdb1d93dd1f5740526230712273d8dfe /gtk2_ardour/step_editor.cc
parentdb3961323894d93d7159f6bc254aefe7a7ac1f99 (diff)
fix 5498 -- use note length from step-entry with midi keybd.
Diffstat (limited to 'gtk2_ardour/step_editor.cc')
-rw-r--r--gtk2_ardour/step_editor.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/gtk2_ardour/step_editor.cc b/gtk2_ardour/step_editor.cc
index 30d424c9c6..a75f0f98e4 100644
--- a/gtk2_ardour/step_editor.cc
+++ b/gtk2_ardour/step_editor.cc
@@ -255,7 +255,9 @@ StepEditor::step_add_note (uint8_t channel, uint8_t pitch, uint8_t velocity, Evo
assert (step_edit_region);
assert (step_edit_region_view);
- if (beat_duration == 0.0) {
+ if (beat_duration == 0.0 && step_editor) {
+ beat_duration = step_editor->note_length();
+ } else if (beat_duration == 0.0) {
bool success;
beat_duration = _editor.get_grid_type_as_beats (success, step_edit_insert_position);