WSL/SLF GitLab Repository

Commit a28adf00 authored by Mathias Bavay's avatar Mathias Bavay
Browse files

Fixed deprecated syntax for shortcuts

parent 8e38a9b0
......@@ -732,12 +732,12 @@ void MainWindow::createMenu()
gui_reset_ = new QAction(getIcon("document-revert"), tr("&Reset to default values"), menu_gui);
menu_gui->addAction(gui_reset_);
gui_reset_->setEnabled(false);
gui_reset_->setShortcut(Qt::CTRL + Qt::Key_Backspace);
gui_reset_->setShortcut(Qt::CTRL | Qt::Key_Backspace);
connect(gui_reset_, &QAction::triggered, this, [=]{ toolbarClick("reset_gui"); });
gui_clear_ = new QAction(getIcon("edit-delete"), tr("&Clear"), menu_gui);
menu_gui->addAction(gui_clear_);
gui_clear_->setEnabled(false);
gui_clear_->setShortcut(Qt::CTRL + Qt::SHIFT + Qt::Key_Backspace);
gui_clear_->setShortcut(Qt::CTRL | Qt::SHIFT | Qt::Key_Backspace);
connect(gui_clear_, &QAction::triggered, this, [=]{ toolbarClick("clear_gui"); });
menu_gui->addSeparator();
gui_close_all_ = new QAction(getIcon("window-close"), tr("Close all content"), menu_gui);
......@@ -754,11 +754,11 @@ void MainWindow::createMenu()
auto *view_log = new QAction(getIcon("utilities-system-monitor"), tr("&Log"), menu_view);
menu_view->addAction(view_log);
connect(view_log, &QAction::triggered, this, &MainWindow::viewLogger);
view_log->setShortcut(Qt::CTRL + Qt::Key_L);
view_log->setShortcut(Qt::CTRL | Qt::Key_L);
auto *window_toggle_workflow = new QAction(getIcon("application-menu"), tr("Toggle wor&kflow"), menu_view);
menu_view->addAction(window_toggle_workflow);
connect(window_toggle_workflow, &QAction::triggered, this, &MainWindow::toggleWorkflow);
window_toggle_workflow->setShortcut(Qt::CTRL + Qt::Key_K);
window_toggle_workflow->setShortcut(Qt::CTRL | Qt::Key_K);
auto *view_refresh = new QAction(getIcon("view-refresh"), tr("&Refresh applications"), menu_view);
menu_view->addAction(view_refresh);
connect(view_refresh, &QAction::triggered, this,
......
......@@ -288,7 +288,7 @@ void PreviewWindow::createMenu()
menu_file->addSeparator();
auto *file_backup = new QAction(tr("Quicksave backup"), menu_file);
menu_file->addAction(file_backup);
file_backup->setShortcut(Qt::CTRL + Qt::ALT + Qt::Key_B);
file_backup->setShortcut(Qt::CTRL | Qt::ALT | Qt::Key_B);
connect(file_backup, &QAction::triggered, this, &PreviewWindow::quickBackup);
auto *file_close_ = new QAction(getIcon("application-exit"), tr("&Close preview"), menu_file);
file_close_->setShortcut(Qt::Key_Escape);
......@@ -428,13 +428,13 @@ void PreviewWindow::createMenu()
auto *trans_comment_block = new QAction(tr("Comment selection"),
trans_comments);
trans_comments->addAction(trans_comment_block);
trans_comment_block->setShortcut(Qt::CTRL + Qt::Key_NumberSign);
trans_comment_block->setShortcut(Qt::CTRL | Qt::Key_NumberSign);
connect(trans_comment_block, &QAction::triggered, this,
[=]{ onTransformMenuClick("transform_comment_block"); });
auto *trans_uncomment_block = new QAction(tr("Uncomment selection"),
trans_comments);
trans_comments->addAction(trans_uncomment_block);
trans_uncomment_block->setShortcut(Qt::CTRL + Qt::SHIFT + Qt::Key_NumberSign);
trans_uncomment_block->setShortcut(Qt::CTRL | Qt::SHIFT | Qt::Key_NumberSign);
connect(trans_uncomment_block, &QAction::triggered, this,
[=]{ onTransformMenuClick("transform_uncomment_block"); });
trans_comments->addSeparator();
......@@ -445,7 +445,7 @@ void PreviewWindow::createMenu()
trans_comments->addAction(trans_comments_content);
auto *trans_comments_duplicate = new QAction(tr("Duplicate all to comment"),
trans_comments);
trans_comments_duplicate->setShortcut(Qt::CTRL + Qt::SHIFT + Qt::Key_B);
trans_comments_duplicate->setShortcut(Qt::CTRL | Qt::SHIFT | Qt::Key_B);
connect(trans_comments_duplicate, &QAction::triggered, this,
[=]{ onTransformMenuClick("transform_comments_duplicate"); } );
trans_comments->addAction(trans_comments_duplicate);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment