Bug 369858 - Closing DebugConsole through window decoration doesn't destroy it
Summary: Closing DebugConsole through window decoration doesn't destroy it
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: 5.8.0
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL: https://phabricator.kde.org/D2931
Keywords:
Depends on:
Blocks:
 
Reported: 2016-10-04 11:16 UTC by Martin Flöser
Modified: 2016-10-05 05:49 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.8.1
mgraesslin: ReviewRequest+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Flöser 2016-10-04 11:16:15 UTC
The close debug console button is connected to DebugConsole::deleteLater. This means if closing that way the DebugConsole gets destroyed and also the created input filter gets destroyed.

But when closing through the window decoration the window only gets hidden and not destroyed, keeping the resources around.

This is extracted from bug #369091 comment 4.
Comment 1 Martin Flöser 2016-10-04 11:39:05 UTC
Git commit 4d47f6d831f0216743a48c196e7f38f4806e857b by Martin Gräßlin.
Committed on 04/10/2016 at 11:37.
Pushed by graesslin into branch 'Plasma/5.8'.

[autotests/integration] Add a test case for closing DebugConsole

This test simulates closing the DebugConsole through the window
decoration. Which unlike the dedicated button does not destroy the
DebugConsole.

M  +25   -0    autotests/integration/debug_console_test.cpp
M  +1    -1    debug_console.h

http://commits.kde.org/kwin/4d47f6d831f0216743a48c196e7f38f4806e857b
Comment 2 Martin Flöser 2016-10-04 12:10:25 UTC
Addressed in https://phabricator.kde.org/D2931
Comment 3 Martin Flöser 2016-10-05 05:49:57 UTC
Git commit fd6e4bb0236b42d4fab2fdc856a381b6159f6605 by Martin Gräßlin.
Committed on 05/10/2016 at 05:48.
Pushed by graesslin into branch 'Plasma/5.8'.

Destroy DebugConsole on hide of QWindow

Summary:
The quit button in the DebugConsole is connected to deleteLater on the
DebugConsole. This is to clean up resources like the input event filter
which is rather expensive to have running.

When closed through the window decoration the DebugConsole window only
got hidden but not destroyed. Resulting in the input filter to continue
processing.

This change ensures that the DebugConsole gets properly destroyed once
the window gets hidden.
FIXED-IN: 5.8.1

Reviewers: #kwin, #plasma_on_wayland

Subscribers: plasma-devel, kwin

Tags: #plasma_on_wayland, #kwin

Differential Revision: https://phabricator.kde.org/D2931

M  +0    -2    autotests/integration/debug_console_test.cpp
M  +16   -0    debug_console.cpp
M  +3    -0    debug_console.h

http://commits.kde.org/kwin/fd6e4bb0236b42d4fab2fdc856a381b6159f6605