2 This file is part of the KDE reminder agent.
4 Copyright (c) 2003 Cornelius Schumacher <schumacher@kde.org>
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License along
17 with this program; if not, write to the Free Software Foundation, Inc.,
18 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
20 As a special exception, permission is given to link this program
21 with any edition of Qt, and distribute the resulting executable,
22 without including the source code for Qt in the source distribution.
25 #include "koalarmclient.h"
26 #include "kdepim-version.h"
29 #include <KCmdLineArgs>
30 #include <KUniqueApplication>
34 #ifdef SERIALIZER_PLUGIN_STATIC
37 Q_IMPORT_PLUGIN(akonadi_serializer_kcalcore
)
40 class ReminderDaemonApp
: public KUniqueApplication
43 ReminderDaemonApp() : mClient( 0 )
45 // ensure the Quit dialog's Cancel response does not close the app
46 setQuitOnLastWindowClosed( false );
51 // Check if we already have a running alarm daemon widget
56 mClient
= new KOAlarmClient
;
62 KOAlarmClient
*mClient
;
65 static const char korgacVersion
[] = KDEPIM_VERSION
;
67 int main( int argc
, char **argv
)
69 KAboutData
aboutData( "korgac", QByteArray(), ki18n( "KOrganizer Reminder Daemon" ),
70 korgacVersion
, ki18n( "KOrganizer Reminder Daemon" ),
71 KAboutData::License_GPL
,
72 ki18n( "(c) 2003 Cornelius Schumacher" ),
73 KLocalizedString(), "http://pim.kde.org" );
74 aboutData
.addAuthor( ki18n( "Cornelius Schumacher" ), ki18n( "Former Maintainer" ),
75 "schumacher@kde.org" );
76 aboutData
.addAuthor( ki18n( "Reinhold Kainhofer" ), ki18n ( "Former Maintainer" ),
77 "kainhofer@kde.org" );
78 aboutData
.addAuthor( ki18n( "Allen Winter" ),ki18n( "Janitorial Staff" ),
81 KCmdLineArgs::init( argc
, argv
, &aboutData
);
83 KCmdLineOptions options
;
84 KCmdLineArgs::addCmdLineOptions( options
);
85 KUniqueApplication::addCmdLineOptions();
87 if ( !ReminderDaemonApp::start() ) {
91 ReminderDaemonApp app
;
92 app
.disableSessionManagement();