MCPcopy Create free account
hub / github.com/clementgallet/libTAS / createMovieMenu

Method createMovieMenu

src/program/ui/MainWindow.cpp:637–671  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

635}
636
637void MainWindow::createMovieMenu()
638{
639 QAction *action;
640
641 /* Movie Menu */
642 QMenu *movieMenu = menuBar()->addMenu(tr("Movie"));
643 movieMenu->setToolTipsVisible(true);
644
645 action = movieMenu->addAction(tr("Open Movie..."), this, &MainWindow::slotBrowseMoviePath);
646 disabledActionsOnStart.append(action);
647 saveMovieAction = movieMenu->addAction(tr("Save Movie"), this, &MainWindow::slotSaveMovie, QKeySequence("Ctrl+S"));
648 saveMovieAction->setEnabled(false);
649 exportMovieAction = movieMenu->addAction(tr("Export Movie..."), this, &MainWindow::slotExportMovie);
650 exportMovieAction->setEnabled(false);
651 settingsMovieAction = movieMenu->addAction(tr("Movie Settings..."), this, [this] { windowManager->showMovieSettingsWindow(); });
652 settingsMovieAction->setEnabled(false);
653 action = movieMenu->addAction(tr("Don't enforce movie settings"), this, [=, this](bool checked){gameLoop->movie.header->skipLoadSettings = checked;});
654 action->setCheckable(true);
655 action->setToolTip("When checked, settings stored inside the movie metadata won't be enforced (e.g. initial time, mouse/controller support, framerate...). You can then save your movie with the new settings.");
656
657 movieMenu->addSeparator();
658
659 annotateMovieAction = movieMenu->addAction(tr("Annotations..."), this, [this] { windowManager->showAnnotationsWindow(); });
660 annotateMovieAction->setEnabled(false);
661
662 movieMenu->addSeparator();
663
664 movieMenu->addAction(tr("Pause Movie at frame..."), this, &MainWindow::slotPauseMovie);
665 autoRestartAction = movieMenu->addAction(tr("Auto-restart game"), this, LAMBDABOOLSLOT(context->config.auto_restart));
666 autoRestartAction->setCheckable(true);
667 autoRestartAction->setToolTip("When checked, the game will automatically restart if closed, except when using the Stop button");
668 disabledActionsOnStart.append(autoRestartAction);
669
670 movieMenu->addAction(tr("Input Editor..."), this, [this] { windowManager->showInputEditorWindow(); });
671}
672
673void MainWindow::createToolsMenu()
674{

Callers

nothing calls this directly

Calls 4

showAnnotationsWindowMethod · 0.80
appendMethod · 0.45
showInputEditorWindowMethod · 0.45

Tested by

no test coverage detected