Fix a logic error resulting in strange recording
This commit is contained in:
parent
7675fe59a5
commit
3790be68c5
@ -35,7 +35,7 @@ ScreenAreaSelector::~ScreenAreaSelector() {
|
|||||||
void ScreenAreaSelector::keyPressEvent(QKeyEvent *event) {
|
void ScreenAreaSelector::keyPressEvent(QKeyEvent *event) {
|
||||||
event->accept();
|
event->accept();
|
||||||
if (event->key() == Qt::Key_Return || event->key() == Qt::Key_Enter) {
|
if (event->key() == Qt::Key_Return || event->key() == Qt::Key_Enter) {
|
||||||
QRect r = QRect(mapToGlobal(pos()), rect().size());
|
QRect r = QRect(mapToGlobal(QPoint(0, 0)), rect().size());
|
||||||
emit selectedArea(r);
|
emit selectedArea(r);
|
||||||
close();
|
close();
|
||||||
} else if (event->key() == Qt::Key_Escape)
|
} else if (event->key() == Qt::Key_Escape)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user