mirror-chatterino2/src/widgets/BasePopup.cpp
2020-10-31 16:42:48 +01:00

22 lines
366 B
C++

#include "widgets/BasePopup.hpp"
namespace chatterino {
BasePopup::BasePopup(FlagsEnum<Flags> _flags, QWidget *parent)
: BaseWindow(_flags | Dialog, parent)
{
}
void BasePopup::keyPressEvent(QKeyEvent *e)
{
if (e->key() == Qt::Key_Escape)
{
this->close();
return;
}
BaseWindow::keyPressEvent(e);
}
} // namespace chatterino