better to check if the notification origins in the frontend

This commit is contained in:
Patrick von Reth 2014-01-13 11:20:26 +01:00
parent 19a89f9e47
commit cbe10a3619
1 changed files with 2 additions and 2 deletions

View File

@ -56,7 +56,7 @@ bool SnarlNetworkFrontend::init(SnoreCore *snore){
void SnarlNetworkFrontend::actionInvoked(Notification notification)
{
//TODO:fix callback
if(notifications.contains(notification.id()))
if(notification.source() == this)
{
SnarlNotification sn=notifications.value(notification.id());
if(notification.actionInvoked().id() == 1 )
@ -71,7 +71,7 @@ void SnarlNetworkFrontend::actionInvoked(Notification notification)
}
void SnarlNetworkFrontend::notificationClosed(Notification notification)
{
if(notifications.contains(notification.id()))
if(notification.source() == this)
{
SnarlNotification sn=notifications.value(notification.id());
if(notification.closeReason() == NotificationEnums::CloseReasons::TIMED_OUT)