Skip to content
Commit 49ea43e2 authored by Felix Ernst's avatar Felix Ernst 🇺🇦 Committed by Felix Ernst
Browse files

Reuse existing proxy style

Before this commit, a new QProxyStyle was created every time the
selection mode was enabled. The previously used one was
automatically deleted in the process because of the std::unique_ptr
re-assignment. This isn't really a problem in itself, but I
strongly assume that the sudden deletion of the old style shortly
before setting a new style might be the cause of the crash/bug
468548.

This commit simply re-uses the previously created proxy style which
doesn't seem to cause any behaviour change even when the
application style has been changed in the time since the proxy
style was created.

Another potential solution might be to simply use deleteLater() on
the old proxy style instead of letting std::unique_ptr delete the
old proxy style instantly while it is still in use. That seems more
involved than simply re-using the old style though.

BUG: 468548
FIXED-IN: 23.08
parent b99f6f50
Pipeline #382115 passed with stage
in 20 minutes and 6 seconds
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