Allow triggering Open latest comic action when the toolbar is hidden

This action is added to the toolbar but not to the viewer. Thus it
cannot be triggered when the toolbar is hidden. Adding it to
MainWindowViewer makes it available at all times.
This commit is contained in:
Igor Kushnir 2021-03-09 10:44:37 +02:00
parent 24e42f76d2
commit 482c19b358

View File

@ -254,6 +254,7 @@ void MainWindowViewer::createActions()
openLatestComicAction->setToolTip(tr("Open the latest comic opened in the previous reading session"));
openLatestComicAction->setData(OPEN_LATEST_COMIC_Y);
openLatestComicAction->setShortcut(ShortcutsManager::getShortcutsManager().getShortcut(OPEN_LATEST_COMIC_Y));
addAction(openLatestComicAction);
connect(openLatestComicAction, &QAction::triggered, this, &MainWindowViewer::openLatestComic);
QAction *recentFileAction = nullptr;