From 4ab1ed7fc94662b201097acecf56682bdcc2f092 Mon Sep 17 00:00:00 2001 From: joshua Date: Sun, 22 May 2022 21:05:54 +0200 Subject: [PATCH] Fix previous workaround The rotate action shortcut was 'space' before this commit and so the keyPressEvent with space key was never propagated because always grabbed by the rotate action. Now the shortcut for the rotate action is ctrl + space. Note that even if rotate exist in element editor, this doesn't work well because the rotation is not well managed by the save/load from elmt file. --- sources/editor/esevent/eseventaddterminal.cpp | 2 +- sources/editor/ui/qetelementeditor.ui | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sources/editor/esevent/eseventaddterminal.cpp b/sources/editor/esevent/eseventaddterminal.cpp index f9c33b5a7..a48516e99 100644 --- a/sources/editor/esevent/eseventaddterminal.cpp +++ b/sources/editor/esevent/eseventaddterminal.cpp @@ -87,7 +87,7 @@ bool ESEventAddTerminal::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { @return */ bool ESEventAddTerminal::keyPressEvent(QKeyEvent *event) { - if (event -> key() == Qt::Key_Alt) { + if (event -> key() == Qt::Key_Space) { switch (m_terminal->orientation()) { case Qet::North : diff --git a/sources/editor/ui/qetelementeditor.ui b/sources/editor/ui/qetelementeditor.ui index bbdc88564..773045c65 100644 --- a/sources/editor/ui/qetelementeditor.ui +++ b/sources/editor/ui/qetelementeditor.ui @@ -25,7 +25,7 @@ 0 0 800 - 20 + 21 @@ -498,7 +498,7 @@ Rotation - Space + Ctrl+Space