[SCM] ktp-text-ui packaging branch, master, updated. debian/15.12.1-1-1918-gdf4b0ec

Maximiliano Curia maxy at moszumanska.debian.org
Sat May 28 00:21:50 UTC 2016


Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-text-ui.git;a=commitdiff;h=91a2eff

The following commit has been merged in the master branch:
commit 91a2eff637a87dda957b973dbfb236181324ac1b
Author: Martin Klapetek <martin.klapetek at gmail.com>
Date:   Sat May 12 21:33:13 2012 +0200

    Use force when activating the chat window from notification
    
    This works around our old problem when user would click the new message notification and nothing would happen. For some weird reason the window would never be raised by using standard "raising ways", so we decided to force-activate it. This slot is called only from the notification's activated() signal, so there's no danger of misuse.
    
    Reviewed-by: David Edmundson
---
 app/chat-tab.cpp    | 4 +++-
 lib/chat-widget.cpp | 5 ++++-
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/app/chat-tab.cpp b/app/chat-tab.cpp
index 299c292..5c9308a 100644
--- a/app/chat-tab.cpp
+++ b/app/chat-tab.cpp
@@ -27,6 +27,7 @@
 #include <KDebug>
 #include <QStackedWidget>
 #include <KDE/KColorScheme>
+#include <KDE/KWindowSystem>
 
 #include <TelepathyQt/Account>
 #include <TelepathyQt/TextChannel>
@@ -75,7 +76,8 @@ void ChatTab::showOnTop()
         kError() << "Attempting to focus chatTab without chatWindow being set!";
     }
 
-    activateWindow();
+    m_chatWindow->raise();
+    KWindowSystem::forceActiveWindow(m_chatWindow->winId());
 }
 
 void ChatTab::onConnectionStatusChanged(Tp::ConnectionStatus status)
diff --git a/lib/chat-widget.cpp b/lib/chat-widget.cpp
index f2d1809..a505374 100644
--- a/lib/chat-widget.cpp
+++ b/lib/chat-widget.cpp
@@ -627,7 +627,10 @@ void ChatWidget::notifyAboutIncomingMessage(const Tp::ReceivedMessage & message)
     }
 
 
-    KNotification *notification = new KNotification(notificationType, this);
+    KNotification *notification = new KNotification(notificationType, this,
+                                                    KNotification::RaiseWidgetOnActivation
+                                                    | KNotification::CloseWhenWidgetActivated
+                                                    | KNotification::Persistent);
     notification->setComponentData(d->telepathyComponentData());
     notification->setTitle(i18n("%1 has sent you a message", message.sender()->alias()));
 

-- 
ktp-text-ui packaging



More information about the pkg-kde-commits mailing list