Commit 12e42f01 authored by David Redondo's avatar David Redondo 🏎
Browse files

Clean up listener

If the style is unloaded for example by an application dynamically
switching styles, the listener was still around leading us to call
into destroyed objects when the color scheme was changed.
BUG:432660


(cherry picked from commit 5de36bd1)
parent bc8b9cc5
......@@ -41,7 +41,7 @@ namespace Breeze {
void ToolsAreaManager::registerApplication(QApplication *application)
{
_listener = new AppListener;
_listener = new AppListener(this);
_listener->manager = this;
if (application->property(colorProperty).isValid()) {
auto path = application->property(colorProperty).toString();
......
......@@ -18,6 +18,7 @@ namespace Breeze {
class AppListener : public QObject
{
Q_OBJECT
using QObject::QObject;
bool eventFilter(QObject *watched, QEvent *event) override;
......
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