mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
add ctrl enter as shortcut for ok in load deck from clipboard (#5417)
This commit is contained in:
parent
93fab3d78f
commit
b8cf3e2cab
2 changed files with 13 additions and 0 deletions
|
|
@ -71,3 +71,13 @@ void DlgLoadDeckFromClipboard::actOK()
|
|||
delete deckLoader;
|
||||
}
|
||||
}
|
||||
|
||||
void DlgLoadDeckFromClipboard::keyPressEvent(QKeyEvent *event)
|
||||
{
|
||||
if (event->key() == Qt::Key_Return && event->modifiers() & Qt::ControlModifier) {
|
||||
event->accept();
|
||||
actOK();
|
||||
return;
|
||||
}
|
||||
QDialog::keyPressEvent(event);
|
||||
}
|
||||
|
|
@ -26,6 +26,9 @@ public:
|
|||
{
|
||||
return deckList;
|
||||
}
|
||||
|
||||
protected:
|
||||
void keyPressEvent(QKeyEvent *event) override;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue