[kwin/oxygen] Add context object to lambda connections in Oxygen::Factory
The connect is from the KDecorationOptions which lives longer than the factory, thus the lambda might be invoked after the Factory got destroyed. Adding the context object protects against that.
This commit is contained in:
parent
d85f9971e0
commit
098620832a
1 changed files with 2 additions and 2 deletions
|
@ -48,10 +48,10 @@ namespace Oxygen
|
|||
{
|
||||
readConfig();
|
||||
setInitialized( true );
|
||||
connect(options(), &KDecorationOptions::colorsChanged, [this]() {
|
||||
connect(options(), &KDecorationOptions::colorsChanged, this, [this]() {
|
||||
_shadowCache.invalidateCaches();
|
||||
});
|
||||
connect(options(), &KDecorationOptions::configChanged, [this]() {
|
||||
connect(options(), &KDecorationOptions::configChanged, this, [this]() {
|
||||
// read in the configuration
|
||||
setInitialized( false );
|
||||
readConfig();
|
||||
|
|
Loading…
Reference in a new issue