sort_track_selection (ts);
} else {
/* Figure out which track to base the paste at. */
- TimeAxisView* base_track;
+ TimeAxisView* base_track = NULL;
if (_edit_point == Editing::EditAtMouse && entered_track) {
/* With the mouse edit point, paste onto the track under the mouse. */
base_track = entered_track;
} else if (_last_cut_copy_source_track) {
/* Paste to the track that the cut/copy came from (see mantis #333). */
base_track = _last_cut_copy_source_track;
+ } else {
+ /* This is "impossible" since we've copied... well, do nothing. */
+ return;
}
/* Walk up to parent if necessary, so base track is a route. */
vector<Evoral::Sequence<Evoral::MusicalTime>::Notes> v;
v.push_back (selected);
- framepos_t pos_frames = mrv.midi_region()->position() - mrv.midi_region()->start();
- double pos_beats = _session->tempo_map().framewalk_to_beats(0, pos_frames);
+ framepos_t pos_frames = mrv.midi_region()->position() - mrv.midi_region()->start();
+ Evoral::MusicalTime pos_beats = _session->tempo_map().framewalk_to_beats(0, pos_frames);
return op (mrv.midi_region()->model(), pos_beats, v);
}
qd->hide ();
if (r == Gtk::RESPONSE_OK) {
- Quantize quant (*_session, qd->snap_start(), qd->snap_end(),
+ Quantize quant (qd->snap_start(), qd->snap_end(),
qd->start_grid_size(), qd->end_grid_size(),
qd->strength(), qd->swing(), qd->threshold());
*/
MidiRegionView* first = dynamic_cast<MidiRegionView*> (rs.front ());
- Evoral::PatchChange<Evoral::MusicalTime> empty (0, 0, 0, 0);
+ Evoral::PatchChange<Evoral::MusicalTime> empty (Evoral::MusicalTime(), 0, 0, 0);
PatchChangeDialog d (0, _session, empty, first->instrument_info(), Gtk::Stock::ADD);
if (d.run() == RESPONSE_CANCEL) {