Commit 6eac53b6 authored by Fushan Wen's avatar Fushan Wen 💬 Committed by Nate Graham
Browse files

shell/panelview: set passive status when pressing Escape key

CCBUG: 453166
CCBUG: 352476
parent 3a16cbe7
......@@ -859,6 +859,14 @@ void PanelView::moveEvent(QMoveEvent *ev)
void PanelView::keyPressEvent(QKeyEvent *event)
{
// Press escape key to cancel focus on the panel
if (event->key() == Qt::Key_Escape) {
if (containment()->status() == Plasma::Types::AcceptingInputStatus) {
containment()->setStatus(Plasma::Types::PassiveStatus);
}
// No return for Wayland
}
PlasmaQuick::ContainmentView::keyPressEvent(event);
if (event->isAccepted()) {
return;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment