X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;ds=sidebyside;f=main.cpp;h=4383f2e84958bc1dbfc06c6c72f58e9a959cba36;hb=41561143a592e0409168bbd91350761d1b048c47;hp=0a6819b2d3587396e7a4f563df4d34c12f23c5a9;hpb=3b736d3d022d8847f247b307d652c76bdf2efe4e;p=pkanalytics diff --git a/main.cpp b/main.cpp index 0a6819b..4383f2e 100644 --- a/main.cpp +++ b/main.cpp @@ -75,6 +75,17 @@ MainWindow::MainWindow(EventsModel *events, PlayersModel *players) : events(even QShortcut *pgup = new QShortcut(QKeySequence(Qt::Key_PageUp), this); connect(pgup, &QShortcut::activated, [this]() { seek(120000); }); + // Ugh. Used when Qt messes up and hangs the video. + QShortcut *f5 = new QShortcut(QKeySequence(Qt::Key_F5), this); + connect(f5, &QShortcut::activated, [this]() { + QVideoWidget *nvw = new QVideoWidget(ui->video->parentWidget()); + nvw->setObjectName("video"); + nvw->setMinimumSize(QSize(320, 240)); + video->setVideoOutput(nvw); + ui->main_grid->replaceWidget(ui->video, nvw); + ui->video = nvw; + }); + connect(ui->minus10s, &QPushButton::clicked, [this]() { seek(-10000); }); connect(ui->plus10s, &QPushButton::clicked, [this]() { seek(10000); });