• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepimlibs API Reference
  • KDE Home
  • Contact Us
 

akonadi

  • sources
  • kde-4.12
  • kdepimlibs
  • akonadi
notificationsource.cpp
1 /*
2  * Copyright (C) 2013 Daniel Vrátil <dvratil@redhat.com>
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation; either version 2 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License along
15  * with this program; if not, write to the Free Software Foundation, Inc.,
16  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
17  *
18  */
19 
20 #include "notificationsource_p.h"
21 
22 using namespace Akonadi;
23 
24 NotificationSource::NotificationSource( QObject *source ):
25  QObject( source )
26 {
27  Q_ASSERT( source );
28 
29  connect( source, SIGNAL(notifyV2(Akonadi::NotificationMessageV2::List)),
30  this, SIGNAL(notifyV2(Akonadi::NotificationMessageV2::List)) );
31 }
32 
33 NotificationSource::~NotificationSource()
34 {
35 }
36 
37 void NotificationSource::setAllMonitored( bool allMonitored )
38 {
39  const bool ok = QMetaObject::invokeMethod( parent(), "setAllMonitored",
40  Q_ARG( bool, allMonitored ) );
41  Q_ASSERT( ok );
42  Q_UNUSED( ok );
43 }
44 
45 void NotificationSource::setMonitoredCollection( Entity::Id id, bool monitored )
46 {
47  const bool ok = QMetaObject::invokeMethod( parent(), "setMonitoredCollection",
48  Q_ARG( qlonglong, id ),
49  Q_ARG( bool, monitored ) );
50  Q_ASSERT( ok );
51  Q_UNUSED( ok );
52 }
53 
54 void NotificationSource::setMonitoredItem( Entity::Id id, bool monitored )
55 {
56  const bool ok = QMetaObject::invokeMethod( parent(), "setMonitoredItem",
57  Q_ARG( qlonglong, id ),
58  Q_ARG( bool, monitored ) );
59  Q_ASSERT( ok );
60  Q_UNUSED( ok );
61 }
62 
63 void NotificationSource::setMonitoredResource( const QByteArray &resource, bool monitored )
64 {
65  const bool ok = QMetaObject::invokeMethod( parent(), "setMonitoredResource",
66  Q_ARG( QByteArray, resource ),
67  Q_ARG( bool, monitored ) );
68  Q_ASSERT( ok );
69  Q_UNUSED( ok );
70 }
71 
72 void NotificationSource::setMonitoredMimeType( const QString &mimeType, bool monitored )
73 {
74  const bool ok = QMetaObject::invokeMethod( parent(), "setMonitoredMimeType",
75  Q_ARG( QString, mimeType ),
76  Q_ARG( bool, monitored ) );
77  Q_ASSERT( ok );
78  Q_UNUSED( ok );
79 }
80 
81 void NotificationSource::setIgnoredSession( const QByteArray &session, bool ignored )
82 {
83  const bool ok = QMetaObject::invokeMethod( parent(), "setIgnoredSession",
84  Q_ARG( QByteArray, session ),
85  Q_ARG( bool, ignored ) );
86  Q_ASSERT( ok );
87  Q_UNUSED( ok );
88 }
89 
90 QObject* NotificationSource::source() const
91 {
92  return parent();
93 }
Akonadi::Entity::Id
qint64 Id
Describes the unique id type.
Definition: entity.h:65
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:00:27 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

akonadi

Skip menu "akonadi"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • Modules
  • Related Pages

kdepimlibs API Reference

Skip menu "kdepimlibs API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kldap
  • kmbox
  • kmime
  • kpimidentities
  • kpimtextedit
  • kresources
  • ktnef
  • kxmlrpcclient
  • microblog

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal