[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [kwin] kcmkwin/kwindecoration/declarative-plugin: Testing whether m_lastCreatedSettings is not null 
From:       Ivan Čukić <ivan.cukic () kde ! org>
Date:       2016-04-08 7:26:48
Message-ID: E1aoQoa-0002pp-UO () scm ! kde ! org
[Download RAW message or body]

Git commit 1fef4760bf1d3b9446713a6d55d0fc0119b8d1d7 by Ivan Čukić.
Committed on 08/04/2016 at 07:26.
Pushed by ivan into branch 'master'.

Testing whether m_lastCreatedSettings is not null before calling its method

Summary:
It looks like something was forgotten here - there is
a completely empty body for an if statement that checks
whether the pointer is null.
So this might not be the desired way to fix this.
Should m_lastCreatedSettings be instantiated instead?

Reviewers: graesslin

Reviewed By: graesslin

Subscribers: plasma-devel

Projects: #plasma

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

M  +2    -2    kcmkwin/kwindecoration/declarative-plugin/previewbridge.cpp

http://commits.kde.org/kwin/1fef4760bf1d3b9446713a6d55d0fc0119b8d1d7

diff --git a/kcmkwin/kwindecoration/declarative-plugin/previewbridge.cpp \
b/kcmkwin/kwindecoration/declarative-plugin/previewbridge.cpp index 7d201f3..7a74077 \
                100644
--- a/kcmkwin/kwindecoration/declarative-plugin/previewbridge.cpp
+++ b/kcmkwin/kwindecoration/declarative-plugin/previewbridge.cpp
@@ -199,9 +199,9 @@ void PreviewBridge::configure()
 
     auto save = [this,kcm] {
         kcm->save();
-        if (!m_lastCreatedSettings) {
+        if (m_lastCreatedSettings) {
+            emit m_lastCreatedSettings->decorationSettings()->reconfigured();
         }
-        emit m_lastCreatedSettings->decorationSettings()->reconfigured();
         // Send signal to all kwin instances
         QDBusMessage message = QDBusMessage::createSignal(QStringLiteral("/KWin"),
                                                           \
QStringLiteral("org.kde.KWin"),


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic