Reenabled Ctrl+P shortcut for "print model"
This commit is contained in:
@@ -1573,7 +1573,7 @@ QAction * MainWindow::addAct(QString icon, QString sName, QString lName, QKeySeq
|
|||||||
if (!lName.isEmpty())
|
if (!lName.isEmpty())
|
||||||
newAction->setStatusTip(lName);
|
newAction->setStatusTip(lName);
|
||||||
if (shortcut != 0)
|
if (shortcut != 0)
|
||||||
newAction->setShortcuts(shortcut);
|
newAction->setShortcut(QKeySequence(shortcut));
|
||||||
if (slotObj == NULL)
|
if (slotObj == NULL)
|
||||||
slotObj = this;
|
slotObj = this;
|
||||||
connect(newAction, SIGNAL(triggered()), slotObj, slot);
|
connect(newAction, SIGNAL(triggered()), slotObj, slot);
|
||||||
@@ -1653,7 +1653,7 @@ void MainWindow::createActions()
|
|||||||
// dutchLangAct = addAct( langAlignGroup, tr("Dutch"), tr("Use Dutch in menus"), SLOT(setNLLanguage()));
|
// dutchLangAct = addAct( langAlignGroup, tr("Dutch"), tr("Use Dutch in menus"), SLOT(setNLLanguage()));
|
||||||
|
|
||||||
aboutAct = addAct("information.png", tr("About..."), tr("Show the application's About box"), SLOT(about()));
|
aboutAct = addAct("information.png", tr("About..."), tr("Show the application's About box"), SLOT(about()));
|
||||||
printAct = addAct("print.png", tr("Print..."), tr("Print current model"), SLOT(print()));
|
printAct = addAct("print.png", tr("Print..."), tr("Print current model"), QKeySequence::Print, SLOT(print()));
|
||||||
simulateAct = addAct("simulate.png", tr("Simulate..."), tr("Simulate current model"), SLOT(simulate()));
|
simulateAct = addAct("simulate.png", tr("Simulate..."), tr("Simulate current model"), SLOT(simulate()));
|
||||||
loadbackupAct = addAct("open.png", tr("Load Backup..."), tr("Load backup from file"), SLOT(loadBackup()));
|
loadbackupAct = addAct("open.png", tr("Load Backup..."), tr("Load backup from file"), SLOT(loadBackup()));
|
||||||
logsAct = addAct("logs.png", tr("View Log File..."), tr("Open and view log file"), SLOT(logFile()));
|
logsAct = addAct("logs.png", tr("View Log File..."), tr("Open and view log file"), SLOT(logFile()));
|
||||||
|
|||||||
@@ -97,7 +97,7 @@ void ModelsListWidget::ShowContextMenu(const QPoint& pos)
|
|||||||
contextMenu.addSeparator();
|
contextMenu.addSeparator();
|
||||||
contextMenu.addAction(CompanionIcon("currentmodel.png"), tr("&Use as default"),this,SLOT(setdefault()));
|
contextMenu.addAction(CompanionIcon("currentmodel.png"), tr("&Use as default"),this,SLOT(setdefault()));
|
||||||
contextMenu.addSeparator();
|
contextMenu.addSeparator();
|
||||||
contextMenu.addAction(CompanionIcon("print.png"), tr("P&rint model"),this, SLOT(print()),tr("Alt+R"));
|
contextMenu.addAction(CompanionIcon("print.png"), tr("P&rint model"),this, SLOT(print()),QKeySequence(tr("Ctrl+P")));
|
||||||
contextMenu.addSeparator();
|
contextMenu.addSeparator();
|
||||||
contextMenu.addAction(CompanionIcon("simulate.png"), tr("&Simulate model"),this, SLOT(simulate()),tr("Alt+S"));
|
contextMenu.addAction(CompanionIcon("simulate.png"), tr("&Simulate model"),this, SLOT(simulate()),tr("Alt+S"));
|
||||||
contextMenu.exec(globalPos);
|
contextMenu.exec(globalPos);
|
||||||
|
|||||||
Reference in New Issue
Block a user