X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=futatabi%2Fmainwindow.cpp;h=f55ad0e489083572e9d86fa80e0dd2f8c749d656;hb=ea502b76e42b700e73afb25522a0b947e9ee60a9;hp=05ea5821a090451bf79fe8f8f80255d7e7e462c4;hpb=1f63c84df7b2f2dba436b4ace8eaabe5beecb425;p=nageru diff --git a/futatabi/mainwindow.cpp b/futatabi/mainwindow.cpp index 05ea582..f55ad0e 100644 --- a/futatabi/mainwindow.cpp +++ b/futatabi/mainwindow.cpp @@ -289,7 +289,7 @@ MainWindow::MainWindow() if (!load_midi_mapping_from_file(global_flags.midi_mapping_filename, &midi_mapping)) { fprintf(stderr, "Couldn't load MIDI mapping '%s'; exiting.\n", global_flags.midi_mapping_filename.c_str()); - exit(1); + abort(); } midi_mapper.set_midi_mapping(midi_mapping); } @@ -388,6 +388,10 @@ void MainWindow::cue_in_clicked() playlist_selection_changed(); } + // Show the clip in the preview. + unsigned stream_idx = ui->preview_display->get_stream_idx(); + preview_single_frame(cliplist_clips->mutable_back()->pts_in, stream_idx, FIRST_AT_OR_AFTER); + // Select the item so that we can jog it. ui->clip_list->setFocus(); QModelIndex index = cliplist_clips->index(cliplist_clips->size() - 1, int(ClipList::Column::IN)); @@ -404,6 +408,10 @@ void MainWindow::cue_out_clicked() cliplist_clips->mutable_back()->pts_out = current_pts + lrint(global_flags.cue_out_point_padding_seconds * TIMEBASE); + // Show the clip in the preview. (TODO: This won't take padding into account.) + unsigned stream_idx = ui->preview_display->get_stream_idx(); + preview_single_frame(cliplist_clips->mutable_back()->pts_out, stream_idx, LAST_BEFORE); + // Select the item so that we can jog it. ui->clip_list->setFocus(); QModelIndex index = cliplist_clips->index(cliplist_clips->size() - 1, int(ClipList::Column::OUT));