Use AbstractClient for keyboard moving of clients

As keyPressEvent is in AbstractClient now we don't need to cast to
Client any more. This allows to end move of ShellClients as well.
This commit is contained in:
Martin Gräßlin 2015-10-23 15:32:51 +02:00
parent 5d2251875f
commit ac1f01fd3f

View file

@ -909,7 +909,7 @@ void InputRedirection::processKeyboardKey(uint32_t key, InputRedirection::Keyboa
return;
}
if (workspace()) {
if (Client *c = dynamic_cast<Client*>(workspace()->getMovingClient())) {
if (AbstractClient *c = workspace()->getMovingClient()) {
c->keyPressEvent(m_xkb->toQtKey(m_xkb->toKeysym(key)) | m_xkb->modifiers());
if (c->isMove() || c->isResize()) {
// only update if mode didn't end