Fixed issue #841. Variables Table won't open again when closed with Esc.
--HG-- branch : develop
This commit is contained in:
parent
3b4007a40c
commit
8a255c063e
|
@ -212,6 +212,20 @@ void DialogTool::showEvent(QShowEvent *event)
|
|||
ShowVisualization();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------------------------------------------------
|
||||
void DialogTool::keyPressEvent(QKeyEvent *event)
|
||||
{
|
||||
switch (event->key())
|
||||
{
|
||||
case Qt::Key_Escape:
|
||||
DialogRejected();
|
||||
return; // After reject the dialog will be destroyed, exit imidiately
|
||||
default:
|
||||
break;
|
||||
}
|
||||
QDialog::keyPressEvent ( event );
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------------------------------------------------
|
||||
void DialogTool::FillComboBoxPiecesList(QComboBox *box, const QVector<quint32> &list)
|
||||
{
|
||||
|
|
|
@ -205,6 +205,7 @@ protected:
|
|||
|
||||
virtual void closeEvent ( QCloseEvent * event ) Q_DECL_OVERRIDE;
|
||||
virtual void showEvent( QShowEvent *event ) Q_DECL_OVERRIDE;
|
||||
virtual void keyPressEvent(QKeyEvent *event) Q_DECL_OVERRIDE;
|
||||
|
||||
void FillComboBoxPiecesList(QComboBox *box, const QVector<quint32> &list);
|
||||
void FillComboBoxPoints(QComboBox *box, FillComboBox rule = FillComboBox::Whole,
|
||||
|
|
Loading…
Reference in New Issue
Block a user