1959.1.18
by Rolf Eike Beer
bump version number for KDE SC 4.8.1 |
1 |
/*
|
2 |
* Copyright (C) 2002 Jean-Baptiste Mardelle <bj@altern.org>
|
|
3 |
* Copyright (C) 2007,2008,2009,2010,2011,2012
|
|
4 |
* Rolf Eike Beer <kde@opensource.sf-tec.de>
|
|
5 |
*/
|
|
155
by Jean-Baptiste Mardelle
reformatted source files, added option to disable question box on kgpg exit, fixed shredding,... |
6 |
|
7 |
/***************************************************************************
|
|
8 |
* *
|
|
9 |
* This program is free software; you can redistribute it and/or modify *
|
|
10 |
* it under the terms of the GNU General Public License as published by *
|
|
11 |
* the Free Software Foundation; either version 2 of the License, or *
|
|
12 |
* (at your option) any later version. *
|
|
13 |
* *
|
|
14 |
***************************************************************************/
|
|
117
by Jean-Baptiste Mardelle
major rewrite. merged kgpgapplet with kgpg. |
15 |
|
867
by Laurent Montel
Remove not necessary include |
16 |
|
117
by Jean-Baptiste Mardelle
major rewrite. merged kgpgapplet with kgpg. |
17 |
|
877
by Urs Wolfer
Work by Lukas Kropatschek: |
18 |
#include <KUniqueApplication> |
19 |
#include <KCmdLineArgs> |
|
20 |
#include <KAboutData> |
|
21 |
#include <KLocale> |
|
602
by Jimmy Gilles
Upgrating to KDE4 and QT4. Creation of a new class KgpgKey, and other things |
22 |
|
1
by Jean-Baptiste Mardelle
imported sources |
23 |
#include "kgpg.h" |
24 |
||
417
by Andy Goossens
CVS_SILENT |
25 |
static const char description[] = |
920
by Rolf Eike Beer
Kgpg -> KGpg in user visible strings |
26 |
I18N_NOOP("KGpg - simple gui for gpg\n\nKGpg was designed to make gpg very easy to use.\nI tried to make it as secure as possible.\nHope you enjoy it."); |
117
by Jean-Baptiste Mardelle
major rewrite. merged kgpgapplet with kgpg. |
27 |
|
1960
by Rolf Eike Beer
bump version number for post-4.8 |
28 |
static const char version[] = "2.7.60"; |
1
by Jean-Baptiste Mardelle
imported sources |
29 |
|
153
by Jean-Baptiste Mardelle
start implementing multi-file operation (multi encryption now works) |
30 |
int main(int argc, char *argv[]) |
1
by Jean-Baptiste Mardelle
imported sources |
31 |
{
|
1368
by Friedrich W. H. Kossebau
Updating the version number and adding link to homepage on utils.kde.org |
32 |
KAboutData about("kgpg", 0, ki18n("KGpg"), version, ki18n(description), KAboutData::License_GPL, ki18n("(C) 2003 Jean-Baptiste Mardelle"), KLocalizedString(), "http://utils.kde.org/projects/kgpg"); |
1291
by Rolf Eike Beer
improve role description of bj |
33 |
about.addAuthor(ki18n("Jean-Baptiste Mardelle"), ki18n("Author and former maintainer"), "bj@altern.org"); |
907
by Chusslove Illich
Auto-conversion to new KCmdLineArgs/KAboutData/KComponentData API (trunk/KDE). Watch for the few remaining QString to QByteArray assignments that will not compile without extra specification (typically needs .toLocal8Bit() or .toUtf8()). |
34 |
about.addAuthor(ki18n("Jimmy Gilles"), KLocalizedString(), "jimmygilles@gmail.com"); |
1287
by Rolf Eike Beer
add role description for KGpg authors |
35 |
about.addAuthor(ki18n("Rolf Eike Beer"), ki18n("Maintainer"), "kde@opensource.sf-tec.de"); |
602
by Jimmy Gilles
Upgrating to KDE4 and QT4. Creation of a new class KgpgKey, and other things |
36 |
|
37 |
KCmdLineArgs::init(argc, argv, &about); |
|
907
by Chusslove Illich
Auto-conversion to new KCmdLineArgs/KAboutData/KComponentData API (trunk/KDE). Watch for the few remaining QString to QByteArray assignments that will not compile without extra specification (typically needs .toLocal8Bit() or .toUtf8()). |
38 |
|
39 |
KCmdLineOptions options; |
|
40 |
options.add("e", ki18n("Encrypt file")); |
|
41 |
options.add("k", ki18n("Open key manager")); |
|
1012
by Rolf Eike Beer
Allow opening editor directly from command line |
42 |
options.add("d", ki18n("Open editor")); |
907
by Chusslove Illich
Auto-conversion to new KCmdLineArgs/KAboutData/KComponentData API (trunk/KDE). Watch for the few remaining QString to QByteArray assignments that will not compile without extra specification (typically needs .toLocal8Bit() or .toUtf8()). |
43 |
options.add("s", ki18n("Show encrypted file")); |
1799
by Rolf Eike Beer
remove a string that differs only by case from the other one |
44 |
options.add("S", ki18n("Sign File")); |
907
by Chusslove Illich
Auto-conversion to new KCmdLineArgs/KAboutData/KComponentData API (trunk/KDE). Watch for the few remaining QString to QByteArray assignments that will not compile without extra specification (typically needs .toLocal8Bit() or .toUtf8()). |
45 |
options.add("V", ki18n("Verify signature")); |
46 |
options.add("+[File]", ki18n("File to open")); |
|
602
by Jimmy Gilles
Upgrating to KDE4 and QT4. Creation of a new class KgpgKey, and other things |
47 |
KCmdLineArgs::addCmdLineOptions(options); |
48 |
KUniqueApplication::addCmdLineOptions(); |
|
49 |
||
50 |
if (!KUniqueApplication::start()) |
|
51 |
return 0; |
|
52 |
||
1548
by Rolf Eike Beer
port KGpg to the new systray framework |
53 |
KApplication *app = new KGpgApp(); |
1371
by Rolf Eike Beer
improve "minimize to tray on window close" |
54 |
app->setQuitOnLastWindowClosed(false); |
602
by Jimmy Gilles
Upgrating to KDE4 and QT4. Creation of a new class KgpgKey, and other things |
55 |
return app->exec(); |
9
by Jean-Baptiste Mardelle
code cleanup, moving all encryption functions into kgpginterface.h /.cpp for easy reuse by other programs. fixed bug with filenames containing whitespaces. key manager can now be used as a standalone app. |
56 |
}
|