diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2010-02-18 13:59:49 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2010-02-18 13:59:49 +0000 |
commit | ce7a5e1c9fa3edf2d9cc66875505e402a0aaa6f6 (patch) | |
tree | 8a798270cd892823c7eeef99c2f3cdd4bf657bb3 /gtk2_ardour/midi_time_axis.cc | |
parent | cdcc4d3720d8168a158f6a5a5f23e9ce981bc68c (diff) |
the Properties & 64bit region commit
git-svn-id: svn://localhost/ardour2/branches/3.0@6695 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/midi_time_axis.cc')
-rw-r--r-- | gtk2_ardour/midi_time_axis.cc | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/gtk2_ardour/midi_time_axis.cc b/gtk2_ardour/midi_time_axis.cc index d1a60ce04a..b1adb7c67e 100644 --- a/gtk2_ardour/midi_time_axis.cc +++ b/gtk2_ardour/midi_time_axis.cc @@ -395,7 +395,7 @@ MidiTimeAxisView::build_automation_action_menu () something about MIDI (!) would not expect to find them there. */ - add_channel_command_menu_item (automation_items, _("Program Change"), MidiPgmChangeAutomation, MIDI_CMD_PGM_CHANGE); + add_channel_command_menu_item (automation_items, _("Program PropertyChange"), MidiPgmChangeAutomation, MIDI_CMD_PGM_CHANGE); add_channel_command_menu_item (automation_items, _("Bender"), MidiPitchBenderAutomation, MIDI_CMD_BENDER); add_channel_command_menu_item (automation_items, _("Pressure"), MidiChannelPressureAutomation, MIDI_CMD_CHANNEL_PRESSURE); @@ -968,7 +968,7 @@ MidiTimeAxisView::add_region (nframes64_t pos) real_editor->begin_reversible_command (_("create region")); XMLNode &before = playlist()->get_state(); - nframes64_t start = pos; + framepos_t start = pos; real_editor->snap_to (start, -1); const Meter& m = _session->tempo_map().meter_at(start); const Tempo& t = _session->tempo_map().tempo_at(start); @@ -979,8 +979,13 @@ MidiTimeAxisView::add_region (nframes64_t pos) boost::shared_ptr<Source> src = _session->create_midi_source_for_session (*diskstream.get()); - boost::shared_ptr<Region> region = (RegionFactory::create (src, 0, (nframes_t) length, - PBD::basename_nosuffix(src->name()))); + PropertyList plist; + + plist.add (ARDOUR::Properties::start, 0); + plist.add (ARDOUR::Properties::length, length); + plist.add (ARDOUR::Properties::name, PBD::basename_nosuffix(src->name())); + + boost::shared_ptr<Region> region = (RegionFactory::create (src, plist)); playlist()->add_region (region, start); XMLNode &after = playlist()->get_state(); |